← Back to team overview

yade-users team mailing list archive

Re: 3d view output

 


Dear Vaclav,
I know how to solve the problem now. I just need to reset scene center to median body position by press the Key combination: ALT + C. I wonder if we can make some modifications to the scripts to let the view set the scene center automatically?
I think it would be reasonable to center the scene using the median centring by default, rather than the dumb scene bounding box method (unless someone has a plausible objection), I will fix that in a few days.
What's more, I also want to know how to zoom the view automatically by adding some codes in GLViewer.cpp file? For instance, I want my model always be shown in the same size as the view.
Hi Tao, there is a functionality to save & load the 3d view configuration (using the keys Alt-7,8,9 and 7,8,9 to save/load, and Alt-S to save to file I think), and one can also handle that from scripts. They key is to understand that the GL rendering happens in 2 places, one is qt.OpenGLRenderer, the other one is qt.GLViewer (which you can retrive by calling qt.views()[0] IIRC). I will write you a proper answer tomorrow, you can have a look in docs for now.

Cheers, Vaclav



Follow ups

References