How to use translation in opencascade... Thank for u help...

Gamerz's picture

I mean translation using mouse movement..

Davide Canalia's picture

do you mean panning the view or moving the object?

Gamerz's picture

moving the object!!... Because i can't get screen ratio... so my object move faster than my mouse movement...

ziyoo's picture

get screen ratio using gluProject and gluUnProject

Davide Canalia's picture

Have you tried using the Convert method to get the mouse position in world coordinates and working with that value?

I do the same and i have any problem...But maybe i don't understand your problem.

Gamerz's picture

i use manual convert method from mouse position to world coordinat, but i can't find perfect ratio between mouse movement and world coordinat...
do you know how to convert it using opencascade??...
i stiil use ziyoo sugestion but still not working well...

Svetlozar Kostadinov's picture

We use V3d_View::Convert() and it works fine.