Closed vitalii-p closed 7 months ago
Hi, you can setup the camera more simply by passing a dictionary:
###################################################
## Template python code to position this camera: ##
cam = dict(
position=(44.1916, -32.0029, 19.2009),
focal_point=(-1.21754, 9.83238e-4, -2.27213e-4),
viewup=(0, 0, 1.00000),
roll=-77.0346,
distance=58.7786,
clipping_range=(21.9889, 105.231),
)
show(mymeshes, camera=cam)
You get this template code by pressing Shift-C
in the rendering window.
Also - if you change some settings you should call plotter.render()
to update the scene.
About the second problem - i cannot help without a specific reproducible example. In vedo 5.0 there is a better management of transformations so I hope you should now get the correct behavior.
Thanks a lot, @marcomusy ! You saved my day, your approach with dict definitely works!
I tried to set camera parameters for triangular mesh rendering, but seems like those parameters don't affect the output image. Here is my code for setting up the camera
Then I call
Despite of changing SetPosition or SetFocalPoint - output image is still the same.
Currently I use vedo==2023.4.6, tried with 2023.5.0 - issue with the camera remains, but in addition I got wrong transformations when applied the same matrices via
mesh.apply_transform
.Could you help me with camera setup? Thanks in advance!