CeresEngine 0.2.0
A game development framework
Loading...
Searching...
No Matches
GLStateManager.hpp
Go to the documentation of this file.
1//
2// CeresEngine - A game development framework
3//
4// Created by Rogiel Sulzbach.
5// Copyright (c) 2018-2022 Rogiel Sulzbach. All rights reserved.
6//
7
8#pragma once
9
10#include "OpenGL.hpp"
11
13
16
17#include <array>
18#include <functional>
19#include <optional>
20
21namespace CeresEngine {
22
27 template<typename Setter> struct GLGlobalState;
28
29 template<typename T, typename... Ts> GLGlobalState(void (*const&)(T, Ts...)) -> GLGlobalState<void (*)(T, Ts...)>;
30
36 template<typename T, typename... Ts> struct GLGlobalState<void (*)(T, Ts...)> final {
38 using Setter = void (*)(T, Ts...);
39
41 using Value = std::conditional_t<sizeof...(Ts) == 0, T, Tuple<T, Ts...>>;
42
44 const Setter* setter;
45
47 std::optional<Value> current;
48
52 const Setter& setter) noexcept
53 : setter(&setter) {}
54
58 inline GLGlobalState& operator=(Value value) {
59 if(current == value) {
60 return *this;
61 }
62
63 if constexpr(sizeof...(Ts) == 0) {
64 (*setter)(value);
65 } else {
66 value.apply(*setter);
67 }
68 current = value;
69 GLThrowIfFailed("setting GLGlobalState");
70
71 return *this;
72 }
73
76 CE_EXPLICIT(false) inline operator Value() const { // NOLINT
77 return *current;
78 }
79
82 inline explicit operator bool() const { return *setter != nullptr && **setter != nullptr; }
83 };
84
90 template<typename T, typename... Ts> struct GLGlobalState<void(T, Ts...)> final {
92 using Setter = void (*)(T, Ts...);
93
95 using Value = std::conditional_t<sizeof...(Ts) == 0, T, Tuple<T, Ts...>>;
96
99
101 std::optional<Value> current;
102
106 : setter(setter) {}
107
108 // /// Creates a new `GLGlobalState` object.
109 // /// \param setter The setter function
110 // template<typename F>
111 // inline GLGlobalState(F setter) noexcept //
112 // NOLINT(google-explicit-constructor,hicpp-explicit-conversions)
113 // : setter(setter) {}
114
119 if(current == value) {
120 return *this;
121 }
122
123 if constexpr(sizeof...(Ts) == 0) {
124 setter(value);
125 } else {
126 std::apply(setter, value);
127 }
128 current = value;
129 GLThrowIfFailed("setting GLGlobalState");
130
131 return *this;
132 }
133
136 CE_EXPLICIT(false) inline operator Value() const { // NOLINT
137 return *current;
138 }
139
142 inline explicit operator bool() const { return *setter != nullptr && **setter != nullptr; }
143 };
144
152 template<template<typename> class F, typename T, typename... Ts> struct GLGlobalState<F<void(T, Ts...)>> final {
154 using Setter = F<void(T, Ts...)>;
155
157 using Value = std::conditional_t<sizeof...(Ts) == 0, T, Tuple<T, Ts...>>;
158
161
163 std::optional<Value> current;
164
167 CE_EXPLICIT(false) GLGlobalState(Setter&& setter) noexcept // NOLINT
168 : setter(std::forward<decltype(setter)>(setter)) {}
169
174 if(current == value) {
175 return *this;
176 }
177
178 if constexpr(sizeof...(Ts) == 0) {
179 setter(value);
180 } else {
181 std::apply(setter, value);
182 }
183 current = value;
184 GLThrowIfFailed("setting GLGlobalState");
185
186 return *this;
187 }
188
191 CE_EXPLICIT(false) inline operator Value() const { // NOLINT
192 return *current;
193 }
194
197 inline explicit operator bool() const { return setter != nullptr; }
198 };
199
200 template<typename I, typename Setter, size_t N> struct GLGlobalStateCollection;
201
208 template<typename I, typename T, typename... Ts, size_t N> struct GLGlobalStateCollection<I, void(T, Ts...), N> final {
209 using Index = I;
210
212 using Setter = void (*)(I, T, Ts...);
213
215 using Value = std::conditional_t<sizeof...(Ts) == 0, T, Tuple<T, Ts...>>;
216
219
222
223 struct Entry {
226
229
231 std::optional<Value>& current;
232
237 CE_EXPLICIT(false) inline Entry( // NOLINT
238 Index index, const Setter setter, std::optional<Value>& current) noexcept
239 : index(index), setter(setter), current(current) {}
240
244 inline Entry& operator=(Value value) {
245 if(current == value) {
246 return *this;
247 }
248
249 if constexpr(sizeof...(Ts) == 0) {
250 setter(index, value);
251 } else {
252 value.apply([&](auto... args) { setter(index, args...); });
253 }
254 current = value;
255 GLThrowIfFailed("setting GLGlobalState");
256
257 return *this;
258 }
259
262 CE_EXPLICIT(false) inline operator Value() const { // NOLINT
263 return *current;
264 }
265
268 inline explicit operator bool() const { return setter != nullptr; }
269 };
270
274 : setter(setter) {}
275
278 template<typename F>
280 : setter(setter) {}
281
282 Entry operator[](Index index) { return Entry(index, setter, current[index]); }
283 };
284
285 // ---------------------------------------------------------------------------------------------
286
287 template<typename O, typename Setter> struct GLObjectState;
288
289 template<typename Object, typename T> struct GLObjectState<Object, void(T)> final {
291 using Setter = void (*)(Object, T);
292
295
298
300 std::optional<T> current;
301
302 inline GLObjectState(const Object object, const Setter setter) : object(object), setter(setter) {}
303
307 inline GLObjectState& operator=(T value) {
308 if(current == value) {
309 return *this;
310 }
311
312 setter(object, value);
313 current = value;
314
315 GLThrowIfFailed("setting GLObjectState");
316
317 return *this;
318 }
319
322 CE_EXPLICIT(false) inline operator T() const { // NOLINT
323 return *current;
324 }
325 };
326
327 // ---------------------------------------------------------------------------------------------
328
335
338
346
350 inline GLCapability& operator=(const bool state) {
351 if(current == state) {
352 return *this;
353 }
354
355 if(state) {
357 } else {
359 }
360 GLThrowIfFailed("setting GLCapability");
361
362 current = state;
363 return *this;
364 }
365
368 CE_EXPLICIT(false) inline operator bool() const { // NOLINT
369 return current;
370 }
371 };
372
373 // ---------------------------------------------------------------------------------------------
374
375 template<auto T> static inline const constexpr auto bindBuffer = +[](GLuint id) constexpr { return glBindBuffer(T, id); };
376
377 extern struct GLState final {
386
391
397
398 struct {
406
414
422
429
430 struct {
434
439
443 GLThrowIfFailed("glBindTextureUnit");
444 } else {
446 GLThrowIfFailed("glActiveTexture");
447 // bindings.texture = {
448 // GL_TEXTURE_2D,
449 // id
450 // };
451 // GLThrowIfFailed("glBindTexture");
452 }
453 };
454
470
474 glBindSampler(index, id);
475 };
476
485 const GLsizei stride) {
488 GLThrowIfFailed("glBindVertexBuffer");
489 } else {
492 }
493 };
494
495 struct {
499
503
504 struct {
508
513
517
522
526
530
534
538
542
546
551
557
558 struct {
562
570
571 struct {
577
582
589
597
606
607 struct {
611
626
644
645 struct {
649
661
665
666 struct {
671
681
694
700
709
710 struct {
719
720 struct {
727
728 struct {
734
740
747
748 struct {
752
758
764
773
779
780 struct {
784
789
800
801 struct {
808
817
823
824 struct {
829
840
845
851
855
856 struct {
861
868
875
876 struct {
882
890
898
910
911 // /// If enabled, the active fragment shader is run once for
912 // each covered
913 // /// sample, or at fraction of this rate as determined by the
914 // current
915 // /// value of GL_MIN_SAMPLE_SHADING_VALUE. See
916 // glMinSampleShading. GLCapability sampleShading =
917 // GL_SAMPLE_SHADING;
918
920
922
923} // namespace CeresEngine
#define glSampleCoverage
Definition GLLoader.hpp:3236
ptrdiff_t GLintptr
Definition GLLoader.hpp:755
#define glBlendColor
Definition GLLoader.hpp:3573
#define glDebugMessageCallback
Definition GLLoader.hpp:15924
#define GL_CLIP_DISTANCE7
Definition GLLoader.hpp:1677
#define glLogicOp
Definition GLLoader.hpp:2142
#define glClearColor
Definition GLLoader.hpp:2108
#define GL_CLIP_DISTANCE3
Definition GLLoader.hpp:1673
#define GL_TEXTURE0
Definition GLLoader.hpp:1366
#define GL_POLYGON_OFFSET_LINE
Definition GLLoader.hpp:1224
#define glCullFace
Definition GLLoader.hpp:2052
#define glBlendFuncSeparate
Definition GLLoader.hpp:3420
#define glBindBufferRange
Definition GLLoader.hpp:4074
#define GL_SAMPLE_COVERAGE
Definition GLLoader.hpp:1402
#define GL_PRIMITIVE_RESTART_FIXED_INDEX
Definition GLLoader.hpp:4929
#define GL_PROGRAM_POINT_SIZE
Definition GLLoader.hpp:1973
#define glBindBuffer
Definition GLLoader.hpp:3610
#define GL_POLYGON_OFFSET_FILL
Definition GLLoader.hpp:1225
#define glBindVertexBuffer
Definition GLLoader.hpp:11921
#define GL_COLOR_LOGIC_OP
Definition GLLoader.hpp:1221
#define glEnable
Definition GLLoader.hpp:2130
#define glPolygonOffset
Definition GLLoader.hpp:3099
#define GL_POLYGON_SMOOTH
Definition GLLoader.hpp:854
#define GL_FRAMEBUFFER_SRGB
Definition GLLoader.hpp:1868
#define glBindVertexArray
Definition GLLoader.hpp:4361
#define GL_DEPTH_TEST
Definition GLLoader.hpp:859
#define GL_STENCIL_TEST
Definition GLLoader.hpp:863
#define GL_RASTERIZER_DISCARD
Definition GLLoader.hpp:1716
#define GL_CLIP_DISTANCE5
Definition GLLoader.hpp:1675
#define GL_SAMPLE_MASK
Definition GLLoader.hpp:2011
#define glDepthFunc
Definition GLLoader.hpp:2153
#define GL_TEXTURE_CUBE_MAP_SEAMLESS
Definition GLLoader.hpp:1994
#define glScissor
Definition GLLoader.hpp:2071
#define GL_SAMPLE_ALPHA_TO_ONE
Definition GLLoader.hpp:1401
#define glBindSampler
Definition GLLoader.hpp:4538
#define glStencilOp
Definition GLLoader.hpp:2150
#define glBindTextureUnit
Definition GLLoader.hpp:9615
#define glEnableVertexAttribArray
Definition GLLoader.hpp:3699
#define GL_CLIP_DISTANCE2
Definition GLLoader.hpp:1672
#define GL_ARRAY_BUFFER
Definition GLLoader.hpp:1518
#define GL_DITHER
Definition GLLoader.hpp:873
#define glBindFramebuffer
Definition GLLoader.hpp:4293
#define GL_DRAW_FRAMEBUFFER
Definition GLLoader.hpp:1799
unsigned int GLenum
Definition GLLoader.hpp:723
#define glPointSize
Definition GLLoader.hpp:2064
#define glPrimitiveRestartIndex
Definition GLLoader.hpp:4391
#define GL_CLIP_DISTANCE6
Definition GLLoader.hpp:1676
#define glStencilFunc
Definition GLLoader.hpp:2146
#define GL_CULL_FACE
Definition GLLoader.hpp:855
#define GL_CLIP_DISTANCE0
Definition GLLoader.hpp:1670
#define glDepthRangef
Definition GLLoader.hpp:9022
int GLsizei
Definition GLLoader.hpp:734
#define glDepthMask
Definition GLLoader.hpp:2124
#define GL_SAMPLE_ALPHA_TO_COVERAGE
Definition GLLoader.hpp:1400
#define glBindTexture
Definition GLLoader.hpp:3132
#define GL_FRAMEBUFFER
Definition GLLoader.hpp:1848
#define glFrontFace
Definition GLLoader.hpp:2055
#define GL_CLIP_DISTANCE1
Definition GLLoader.hpp:1671
#define GL_BLEND
Definition GLLoader.hpp:876
#define GL_MULTISAMPLE
Definition GLLoader.hpp:1399
unsigned int GLuint
Definition GLLoader.hpp:733
ptrdiff_t GLsizeiptr
Definition GLLoader.hpp:761
#define GL_POLYGON_OFFSET_POINT
Definition GLLoader.hpp:1223
#define GL_CLIP_DISTANCE4
Definition GLLoader.hpp:1674
#define glViewport
Definition GLLoader.hpp:2215
#define GL_READ_FRAMEBUFFER
Definition GLLoader.hpp:1798
#define GL_DEBUG_OUTPUT_SYNCHRONOUS
Definition GLLoader.hpp:7065
#define GL_SCISSOR_TEST
Definition GLLoader.hpp:881
#define glSampleMaski
Definition GLLoader.hpp:4513
#define glLineWidth
Definition GLLoader.hpp:2061
#define glPolygonMode
Definition GLLoader.hpp:2067
#define GL_PRIMITIVE_RESTART
Definition GLLoader.hpp:1930
#define glUseProgram
Definition GLLoader.hpp:3782
#define glDisable
Definition GLLoader.hpp:2127
#define GL_DEPTH_CLAMP
Definition GLLoader.hpp:1989
#define glBlendEquationSeparate
Definition GLLoader.hpp:3654
#define glActiveTexture
Definition GLLoader.hpp:3232
#define GL_LINE_SMOOTH
Definition GLLoader.hpp:849
#define GL_DEBUG_OUTPUT
Definition GLLoader.hpp:7099
#define CE_EXPLICIT(EXPR)
Definition Macros.hpp:413
Definition GLStateManager.hpp:921
Tuple is a fixed-size collection of heterogeneous values.
Definition Tuple.hpp:15
Definition Application.hpp:19
void GLThrowIfFailed(const char *info)
struct CeresEngine::GLState state
@ Object
Specifies that the normal map is in object space.
std::array< T, N > Array
Array is a container that encapsulates fixed size arrays.
Definition Array.hpp:17
constexpr size_t hash(const T &v)
Generates a hash for the provided type.
Definition Hash.hpp:25
Definition Span.hpp:668
A helper class that wraps a OpenGL capability.
Definition GLStateManager.hpp:332
GLenum capability
The OpenGL capability constant.
Definition GLStateManager.hpp:334
bool current
The current state.
Definition GLStateManager.hpp:337
GLCapability & operator=(const bool state)
Sets the capability state value.
Definition GLStateManager.hpp:350
std::conditional_t< sizeof...(Ts)==0, T, Tuple< T, Ts... > > Value
The operator= parameter type.
Definition GLStateManager.hpp:157
std::optional< Value > current
The currently set value.
Definition GLStateManager.hpp:163
F< void(T, Ts...)> Setter
The OpenGL setter function signature.
Definition GLStateManager.hpp:154
GLGlobalState & operator=(Value value)
Changes the OpenGL state variable to value.
Definition GLStateManager.hpp:173
const Setter setter
The setter function pointer.
Definition GLStateManager.hpp:160
const Setter * setter
The setter function pointer.
Definition GLStateManager.hpp:44
std::conditional_t< sizeof...(Ts)==0, T, Tuple< T, Ts... > > Value
The operator= parameter type.
Definition GLStateManager.hpp:41
void(*)(T, Ts...) Setter
The OpenGL setter function signature.
Definition GLStateManager.hpp:38
GLGlobalState & operator=(Value value)
Changes the OpenGL state variable to value.
Definition GLStateManager.hpp:58
std::optional< Value > current
The currently set value.
Definition GLStateManager.hpp:47
void(*)(T, Ts...) Setter
The OpenGL setter function signature.
Definition GLStateManager.hpp:92
GLGlobalState & operator=(Value value)
Changes the OpenGL state variable to value.
Definition GLStateManager.hpp:118
const Setter setter
The setter function pointer.
Definition GLStateManager.hpp:98
std::conditional_t< sizeof...(Ts)==0, T, Tuple< T, Ts... > > Value
The operator= parameter type.
Definition GLStateManager.hpp:95
std::optional< Value > current
The currently set value.
Definition GLStateManager.hpp:101
const Setter setter
The setter function pointer.
Definition GLStateManager.hpp:228
Entry & operator=(Value value)
Changes the OpenGL state variable to value.
Definition GLStateManager.hpp:244
const Index index
The entry index.
Definition GLStateManager.hpp:225
std::optional< Value > & current
The currently set value.
Definition GLStateManager.hpp:231
Entry operator[](Index index)
Definition GLStateManager.hpp:282
Array< std::optional< Value >, N > current
The current value.
Definition GLStateManager.hpp:221
void(*)(I, T, Ts...) Setter
The OpenGL setter function signature.
Definition GLStateManager.hpp:212
const Setter setter
The setter function pointer.
Definition GLStateManager.hpp:218
std::conditional_t< sizeof...(Ts)==0, T, Tuple< T, Ts... > > Value
The operator= parameter type.
Definition GLStateManager.hpp:215
Definition GLStateManager.hpp:200
A helper class that wraps an OpenGL state function.
Definition GLStateManager.hpp:27
GLObjectState & operator=(T value)
Changes the OpenGL state variable to value.
Definition GLStateManager.hpp:307
std::optional< T > current
The currently set value.
Definition GLStateManager.hpp:300
void(*)(Object, T) Setter
The OpenGL setter function signature.
Definition GLStateManager.hpp:291
GLObjectState(const Object object, const Setter setter)
Definition GLStateManager.hpp:302
const Object object
The OpenGL object handle.
Definition GLStateManager.hpp:294
const Setter setter
The setter function.
Definition GLStateManager.hpp:297
Definition GLStateManager.hpp:287
Definition GLStateManager.hpp:377
struct CeresEngine::GLState::@34::@46 buffer
GLGlobalState< decltype(glad_glPrimitiveRestartIndex)> index
Specify the primitive restart index index: Specifies the value to be interpreted as the primitive res...
Definition GLStateManager.hpp:821
GLCapability framebufferSRGB
If enabled and the value of GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING for the framebuffer attachment c...
Definition GLStateManager.hpp:708
GLCapability withFixedIndex
Enables primitive restarting with a fixed index.
Definition GLStateManager.hpp:816
struct CeresEngine::GLState::@34 bindings
GLCapability offset
If enabled, and if the polygon is rendered in GL_FILL mode, an offset is added to depth values of a p...
Definition GLStateManager.hpp:725
GLCapability textureCubeMapSeamless
If enabled, cubemap textures are sampled such that when linearly sampling from the border between two...
Definition GLStateManager.hpp:874
GLGlobalState< decltype(glad_glScissor)> box
Define the scissor box x, y: Specify the lower left corner of the scissor box.
Definition GLStateManager.hpp:659
GLGlobalState< decltype(glad_glDepthMask)> mask
Enable or disable writing into the depth buffer flag: Specifies whether the depth buffer is enabled f...
Definition GLStateManager.hpp:588
GLGlobalState< decltype(glad_glClearColor)> clearColor
Specify clear values for the color buffers.
Definition GLStateManager.hpp:427
GLGlobalState< decltype(glad_glSampleCoverage)> coverage
Specify multisample coverage parameters value: Specify a single floating-point sample coverage value.
Definition GLStateManager.hpp:798
struct CeresEngine::GLState::@38 scissor
GLCapability enableCoverage
If enabled, the fragment's coverage is ANDed with the temporary coverage value.
Definition GLStateManager.hpp:788
GLGlobalState< void(GLuint)> read
Bind a framebuffer to a framebuffer target to GL_READ_FRAMEBUFFER.
Definition GLStateManager.hpp:419
GLGlobalState< decltype(glad_glLineWidth)> width
Specify the width of rasterized lines.
Definition GLStateManager.hpp:762
GLGlobalState< decltype(glad_glBindTexture)> texture
Bind a named texture to a texturing target target: Specifies the target to which the texture is bound...
Definition GLStateManager.hpp:438
struct CeresEngine::GLState::@42 primitiveRestart
GLGlobalState< decltype(glad_glPolygonMode)> mode
Select a polygon rasterization mode face: Specifies the polygons that mode​ applies to.
Definition GLStateManager.hpp:718
GLGlobalState< void(GLuint)> dispatchIndirect
Bind a named buffer object as a GL_DISPATCH_INDIRECT_BUFFER buffer: Specifies the name of a buffer ob...
Definition GLStateManager.hpp:521
GLCapability dither
If enabled, dither color components or indices before they are written to the color buffer.
Definition GLStateManager.hpp:664
GLGlobalState< decltype(glad_glBlendColor)> color
Set the blend color red, green, blue, alpha: specify the components of GL_BLEND_COLOR
Definition GLStateManager.hpp:698
GLGlobalState< void(GLuint)> write
Bind a named buffer object as a GL_COPY_WRITE_BUFFER buffer: Specifies the name of a buffer object.
Definition GLStateManager.hpp:511
GLGlobalState< void(GLuint)> shaderStorage
Bind a named buffer object as a GL_SHADER_STORAGE_BUFFER buffer: Specifies the name of a buffer objec...
Definition GLStateManager.hpp:541
GLGlobalState< decltype(glad_glBlendEquationSeparate)> equation
Set the RGB blend equation and the alpha blend equation separately buf: for glBlendEquationi,...
Definition GLStateManager.hpp:680
GLCapability clipDistance[8]
If enabled, clip geometry against user-defined half space i.
Definition GLStateManager.hpp:900
GLCapability clamping
If enabled, the -wc ≤ zc ≤ wc plane equation is ignored by view volume clipping (effectively,...
Definition GLStateManager.hpp:581
struct CeresEngine::GLState::@35 culling
struct CeresEngine::GLState::@44 sampleMask
GLGlobalState< void(GLuint)> transformFeedback
Bind a named buffer object as a GL_TRANSFORM_FEEDBACK_BUFFER buffer: Specifies the name of a buffer o...
Definition GLStateManager.hpp:550
GLGlobalState< void(GLuint)> atomicCounter
Bind a named buffer object as a GL_ATOMIC_COUNTER_BUFFER buffer: Specifies the name of a buffer objec...
Definition GLStateManager.hpp:502
GLGlobalState< decltype(glad_glViewport)> viewport
Set the viewport x, y: Specify the lower left corner of the viewport rectangle, in pixels.
Definition GLStateManager.hpp:385
GLGlobalState< decltype(glad_glPointSize)> size
Specify the diameter of rasterized points size: Specifies the diameter of rasterized points.
Definition GLStateManager.hpp:733
GLGlobalStateCollection< GLuint, void(GLuint), 96 > samplers
bind a named sampler to a texturing target.
Definition GLStateManager.hpp:473
GLGlobalState< decltype(glad_glDepthRangef)> range
Specify mapping of depth values from normalized device coordinates to window coordinates nearVal: Spe...
Definition GLStateManager.hpp:604
GLCapability sizeFromProgram
If enabled and a vertex or geometry shader is active, then the derived point size is taken from the (...
Definition GLStateManager.hpp:745
GLGlobalState< void(GLuint)> pixelUnpack
Bind a named buffer object as a GL_PIXEL_UNPACK_BUFFER buffer: Specifies the name of a buffer object.
Definition GLStateManager.hpp:533
struct CeresEngine::GLState::@34::@46::@47 copy
struct CeresEngine::GLState::@41 multisample
GLGlobalState< decltype(glad_glBindVertexArray)> vertexArray
Bind a vertex array object array: Specifies the name of the vertex array to bind.
Definition GLStateManager.hpp:433
GLCapability smooth
If enabled, draw lines with correct filtering.
Definition GLStateManager.hpp:751
struct CeresEngine::GLState::@45 debugOutput
GLCapability point
If enabled, an offset is added to depth values of a polygon's fragments before the depth comparison i...
Definition GLStateManager.hpp:739
struct CeresEngine::GLState::@43 logicOp
GLGlobalState< void(GLuint)> drawIndirect
Bind a named buffer object as a GL_DRAW_INDIRECT_BUFFER buffer: Specifies the name of a buffer object...
Definition GLStateManager.hpp:516
GLCapability rasterizerDiscard
If enabled, all primitives are discarded before rasterization, but after any optional transform feedb...
Definition GLStateManager.hpp:844
GLGlobalStateCollection< GLenum, void(GLuint), 96 > textures
Definition GLStateManager.hpp:440
GLGlobalState< decltype(glad_glDepthFunc)> function
Specify the value used for depth buffer comparisons func: Specifies the depth comparison function.
Definition GLStateManager.hpp:596
struct CeresEngine::GLState::@37 stencil
struct CeresEngine::GLState::@36 depth
GLGlobalState< void(GLuint)> uniform
Bind a named buffer object as a GL_UNIFORM_BUFFER buffer: Specifies the name of a buffer object.
Definition GLStateManager.hpp:554
struct CeresEngine::GLState::@39 blending
struct CeresEngine::GLState::@33 framebuffer
GLCapability sampleAlphaToCoverage
If enabled, compute a temporary coverage value where each bit is determined by the alpha value at the...
Definition GLStateManager.hpp:850
GLGlobalState< decltype(glad_glFrontFace)> frontFace
Define front- and back-facing polygons mode: Specifies the orientation of front-facing polygons.
Definition GLStateManager.hpp:390
GLGlobalState< decltype(glad_glStencilOp)> operation
Set front and back stencil test actions sfail: Specifies the action to take when the stencil test fai...
Definition GLStateManager.hpp:642
GLGlobalStateCollection< GLuint, void(GLuint, GLintptr, GLsizei), 10 > vertexBuffer
Bind a buffer to a vertex buffer bind point.
Definition GLStateManager.hpp:484
GLGlobalState< void(GLuint)> global
Bind a framebuffer to a framebuffer target to GL_FRAMEBUFFER.
Definition GLStateManager.hpp:403
GLCapability sampleAlphaToOne
If enabled, each sample alpha value is replaced by the maximum representable alpha value.
Definition GLStateManager.hpp:854
GLCapability testingEnabled
If enabled, do depth comparisons and update the depth buffer.
Definition GLStateManager.hpp:576
GLGlobalState< void(GLuint)> pixelPack
Bind a named buffer object as a GL_PIXEL_PACK_BUFFER buffer: Specifies the name of a buffer object.
Definition GLStateManager.hpp:529
GLCapability enabled
If enabled, cull polygons based on their winding in window coordinates.
Definition GLStateManager.hpp:561
struct CeresEngine::GLState::@40 polygon
GLGlobalState< decltype(glad_glDebugMessageCallback)> callback
Specify a callback to receive debugging messages from the GL.
Definition GLStateManager.hpp:896
GLGlobalState< void(GLuint)> query
Bind a named buffer object as a GL_QUERY_BUFFER buffer: Specifies the name of a buffer object.
Definition GLStateManager.hpp:537
GLGlobalStateCollection< GLuint, void(GLenum, GLuint, GLintptr, GLsizeiptr), 96 > buffers
Bind a range within a buffer object to an indexed buffer target.
Definition GLStateManager.hpp:466
GLGlobalState< decltype(glad_glUseProgram)> program
Installs a program object as part of current rendering state program: Specifies the handle of the pro...
Definition GLStateManager.hpp:396
GLGlobalState< void(GLuint)> draw
Bind a framebuffer to a framebuffer target to GL_DRAW_FRAMEBUFFER.
Definition GLStateManager.hpp:411
struct CeresEngine::GLState::@40::@50 line
GLGlobalState< void(GLuint)> elementArray
Bind a named buffer object as a GL_ELEMENT_ARRAY_BUFFER buffer: Specifies the name of a buffer object...
Definition GLStateManager.hpp:525
struct CeresEngine::GLState::@40::@48 fill
GLCapability synchronous
If enabled, debug messages are produced synchronously by a debug context.
Definition GLStateManager.hpp:889
GLGlobalState< decltype(glad_glCullFace)> face
Specify whether front- or back-facing facets can be culled mode: Specifies whether front- or back-fac...
Definition GLStateManager.hpp:568
GLGlobalState< decltype(glad_glSampleMaski)> value
Set the value of a sub-word of the sample mask maskNumber: Specifies which 32-bit sub-word of the sam...
Definition GLStateManager.hpp:866
GLGlobalState< void(GLuint)> array
Bind a named buffer object as a GL_ARRAY_BUFFER buffer: Specifies the name of a buffer object.
Definition GLStateManager.hpp:498