Tramway SDK
vertices.h
Go to the documentation of this file.
1// TRAMWAY DRIFT AND DUNGEON EXPLORATION SIMULATOR 2022
2// All rights reserved.
3
4#ifndef TRAM_SDK_RENDER_VERTICES_H
5#define TRAM_SDK_RENDER_VERTICES_H
6
7#include <render/renderer.h>
8
9#include <render/render.h>
10
11namespace tram::Render {
12
14 vec3 co; //< Vertex position in object space.
15 vec3 normal; //< Vertex normal vector.
16 vec2 tex; //< Vertex texture coordinates.
17 vec2 lighttex; //< Vertex lightmap coordinates.
18 uint32_t texture; //< Vertex texture material index.
19};
20
22 vec3 co; //< Vertex position in object space.
23 vec3 normal; //< Vertex normal vector.
24 vec2 tex; //< Vertex texture coordinates.
25 ivec4 bone; //< Vertex bone indices.
26 vec4 boneweight; //< Vertex bone weights.
27 uint32_t texture; //< Vertex texture material index.
28};
29
31 vec3 co; //< Sprite position in object space.
32 vec2 voffset; //< Vertex offset in projection space.
33 vec2 texco; //< Vertex texture coordinates.
34 vec3 color; //< Vertex color.
35 float verticality; //< I don't remember.
36 uint32_t texture; //< Vertex texture material index.
37};
38
39struct LineVertex {
40 vec3 co; //< Vertex position in object space.
41 vec3 color; //< Vertex color.
42};
43
44struct Triangle {
45 ivec3 indices; //< Triangle vertex indices.
46};
47
48struct ModelData {};
49
50struct StaticModelData : public ModelData {
51 std::vector<StaticModelVertex> vertices;
52 std::vector<Triangle> indices;
53};
54
55struct DynamicModelData : public ModelData {
56 std::vector<DynamicModelVertex> vertices;
57 std::vector<Triangle> indices;
58 std::vector<UID> groups;
59};
60
61}
62
63#endif // TRAM_SDK_RENDER_VERTICES_H
Definition: gui.h:9
glm::ivec4 ivec4
Definition: math.h:19
glm::vec4 vec4
Definition: math.h:16
glm::vec2 vec2
Definition: math.h:17
glm::ivec3 ivec3
Definition: math.h:18
glm::vec3 vec3
Definition: math.h:12
Definition: renderer.cpp:456
Definition: vertices.h:55
std::vector< Triangle > indices
Definition: vertices.h:57
std::vector< DynamicModelVertex > vertices
Definition: vertices.h:56
std::vector< UID > groups
Definition: vertices.h:58
Definition: vertices.h:21
ivec4 bone
Definition: vertices.h:25
vec2 tex
Definition: vertices.h:24
vec4 boneweight
Definition: vertices.h:26
uint32_t texture
Definition: vertices.h:27
vec3 co
Definition: vertices.h:22
vec3 normal
Definition: vertices.h:23
vec3 co
Definition: vertices.h:40
vec3 color
Definition: vertices.h:41
Definition: vertices.h:48
Definition: vertices.h:30
vec2 voffset
Definition: vertices.h:32
float verticality
Definition: vertices.h:35
uint32_t texture
Definition: vertices.h:36
vec2 texco
Definition: vertices.h:33
vec3 co
Definition: vertices.h:31
vec3 color
Definition: vertices.h:34
Definition: vertices.h:50
std::vector< Triangle > indices
Definition: vertices.h:52
std::vector< StaticModelVertex > vertices
Definition: vertices.h:51
Definition: vertices.h:13
vec3 co
Definition: vertices.h:14
uint32_t texture
Definition: vertices.h:18
vec3 normal
Definition: vertices.h:15
vec2 lighttex
Definition: vertices.h:17
vec2 tex
Definition: vertices.h:16
Definition: vertices.h:44
ivec3 indices
Definition: vertices.h:45