3
\$\begingroup\$

I'm trying to compute the line intersecting my plane (transformed to NDC) and the near plane.
I have troubles to get a correct result and I think it is coming from the near plane equation.

I suppose that the equation in normalized device coordinates is \$N=(0,0,1)\$ and \$O=(0,0,near)\$.
But what is the value of \$near\$? Is it constant or it depends on the frustum?

\$\endgroup\$
3
  • \$\begingroup\$ doesn't it go from -1 to 1? I thought NDC is a box that goes from -1 to 1 on all axis \$\endgroup\$
    – Sidar
    Commented Jan 23, 2018 at 14:08
  • \$\begingroup\$ @Sidar, yes you're right. I managed to fix my issue, thanks. The equation of near plane in NDC is \$z+1=0\$ \$\endgroup\$
    – Michael M.
    Commented Jan 23, 2018 at 15:44
  • \$\begingroup\$ might want to post the answer then =P \$\endgroup\$
    – Sidar
    Commented Jan 23, 2018 at 15:59

1 Answer 1

3
\$\begingroup\$

In NDC, the clipping planes are a box that goes from -1 to 1.
Near plane equation is therefore \$Z+1=0\$ and far plane \$Z-1=0\$

\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .