1
\$\begingroup\$

I dont understand for what i need the inverse of the perspective Matrix in Computer Graphics and how do i calculate it?Maybe someone has an explanation for me.

\$\endgroup\$
  • 4
    \$\begingroup\$ Could you add a bit more to the context? It's not clear what you need. \$\endgroup\$ – Vaillancourt Dec 8 '15 at 17:22
  • 1
    \$\begingroup\$ just about any matrix math library worth it salt will have an inverse operation. \$\endgroup\$ – ratchet freak Dec 8 '15 at 19:20
  • 1
    \$\begingroup\$ If you don't need it, why do you want to calculate it? \$\endgroup\$ – Nicol Bolas Dec 8 '15 at 19:54
  • \$\begingroup\$ @ratchetfreak right. but it's not the only thing there is to it. one needs not to forget the division by w stage, which is a bit tricky to invert, you need to choose an arbitrary w because it gets "lost in projection". and then multiply with the inverse matrix. \$\endgroup\$ – v.oddou Dec 9 '15 at 0:49
4
\$\begingroup\$

The inverse projection matrix can be used for mouse/ray picking (letting you click an object in the world)

For more info: How do you determine which object/surface the user's pointing at with lwjgl?

\$\endgroup\$
3
\$\begingroup\$

An inverse projection matrix is used to invert coordinates from the projected space to either world or local space, i.e. You can use the inverse projection matrix to find out where a pixel is in relation to game objects.

This can be extremly useful for postprocessing effects like deferred rendering.

Calculating it can be a bit tricky and requires knowledge in linear algebra, if you have an API handy I suggest using it. Or google around for a while.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.