1 #ifndef MSP_GL_REFLECTDATA_H_
2 #define MSP_GL_REFLECTDATA_H_
13 Reflection data for shader programs.
21 UNIFORM_BLOCK_BINDING = 0,
22 TEXTURE_BINDING = 0x1000000
25 typedef unsigned LayoutHash;
26 struct UniformBlockInfo;
31 const UniformBlockInfo *block = 0;
37 unsigned array_size = 0;
38 unsigned array_stride = 0;
39 unsigned matrix_stride = 0;
45 struct UniformBlockInfo
48 unsigned data_size = 0;
49 int bind_point = DEFAULT_BLOCK;
50 std::vector<const UniformInfo *> uniforms;
51 LayoutHash layout_hash = 0;
54 void update_layout_hash();
61 unsigned array_size = 0;
65 std::vector<UniformBlockInfo> uniform_blocks;
66 std::vector<UniformInfo> uniforms;
67 LayoutHash layout_hash = 0;
68 std::vector<AttributeInfo> attributes;
69 unsigned n_clip_distances = 0;
70 unsigned n_descriptor_sets = 0;
71 std::vector<int> used_bindings;
73 void update_layout_hash();
74 void update_used_bindings();