Matrix4d.setPerspectiveOffCenter
- Matrix4d setPerspectiveOffCenter(double fovy, double offAngleX, double offAngleY, double aspect, double zNear, double zFar)
struct Matrix4d
ref return
setPerspectiveOffCenter
- Matrix4d setPerspectiveOffCenter(double fovy, double offAngleX, double offAngleY, double aspect, double zNear, double zFar, bool zZeroToOne)
matrix_4d Matrix4d
constructorsfunctionsstatic variablesvariables
Set this matrix to be an asymmetric off-center perspective projection frustum transformation for a right-handed coordinate system using OpenGL's NDC z range of <code>[-1..+1]</code>. <p> The given angles <code>offAngleX</code> and <code>offAngleY</code> are the horizontal and vertical angles between the line of sight and the line given by the center of the near and far frustum planes. So, when <code>offAngleY</code> is just <code>fovy/2</code> then the projection frustum is rotated towards +Y and the bottom frustum plane is parallel to the XZ-plane. <p> In order to apply the perspective projection transformation to an existing transformation, use {@link #perspectiveOffCenter(double, double, double, double, double, double) perspectiveOffCenter()}.
@see #perspectiveOffCenter(double, double, double, double, double, double)
@param fovy the vertical field of view in radians (must be greater than zero and less than {@link Math#PI PI}) @param offAngleX the horizontal angle between the line of sight and the line crossing the center of the near and far frustum planes @param offAngleY the vertical angle between the line of sight and the line crossing the center of the near and far frustum planes @param aspect the aspect ratio (i.e. width / height; must be greater than zero) @param zNear near clipping plane distance. This value must be greater than zero. If the special value {@link Double#POSITIVE_INFINITY} is used, the near clipping plane will be at positive infinity. In that case, <code>zFar</code> may not also be {@link Double#POSITIVE_INFINITY}. @param zFar far clipping plane distance. This value must be greater than zero. If the special value {@link Double#POSITIVE_INFINITY} is used, the far clipping plane will be at positive infinity. In that case, <code>zNear</code> may not also be {@link Double#POSITIVE_INFINITY}. @return this