cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

The PTC Community email address has changed to community-mailer@ptc.com. Learn more.

OpenGL matrices for manual rendering

0 Kudos

OpenGL matrices for manual rendering

Hello!

 

ProTookit provides 2 matrices (retrieved with ProViewMatrixGet and ProWindowCurrentMatrixGet) which describe model projection from 3D model coordinates to graphics window. These matrices are some abstraction and cannot be explicitly used to set up OpenGL matrices. 

In case user addin needs to render additional custom graphics, which shared the same 3D model space, one have to figure out in all the details how transformations Solid CS -> Screen CS -> Window CS -> window pixels are designed behind the scenes. This is actuall gettign harder with perspective projection.

 

There are 3 suggested ideas:

  • either provide more detailed information about how API matricies can be used to produce OpenGL matrices,
  • or, provide new API functions to generate OpenGL matrices,
  • or, (as most CADs actually do) setup OpenGL matrices when rendering events are sent to toolkit users.

Thank you in advance!