未验证 提交 946b8d23 编写于 作者: M Michael Herzog 提交者: GitHub

Merge pull request #17648 from etpeterson/VolumeShader-object-position

Object orientation added to VolumeShader clipping
......@@ -67,8 +67,8 @@ THREE.VolumeRenderShader1 = {
" void main() {",
// Prepare transforms to map to "camera view". See also:
// https://threejs.org/docs/#api/renderers/webgl/WebGLProgram
" mat4 viewtransformf = viewMatrix;",
" mat4 viewtransformi = inversemat(viewMatrix);",
" mat4 viewtransformf = modelViewMatrix;",
" mat4 viewtransformi = inversemat(modelViewMatrix);",
// Project local vertex coordinate to camera position. Then do a step
// backward (in cam coords) to the near clipping plane, and project back. Do
......
......@@ -72,8 +72,8 @@ var VolumeRenderShader1 = {
" void main() {",
// Prepare transforms to map to "camera view". See also:
// https://threejs.org/docs/#api/renderers/webgl/WebGLProgram
" mat4 viewtransformf = viewMatrix;",
" mat4 viewtransformi = inversemat(viewMatrix);",
" mat4 viewtransformf = modelViewMatrix;",
" mat4 viewtransformi = inversemat(modelViewMatrix);",
// Project local vertex coordinate to camera position. Then do a step
// backward (in cam coords) to the near clipping plane, and project back. Do
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册