Transforming a camera.toworld with the initial value. #1002
-
Hi. I'm facing a problem in rendering from multiple view points.
And I would like to get the parameters and rotate them, then return it with a new value in mi.load_dict.
But it seems that I can get no changes from the function. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Hi @Whisper-MMM , I'm not 100% sure if this is what you're after, but from what I can piece together you want something like: scene = mi.load_dict(...)
params = mi.traverse(scene)
origin = params['PerspectiveCamera.to_world']
rotation = origin.rotate([0.0, 1.0, 0.0], theta)
# Then you want to update the scene?
params['PerspectiveCamera.to_world'] = rotation
params.update() Regardless, there's a really good tutorial Rendering from multiple view points that shows you how to initialise your multiple sensors independent of the scene which might a better approach anyway. |
Beta Was this translation helpful? Give feedback.
Oh, I think I know what's going on. Please try
rotate
here is a static method which is why it's returning just the transformation and not transformation applied toorigin