|
GREM 3.12.0
Game/Rendering Engine Modules for C++
|
Configuration of an arbitrarily transformed 2D triangle instance, optionally textured, to draw. More...
#include <GREM/graphics_2d/Instances2D.hpp>
Public Attributes | |
| const Texture * | texture = nullptr |
| Non-owning pointer to a texture to apply to the triangle, or nullptr to use a fully white texture. | |
| vec2 | pointA {0.0f, 0.0f} |
| Position, in world coordinates, of the first vertex of the triangle to draw. | |
| vec2 | pointB {1.0f, 0.0f} |
| Position, in world coordinates, of the second vertex of the triangle to draw. | |
| vec2 | pointC {0.0f, 1.0f} |
| Position, in world coordinates, of the third vertex of the triangle to draw. | |
| vec2 | textureOffset {0.0f, 0.0f} |
| Offset, in texture coordinates, to apply to the texture coordinates before sampling the texture. | |
| mat2 | textureBasis {1.0f} |
| Texture coordinate basis to scale/rotate/shear the texture coordinates by before sampling the texture. | |
| Color | color = Color::WHITE |
| Tint color to use in the shader. | |
| Color | emissiveColor = Color::INVISIBLE |
| Emissive color to use in the shader. | |
Configuration of an arbitrarily transformed 2D triangle instance, optionally textured, to draw.
| const Texture* grem::graphics::TriangleInstance2D::texture = nullptr |
Non-owning pointer to a texture to apply to the triangle, or nullptr to use a fully white texture.
| vec2 grem::graphics::TriangleInstance2D::pointA {0.0f, 0.0f} |
Position, in world coordinates, of the first vertex of the triangle to draw.
| vec2 grem::graphics::TriangleInstance2D::pointB {1.0f, 0.0f} |
Position, in world coordinates, of the second vertex of the triangle to draw.
| vec2 grem::graphics::TriangleInstance2D::pointC {0.0f, 1.0f} |
Position, in world coordinates, of the third vertex of the triangle to draw.
| vec2 grem::graphics::TriangleInstance2D::textureOffset {0.0f, 0.0f} |
Offset, in texture coordinates, to apply to the texture coordinates before sampling the texture.
| mat2 grem::graphics::TriangleInstance2D::textureBasis {1.0f} |
Texture coordinate basis to scale/rotate/shear the texture coordinates by before sampling the texture.
| Color grem::graphics::TriangleInstance2D::color = Color::WHITE |
Tint color to use in the shader.
When no texture is specified, this effectively controls the base color of the triangle.
| Color grem::graphics::TriangleInstance2D::emissiveColor = Color::INVISIBLE |
Emissive color to use in the shader.