Matrix.CreatePerspective Method (Microsoft.Xna.Framework)
Creates a new projection Matrix for perspective view.
- C#
- VB
- F#
public static Matrix CreatePerspective( float width, float height, float nearPlaneDistance, float farPlaneDistance )
Syntax for VB is not yet implemented.
Syntax for F# is not yet implemented.
Parameters
- width
-
Type: System.Single
Width of the viewing volume.
- height
-
Type: System.Single
Height of the viewing volume.
- nearPlaneDistance
-
Type: System.Single
Distance to the near plane.
- farPlaneDistance
-
Type: System.Single
Distance to the far plane.
Return Value
Type: Microsoft.Xna.Framework.MatrixThe new projection Matrix for perspective view.
Supported in:
Windows DirectX Desktop
Linux Desktop
Windows OpenGL Desktop
Web
Windows DirectX Desktop
Linux Desktop
Windows OpenGL Desktop
Web