Carna Version 3.3.3
Loading...
Searching...
No Matches
VertexAttributes.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2010 - 2015 Leonid Kostrykin
3 *
4 * Chair of Medical Engineering (mediTEC)
5 * RWTH Aachen University
6 * Pauwelsstr. 20
7 * 52074 Aachen
8 * Germany
9 *
10 */
11
12#ifndef VERTEXATTRIBUTES_H_6014714286
13#define VERTEXATTRIBUTES_H_6014714286
14
15#include <Carna/Carna.h>
16#include <vector>
17
22namespace Carna
23{
24
25namespace base
26{
27
28
29
30// ----------------------------------------------------------------------------------
31// VertexAttributes
32// ----------------------------------------------------------------------------------
33
41{
42
46 const static unsigned int TYPE_FLOAT;
47
51 const static unsigned int TYPE_INT;
52
56 const static unsigned int TYPE_UINT;
57
60 std::size_t position;
61
65 std::size_t componentsCount;
66
71 unsigned int type;
72
88 VertexAttribute( std::size_t position, std::size_t componentsCount, unsigned int type )
91 , type( type )
92 {
93 }
94
95}; // VertexAttribute
96
97
101typedef std::vector< VertexAttribute > VertexAttributes;
102
103
104
105} // namespace Carna :: base
106
107} // namespace Carna
108
109#endif // VERTEXATTRIBUTES_H_6014714286
std::vector< VertexAttribute > VertexAttributes
Defines VertexAttribute vector.
Declares a vertex attribute.
static const unsigned int TYPE_INT
Indicates vertex attribute of GL_INT type.
VertexAttribute(std::size_t position, std::size_t componentsCount, unsigned int type)
static const unsigned int TYPE_UINT
Indicates vertex attribute of GL_UNSIGNED_INT type.
static const unsigned int TYPE_FLOAT
Indicates vertex attribute of GL_FLOAT type.