Magnum::Shaders::ProjectionUniform3D struct new in Git master

3D projection uniform common for all shaders

Contains the per-view projection matrix used by the MeshVisualizerGL3D and PhongGL shaders that need a separate projection and transformation matrix.

Constructors, destructors, conversion operators

ProjectionUniform3D(DefaultInitT = DefaultInit) explicit constexpr noexcept
Construct with default parameters.
ProjectionUniform3D(NoInitT) explicit noexcept
Construct without initializing the contents.

Public variables

Matrix4 projectionMatrix
Projection matrix.

Convenience setters

Provided to allow the use of method chaining for populating a structure in a single expression, otherwise equivalent to accessing the fields directly. Also guaranteed to provide backwards compatibility when packing of the actual fields changes.

auto setProjectionMatrix(const Matrix4& matrix) -> ProjectionUniform3D&
Set the projectionMatrix field.

Function documentation

ProjectionUniform3D& Magnum::Shaders::ProjectionUniform3D::setProjectionMatrix(const Matrix4& matrix)

Set the projectionMatrix field.

Returns Reference to self (for method chaining)

Variable documentation

Matrix4 Magnum::Shaders::ProjectionUniform3D::projectionMatrix

Projection matrix.

Default value is an identity matrix (i.e., an orthographic projection of the default $ [ -\boldsymbol{1} ; \boldsymbol{1} ] $ cube).