diff --git a/CHANGELOG.md b/CHANGELOG.md
index 6e6919bf84..be50d95f56 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -81,6 +81,9 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
- New `Attachable` INI and Lua (R/W) properties `InheritsVelWhenDetached` and `InheritsAngularVelWhenDetached`, which determine how much of these velocities an attachable inherits from its parent when detached. Defaults to 1.
+- New GPU Renderer using OpenGL+Raylib, draw now takes 0ms in pretty much every instance.
+
+- New Z Order for scene layers and primitives: Background layer sits at z=100, Terrain Background at z=50, Terrain color and MO color at z=0, GUIs sit at z=-100, allowed z range is [-200, +200], in the future this'll be expanded to MO draw as well.
- Added Lua-accessible bitmap manipulation functions to `MOSprite`s:
```
GetSpritePixelIndex(int x, int y, int whichFrame) - Returns the color index of the pixel at the given coordinate on the given frame of the sprite ((0, 0) is the upper left corner!)
@@ -103,6 +106,15 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
- New `SceneMan` function `CastAllMOsRay(startVector, rayVector, table ignoreMOIDs, ignoreTeam, ignoreMaterial, bool ignoreAllTerrain, int skip)` which returns an iterator with pointers to all the non-ignored MOs met along the ray.
+- New parameter `depth` for all primitives sets draw depth of the drawn primitive. The default depth is -75.0 (lower numbers draw on top, higher numbers in the back).
+
+- New `DrawDepth` enum for default draw depths:
+ - `Default` = 0.0f (Main draw depth for MOs)
+ - `GUI` = -100.0f (Draw Depth of GUI elements)
+ - `Primitive` = -75.0f (Default Primitive draw depth)
+ - `TerrainBackground` = 50.0f (Draw Depth of Terrain Background layer)
+ - `Background` = 100.0f (Draw Depth of Background layer)
+
- Added scaling capability to Bitmap primitives.
New draw bindings with argument for scale are:
```
@@ -168,6 +180,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
- `InheritsVel` and its ilk have been uncapped, allowing users to set them outside of 0-1.
+- Lua renamed `SceneLayer`->`StaticSceneLayer` due to changed SLBackground base class.
+
- `Scene` Lua functions `AddNavigatableArea(areaName)` and `ClearNavigatableAreas()` have been renamed/corrected to `AddNavigableArea(areaName)` and `ClearNavigableAreas()`, respectively.
- `MOSRotating` Lua function `AddWound` now additionally accepts the format `MOSRotating:AddWound(AEmitter* woundToAdd, const Vector& parentOffsetToSet, bool checkGibWoundLimit, bool isEntryWound, bool isExitWound)`, allowing modders to specify added wounds as entry- or exit wounds, for the purpose of not playing multiple burst sounds on the same frame. These new arguments are optional.
@@ -204,6 +218,9 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
- Fixed an issue where internal Lua functions OriginalDoFile, OriginalLoadFile, and OriginalRequire were polluting the global namespace. They have now been made inaccessible.
+- Fixed the palette being mangled to 6bit/color on load.
+
+- Fixed allegro not loading alpha of image with alpha by using SDL_image instead.
- Fixed `MOSprite:UnRotateOffset()` giving the wrong results on HFLipped sprites.
- Various fixes and improvements to inventory management when dual-wielding or carrying a shield, to stop situations where the actor unexpectedly puts their items away.
diff --git a/Data/Base.rte/Shaders/Background.frag b/Data/Base.rte/Shaders/Background.frag
index e148f9440b..7f8449e15b 100644
--- a/Data/Base.rte/Shaders/Background.frag
+++ b/Data/Base.rte/Shaders/Background.frag
@@ -1,14 +1,19 @@
-#version 130
+#version 330
+#extension GL_KHR_blend_equation_advanced: enable
+#extension GL_ARB_sample_shading: enable
in vec2 textureUV;
in vec4 vertexColor;
+#ifdef GL_KHR_blend_equation_advanced
+layout(blend_support_all_equations) out;
+#endif
out vec4 FragColor;
-
uniform sampler2D rteTexture;
uniform sampler2D rtePalette;
-uniform vec4 rteColor;
-uniform bool drawMasked;
+uniform vec4 rteColor = vec4(1.0);
+uniform bool rteBlendInvert = false;
+uniform bool drawMasked = false;
vec4 texture2DAA(sampler2D tex, vec2 uv) {
@@ -25,5 +30,9 @@ void main() {
if (red==0 && drawMasked) {
discard;
}
- FragColor = texture2DAA(rtePalette, vec2(red * rteColor.r * vertexColor.r, 0.0)) * vec4(vec3(1.0), rteColor.a * vertexColor.a);
+ if (!rteBlendInvert) {
+ FragColor = texture2DAA(rtePalette, vec2(red * vertexColor.r, 0.0)) * vec4(rteColor.rgb, rteColor.a * vertexColor.a);
+ } else {
+ FragColor = vec4(vec3(1.0), 0.0) - (texture2DAA(rtePalette, vec2(red * vertexColor.r, 0.0)) * vec4(rteColor.rgb, -rteColor.a * vertexColor.a));
+ }
}
diff --git a/Data/Base.rte/Shaders/Blit8.vert b/Data/Base.rte/Shaders/Blit8.vert
index 489d0eb9fb..ee58dc5626 100644
--- a/Data/Base.rte/Shaders/Blit8.vert
+++ b/Data/Base.rte/Shaders/Blit8.vert
@@ -6,11 +6,11 @@ in vec4 rteVertexColor;
out vec2 textureUV;
out vec4 vertexColor;
-//uniform mat4 rteModelViewProjection;
+uniform mat4 rteView;
uniform mat4 rteProjection;
void main() {
- gl_Position = rteProjection * vec4(rteVertexPosition, 1.0);
+ gl_Position = rteProjection * rteView * vec4(rteVertexPosition, 1.0);
textureUV = rteVertexTexUV;
vertexColor = rteVertexColor;
}
diff --git a/Data/Base.rte/Shaders/Dissolve.frag b/Data/Base.rte/Shaders/Dissolve.frag
new file mode 100644
index 0000000000..446027755b
--- /dev/null
+++ b/Data/Base.rte/Shaders/Dissolve.frag
@@ -0,0 +1,52 @@
+#version 130
+
+in vec2 textureUV;
+in vec4 vertexColor;
+
+out vec4 FragColor;
+
+uniform sampler2D rteTexture;
+uniform sampler2D rtePalette;
+uniform vec4 rteColor;
+
+// Pseudo random number generator.
+float hash( vec2 a )
+{
+ return fract( sin( a.x * 3433.8 + a.y * 3843.98 ) * 45933.8 );
+}
+
+// Value noise courtesy of BigWingz
+// check his youtube channel he has
+// a video of this one.
+// Succint version by FabriceNeyret
+float noise( vec2 U )
+{
+ vec2 id = floor( U );
+ U = fract( U );
+ U *= U * ( 3. - 2. * U );
+
+ vec2 A = vec2( hash(id), hash(id + vec2(0,1)) );
+ vec2 B = vec2( hash(id + vec2(1,0)), hash(id + vec2(1,1)) );
+ vec2 C = mix( A, B, U.x);
+
+ return mix( C.x, C.y, U.y );
+}
+
+vec4 texture2DAA(sampler2D tex, vec2 uv) {
+ vec2 texsize = vec2(textureSize(tex, 0));
+ vec2 uv_texspace = uv * texsize;
+ vec2 seam = floor(uv_texspace + .5);
+ uv_texspace = (uv_texspace - seam) / fwidth(uv_texspace) + seam;
+ uv_texspace = clamp(uv_texspace, seam - .5, seam + .5);
+ return texture(tex, uv_texspace / texsize);
+}
+
+void main() {
+ if (noise(gl_FragCoord.xy + textureUV) < 0.5) {
+ discard;
+ }
+ float red = texture2D(rteTexture, textureUV).r;
+ vec4 color = texture2DAA(rtePalette, vec2(red * vertexColor.r, 0.0)) * vec4(rteColor.rgb, rteColor.a * vertexColor.a);
+
+ FragColor = color;
+}
\ No newline at end of file
diff --git a/Data/Base.rte/Shaders/PostProcess.vert b/Data/Base.rte/Shaders/PostProcess.vert
index 1b790d261f..8c2ba4bfa1 100644
--- a/Data/Base.rte/Shaders/PostProcess.vert
+++ b/Data/Base.rte/Shaders/PostProcess.vert
@@ -7,11 +7,11 @@ in vec4 rteVertexColor;
out vec2 textureUV;
out vec4 vertexColor;
-uniform mat4 rteModel;
+uniform mat4 rteView;
uniform mat4 rteProjection;
void main() {
- gl_Position = rteProjection * rteModel * vec4(rteVertexPosition, 1.0);
+ gl_Position = rteProjection * rteView * vec4(rteVertexPosition, 1.0);
vertexColor = rteVertexColor;
textureUV = rteVertexTexUV;
}
diff --git a/Data/Base.rte/Shaders/ScreenBlit.vert b/Data/Base.rte/Shaders/ScreenBlit.vert
index 85316fb3f2..3532362c5e 100644
--- a/Data/Base.rte/Shaders/ScreenBlit.vert
+++ b/Data/Base.rte/Shaders/ScreenBlit.vert
@@ -5,10 +5,10 @@ in vec2 rteVertexTexUV;
out vec2 textureUV;
-uniform mat4 rteModel;
+uniform mat4 rteView;
uniform mat4 rteProjection;
void main() {
- gl_Position = rteProjection * rteModel * vec4(rteVertexPosition, 1.0);
+ gl_Position = rteProjection * rteView * vec4(rteVertexPosition, 1.0);
textureUV = rteVertexTexUV;
}
diff --git a/Data/Base.rte/Shaders/Shaders.ini b/Data/Base.rte/Shaders/Shaders.ini
index 6575f0b548..d738855d23 100644
--- a/Data/Base.rte/Shaders/Shaders.ini
+++ b/Data/Base.rte/Shaders/Shaders.ini
@@ -17,3 +17,8 @@ AddShader = Shader
PresetName = Background
VertexShader = Base.rte/Shaders/Blit8.vert
FragmentShader = Base.rte/Shaders/Background.frag
+
+AddShader = Shader
+ PresetName = Dissolve
+ VertexShader = Base.rte/Shaders/Blit8.vert
+ FragmentShader = Base.rte/Shaders/Dissolve.frag
diff --git a/RTEA.vcxproj b/RTEA.vcxproj
index e309a027e6..bc8a3fa286 100644
--- a/RTEA.vcxproj
+++ b/RTEA.vcxproj
@@ -801,7 +801,7 @@
-
+
@@ -1324,7 +1324,7 @@
-
+
diff --git a/RTEA.vcxproj.filters b/RTEA.vcxproj.filters
index f390c1ddc6..14673a2d77 100644
--- a/RTEA.vcxproj.filters
+++ b/RTEA.vcxproj.filters
@@ -499,8 +499,8 @@
Entities
-
- System
+
+ Renderer
Menus
@@ -1080,8 +1080,8 @@
Entities
-
- System
+
+ Renderer
Menus
diff --git a/Source/Entities/PieMenu.cpp b/Source/Entities/PieMenu.cpp
index edfe830771..a0ab6f4e58 100644
--- a/Source/Entities/PieMenu.cpp
+++ b/Source/Entities/PieMenu.cpp
@@ -636,6 +636,7 @@ void PieMenu::Draw(BITMAP* targetBitmap, const Vector& targetPos) const {
Vector drawPos;
CalculateDrawPosition(targetBitmap, targetPos, drawPos);
+ rlZDepth(c_GuiDepth);
if (m_EnabledState != EnabledState::Disabled) {
if (m_DrawBackgroundTransparent) {
g_FrameMan.SetTransTableFromPreset(TransparencyPreset::MoreTrans);
@@ -646,6 +647,7 @@ void PieMenu::Draw(BITMAP* targetBitmap, const Vector& targetPos) const {
DrawTexture(g_GLResourceMan.GetStaticTextureFromBitmap(m_BGBitmap), drawPos.GetFloorIntX() - m_BGBitmap->w / 2, drawPos.GetFloorIntY() - m_BGBitmap->h / 2, {255, 255, 255, 255});
}
}
+ rlZDepth(c_DefaultDrawDepth);
if (m_EnabledState == EnabledState::Enabled) {
DrawPieIcons(targetBitmap, drawPos);
diff --git a/Source/Entities/SceneLayer.cpp b/Source/Entities/SceneLayer.cpp
index ce8f8b9155..d75751baea 100644
--- a/Source/Entities/SceneLayer.cpp
+++ b/Source/Entities/SceneLayer.cpp
@@ -432,10 +432,10 @@ void SceneLayerImpl::UpdateTargetRegion(const Bo
Box bitmapDimensions(Vector(), bitmapWidth, bitmapHeight);
for (int tiledOffsetX = 0; tiledOffsetX < areaToCoverX;) {
- float destX = scaledTarget.GetCorner().GetFloorIntX() + tiledOffsetX - scaledOffset.GetFloorIntX();
+ float destX = tiledOffsetX - scaledOffset.GetFloorIntX();
for (int tiledOffsetY = 0; tiledOffsetY < areaToCoverY;) {
- float destY = scaledTarget.GetCorner().GetFloorIntY() + tiledOffsetY - scaledOffset.GetFloorIntY();
+ float destY = tiledOffsetY - scaledOffset.GetFloorIntY();
Box update = bitmapDimensions.GetIntersection({-Vector(destX, destY), scaledTarget.m_Width, scaledTarget.m_Height});
update.m_Corner = update.m_Corner.GetFloored();
update.m_Width = std::ceil(update.m_Width) + 1;
diff --git a/Source/Lua/LuaBindingRegisterDefinitions.h b/Source/Lua/LuaBindingRegisterDefinitions.h
index 1b8a8b953d..91be1b3c54 100644
--- a/Source/Lua/LuaBindingRegisterDefinitions.h
+++ b/Source/Lua/LuaBindingRegisterDefinitions.h
@@ -302,5 +302,6 @@ namespace RTE {
LuaBindingRegisterFunctionDeclarationForType(AlarmEvent);
LuaBindingRegisterFunctionDeclarationForType(Directions);
LuaBindingRegisterFunctionDeclarationForType(DrawBlendMode);
+ LuaBindingRegisterFunctionDeclarationForType(DrawDepth);
};
} // namespace RTE
diff --git a/Source/Lua/LuaBindingsMisc.cpp b/Source/Lua/LuaBindingsMisc.cpp
index 22193c6d24..a57e9e369e 100644
--- a/Source/Lua/LuaBindingsMisc.cpp
+++ b/Source/Lua/LuaBindingsMisc.cpp
@@ -43,3 +43,14 @@ LuaBindingRegisterFunctionDefinitionForType(MiscLuaBindings, DrawBlendMode) {
luabind::value("Transparency", DrawBlendMode::BlendTransparency),
luabind::value("BlendModeCount", DrawBlendMode::BlendModeCount)];
}
+
+LuaBindingRegisterFunctionDefinitionForType(MiscLuaBindings, DrawDepth) {
+ return luabind::class_("DrawDepth")
+ .enum_("DrawDepth")[
+ luabind::value("Default", c_DefaultDrawDepth),
+ luabind::value("GUI", c_GuiDepth),
+ luabind::value("Primitive", c_PrimitiveDepth),
+ luabind::value("TerrainBackground", c_TerrainBGDepth),
+ luabind::value("Background", c_BackgroundDepth)
+ ];
+}
diff --git a/Source/Lua/LuaBindingsPrimitives.cpp b/Source/Lua/LuaBindingsPrimitives.cpp
index 3122129a26..6c08f707f4 100644
--- a/Source/Lua/LuaBindingsPrimitives.cpp
+++ b/Source/Lua/LuaBindingsPrimitives.cpp
@@ -11,85 +11,100 @@ LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, GraphicalPrimi
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, LinePrimitive) {
return luabind::class_("LinePrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, ArcPrimitive) {
return luabind::class_("ArcPrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, SplinePrimitive) {
return luabind::class_("SplinePrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, BoxPrimitive) {
return luabind::class_("BoxPrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, BoxFillPrimitive) {
return luabind::class_("BoxFillPrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, RoundedBoxPrimitive) {
return luabind::class_("RoundedBoxPrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, RoundedBoxFillPrimitive) {
return luabind::class_("RoundedBoxFillPrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, CirclePrimitive) {
return luabind::class_("CirclePrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, CircleFillPrimitive) {
return luabind::class_("CircleFillPrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, EllipsePrimitive) {
return luabind::class_("EllipsePrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, EllipseFillPrimitive) {
return luabind::class_("EllipseFillPrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, TrianglePrimitive) {
return luabind::class_("TrianglePrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, TriangleFillPrimitive) {
return luabind::class_("TriangleFillPrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, TextPrimitive) {
return luabind::class_("TextPrimitive")
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, BitmapPrimitive) {
@@ -98,5 +113,7 @@ LuaBindingRegisterFunctionDefinitionForType(PrimitiveLuaBindings, BitmapPrimitiv
.def(luabind::constructor())
.def(luabind::constructor())
.def(luabind::constructor())
- .def(luabind::constructor());
+ .def(luabind::constructor())
+ .def(luabind::constructor())
+ .def(luabind::constructor());
}
diff --git a/Source/Lua/LuabindDefinitions.h b/Source/Lua/LuabindDefinitions.h
index edfd37d16f..eb3ef34c10 100644
--- a/Source/Lua/LuabindDefinitions.h
+++ b/Source/Lua/LuabindDefinitions.h
@@ -42,6 +42,7 @@ namespace RTE {
struct gamepad_axis : public luabind::enum_wrapper {};
struct directions : public luabind::enum_wrapper {};
struct blend_modes : public luabind::enum_wrapper {};
+ struct draw_depths : public luabind::enum_wrapper {};
/// Special callback function for adding file name and line number to error messages when calling functions incorrectly.
/// @param luaState The Lua master state.
diff --git a/Source/Managers/FrameMan.cpp b/Source/Managers/FrameMan.cpp
index 8abbee6188..40752c0cb8 100644
--- a/Source/Managers/FrameMan.cpp
+++ b/Source/Managers/FrameMan.cpp
@@ -1,5 +1,6 @@
#include "FrameMan.h"
+#include "SDL3/SDL_surface.h"
#include "WindowMan.h"
#include "PostProcessMan.h"
#include "PresetMan.h"
@@ -25,6 +26,7 @@
#include "GLCheck.h"
#include "glad/gl.h"
+#include "Draw.h"
#include "tracy/Tracy.hpp"
#include "tracy/TracyOpenGL.hpp"
@@ -33,6 +35,7 @@
using namespace RTE;
void BitmapDeleter::operator()(BITMAP* bitmap) const { destroy_bitmap(bitmap); }
+void SurfaceDeleter::operator()(SDL_Surface* surface) const { SDL_DestroySurface(surface); }
const std::array, DrawBlendMode::BlendModeCount> FrameMan::c_BlenderSetterFunctions = {
nullptr, // NoBlend obviously has no blender, but we want to keep the indices matching with the enum.
@@ -155,15 +158,15 @@ int FrameMan::CreateBackBuffers() {
m_PlayerScreen = m_BackBuffer;
}
- m_ScreenDumpBuffer = std::unique_ptr(create_bitmap_ex(24, m_BackBuffer32->w, m_BackBuffer32->h));
+ m_ScreenDumpBuffer = std::unique_ptr(SDL_CreateSurface(m_BackBuffer8->w, m_BackBuffer8->h, SDL_PIXELFORMAT_RGB24));
return 0;
}
void FrameMan::CreatePresetColorTables() {
// Create RGB lookup table that supposedly speeds up calculation of other color tables.
- //create_rgb_table(&m_RGBTable, m_DefaultPalette, nullptr);
- //rgb_map = &m_RGBTable;
+ // create_rgb_table(&m_RGBTable, m_DefaultPalette, nullptr);
+ // rgb_map = &m_RGBTable;
// Create transparency color tables. Tables for other blend modes will be created on demand.
int transparencyPresetCount = BlendAmountLimits::MaxBlend / c_BlendAmountStep;
@@ -357,6 +360,67 @@ void FrameMan::ClearScreenText(int whichScreen) {
}
}
+void FrameMan::SetBlendMode(DrawBlendMode blendMode) {
+ GLint invertLoc = rlGetLocationUniformCurrent("rteBlendInvert");
+ glUniform1i(invertLoc, 0);
+ switch (blendMode) {
+ case BlendTransparency: {
+ rlSetBlendMode(RL_BLEND_ALPHA);
+ break;
+ }
+ case BlendScreen: {
+ rlSetBlendMode(RL_BLEND_SCREEN);
+ break;
+ }
+ case BlendDifference: {
+ rlSetBlendMode(RL_BLEND_SUBTRACT_COLORS);
+ break;
+ }
+ case BlendMultiply: {
+ rlSetBlendMode(RL_BLEND_MULTIPLIED);
+ break;
+ }
+ case BlendBurn: {
+ rlSetBlendMode(RL_BLEND_BURN);
+ break;
+ }
+ case BlendDodge: {
+ rlSetBlendMode(RL_BLEND_DODGE);
+ break;
+ }
+ case BlendColor: {
+ rlSetBlendMode(RL_BLEND_HSL_COLOR);
+ break;
+ }
+ case BlendLuminance: {
+ rlSetBlendMode(RL_BLEND_HSL_LUMINOSITY);
+ break;
+ }
+ case BlendSaturation: {
+ rlSetBlendMode(RL_BLEND_HSL_SATURATION);
+ break;
+ }
+ case BlendInvert: {
+ rlSetBlendMode(RL_BLEND_ALPHA);
+ glUniform1i(invertLoc, 1);
+ break;
+ }
+ case BlendDissolve: {
+ rlSetBlendMode(RL_BLEND_ALPHA);
+ const Shader* dissolve = dynamic_cast(g_PresetMan.GetEntityPreset("Shader", "Dissolve"));
+ dissolve->Begin();
+ GLint paletteLoc = dissolve->GetUniformLocation("rtePalette");
+ rlSetUniformSampler(paletteLoc, g_PostProcessMan.GetPaletteTexture());
+ break;
+ }
+ default: {
+ rlSetBlendMode(RL_BLEND_ALPHA);
+ RTEAssert(blendMode < BlendModeCount, "Unkown blend mode selected!");
+ break;
+ }
+ }
+}
+
void FrameMan::SetColorTable(DrawBlendMode blendMode, std::array colorChannelBlendAmounts) {
RTEAssert(blendMode > DrawBlendMode::NoBlend && blendMode < DrawBlendMode::BlendModeCount, "Invalid DrawBlendMode or DrawBlendMode::NoBlend passed into FrameMan::SetColorTable. See DrawBlendMode enumeration for defined values.");
@@ -426,11 +490,10 @@ bool FrameMan::LoadPalette(const std::string& palettePath) {
SDL_Palette* palette = SDL_GetSurfacePalette(paletteImage);
for (size_t i = 0; i < 256; i++) {
m_Palette[i] = {
- palette->colors[i].r,
- palette->colors[i].g,
- palette->colors[i].b,
- 0
- };
+ palette->colors[i].r,
+ palette->colors[i].g,
+ palette->colors[i].b,
+ 0};
}
SDL_DestroySurface(paletteImage);
@@ -450,9 +513,10 @@ int FrameMan::SaveBitmap(SaveBitmapMode modeToSave, const std::string& nameBase,
if (nameBase.empty() || nameBase.size() <= 0) {
return -1;
}
+ set_palette(m_DefaultPalette);
// TODO: Remove this once GCC13 is released and switched to. std::format and std::chrono::time_zone are not part of latest libstdc++.
-#if defined(__GNUC__) && (__GNUC__ < 13 || defined(__APPLE__)) //FIXME: macOS for some reason builds with incorrect iconv in CI which breaks format, could not debug.
+#if defined(__GNUC__) && (__GNUC__ < 13 || defined(__APPLE__)) // FIXME: macOS for some reason builds with incorrect iconv in CI which breaks format, could not debug.
std::chrono::time_point now = std::chrono::system_clock::now();
time_t currentTime = std::chrono::system_clock::to_time_t(now);
tm* localCurrentTime = std::localtime(¤tTime);
@@ -461,7 +525,7 @@ int FrameMan::SaveBitmap(SaveBitmapMode modeToSave, const std::string& nameBase,
std::array fullFileNameBuffer = {};
// We can't get sub-second precision from timeBuffer so we'll append absolute time to not overwrite the same file when dumping multiple times per second.
- std::snprintf(fullFileNameBuffer.data(), sizeof(fullFileNameBuffer), "%s/%s_%s.%zi.png", System::GetScreenshotDirectory().c_str(), nameBase.c_str(), formattedTimeAndDate.data(), g_TimerMan.GetAbsoluteTime());
+ std::snprintf(fullFileNameBuffer.data(), sizeof(fullFileNameBuffer), "%s/%s_%s.%lli.png", System::GetScreenshotDirectory().c_str(), nameBase.c_str(), formattedTimeAndDate.data(), g_TimerMan.GetAbsoluteTime());
std::string fullFileName(fullFileNameBuffer.data());
#else
@@ -478,23 +542,21 @@ int FrameMan::SaveBitmap(SaveBitmapMode modeToSave, const std::string& nameBase,
}
break;
case ScreenDump:
- if (m_BackBuffer32 && m_ScreenDumpBuffer) {
+ if (m_ScreenDumpBuffer) {
SaveScreenToBitmap();
// Make a copy of the buffer because it may be overwritten mid thread and everything will be on fire.
- BITMAP* outputBitmap = create_bitmap_ex(bitmap_color_depth(m_ScreenDumpBuffer.get()), m_ScreenDumpBuffer->w, m_ScreenDumpBuffer->h);
- stretch_blit(m_ScreenDumpBuffer.get(), outputBitmap, 0, 0, m_ScreenDumpBuffer->w, m_ScreenDumpBuffer->h, 0, 0, outputBitmap->w, outputBitmap->h);
-
- auto saveScreenDump = [fullFileName](BITMAP* bitmapToSaveCopy) {
+ SDL_Surface* saveSurface = SDL_ConvertSurface(m_ScreenDumpBuffer.get(), m_ScreenDumpBuffer->format);
+ auto saveScreenDump = [fullFileName](SDL_Surface* bitmapToSaveCopy) {
// nullptr for the PALETTE parameter here because we're saving a 24bpp file and it's irrelevant.
- if (save_png(fullFileName.c_str(), bitmapToSaveCopy, nullptr) == 0) {
+ if (IMG_SavePNG(bitmapToSaveCopy, fullFileName.c_str()) == 0) {
g_ConsoleMan.PrintString("SYSTEM: Screen was dumped to: " + fullFileName);
} else {
g_ConsoleMan.PrintString("ERROR: Unable to save bitmap to: " + fullFileName);
}
- destroy_bitmap(bitmapToSaveCopy);
+ // SDL_FreeSurface(bitmapToSaveCopy);
};
- std::thread saveThread(saveScreenDump, outputBitmap);
+ std::thread saveThread(saveScreenDump, saveSurface);
saveThread.detach();
saveSuccess = true;
@@ -522,12 +584,19 @@ int FrameMan::SaveBitmap(SaveBitmapMode modeToSave, const std::string& nameBase,
BITMAP* depthConvertBitmap = create_bitmap_ex(24, m_WorldDumpBuffer->w, m_WorldDumpBuffer->h);
blit(m_WorldDumpBuffer.get(), depthConvertBitmap, 0, 0, 0, 0, m_WorldDumpBuffer->w, m_WorldDumpBuffer->h);
-
- if (save_png(fullFileName.c_str(), depthConvertBitmap, nullptr) == 0) {
+ SDL_Surface* saveSurface = SDL_CreateSurfaceFrom(
+ depthConvertBitmap->w,
+ depthConvertBitmap->h,
+ SDL_PIXELFORMAT_RGB24,
+ depthConvertBitmap->dat,
+ 3);
+
+ if (IMG_SavePNG(saveSurface, fullFileName.c_str()) == 0) {
g_ConsoleMan.PrintString("SYSTEM: World was dumped to: " + fullFileName);
saveSuccess = true;
}
destroy_bitmap(depthConvertBitmap);
+ SDL_DestroySurface(saveSurface);
}
break;
default:
@@ -547,28 +616,31 @@ void FrameMan::SaveScreenToBitmap() {
return;
}
+ glPixelStorei(GL_PACK_ALIGNMENT, 4);
GL_CHECK(glBindTexture(GL_TEXTURE_2D, g_WindowMan.GetScreenBuffer()->GetColorTexture().id));
- GL_CHECK(glGetTexImage(GL_TEXTURE_2D, 0, GL_RGB, GL_UNSIGNED_BYTE, m_ScreenDumpBuffer->line[0]));
+ GL_CHECK(glGetTexImage(GL_TEXTURE_2D, 0, GL_RGB, GL_UNSIGNED_BYTE, m_ScreenDumpBuffer->pixels));
+
+ // Flip the pixels
+ std::vector temp(m_ScreenDumpBuffer->pitch);
+ char* pixels = reinterpret_cast(m_ScreenDumpBuffer->pixels);
+ size_t pitch = m_ScreenDumpBuffer->pitch;
+ for (size_t y = 0; y < m_ScreenDumpBuffer->h / 2; ++y) {
+ std::swap_ranges(pixels + y * pitch, pixels + (y + 1) * pitch, pixels + (m_ScreenDumpBuffer->h - y - 1) * pitch);
+ }
}
int FrameMan::SaveIndexedPNG(const char* fileName, BITMAP* bitmapToSave) const {
- // nullptr for the PALETTE parameter here because the bitmap is 32bpp and whatever we index it with will end up wrong anyway.
- save_png(fileName, bitmapToSave, nullptr);
-
- int lastColorConversionMode = get_color_conversion();
- set_color_conversion(COLORCONV_REDUCE_TO_256);
- // nullptr for the PALETTE parameter here because we don't need the bad palette from it and don't want it to overwrite anything.
- BITMAP* tempLoadBitmap = load_bitmap(fileName, nullptr);
- std::remove(fileName);
-
- BITMAP* tempConvertingBitmap = create_bitmap_ex(8, bitmapToSave->w, bitmapToSave->h);
- blit(tempLoadBitmap, tempConvertingBitmap, 0, 0, 0, 0, tempConvertingBitmap->w, tempConvertingBitmap->h);
-
- int saveResult = save_png(fileName, tempConvertingBitmap, m_Palette);
-
- set_color_conversion(lastColorConversionMode);
- destroy_bitmap(tempLoadBitmap);
- destroy_bitmap(tempConvertingBitmap);
+ set_palette(m_DefaultPalette);
+ SDL_Surface* surface = SDL_CreateSurfaceFrom(bitmapToSave->w,
+ bitmapToSave->h,
+ SDL_PIXELFORMAT_INDEX8,
+ bitmapToSave->dat,
+ bitmap_color_depth(bitmapToSave) / 8);
+ SDL_Palette* pal = ContentFile::DefaultPaletteToSDL();
+ SDL_SetSurfacePalette(surface, pal);
+ int saveResult = IMG_SavePNG(surface, fileName);
+ SDL_DestroyPalette(pal);
+ SDL_DestroySurface(surface);
return saveResult;
}
@@ -737,7 +809,7 @@ void FrameMan::Draw() {
ZoneScopedN("Draw");
TracyGpuZone("FrameMan::Draw");
- //rlSetShader(rlGetShaderIdDefault(), rlGetShaderLocsDefault());
+ // rlSetShader(rlGetShaderIdDefault(), rlGetShaderLocsDefault());
Shader backgroundShader;
g_PresetMan.GetEntityPreset("Shader", "Background")->Clone(&backgroundShader);
glClearColor(0.0f, 0.0f, 0.0f, 0.0f);
@@ -763,13 +835,13 @@ void FrameMan::Draw() {
rlSetBlendMode(RL_BLEND_ALPHA);
rlEnableDepthTest();
- m_PlayerScreen->Begin(true);
+ m_PlayerScreen->Begin(true, 1.0f);
backgroundShader.Begin();
backgroundShader.Enable();
rlSetUniformSampler(backgroundShader.GetUniformLocation("rtePalette"), g_PostProcessMan.GetPaletteTexture());
backgroundShader.SetInt("drawMasked", 1);
- //rlSetUniformSampler(backgroundShader.GetUniformLocation("rtePalette"), g_PostProcessMan.GetPaletteTexture());
+ // rlSetUniformSampler(backgroundShader.GetUniformLocation("rtePalette"), g_PostProcessMan.GetPaletteTexture());
BITMAP* drawScreen = (screenCount == 1) ? m_BackBuffer8.get() : m_PlayerScreen8.get();
BITMAP* drawScreenGUI = (screenCount == 1) ? m_BackBuffer8.get() : m_PlayerScreen8.get();
// Need to clear the backbuffers because Scene background layers can be too small to fill the whole backbuffer or drawn masked resulting in artifacts from the previous frame.
@@ -796,6 +868,8 @@ void FrameMan::Draw() {
// Draw the scene
g_SceneMan.Draw(drawScreen, drawScreenGUI, targetPos);
+ g_PrimitiveMan.DrawPrimitives(playerScreen, drawScreenGUI, targetPos);
+
// Get only the scene-relative post effects that affect this player's screen
if (pActivity) {
g_PostProcessMan.GetPostScreenEffectsWrapped(targetPos, drawScreen->w, drawScreen->h, screenRelativeEffects, pActivity->GetTeamOfPlayer(pActivity->PlayerOfScreen(playerScreen)));
@@ -844,7 +918,7 @@ void FrameMan::Draw() {
}
rlEnableDepthTest();
- rlZDepth(c_GuiDepth-1.0f);
+ rlZDepth(c_GuiDepth - 1.0f);
g_GLResourceMan.UpdateDynamicBitmap(m_BackBuffer8.get(), true);
backgroundShader.Begin();
backgroundShader.Enable();
@@ -921,7 +995,39 @@ void FrameMan::DrawScreenFlash(int playerScreen, BITMAP* playerGUIBitmap) {
if (m_FlashedLastFrame[playerScreen]) {
m_FlashedLastFrame[playerScreen] = false;
} else {
- rectfill(playerGUIBitmap, 0, 0, playerGUIBitmap->w, playerGUIBitmap->h, m_FlashScreenColor[playerScreen]);
+ rlZDepth(c_GuiDepth);
+ rlBegin(RL_QUADS);
+
+ rlColor4ub(m_FlashScreenColor[playerScreen], 0, 0, 50);
+ rlVertex2f(playerGUIBitmap->w * .25f, playerGUIBitmap->h * .25f);
+ rlVertex2f(playerGUIBitmap->w - playerGUIBitmap->w * .25f, playerGUIBitmap->h * 0.25f);
+ rlColor4ub(m_FlashScreenColor[playerScreen], 0, 0, 255);
+ rlVertex2f(playerGUIBitmap->w, 0.0f);
+ rlVertex2f(0.0f, 0.0f);
+
+ rlColor4ub(m_FlashScreenColor[playerScreen], 0, 0, 50);
+ rlVertex2f(playerGUIBitmap->w * .25f, playerGUIBitmap->h - playerGUIBitmap->h * .25f);
+ rlVertex2f(playerGUIBitmap->w * .25f, playerGUIBitmap->h * 0.25f);
+ rlColor4ub(m_FlashScreenColor[playerScreen], 0, 0, 255);
+ rlVertex2f(0.0f, 0.0f);
+ rlVertex2f(0.0f, playerGUIBitmap->h);
+
+ rlColor4ub(m_FlashScreenColor[playerScreen], 0, 0, 50);
+ rlVertex2f(playerGUIBitmap->w - playerGUIBitmap->w * .25f, playerGUIBitmap->h - playerGUIBitmap->h * .25f);
+ rlVertex2f(playerGUIBitmap->w * .25f, playerGUIBitmap->h - playerGUIBitmap->h * .25f);
+ rlColor4ub(m_FlashScreenColor[playerScreen], 0, 0, 255);
+ rlVertex2f(0.0f, playerGUIBitmap->h);
+ rlVertex2f(playerGUIBitmap->w, playerGUIBitmap->h);
+
+ rlColor4ub(m_FlashScreenColor[playerScreen], 0, 0, 50);
+ rlVertex2f(playerGUIBitmap->w - playerGUIBitmap->w * .25f, playerGUIBitmap->h * .25f);
+ rlVertex2f(playerGUIBitmap->w - playerGUIBitmap->w * .25f, playerGUIBitmap->h - playerGUIBitmap->h * .25f);
+ rlColor4ub(m_FlashScreenColor[playerScreen], 0, 0, 255);
+ rlVertex2f(playerGUIBitmap->w, playerGUIBitmap->h);
+ rlVertex2f(playerGUIBitmap->w, 0.0f);
+
+ rlEnd();
+ rlZDepth(c_DefaultDrawDepth);
m_FlashedLastFrame[playerScreen] = true;
}
}
diff --git a/Source/Managers/FrameMan.h b/Source/Managers/FrameMan.h
index be6e0daee7..a64ae9338e 100644
--- a/Source/Managers/FrameMan.h
+++ b/Source/Managers/FrameMan.h
@@ -21,6 +21,9 @@ namespace RTE {
struct BitmapDeleter {
void operator()(BITMAP* bitmap) const;
};
+ struct SurfaceDeleter {
+ void operator()(SDL_Surface* surface) const;
+ };
/// The singleton manager over the composition of frames.
class FrameMan : public Singleton {
@@ -188,6 +191,12 @@ namespace RTE {
/// Clears the 32bpp backbuffer with black.
void ClearBackBuffer32() { clear_to_color(m_BackBuffer32.get(), 0); }
+ /// Set the current GL Blend mode. This generally requires a batch flush.
+ /// @param blendMode The new blend mode to set.
+ /// @remark Some blendmodes are not possible to do within the limits of the usual gpu blending functions
+ /// and will make use of the blending shader instead, so if necessary restore the current shader after use.
+ void SetBlendMode(DrawBlendMode blendMode);
+
/// Sets a specific color table which is used for any subsequent blended drawing in indexed color modes.
/// @param blendMode The blending mode that will be used in drawing.
/// @param colorChannelBlendAmounts The color channel blend amounts that will be used to select or create the correct table in the specified blending mode.
@@ -354,7 +363,7 @@ namespace RTE {
std::shared_ptr m_BackBuffer8; //!< Screen backbuffer, always 8bpp, gets copied to the 32bpp buffer for post-processing.
std::unique_ptr m_BackBuffer32; //!< 32bpp backbuffer, only used for post-processing.
std::unique_ptr m_OverlayBitmap32; //!< 32bpp bitmap used for overlaying (fading in/out or darkening) the screen.
- std::unique_ptr m_ScreenDumpBuffer; //!< Temporary buffer for making quick screencaps. This is used for color conversion between 32bpp and 24bpp so we can save the file.
+ std::unique_ptr m_ScreenDumpBuffer; //!< Temporary buffer for making quick screencaps. This is used for color conversion between 32bpp and 24bpp so we can save the file.
std::unique_ptr m_WorldDumpBuffer; //!< Temporary buffer for making whole scene screencaps.
std::unique_ptr m_ScenePreviewDumpGradient; //!< BITMAP for the scene preview sky gradient (easier to load from a pre-made file because it's dithered).
std::unique_ptr m_ScreenDumpNamePlaceholder; //!< Dummy BITMAP for keeping naming continuity when saving ScreenDumps with multi-threading.
diff --git a/Source/Managers/GLResourceMan.cpp b/Source/Managers/GLResourceMan.cpp
index 64afad6a7f..7c7353675f 100644
--- a/Source/Managers/GLResourceMan.cpp
+++ b/Source/Managers/GLResourceMan.cpp
@@ -154,5 +154,5 @@ GLuint GLResourceMan::UpdateDynamicBitmap(BITMAP* bitmap, bool updated, const st
void GLResourceMan::DestroyBitmapInfo(BITMAP* bitmap) {
GLBitmapInfo* info = GetBitmapInfo(bitmap);
- glDeleteTextures(1, &info->m_Texture);
+ rlUnloadTexture(info->m_Texture);
}
\ No newline at end of file
diff --git a/Source/Managers/LuaMan.cpp b/Source/Managers/LuaMan.cpp
index d1762b2bc1..b423831ed3 100644
--- a/Source/Managers/LuaMan.cpp
+++ b/Source/Managers/LuaMan.cpp
@@ -94,10 +94,10 @@ void LuaStateWrapper::Initialize() {
.def("FileEOF", &LuaStateWrapper::FileEOF),
luabind::def("DeleteEntity", &LuaAdaptersUtility::DeleteEntity, luabind::adopt(_1)), // NOT a member function, so adopting _1 instead of the _2 for the first param, since there's no "this" pointer!!
- luabind::def("LERP", (float (*)(float, float, float, float, float)) & Lerp),
- luabind::def("Lerp", (float (*)(float, float, float, float, float)) & Lerp),
- luabind::def("Lerp", (Vector(*)(float, float, Vector, Vector, float)) & Lerp),
- luabind::def("Lerp", (Matrix(*)(float, float, Matrix, Matrix, float)) & Lerp),
+ luabind::def("LERP", (float (*)(float, float, float, float, float))&Lerp),
+ luabind::def("Lerp", (float (*)(float, float, float, float, float))&Lerp),
+ luabind::def("Lerp", (Vector(*)(float, float, Vector, Vector, float))&Lerp),
+ luabind::def("Lerp", (Matrix(*)(float, float, Matrix, Matrix, float))&Lerp),
luabind::def("EaseIn", &EaseIn),
luabind::def("EaseOut", &EaseOut),
luabind::def("EaseInOut", &EaseInOut),
@@ -212,7 +212,8 @@ void LuaStateWrapper::Initialize() {
RegisterLuaBindingsOfType(InputLuaBindings, SDL_GamepadAxis),
RegisterLuaBindingsOfType(MiscLuaBindings, AlarmEvent),
RegisterLuaBindingsOfType(MiscLuaBindings, Directions),
- RegisterLuaBindingsOfType(MiscLuaBindings, DrawBlendMode)];
+ RegisterLuaBindingsOfType(MiscLuaBindings, DrawBlendMode),
+ RegisterLuaBindingsOfType(MiscLuaBindings, DrawDepth)];
// Assign the manager instances to globals in the lua master state
luabind::globals(m_State)["TimerMan"] = &g_TimerMan;
diff --git a/Source/Managers/PostProcessMan.cpp b/Source/Managers/PostProcessMan.cpp
index bfd459c619..6081b966b1 100644
--- a/Source/Managers/PostProcessMan.cpp
+++ b/Source/Managers/PostProcessMan.cpp
@@ -326,7 +326,7 @@ void PostProcessMan::PostProcess() {
UpdatePalette();
// First copy the current 8bpp backbuffer to the 32bpp buffer; we'll add effects to it
- m_PostProcessFramebuffer->Begin(false);
+ m_PostProcessFramebuffer->Begin(true);
//m_Blit8->Begin();
//int paletteUniform = m_Blit8->GetUniformLocation("rtePalette");
//rlSetUniformSampler(paletteUniform, m_Palette8Texture);
@@ -340,6 +340,8 @@ void PostProcessMan::PostProcess() {
rlEnableColorBlend();
rlSetBlendFactorsSeparate(GL_ONE, GL_ONE_MINUS_SRC_COLOR, GL_ONE, GL_ONE_MINUS_SRC_ALPHA, GL_FUNC_ADD, GL_FUNC_ADD);
rlSetBlendMode(RL_BLEND_CUSTOM_SEPARATE);
+ m_PostProcessFramebuffer->End();
+ m_PostProcessFramebuffer->Begin(false);
m_PostProcessShader->Begin();
diff --git a/Source/Managers/PrimitiveMan.cpp b/Source/Managers/PrimitiveMan.cpp
index 7b3df14769..a16bc14beb 100644
--- a/Source/Managers/PrimitiveMan.cpp
+++ b/Source/Managers/PrimitiveMan.cpp
@@ -4,10 +4,15 @@
#include "SceneMan.h"
#include "ConsoleMan.h"
#include "MOSprite.h"
+#include "Shader.h"
#include "tracy/Tracy.hpp"
#include
+#include "Draw.h"
+#include "glad/gl.h"
+#include "Shader.h"
+#include "PresetMan.h"
using namespace RTE;
@@ -71,18 +76,7 @@ void PrimitiveMan::SchedulePrimitivesForBlendedDrawing(DrawBlendMode blendMode,
}
void PrimitiveMan::DrawLinePrimitive(int player, const Vector& startPos, const Vector& endPos, unsigned char color, int thickness) {
- if (thickness > 1) {
- Vector dirVector = g_SceneMan.ShortestDistance(startPos, endPos, g_SceneMan.SceneWrapsX()).SetMagnitude(static_cast(thickness - 1) / 2.0F).Perpendicularize();
- Vector pointA = startPos + dirVector;
- Vector pointB = startPos - dirVector;
- Vector pointC = endPos + dirVector;
- Vector pointD = endPos - dirVector;
-
- DrawTriangleFillPrimitive(player, pointA, pointB, pointC, color);
- DrawTriangleFillPrimitive(player, pointC, pointD, pointB, color);
- } else {
- SchedulePrimitive(std::make_unique(player, startPos, endPos, color));
- }
+ SchedulePrimitive(std::make_unique(player, startPos, endPos, thickness, color));
}
void PrimitiveMan::DrawArcPrimitive(const Vector& centerPos, float startAngle, float endAngle, int radius, unsigned char color) {
@@ -241,29 +235,51 @@ void PrimitiveMan::DrawPrimitives(int player, BITMAP* targetBitmap, const Vector
int lastDrawMode = DRAW_MODE_SOLID;
DrawBlendMode lastBlendMode = DrawBlendMode::NoBlend;
std::array lastBlendAmounts = {BlendAmountLimits::MinBlend, BlendAmountLimits::MinBlend, BlendAmountLimits::MinBlend, BlendAmountLimits::MinBlend};
-
+ GLint currentShader = rlGetShaderCurrent();
+ rlDrawRenderBatchActive();
+ if (GLAD_GL_KHR_blend_equation_advanced_coherent){
+ glBlendBarrierKHR();
+ rlEnableAdvancedColorBlend();
+ }
+ const Shader* background = dynamic_cast(g_PresetMan.GetEntityPreset("Shader", "Background"));
+ rlEnableColorBlend();
for (const std::unique_ptr& primitive: m_ScheduledPrimitives) {
if (int playerToDrawFor = primitive->m_Player; playerToDrawFor == player || playerToDrawFor == -1) {
+ rlDrawRenderBatchActive();
if (DrawBlendMode blendMode = primitive->m_BlendMode; blendMode > DrawBlendMode::NoBlend) {
if (const std::array& blendAmounts = primitive->m_ColorChannelBlendAmounts; blendMode != lastBlendMode || blendAmounts != lastBlendAmounts) {
- g_FrameMan.SetColorTable(blendMode, blendAmounts);
+ if (lastBlendMode == BlendDissolve) {
+ background->Begin();
+ }
+ rlEnableShader(rlGetShaderCurrent());
+ g_FrameMan.SetBlendMode(blendMode);
+ GLint colorUniform = glGetUniformLocation(rlGetShaderCurrent(), "rteColor");
+ glUniform4f(colorUniform, blendAmounts[0] / static_cast(MaxBlend), blendAmounts[1] / static_cast(MaxBlend), blendAmounts[2] / static_cast(MaxBlend), blendAmounts[3] / static_cast(MaxBlend));
lastBlendMode = blendMode;
lastBlendAmounts = blendAmounts;
}
- if (lastDrawMode != DRAW_MODE_TRANS) {
- // Drawing mode is set so blending effects apply to true primitives. For bitmap based primitives it has no effect.
- drawing_mode(DRAW_MODE_TRANS, nullptr, 0, 0);
- lastDrawMode = DRAW_MODE_TRANS;
- }
} else {
- if (lastDrawMode != DRAW_MODE_SOLID) {
- drawing_mode(DRAW_MODE_SOLID, nullptr, 0, 0);
- lastDrawMode = DRAW_MODE_SOLID;
- }
+ g_FrameMan.SetBlendMode(BlendTransparency);
+ rlEnableShader(currentShader);
+ GLint colorUniform = glGetUniformLocation(rlGetShaderCurrent(), "rteColor");
+ glUniform4f(colorUniform, 1.0f, 1.0f, 1.0f, 1.0f);
lastBlendMode = DrawBlendMode::NoBlend;
}
- primitive->Draw(targetBitmap, targetPos);
+ if (GLAD_GL_KHR_blend_equation_advanced_coherent) {
+ glBlendBarrierKHR();
+ }
+ rlZDepth(primitive->m_Depth);
+ primitive->DrawTiled(targetBitmap, targetPos);
}
}
+ rlDrawRenderBatchActive();
+ if (GLAD_GL_KHR_blend_equation_advanced_coherent) {
+ rlDisableAdvancedColorBlend();
+ }
+ rlSetBlendMode(RL_BLEND_ALPHA);
+ background->Begin();
+ GLint colorUniform = glGetUniformLocation(rlGetShaderCurrent(), "rteColor");
+ glUniform4f(colorUniform, 1.0f, 1.0f, 1.0f, 1.0f);
+ rlZDepth(c_DefaultDrawDepth);
drawing_mode(DRAW_MODE_SOLID, nullptr, 0, 0);
}
diff --git a/Source/Managers/SceneMan.cpp b/Source/Managers/SceneMan.cpp
index 89a49efb1e..70e39ecc37 100644
--- a/Source/Managers/SceneMan.cpp
+++ b/Source/Managers/SceneMan.cpp
@@ -2631,8 +2631,6 @@ void SceneMan::Draw(BITMAP* targetBitmap, BITMAP* targetGUIBitmap, const Vector&
g_MovableMan.DrawHUD(targetGUIBitmap, targetPos, m_LastUpdatedScreen);
}
- g_PrimitiveMan.DrawPrimitives(m_LastUpdatedScreen, targetGUIBitmap, targetPos);
-
if (shouldDrawHUD) {
g_ActivityMan.GetActivity()->DrawGUI(targetGUIBitmap, targetPos, m_LastUpdatedScreen);
}
diff --git a/Source/Managers/UInputMan.h b/Source/Managers/UInputMan.h
index 70bb1f27dd..3a66f0c478 100644
--- a/Source/Managers/UInputMan.h
+++ b/Source/Managers/UInputMan.h
@@ -188,7 +188,7 @@ namespace RTE {
/// Gets the state of either Alt key.
/// @return The state of either Alt key.
- bool FlagAltState() const { return (SDL_GetModState() & SDL_KMOD_ALT) > 0; }
+ bool FlagAltState() const { return (SDL_GetModState() & SDL_KMOD_ALT | SDL_KMOD_MODE) > 0; }
/// Gets the state of the Left Shift key.
/// @return The state of the Left Shift key.
diff --git a/Source/Managers/WindowMan.cpp b/Source/Managers/WindowMan.cpp
index adfa755f09..c0976ad8fc 100644
--- a/Source/Managers/WindowMan.cpp
+++ b/Source/Managers/WindowMan.cpp
@@ -109,7 +109,7 @@ void WindowMan::Initialize() {
SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 1);
SDL_GL_SetAttribute(SDL_GL_CONTEXT_MAJOR_VERSION, 3);
SDL_GL_SetAttribute(SDL_GL_CONTEXT_MINOR_VERSION, 3);
- SDL_GL_SetAttribute(SDL_GL_CONTEXT_PROFILE_MASK, SDL_GL_CONTEXT_PROFILE_CORE);
+ SDL_GL_SetAttribute(SDL_GL_CONTEXT_PROFILE_MASK, SDL_GL_CONTEXT_PROFILE_COMPATIBILITY);
CreatePrimaryWindow();
InitializeOpenGL();
@@ -721,8 +721,6 @@ void WindowMan::ClearBackbuffer(bool clearFrameMan) {
if (clearFrameMan) {
g_FrameMan.ClearBackBuffer32();
}
- m_ScreenBuffer->Begin(true);
- m_ScreenBuffer->End();
GL_CHECK(glActiveTexture(GL_TEXTURE0));
GL_CHECK(glBindTexture(GL_TEXTURE_2D, 0));
GL_CHECK(glActiveTexture(GL_TEXTURE1));
@@ -732,7 +730,7 @@ void WindowMan::ClearBackbuffer(bool clearFrameMan) {
void WindowMan::UploadFrame() {
- m_ScreenBuffer->Begin(false);
+ m_ScreenBuffer->Begin(g_ActivityMan.IsInActivity());
rlDisableDepthTest();
rlDisableColorBlend();
diff --git a/Source/Menus/LoadingScreen.cpp b/Source/Menus/LoadingScreen.cpp
index 0858acbab7..0056fc89a9 100644
--- a/Source/Menus/LoadingScreen.cpp
+++ b/Source/Menus/LoadingScreen.cpp
@@ -15,12 +15,15 @@
#include "raylib/raylib.h"
#include "raylib/rlgl.h"
+#include "RenderTarget.h"
using namespace RTE;
+LoadingScreen::LoadingScreen() { Clear(); }
void LoadingScreen::Clear() {
m_LoadingLogWriter = nullptr;
m_LoadingSplashBitmap = nullptr;
+ m_LoadingBackground.reset();
m_ProgressListboxBitmap = nullptr;
m_ProgressListboxPosX = 0;
m_ProgressListboxPosY = 0;
@@ -69,13 +72,21 @@ void LoadingScreen::CreateLoadingSplash(int xOffset) {
m_LoadingSplashBitmap = create_bitmap_ex(FrameMan::c_BPP, backbuffer->w, backbuffer->h);
clear_bitmap(m_LoadingSplashBitmap);
- StaticSceneLayer loadingSplash;
- loadingSplash.Create(ContentFile("Base.rte/GUIs/Title/LoadingSplash.png").GetAsBitmap(COLORCONV_NONE, false), false, Vector(), true, false, Vector(1.0F, 0));
- loadingSplash.SetOffset(Vector(static_cast(((loadingSplash.GetBitmap()->w - g_WindowMan.GetResX()) / 2) + xOffset), 0));
-
- Box loadingSplashTargetBox(Vector(0, static_cast((g_WindowMan.GetResY() - loadingSplash.GetBitmap()->h) / 2)), static_cast(g_WindowMan.GetResX()), static_cast(loadingSplash.GetBitmap()->h));
+ m_LoadingBackground = std::make_unique();
+ m_LoadingBackground->Create(ContentFile("Base.rte/GUIs/Title/LoadingSplash.png").GetAsBitmap(COLORCONV_NONE, false), false, Vector(), true, false, Vector(1.0F, 0));
+ m_LoadingBackground->SetOffset(Vector(static_cast(((m_LoadingBackground->GetBitmap()->w - g_WindowMan.GetResX()) / 2) + xOffset), 0));
+
+ Box loadingSplashTargetBox(Vector(0, static_cast((g_WindowMan.GetResY() - m_LoadingBackground->GetBitmap()->h) / 2)), static_cast(g_WindowMan.GetResX()), static_cast(m_LoadingBackground->GetBitmap()->h));
+ RenderTarget defaultTarget{
+ FloatRect(0, 0, g_WindowMan.GetResX(), g_WindowMan.GetResY()),
+ FloatRect(0, 0, g_WindowMan.GetResX(), g_WindowMan.GetResY()),
+ 0,
+ Texture2D(),
+ true
+ };
+ defaultTarget.Begin();
g_WindowMan.ClearBackbuffer();
- loadingSplash.Draw(loadingSplashTargetBox, loadingSplashTargetBox);
+ m_LoadingBackground->Draw(loadingSplashTargetBox, loadingSplashTargetBox);
rlDrawRenderBatchActive();
g_WindowMan.Present();
}
@@ -140,7 +151,10 @@ void LoadingScreen::LoadingSplashProgressReport(const std::string& reportString,
blit(g_LoadingScreen.m_ProgressListboxBitmap, g_FrameMan.GetBackBuffer32(), 0, 0, g_LoadingScreen.m_ProgressListboxPosX, g_LoadingScreen.m_ProgressListboxPosY, g_LoadingScreen.m_ProgressListboxBitmap->w, g_LoadingScreen.m_ProgressListboxBitmap->h);
+ Box loadingSplashTargetBox(Vector(0, static_cast((g_WindowMan.GetResY() - g_LoadingScreen.m_LoadingBackground->GetBitmap()->h) / 2)), static_cast(g_WindowMan.GetResX()), static_cast(g_LoadingScreen.m_LoadingBackground->GetBitmap()->h));
g_WindowMan.ClearBackbuffer(false);
+ g_WindowMan.GetScreenBuffer()->Begin();
+ g_LoadingScreen.m_LoadingBackground->Draw(loadingSplashTargetBox, loadingSplashTargetBox);
g_WindowMan.UploadFrame();
}
}
diff --git a/Source/Menus/LoadingScreen.h b/Source/Menus/LoadingScreen.h
index 359d2fb598..f7e121c0cf 100644
--- a/Source/Menus/LoadingScreen.h
+++ b/Source/Menus/LoadingScreen.h
@@ -13,6 +13,7 @@ namespace RTE {
class GUIInputWrapper;
class GUIControlManager;
class Writer;
+ class StaticSceneLayer;
/// Handling for the loading screen composition and loading progress box when starting the game.
class LoadingScreen : public Singleton {
@@ -20,7 +21,7 @@ namespace RTE {
public:
#pragma region Creation
/// Constructor method used to instantiate a LoadingScreen object in system memory.
- LoadingScreen() { Clear(); }
+ LoadingScreen();
/// Makes the LoadingScreen object ready for use.
/// @param guiScreen Pointer to a GUIScreen interface that will be used by this LoadingScreen's GUIControlManager. Ownership is NOT transferred!
@@ -58,6 +59,7 @@ namespace RTE {
BITMAP* m_LoadingSplashBitmap; //!< BITMAP that is used for drawing the splash screen.
BITMAP* m_ProgressListboxBitmap; //!< BITMAP that the progress report will be drawn into.
+ std::unique_ptr m_LoadingBackground; //!< Loading Screen Background image.
int m_ProgressListboxPosX; //!< Position of the progress report box on X axis.
int m_ProgressListboxPosY; //!< Position of the progress report box on Y axis.
diff --git a/Source/Menus/SceneEditorGUI.cpp b/Source/Menus/SceneEditorGUI.cpp
index 03004a56d6..63386f51be 100644
--- a/Source/Menus/SceneEditorGUI.cpp
+++ b/Source/Menus/SceneEditorGUI.cpp
@@ -25,6 +25,9 @@
#include "BunkerAssemblyScheme.h"
#include "GLResourceMan.h"
+#include "tracy/Tracy.hpp"
+#include "tracy/TracyOpenGL.hpp"
+#include "BigTexture.h"
#include
#include
@@ -1179,14 +1182,19 @@ void SceneEditorGUI::Update() {
}
}
-void SceneEditorGUI::Draw(BITMAP* pTargetBitmap, const Vector& targetPos) const {
+void SceneEditorGUI::Draw(BITMAP* pTargetBitmap, const Vector& targetPos) {
+ ZoneScoped;
+ TracyGpuZone("SceneEditor Draw");
// Done, so don't draw the UI
if (m_EditorGUIMode == DONEEDITING)
return;
- BITMAP* temp = create_bitmap_ex(bitmap_color_depth(pTargetBitmap), pTargetBitmap->w, pTargetBitmap->h);
- clear_to_color(temp, 0);
-
+ if (!m_DrawTexture || (m_DrawTexture->m_Width != pTargetBitmap->w && m_DrawTexture->m_Height != pTargetBitmap->h)) {
+ BITMAP* temp = create_bitmap_ex(bitmap_color_depth(pTargetBitmap), pTargetBitmap->w, pTargetBitmap->h);
+ m_DrawBitmap = std::unique_ptr(temp);
+ m_DrawTexture = std::make_unique(m_DrawBitmap.get());
+ }
+ clear_to_color(m_DrawBitmap.get(), 0);
// The get a std::list of the currently edited set of placed objects in the Scene
const std::list* pSceneObjectList = 0;
if (m_FeatureSet == ONLOADEDIT)
@@ -1196,22 +1204,22 @@ void SceneEditorGUI::Draw(BITMAP* pTargetBitmap, const Vector& targetPos) const
// Draw the 'original' set of placed scene objects as solid before the blueprints
const std::list* pOriginalsList = g_SceneMan.GetScene()->GetPlacedObjects(Scene::PLACEONLOAD);
for (std::list::const_iterator itr = pOriginalsList->begin(); itr != pOriginalsList->end(); ++itr) {
- (*itr)->Draw(temp, targetPos);
+ (*itr)->Draw(m_DrawBitmap.get(), targetPos);
// Draw basic HUD if an actor
Actor* pActor = dynamic_cast(*itr);
// if (pActor)
- // pActor->DrawHUD(temp, targetPos);
+ // pActor->DrawHUD(m_DrawBitmap.get(), targetPos);
}
} else if (m_FeatureSet == AIPLANEDIT) {
pSceneObjectList = g_SceneMan.GetScene()->GetPlacedObjects(Scene::AIPLAN);
// Draw the 'original' set of placed scene objects as solid before the planned base
const std::list* pOriginalsList = g_SceneMan.GetScene()->GetPlacedObjects(Scene::PLACEONLOAD);
for (std::list::const_iterator itr = pOriginalsList->begin(); itr != pOriginalsList->end(); ++itr) {
- (*itr)->Draw(temp, targetPos);
+ (*itr)->Draw(m_DrawBitmap.get(), targetPos);
// Draw basic HUD if an actor
Actor* pActor = dynamic_cast(*itr);
// if (pActor)
- // pActor->DrawHUD(temp, targetPos);
+ // pActor->DrawHUD(m_DrawBitmap.get(), targetPos);
}
}
@@ -1225,7 +1233,7 @@ void SceneEditorGUI::Draw(BITMAP* pTargetBitmap, const Vector& targetPos) const
// Draw the currently held object into the order of the std::list if it is to be placed inside
if (m_pCurrentObject && m_DrawCurrentObject && i == m_ObjectListOrder) {
g_FrameMan.SetTransTableFromPreset(m_BlinkTimer.AlternateReal(333) || m_EditorGUIMode == PLACINGOBJECT ? TransparencyPreset::LessTrans : TransparencyPreset::HalfTrans);
- m_pCurrentObject->Draw(temp, targetPos, g_DrawTrans);
+ m_pCurrentObject->Draw(m_DrawBitmap.get(), targetPos, g_DrawTrans);
pActor = dynamic_cast(m_pCurrentObject);
if (pActor)
pActor->DrawHUD(pTargetBitmap, targetPos);
@@ -1238,7 +1246,7 @@ void SceneEditorGUI::Draw(BITMAP* pTargetBitmap, const Vector& targetPos) const
// Blink trans if we are supposed to blink this one
if ((*itr) == m_pObjectToBlink) {
g_FrameMan.SetTransTableFromPreset(m_BlinkTimer.AlternateReal(333) ? TransparencyPreset::LessTrans : TransparencyPreset::HalfTrans);
- (*itr)->Draw(temp, targetPos, g_DrawTrans);
+ (*itr)->Draw(m_DrawBitmap.get(), targetPos, g_DrawTrans);
}
// Drawing of already placed objects that aren't highlighted or anything
else {
@@ -1249,15 +1257,15 @@ void SceneEditorGUI::Draw(BITMAP* pTargetBitmap, const Vector& targetPos) const
// Animate the ghosted into appearing solid in the build order to make the order clear
if (i >= m_RevealIndex) {
g_FrameMan.SetTransTableFromPreset(pActor ? TransparencyPreset::MoreTrans : TransparencyPreset::HalfTrans);
- (*itr)->Draw(temp, targetPos, g_DrawTrans);
+ (*itr)->Draw(m_DrawBitmap.get(), targetPos, g_DrawTrans);
}
// Show as non-transparent half the time to still give benefits of WYSIWYG
else
- (*itr)->Draw(temp, targetPos);
+ (*itr)->Draw(m_DrawBitmap.get(), targetPos);
}
// In full scene edit mode, we want to give a WYSIWYG view
else {
- (*itr)->Draw(temp, targetPos);
+ (*itr)->Draw(m_DrawBitmap.get(), targetPos);
// Draw team marks for doors, deployments and assemblies
Deployment* pDeployment = dynamic_cast(*itr);
@@ -1298,7 +1306,7 @@ void SceneEditorGUI::Draw(BITMAP* pTargetBitmap, const Vector& targetPos) const
if ((m_pCurrentObject && !m_pCurrentObject->IsInGroup("Brains")) && m_EditorGUIMode != INSTALLINGBRAIN && !(m_EditorGUIMode == PLACINGOBJECT && m_PreviousMode == INSTALLINGBRAIN)) {
SceneObject* pBrain = g_SceneMan.GetScene()->GetResidentBrain(m_pController->GetPlayer());
if (pBrain) {
- pBrain->Draw(temp, targetPos);
+ pBrain->Draw(m_DrawBitmap.get(), targetPos);
// Draw basic HUD if an actor
Actor* pActor = dynamic_cast(pBrain);
if (pActor)
@@ -1317,27 +1325,24 @@ void SceneEditorGUI::Draw(BITMAP* pTargetBitmap, const Vector& targetPos) const
}
// If the held object will be placed at the end of the std::list, draw it last to the scene, transperent blinking
else if (m_pCurrentObject && (m_ObjectListOrder < 0 || (pSceneObjectList && m_ObjectListOrder == pSceneObjectList->size()))) {
+ rlZDepth(c_GuiDepth);
g_FrameMan.SetTransTableFromPreset(m_BlinkTimer.AlternateReal(333) || m_EditorGUIMode == PLACINGOBJECT ? TransparencyPreset::LessTrans : TransparencyPreset::HalfTrans);
- m_pCurrentObject->Draw(temp, targetPos, g_DrawTrans);
+ m_pCurrentObject->Draw(m_DrawBitmap.get(), targetPos, g_DrawTrans);
Actor* pActor = dynamic_cast(m_pCurrentObject);
if (pActor && m_FeatureSet != BLUEPRINTEDIT && m_FeatureSet != AIPLANEDIT)
pActor->DrawHUD(pTargetBitmap, targetPos);
+ rlZDepth(c_DefaultDrawDepth);
}
m_pPicker->Draw(pTargetBitmap);
+ m_DrawTexture->Update(Box(Vector(), m_DrawTexture->m_Width, m_DrawTexture->m_Height));
+ rlZDepth(-1);
+ m_DrawTexture->Draw(Box(Vector(), m_DrawTexture->m_Width, m_DrawTexture->m_Height), Box(Vector(), m_DrawTexture->m_Width, m_DrawTexture->m_Height));
+ rlZDepth(0);
+
// Draw the pie menu
m_PieMenu->Draw(pTargetBitmap, targetPos);
-
- Texture2D tempTexture = g_GLResourceMan.GetStaticTextureFromBitmap(temp);
-
- rlZDepth(3);
- DrawTexture(tempTexture, 0, 0, {255, 255, 255, 255});
- rlZDepth(0.0f);
- rlDrawRenderBatchActive();
-
- g_GLResourceMan.DestroyBitmapInfo(temp);
- destroy_bitmap(temp);
}
void SceneEditorGUI::UpdateBrainSkyPathAndCost(Vector brainPos) {
diff --git a/Source/Menus/SceneEditorGUI.h b/Source/Menus/SceneEditorGUI.h
index ac72327824..c255e43838 100644
--- a/Source/Menus/SceneEditorGUI.h
+++ b/Source/Menus/SceneEditorGUI.h
@@ -22,6 +22,7 @@ namespace RTE {
class SceneObject;
class ObjectPickerGUI;
class PieMenu;
+ struct BigTexture;
/// A full menu system that represents the scene editing GUI for Cortex Command
class SceneEditorGUI {
@@ -156,7 +157,7 @@ namespace RTE {
/// Draws the editor
/// @param pTargetBitmap The bitmap to draw on.
/// @param targetPos The absolute position of the target bitmap's upper left corner in the scene. (default: Vector())
- void Draw(BITMAP* pTargetBitmap, const Vector& targetPos = Vector()) const;
+ void Draw(BITMAP* pTargetBitmap, const Vector& targetPos = Vector());
/// Protected member variable and method declarations
protected:
@@ -240,6 +241,14 @@ namespace RTE {
static BITMAP* s_pInvalidPathDot;
// The current pathfinding request
std::shared_ptr m_PathRequest;
+
+ struct BitmapDeleter {
+ void operator() (BITMAP* bitmap) {
+ destroy_bitmap(bitmap);
+ }
+ };
+ std::unique_ptr m_DrawBitmap;
+ std::unique_ptr m_DrawTexture;
/// Private member variable and method declarations
private:
diff --git a/Source/Renderer/BigTexture.cpp b/Source/Renderer/BigTexture.cpp
index 0f88c141ea..b4aa5c0c5f 100644
--- a/Source/Renderer/BigTexture.cpp
+++ b/Source/Renderer/BigTexture.cpp
@@ -4,6 +4,8 @@
#include
#include "Draw.h"
#include "GLResourceMan.h"
+#include "tracy/Tracy.hpp"
+#include "tracy/TracyOpenGL.hpp"
using namespace RTE;
int BigTexture::s_MaxGLTextureSize{0};
@@ -14,10 +16,13 @@ BigTexture::BigTexture(BITMAP* bitmap) {
s_MaxGLTextureSize /= 2;
}
int bitsPerPixel = bitmap_color_depth(bitmap);
+ int bytesPerPixel = bitsPerPixel / 8;
m_Bitmap = bitmap;
GLBitmapInfo* bitmapExtra = g_GLResourceMan.MakeBitmapInfo();
bitmap->extra = reinterpret_cast(bitmapExtra);
PixelFormat format = bitsPerPixel == 8 ? PIXELFORMAT_UNCOMPRESSED_GRAYSCALE : PIXELFORMAT_UNCOMPRESSED_R8G8B8A8;
+ m_Width = bitmap->w;
+ m_Height = bitmap->h;
int height = bitmap->h;
for (int y = 0; y < bitmap->h; y += s_MaxGLTextureSize) {
@@ -35,6 +40,12 @@ BigTexture::BigTexture(BITMAP* bitmap) {
regionHeight,
1,
format);
+ GLuint uploadBuffer;
+ glGenBuffers(1, &uploadBuffer);
+ glBindBuffer(GL_PIXEL_UNPACK_BUFFER, uploadBuffer);
+ glBufferData(GL_PIXEL_UNPACK_BUFFER, regionWidth * regionHeight * bytesPerPixel + 1, NULL, GL_STREAM_DRAW);
+ glBindBuffer(GL_PIXEL_UNPACK_BUFFER, 0);
+ m_UploadBuffers.emplace_back(uploadBuffer);
width -= s_MaxGLTextureSize;
}
height -= s_MaxGLTextureSize;
@@ -48,6 +59,8 @@ BigTexture::~BigTexture() {
}
void BigTexture::Draw(Rectangle source, Rectangle dest) {
+ ZoneScoped;
+ TracyGpuZone("BigTexture::Draw");
float scaleX = dest.width / source.width;
float scaleY = dest.height / source.height;
Box sourceBox(Vector(source.x, source.y), source.width, source.height);
@@ -85,6 +98,8 @@ void BigTexture::Draw(Rectangle source, Rectangle dest) {
}
void BigTexture::Update(const Box& updateRegion) {
+ ZoneScoped;
+ TracyGpuZone("BigTexture Upload");
if (!m_Bitmap->extra) {
m_Bitmap->extra = reinterpret_cast(g_GLResourceMan.MakeBitmapInfo());
}
@@ -93,16 +108,22 @@ void BigTexture::Update(const Box& updateRegion) {
for (int i = 0; i < m_Regions.size(); ++i) {
Box intersect = updateRegion.GetIntersection(m_Regions[i]);
if (!intersect.IsEmpty()) {
- std::vector pixels(std::ceil(intersect.m_Width) * std::ceil(intersect.m_Height) * bytesPerPixel);
+ glBindBuffer(GL_PIXEL_UNPACK_BUFFER, m_UploadBuffers[i]);
+ size_t pixelsSize = std::ceil(intersect.m_Width) * std::ceil(intersect.m_Height) * bytesPerPixel;
+ unsigned char* pixels = (unsigned char*)glMapBufferRange(GL_PIXEL_UNPACK_BUFFER, (intersect.m_Corner.GetFloorIntY() %s_MaxGLTextureSize) * m_Textures[i].width + intersect.m_Corner.GetFloorIntX() % s_MaxGLTextureSize, pixelsSize, GL_MAP_WRITE_BIT|GL_MAP_INVALIDATE_BUFFER_BIT);
+
for (size_t y = 0; y < static_cast(std::ceil(intersect.m_Height)); y++) {
memcpy(
- pixels.data() + y * static_cast(intersect.m_Width) * bytesPerPixel,
+ pixels + y * static_cast(std::ceil(intersect.m_Width)) * bytesPerPixel,
m_Bitmap->line[y + intersect.m_Corner.GetFloorIntY()] + intersect.m_Corner.GetFloorIntX(),
std::ceil(intersect.m_Width) * bytesPerPixel
);
}
+ glUnmapBuffer(GL_PIXEL_UNPACK_BUFFER);
+
glBindTexture(GL_TEXTURE_2D, m_Textures[i].id);
+ glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
glTexSubImage2D(
GL_TEXTURE_2D,
0,
@@ -112,10 +133,11 @@ void BigTexture::Update(const Box& updateRegion) {
std::ceil(intersect.m_Height),
bytesPerPixel == 1 ? GL_RED : GL_RGBA,
GL_UNSIGNED_BYTE,
- pixels.data()
+ reinterpret_cast((intersect.m_Corner.GetFloorIntY() % s_MaxGLTextureSize) * m_Textures[i].width + intersect.m_Corner.GetFloorIntX() % s_MaxGLTextureSize)
);
glBindTexture(GL_TEXTURE_2D, 0);
+ glBindBuffer(GL_PIXEL_UNPACK_BUFFER, 0);
}
}
}
diff --git a/Source/Renderer/BigTexture.h b/Source/Renderer/BigTexture.h
index ecccb00e3a..8e5b0db2a1 100644
--- a/Source/Renderer/BigTexture.h
+++ b/Source/Renderer/BigTexture.h
@@ -21,6 +21,7 @@ namespace RTE {
/// @param dest The destination rectangle on the screen.
void Draw(Rectangle source, Rectangle dest);
std::vector m_Textures{}; //!< The tiles of this BigTexture.
+ std::vector m_UploadBuffers{}; //!< Upload buffers to reduce wait time on big uploads.
std::vector m_Regions{}; //!< The offset regions of each tile.
BITMAP* m_Bitmap{nullptr}; //!< The memory BITMAP, not owned.
int m_Width{0}; //!< The total width of this texture.
diff --git a/Source/Renderer/GraphicalPrimitive.cpp b/Source/Renderer/GraphicalPrimitive.cpp
new file mode 100644
index 0000000000..3b282d1a46
--- /dev/null
+++ b/Source/Renderer/GraphicalPrimitive.cpp
@@ -0,0 +1,273 @@
+#include "GraphicalPrimitive.h"
+#include "Matrix.h"
+#include "FrameMan.h"
+#include "SceneMan.h"
+#include "GLResourceMan.h"
+#include "SLTerrain.h"
+
+#include "GUI.h"
+#include "AllegroBitmap.h"
+
+#include "Draw.h"
+#include
+
+using namespace RTE;
+
+const GraphicalPrimitive::PrimitiveType GraphicalPrimitive::c_PrimitiveType = PrimitiveType::None;
+const GraphicalPrimitive::PrimitiveType LinePrimitive::c_PrimitiveType = PrimitiveType::Line;
+const GraphicalPrimitive::PrimitiveType ArcPrimitive::c_PrimitiveType = PrimitiveType::Arc;
+const GraphicalPrimitive::PrimitiveType SplinePrimitive::c_PrimitiveType = PrimitiveType::Spline;
+const GraphicalPrimitive::PrimitiveType BoxPrimitive::c_PrimitiveType = PrimitiveType::Box;
+const GraphicalPrimitive::PrimitiveType BoxFillPrimitive::c_PrimitiveType = PrimitiveType::BoxFill;
+const GraphicalPrimitive::PrimitiveType RoundedBoxPrimitive::c_PrimitiveType = PrimitiveType::RoundedBox;
+const GraphicalPrimitive::PrimitiveType RoundedBoxFillPrimitive::c_PrimitiveType = PrimitiveType::RoundedBoxFill;
+const GraphicalPrimitive::PrimitiveType CirclePrimitive::c_PrimitiveType = PrimitiveType::Circle;
+const GraphicalPrimitive::PrimitiveType CircleFillPrimitive::c_PrimitiveType = PrimitiveType::CircleFill;
+const GraphicalPrimitive::PrimitiveType EllipsePrimitive::c_PrimitiveType = PrimitiveType::Ellipse;
+const GraphicalPrimitive::PrimitiveType EllipseFillPrimitive::c_PrimitiveType = PrimitiveType::EllipseFill;
+const GraphicalPrimitive::PrimitiveType TrianglePrimitive::c_PrimitiveType = PrimitiveType::Triangle;
+const GraphicalPrimitive::PrimitiveType TriangleFillPrimitive::c_PrimitiveType = PrimitiveType::TriangleFill;
+const GraphicalPrimitive::PrimitiveType PolygonPrimitive::c_PrimitiveType = PrimitiveType::Polygon;
+const GraphicalPrimitive::PrimitiveType PolygonFillPrimitive::c_PrimitiveType = PrimitiveType::PolygonFill;
+const GraphicalPrimitive::PrimitiveType TextPrimitive::c_PrimitiveType = PrimitiveType::Text;
+const GraphicalPrimitive::PrimitiveType BitmapPrimitive::c_PrimitiveType = PrimitiveType::Bitmap;
+
+Vector GraphicalPrimitive::WrapCoordinates(Vector targetPos, const Vector& scenePos) const {
+ return targetPos + scenePos;
+}
+
+void GraphicalPrimitive::DrawTiled(BITMAP* drawScreen, const Vector& targetPos) {
+ Vector tiledTarget{targetPos};
+ if (g_SceneMan.SceneWrapsX()) {
+ tiledTarget.m_X = std::fmod(targetPos.m_X, g_SceneMan.GetSceneWidth());
+ }
+ if (g_SceneMan.SceneWrapsY()) {
+ tiledTarget.m_Y = std::fmod(targetPos.m_Y, g_SceneMan.GetSceneHeight());
+ }
+
+ float bitmapWidth = g_SceneMan.GetSceneWidth();
+ float bitmapHeight = g_SceneMan.GetSceneHeight();
+ float areaToCoverX = drawScreen->w + g_SceneMan.GetTerrain()->GetOffset().m_X;
+ float areaToCoverY = drawScreen->h + g_SceneMan.GetTerrain()->GetOffset().m_Y;
+
+ for (int tiledOffsetX = 0; tiledOffsetX < areaToCoverX;) {
+ float destX = tiledOffsetX - tiledTarget.m_X;
+
+ for (int tiledOffsetY = 0; tiledOffsetY < areaToCoverY;) {
+ float destY = tiledOffsetY - tiledTarget.m_Y;
+ Draw(drawScreen, Vector(destX, destY));
+ if (!g_SceneMan.SceneWrapsY()) {
+ break;
+ }
+ tiledOffsetY += bitmapHeight;
+ }
+ if (!g_SceneMan.SceneWrapsX()) {
+ break;
+ }
+ tiledOffsetX += bitmapWidth;
+ }
+ // Draw(drawScreen, targetPos);
+}
+
+void LinePrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos);
+ Vector drawEnd = WrapCoordinates(targetPos, m_EndPos);
+ DrawLineEx(drawStart, drawEnd, m_Thickness, {m_Color, 0, 0, 255});
+}
+
+void ArcPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos);
+ if (m_Thickness > 1) {
+ DrawRing(drawStart, m_Radius - (m_Thickness / 2.0f), m_Radius + (m_Thickness / 2.0f), m_StartAngle, m_EndAngle, std::abs(m_EndAngle - m_StartAngle), {m_Color, 0, 0, 255});
+ } else {
+ DrawRing(drawStart, m_Radius - 0.5f, m_Radius + 0.5f, m_StartAngle, m_EndAngle, std::abs(m_EndAngle - m_StartAngle), {m_Color, 0, 0, 255});
+ }
+}
+
+void SplinePrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos);
+ Vector drawGuideA = WrapCoordinates(targetPos, m_GuidePointAPos);
+ Vector drawGuideB = WrapCoordinates(targetPos, m_GuidePointBPos);
+ Vector drawEnd = WrapCoordinates(targetPos, m_EndPos);
+
+ std::array guidePoints = {drawStart, drawGuideA, drawGuideB, drawEnd};
+ DrawSplineBasis(guidePoints.data(), guidePoints.size(), 1, {m_Color, 0, 0, 255});
+}
+
+void BoxPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos);
+ Vector drawEnd = WrapCoordinates(targetPos, m_EndPos);
+ Vector dimensions = drawEnd - drawStart;
+ DrawRectangleLines(drawStart.m_X, drawStart.m_Y, dimensions.m_X, dimensions.m_Y, {m_Color, 0, 0, 255});
+}
+
+void BoxFillPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos);
+ Vector drawEnd = WrapCoordinates(targetPos, m_EndPos);
+ Vector dimensions = drawEnd - drawStart;
+ DrawRectangle(drawStart.m_X, drawStart.m_Y, dimensions.m_X, dimensions.m_Y, {m_Color, 0, 0, 255});
+}
+
+void RoundedBoxPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ if (m_StartPos.m_X > m_EndPos.m_X) {
+ std::swap(m_StartPos.m_X, m_EndPos.m_X);
+ }
+ if (m_StartPos.m_Y > m_EndPos.m_Y) {
+ std::swap(m_StartPos.m_Y, m_EndPos.m_Y);
+ }
+
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos);
+ Vector drawEnd = WrapCoordinates(targetPos, m_EndPos);
+ Vector ringCornerTopLeft(drawStart.GetFloorIntX() + m_CornerRadius, drawStart.GetFloorIntY() + m_CornerRadius);
+ Vector ringCornerBottomLeft(drawStart.GetFloorIntX() + m_CornerRadius, drawEnd.GetFloorIntY() - m_CornerRadius + 1.0f);
+ Vector ringCornerTopRight(drawEnd.GetFloorIntX() - m_CornerRadius + 1.0f, drawStart.GetFloorIntY() + m_CornerRadius);
+ Vector ringCornerBottomRight(drawEnd.GetFloorIntX() - m_CornerRadius + 1.0f, drawEnd.GetFloorIntY() - m_CornerRadius + 1.0f);
+
+ DrawRing(ringCornerTopLeft, m_CornerRadius - 1.0f, m_CornerRadius, -90, -180, 90, {m_Color, 0, 0, 255});
+ DrawRing(ringCornerBottomLeft, m_CornerRadius - 1.0f, m_CornerRadius, 90, 180, 90, {m_Color, 0, 0, 255});
+ DrawRing(ringCornerTopRight, m_CornerRadius - 1.0f, m_CornerRadius, 0, -90, 90, {m_Color, 0, 0, 255});
+ DrawRing(ringCornerBottomRight, m_CornerRadius - 1.0f, m_CornerRadius, 90, 0, 90, {m_Color, 0, 0, 255});
+ DrawRectangle(drawStart.GetFloorIntX() + m_CornerRadius, drawStart.GetFloorIntY(), drawEnd.GetFloorIntX() - drawStart.GetFloorIntX() - 2 * m_CornerRadius + 1, 1, {m_Color, 0, 0, 255});
+ DrawRectangle(drawStart.GetFloorIntX() + m_CornerRadius, drawEnd.GetFloorIntY(), drawEnd.GetFloorIntX() - drawStart.GetFloorIntX() - 2 * m_CornerRadius + 1, 1, {m_Color, 0, 0, 255});
+ DrawRectangle(drawStart.GetFloorIntX(), drawStart.GetFloorIntY() + m_CornerRadius, 1, drawEnd.GetFloorIntY() - drawStart.GetFloorIntY() - 2 * m_CornerRadius + 1, {m_Color, 0, 0, 255});
+ DrawRectangle(drawEnd.GetFloorIntX(), drawStart.GetFloorIntY() + m_CornerRadius, 1, drawEnd.GetFloorIntY() - drawStart.GetFloorIntY() - 2 * m_CornerRadius + 1, {m_Color, 0, 0, 255});
+}
+
+void RoundedBoxFillPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ if (m_StartPos.m_X > m_EndPos.m_X) {
+ std::swap(m_StartPos.m_X, m_EndPos.m_X);
+ }
+ if (m_StartPos.m_Y > m_EndPos.m_Y) {
+ std::swap(m_StartPos.m_Y, m_EndPos.m_Y);
+ }
+
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos);
+ Vector drawEnd = WrapCoordinates(targetPos, m_EndPos);
+ DrawCircle(drawStart.GetFloorIntX() + m_CornerRadius, drawStart.GetFloorIntY() + m_CornerRadius, m_CornerRadius, {m_Color, 0, 0, 255});
+ DrawCircle(drawStart.GetFloorIntX() + m_CornerRadius, drawEnd.GetFloorIntY() - m_CornerRadius, m_CornerRadius, {m_Color, 0, 0, 255});
+ DrawCircle(drawEnd.GetFloorIntX() - m_CornerRadius, drawStart.GetFloorIntY() + m_CornerRadius, m_CornerRadius, {m_Color, 0, 0, 255});
+ DrawCircle(drawEnd.GetFloorIntX() - m_CornerRadius, drawEnd.GetFloorIntY() - m_CornerRadius, m_CornerRadius, {m_Color, 0, 0, 255});
+ DrawRectangle(drawStart.GetFloorIntX(), drawStart.GetFloorIntY() + m_CornerRadius, drawEnd.GetFloorIntX() - drawStart.GetFloorIntX(), drawEnd.GetFloorIntY() - drawStart.GetFloorIntY() - 2 * m_CornerRadius, {m_Color, 0, 0, 255});
+ DrawRectangle(drawStart.GetFloorIntX() + m_CornerRadius, drawStart.GetFloorIntY(), drawEnd.GetFloorIntX() - drawStart.GetFloorIntX() - 2 * m_CornerRadius, drawEnd.GetFloorIntY() - drawStart.GetFloorIntY(), {m_Color, 0, 0, 255});
+}
+
+void CirclePrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos);
+ DrawCircleLines(drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), m_Radius, {m_Color, 0, 0, 255});
+}
+
+void CircleFillPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos);
+ DrawCircle(drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), m_Radius, {m_Color, 0, 0, 255});
+}
+
+void EllipsePrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos);
+ DrawEllipseLines(drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), m_HorizRadius, m_VertRadius, {m_Color, 0, 0, 255});
+}
+
+void EllipseFillPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos);
+ DrawEllipse(drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), m_HorizRadius, m_VertRadius, {m_Color, 0, 0, 255});
+}
+
+void TrianglePrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ Vector drawPointA = WrapCoordinates(targetPos, m_PointAPos);
+ Vector drawPointB = WrapCoordinates(targetPos, m_PointBPos);
+ Vector drawPointC = WrapCoordinates(targetPos, m_PointCPos);
+ DrawLine(drawPointA.GetFloorIntX(), drawPointA.GetFloorIntY(), drawPointB.GetFloorIntX(), drawPointB.GetFloorIntY(), {m_Color, 0, 0, 255});
+ DrawLine(drawPointB.GetFloorIntX(), drawPointB.GetFloorIntY(), drawPointC.GetFloorIntX(), drawPointC.GetFloorIntY(), {m_Color, 0, 0, 255});
+ DrawLine(drawPointC.GetFloorIntX(), drawPointC.GetFloorIntY(), drawPointA.GetFloorIntX(), drawPointA.GetFloorIntY(), {m_Color, 0, 0, 255});
+}
+
+void TriangleFillPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ Vector drawPointA = WrapCoordinates(targetPos, m_PointAPos);
+ Vector drawPointB = WrapCoordinates(targetPos, m_PointBPos);
+ Vector drawPointC = WrapCoordinates(targetPos, m_PointCPos);
+ DrawTriangle(drawPointA, drawPointB, drawPointC, {m_Color, 0, 0, 255});
+}
+
+void PolygonPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ Vector drawStart;
+ Vector drawEnd;
+ Vector startPos = WrapCoordinates(targetPos, m_StartPos);
+ for (int i = 0; i < m_Vertices.size(); ++i) {
+ drawStart = startPos - targetPos + (*m_Vertices[i]);
+ drawEnd = startPos - targetPos + ((i + 1 < m_Vertices.size()) ? *m_Vertices[i + 1] : *m_Vertices[0]);
+ DrawLine(drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), drawEnd.GetFloorIntX(), drawEnd.GetFloorIntY(), {m_Color, 0, 0, 255});
+ }
+}
+
+void PolygonFillPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ size_t drawPointsSize = m_Vertices.size();
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos);
+
+ std::vector drawPoints = {};
+ drawPoints.reserve(drawPointsSize);
+
+ for (const Vector* vertex: m_Vertices) {
+ drawPoints.emplace_back(drawStart.GetFloorIntX() + vertex->GetFloorIntX(), drawStart.GetFloorIntY() + vertex->GetFloorIntY());
+ }
+ DrawTriangleStrip(drawPoints.data(), drawPoints.size(), {m_Color, 0, 0, 255});
+}
+
+
+void TextPrimitive::CreateTextBitmap() {
+ if(m_Text.empty()) {
+ return;
+ }
+ GUIFont* font = m_IsSmall ? g_FrameMan.GetSmallFont() : g_FrameMan.GetLargeFont();
+ Matrix rotation = Matrix(m_RotAngle);
+ Vector targetPosAdjustment = Vector();
+
+ int textWidth = font->CalculateWidth(m_Text);
+ int textHeight = font->CalculateHeight(m_Text);
+
+ drawing_mode(DRAW_MODE_SOLID, nullptr, 0, 0);
+
+ m_TextBitmap = create_bitmap_ex(8, textWidth * 2, textHeight);
+ clear_to_color(m_TextBitmap, ColorKeys::g_MaskColor);
+ AllegroBitmap tempDrawAllegroBitmap(m_TextBitmap);
+ font->DrawAligned(&tempDrawAllegroBitmap, textWidth, 0, m_Text, m_Alignment);
+
+ m_TargetPosAlignment = Vector(static_cast(textWidth), 0);
+}
+
+void TextPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ if (!m_TextBitmap) {
+ return;
+ }
+
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos) - m_TargetPosAlignment;
+ Rectangle bitmapRect(0.0f, 0.0f, m_TextBitmap->w, m_TextBitmap->h);
+ Rectangle destRect(
+ drawStart.m_X,
+ drawStart.m_Y,
+ m_TextBitmap->w,
+ m_TextBitmap->h);
+ DrawTexturePro(m_TextBitmap, bitmapRect, destRect, {0.0f, 0.0f}, m_RotAngle, {255, 255, 255, 255});
+}
+
+TextPrimitive::~TextPrimitive() {
+ if (m_TextBitmap) {
+ g_GLResourceMan.DestroyBitmapInfo(m_TextBitmap);
+ destroy_bitmap(m_TextBitmap);
+ }
+}
+
+void BitmapPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
+ if (!m_Bitmap) {
+ return;
+ }
+
+ Vector drawStart = WrapCoordinates(targetPos, m_StartPos);
+
+ Rectangle flippedRect(
+ drawStart.m_X - m_Bitmap->w / 2,
+ drawStart.m_Y - m_Bitmap->h / 2,
+ (m_VFlipped ? -m_Bitmap->w : m_Bitmap->w) * m_Scale,
+ (m_HFlipped ? -m_Bitmap->h : m_Bitmap->h) * m_Scale
+ );
+
+ DrawTexturePro(m_Bitmap, Rectangle(0.0f, 0.0f, m_Bitmap->w, m_Bitmap->h), flippedRect, {0.0f, 0.0f}, m_RotAngle, {255, 255, 255, 255});
+}
diff --git a/Source/System/GraphicalPrimitive.h b/Source/Renderer/GraphicalPrimitive.h
similarity index 84%
rename from Source/System/GraphicalPrimitive.h
rename to Source/Renderer/GraphicalPrimitive.h
index 93c40ae08c..4d366a9026 100644
--- a/Source/System/GraphicalPrimitive.h
+++ b/Source/Renderer/GraphicalPrimitive.h
@@ -5,6 +5,7 @@
#include
#include
#include
+#include
namespace RTE {
@@ -43,27 +44,22 @@ namespace RTE {
Vector m_StartPos; //!< Start position of the primitive.
Vector m_EndPos; //!< End position of the primitive.
+ float m_DrawRadiusSquared{0.0f};
unsigned char m_Color = 0; //!< Color to draw this primitive with.
int m_Player = -1; //!< Player screen to draw this primitive on.
DrawBlendMode m_BlendMode = DrawBlendMode::NoBlend; //!< The blending mode that will be used when drawing this primitive.
std::array m_ColorChannelBlendAmounts = {BlendAmountLimits::MinBlend, BlendAmountLimits::MinBlend, BlendAmountLimits::MinBlend, BlendAmountLimits::MinBlend}; //!< The blending amount for each color channel when drawing in blended mode.
+ float m_Depth{c_PrimitiveDepth};
/// Destructor method used to clean up a GraphicalPrimitive object before deletion from system memory.
virtual ~GraphicalPrimitive() = default;
- /// Translates coordinates from scene to this bitmap offset producing two coordinates.
+ /// Wraps coordinates if current Scene is wrapped.
/// @param targetPos Target position.
/// @param scenePos Position on scene.
- /// @param drawLeftPos 'Left' position of bitmap on scene with negative values as if scene seam is 0,0.
- /// @param drawRightPos 'Right' position of bitmap on scene with positive values.
- /// @remark
- /// Unfortunately it's hard to explain how this works. It tries to represent scene bitmap as two parts with center in 0,0.
- /// Right part is just plain visible part with coordinates from [0, scenewidth] and left part is imaginary bitmap as if we traversed it across the seam right-to-left with coordinates [0, -scenewidth].
- /// So in order to be drawn each screen coordinates calculated twice for left and right 'bitmaps' and then one of them either flies away off-screen or gets drawn on the screen.
- /// When we cross the seam either left or right part is actually drawn in the bitmap, and negative coordinates of right part are compensated by view point offset coordinates when we cross the seam right to left.
- /// I really don't know how to make it simpler, because it has so many special cases and simply wrapping all out-of-the scene coordinates don't work because this way nothing will be ever draw across the seam.
- /// You're welcome to rewrite this nightmare if you can, I wasted a whole week on this (I can admit that I'm just too dumb for this) )))
- void TranslateCoordinates(Vector targetPos, const Vector& scenePos, Vector& drawLeftPos, Vector& drawRightPos) const;
+ Vector WrapCoordinates(Vector targetPos, const Vector& scenePos) const;
+
+ void DrawTiled(BITMAP* drawScreen, const Vector& targetPos);
/// Draws this primitive on provided bitmap.
/// @param drawScreen Bitmap to draw on.
@@ -86,16 +82,36 @@ namespace RTE {
public:
GraphicalPrimitiveOverrideMethods;
+ float m_Thickness{1.0f};
+
+ /// Constructor method for LinePrimitive object.
+ /// @param player Player screen to draw this primitive on.
+ /// @param startPos Start position of the primitive.
+ /// @param end End position of the primitive.
+ /// @param color Color to draw this primitive with.
+ LinePrimitive(int player, const Vector& startPos, const Vector& endPos, unsigned char color, float depth = c_PrimitiveDepth) {
+ m_StartPos = startPos;
+ m_EndPos = endPos;
+ m_DrawRadiusSquared = std::abs((m_StartPos - m_EndPos).GetSqrMagnitude());
+ m_Color = color;
+ m_Player = player;
+ m_Thickness = 1;
+ m_Depth = depth;
+ }
/// Constructor method for LinePrimitive object.
/// @param player Player screen to draw this primitive on.
/// @param startPos Start position of the primitive.
/// @param end End position of the primitive.
+ /// @param thickness Thickness of the line.
/// @param color Color to draw this primitive with.
- LinePrimitive(int player, const Vector& startPos, const Vector& endPos, unsigned char color) {
+ LinePrimitive(int player, const Vector& startPos, const Vector& endPos, float thickness, unsigned char color, float depth = c_PrimitiveDepth) {
m_StartPos = startPos;
m_EndPos = endPos;
+ m_DrawRadiusSquared = std::abs((m_StartPos - m_EndPos).GetSqrMagnitude());
m_Color = color;
m_Player = player;
+ m_Thickness = thickness;
+ m_Depth = depth;
}
private:
@@ -122,12 +138,14 @@ namespace RTE {
/// @param endAngle The angle at which the arc drawing ends.
/// @param radius Radius of the arc primitive.
/// @param color Color to draw this primitive with.
- ArcPrimitive(int player, const Vector& centerPos, float startAngle, float endAngle, int radius, int thickness, unsigned char color) :
+ ArcPrimitive(int player, const Vector& centerPos, float startAngle, float endAngle, int radius, int thickness, unsigned char color, float depth = c_PrimitiveDepth) :
m_StartAngle(startAngle), m_EndAngle(endAngle), m_Radius(radius), m_Thickness(thickness) {
m_StartPos = centerPos;
m_Color = color;
m_Player = player;
+ m_DrawRadiusSquared = (m_Radius + m_Thickness) * (m_Radius + m_Thickness);
+ m_Depth = depth;
}
private:
@@ -152,13 +170,15 @@ namespace RTE {
/// @param guideB The second guide point that controls the curve of the spline. The spline won't necessarily pass through this point, but it will affect it's shape.
/// @param endPos End position of the primitive.
/// @param color Color to draw this primitive with.
- SplinePrimitive(int player, const Vector& startPos, const Vector& guideA, const Vector& guideB, const Vector& endPos, unsigned char color) :
+ SplinePrimitive(int player, const Vector& startPos, const Vector& guideA, const Vector& guideB, const Vector& endPos, unsigned char color, float depth = c_PrimitiveDepth) :
m_GuidePointAPos(guideA), m_GuidePointBPos(guideB) {
m_StartPos = startPos;
m_EndPos = endPos;
m_Color = color;
m_Player = player;
+ m_DrawRadiusSquared = std::max({(startPos - guideA).GetSqrMagnitude(), (startPos - guideB).GetSqrMagnitude(), (startPos - endPos).GetSqrMagnitude()});
+ m_Depth = depth;
}
private:
@@ -178,11 +198,13 @@ namespace RTE {
/// @param topLeftPos Start position of the primitive. Top left corner.
/// @param bottomRightPos End position of the primitive. Bottom right corner.
/// @param color Color to draw this primitive with.
- BoxPrimitive(int player, const Vector& topLeftPos, const Vector& bottomRightPos, unsigned char color) {
+ BoxPrimitive(int player, const Vector& topLeftPos, const Vector& bottomRightPos, unsigned char color, float depth = c_PrimitiveDepth) {
m_StartPos = topLeftPos;
m_EndPos = bottomRightPos;
m_Color = color;
m_Player = player;
+ m_DrawRadiusSquared = (m_EndPos - m_StartPos).GetSqrMagnitude();
+ m_Depth = depth;
}
private:
@@ -202,11 +224,13 @@ namespace RTE {
/// @param topLeftPos Start position of the primitive. Top left corner.
/// @param bottomRightPos End position of the primitive. Bottom right corner.
/// @param color Color to draw this primitive with.
- BoxFillPrimitive(int player, const Vector& topLeftPos, const Vector& bottomRightPos, unsigned char color) {
+ BoxFillPrimitive(int player, const Vector& topLeftPos, const Vector& bottomRightPos, unsigned char color, float depth = c_PrimitiveDepth) {
m_StartPos = topLeftPos;
m_EndPos = bottomRightPos;
m_Color = color;
m_Player = player;
+ m_DrawRadiusSquared = (m_StartPos - m_EndPos).GetSqrMagnitude();
+ m_Depth = depth;
}
private:
@@ -229,13 +253,15 @@ namespace RTE {
/// @param bottomRightPos End position of the primitive. Bottom right corner.
/// @param cornerRadius The radius of the corners of the box. Smaller radius equals sharper corners.
/// @param color Color to draw this primitive with.
- RoundedBoxPrimitive(int player, const Vector& topLeftPos, const Vector& bottomRightPos, int cornerRadius, unsigned char color) :
+ RoundedBoxPrimitive(int player, const Vector& topLeftPos, const Vector& bottomRightPos, int cornerRadius, unsigned char color, float depth = c_PrimitiveDepth) :
m_CornerRadius(cornerRadius) {
m_StartPos = topLeftPos;
m_EndPos = bottomRightPos;
m_Color = color;
m_Player = player;
+ m_DrawRadiusSquared = (m_EndPos - m_StartPos).GetSqrMagnitude();
+ m_Depth = depth;
}
private:
@@ -258,13 +284,14 @@ namespace RTE {
/// @param bottomRightPos End position of the primitive. Bottom right corner.
/// @param cornerRadius The radius of the corners of the box. Smaller radius equals sharper corners.
/// @param color Color to draw this primitive with.
- RoundedBoxFillPrimitive(int player, const Vector& topLeftPos, const Vector& bottomRightPos, int cornerRadius, unsigned char color) :
+ RoundedBoxFillPrimitive(int player, const Vector& topLeftPos, const Vector& bottomRightPos, int cornerRadius, unsigned char color, float depth = c_PrimitiveDepth) :
m_CornerRadius(cornerRadius) {
m_StartPos = topLeftPos;
m_EndPos = bottomRightPos;
m_Color = color;
m_Player = player;
+ m_Depth = depth;
}
private:
@@ -286,12 +313,13 @@ namespace RTE {
/// @param centerPos Position of this primitive's center.
/// @param radius Radius of the circle primitive.
/// @param color Color to draw this primitive with.
- CirclePrimitive(int player, const Vector& centerPos, int radius, unsigned char color) :
+ CirclePrimitive(int player, const Vector& centerPos, int radius, unsigned char color, float depth = c_PrimitiveDepth) :
m_Radius(radius) {
m_StartPos = centerPos;
m_Color = color;
m_Player = player;
+ m_Depth = depth;
}
private:
@@ -313,12 +341,13 @@ namespace RTE {
/// @param centerPos Position of this primitive's center.
/// @param radius Radius of the circle primitive.
/// @param color Color to draw this primitive with.
- CircleFillPrimitive(int player, const Vector& centerPos, int radius, unsigned char color) :
+ CircleFillPrimitive(int player, const Vector& centerPos, int radius, unsigned char color, float depth = c_PrimitiveDepth) :
m_Radius(radius) {
m_StartPos = centerPos;
m_Color = color;
m_Player = player;
+ m_Depth = depth;
}
private:
@@ -342,12 +371,13 @@ namespace RTE {
/// @param horizRadius Horizontal radius of the ellipse primitive.
/// @param vertRadius Vertical radius of the ellipse primitive.
/// @param color Color to draw this primitive with.
- EllipsePrimitive(int player, const Vector& centerPos, int horizRadius, int vertRadius, unsigned char color) :
+ EllipsePrimitive(int player, const Vector& centerPos, int horizRadius, int vertRadius, unsigned char color, float depth = c_PrimitiveDepth) :
m_HorizRadius(horizRadius), m_VertRadius(vertRadius) {
m_StartPos = centerPos;
m_Color = color;
m_Player = player;
+ m_Depth = depth;
}
private:
@@ -370,12 +400,13 @@ namespace RTE {
/// @param centerPos Position of this primitive's center.
/// @param radius Radius of the circle primitive.
/// @param color Color to draw this primitive with.
- EllipseFillPrimitive(int player, const Vector& centerPos, int horizRadius, int vertRadius, unsigned char color) :
+ EllipseFillPrimitive(int player, const Vector& centerPos, int horizRadius, int vertRadius, unsigned char color, float depth = c_PrimitiveDepth) :
m_HorizRadius(horizRadius), m_VertRadius(vertRadius) {
m_StartPos = centerPos;
m_Color = color;
m_Player = player;
+ m_Depth = depth;
}
private:
@@ -400,11 +431,12 @@ namespace RTE {
/// @param pointB Position of the second point of the triangle
/// @param pointC Position of the third point of the triangle
/// @param color Color to draw this primitive with.
- TrianglePrimitive(int player, const Vector& pointA, const Vector& pointB, const Vector& pointC, unsigned char color) :
+ TrianglePrimitive(int player, const Vector& pointA, const Vector& pointB, const Vector& pointC, unsigned char color, float depth = c_PrimitiveDepth) :
m_PointAPos(pointA), m_PointBPos(pointB), m_PointCPos(pointC) {
m_Color = color;
m_Player = player;
+ m_Depth = depth;
}
private:
@@ -429,11 +461,12 @@ namespace RTE {
/// @param pointB Position of the second point of the triangle
/// @param pointC Position of the third point of the triangle
/// @param color Color to draw this primitive with.
- TriangleFillPrimitive(int player, const Vector& pointA, const Vector& pointB, const Vector& pointC, unsigned char color) :
+ TriangleFillPrimitive(int player, const Vector& pointA, const Vector& pointB, const Vector& pointC, unsigned char color, float depth = c_PrimitiveDepth) :
m_PointAPos(pointA), m_PointBPos(pointB), m_PointCPos(pointC) {
m_Color = color;
m_Player = player;
+ m_Depth = depth;
}
private:
@@ -455,12 +488,13 @@ namespace RTE {
/// @param startPos Start position of the primitive.
/// @param vertices A vector containing the positions of the vertices of the polygon, relative to the center position.
/// @param color Color to draw this primitive with.
- PolygonPrimitive(int player, const Vector& startPos, unsigned char color, const std::vector& vertices) :
+ PolygonPrimitive(int player, const Vector& startPos, unsigned char color, const std::vector& vertices, float depth = c_PrimitiveDepth) :
m_Vertices(vertices) {
m_StartPos = startPos;
m_Color = color;
m_Player = player;
+ m_Depth = depth;
}
private:
@@ -482,12 +516,13 @@ namespace RTE {
/// @param startPos Start position of the primitive.
/// @param vertices A vector containing the positions of the vertices of the polygon, relative to the center position.
/// @param color Color to draw this primitive with.
- PolygonFillPrimitive(int player, const Vector& startPos, unsigned char color, const std::vector& vertices) :
+ PolygonFillPrimitive(int player, const Vector& startPos, unsigned char color, const std::vector& vertices, float depth = c_PrimitiveDepth) :
m_Vertices(vertices) {
m_StartPos = startPos;
m_Color = color;
m_Player = player;
+ m_Depth = depth;
}
private:
@@ -506,6 +541,10 @@ namespace RTE {
bool m_IsSmall = false; //!< Use small or large font. True for small font.
int m_Alignment = 0; //!< Alignment of text.
float m_RotAngle = 0; //!< Angle to rotate text in radians.
+ BITMAP* m_TextBitmap = nullptr;
+ Vector m_TargetPosAlignment{};
+
+ void CreateTextBitmap();
/// Constructor method for TextPrimitive object.
/// @param player Player screen to draw this primitive on.
@@ -514,13 +553,17 @@ namespace RTE {
/// @param isSmall Use small or large font. True for small font.
/// @param alignment Alignment of text.
/// @param rotAngle Angle to rotate text in radians.
- TextPrimitive(int player, const Vector& pos, const std::string& text, bool isSmall, int alignment, float rotAngle) :
+ TextPrimitive(int player, const Vector& pos, const std::string& text, bool isSmall, int alignment, float rotAngle, float depth = c_PrimitiveDepth) :
m_Text(text), m_IsSmall(isSmall), m_Alignment(alignment), m_RotAngle(rotAngle) {
m_StartPos = pos;
m_Player = player;
+ m_Depth = depth;
+ CreateTextBitmap();
}
+ ~TextPrimitive();
+
private:
static const PrimitiveType c_PrimitiveType; //!< Type identifier of this primitive.
};
@@ -548,7 +591,7 @@ namespace RTE {
/// @param hFlipped Whether the BITMAP to draw should be horizontally flipped.
/// @param vFlipped Whether the BITMAP to draw should be vertically flipped.
BitmapPrimitive(int player, const Vector& centerPos, BITMAP* bitmap, float rotAngle, float scale, bool hFlipped, bool vFlipped) :
- m_Bitmap(bitmap), m_RotAngle(rotAngle), m_HFlipped(hFlipped), m_VFlipped(vFlipped) {
+ m_Bitmap(bitmap), m_RotAngle(rotAngle), m_HFlipped(hFlipped), m_VFlipped(vFlipped), m_Scale(1.0f) {
m_StartPos = centerPos;
m_Player = player;
@@ -562,8 +605,13 @@ namespace RTE {
/// @param rotAngle Angle to rotate BITMAP in radians.
/// @param hFlipped Whether the BITMAP to draw should be horizontally flipped.
/// @param vFlipped Whether the BITMAP to draw should be vertically flipped.
- BitmapPrimitive(int player, const Vector& centerPos, BITMAP* bitmap, float rotAngle, bool hFlipped, bool vFlipped) :
- BitmapPrimitive(player, centerPos, bitmap, rotAngle, 1.0f, hFlipped, vFlipped) {}
+ BitmapPrimitive(int player, const Vector& centerPos, BITMAP* bitmap, float rotAngle, bool hFlipped, bool vFlipped, float depth = c_PrimitiveDepth) :
+ m_Bitmap(bitmap), m_RotAngle(rotAngle), m_HFlipped(hFlipped), m_VFlipped(vFlipped), m_Scale(1.0f) {
+
+ m_StartPos = centerPos;
+ m_Player = player;
+ m_Depth = depth;
+ }
/// Constructor method for BitmapPrimitive object.
/// @param player Player screen to draw this primitive on.
@@ -574,12 +622,12 @@ namespace RTE {
/// @param scale BITMAP scale.
/// @param hFlipped Whether the BITMAP to draw should be horizontally flipped.
/// @param vFlipped Whether the BITMAP to draw should be vertically flipped.
- BitmapPrimitive(int player, const Vector& centerPos, const MOSprite* moSprite, float rotAngle, unsigned int frame, float scale, bool hFlipped, bool vFlipped) :
- m_Bitmap(moSprite->GetSpriteFrame(frame)), m_RotAngle(rotAngle), m_HFlipped(hFlipped), m_VFlipped(vFlipped) {
+ BitmapPrimitive(int player, const Vector& centerPos, const MOSprite* moSprite, float rotAngle, unsigned int frame, float scale, bool hFlipped, bool vFlipped, float depth = c_PrimitiveDepth) :
+ m_Bitmap(moSprite->GetSpriteFrame(frame)), m_RotAngle(rotAngle), m_HFlipped(hFlipped), m_VFlipped(vFlipped), m_Scale(scale) {
m_StartPos = centerPos;
m_Player = player;
- m_Scale = scale;
+ m_Depth = depth;
}
/// Constructor method for BitmapPrimitive object.
@@ -590,8 +638,12 @@ namespace RTE {
/// @param frame Frame number of the MOSprite that will be drawn.
/// @param hFlipped Whether the BITMAP to draw should be horizontally flipped.
/// @param vFlipped Whether the BITMAP to draw should be vertically flipped.
- BitmapPrimitive(int player, const Vector& centerPos, const MOSprite* moSprite, float rotAngle, unsigned int frame, bool hFlipped, bool vFlipped) :
- BitmapPrimitive(player, centerPos, moSprite, rotAngle, frame, 1.0f, hFlipped, vFlipped) {}
+ BitmapPrimitive(int player, const Vector& centerPos, const MOSprite* moSprite, float rotAngle, unsigned int frame, bool hFlipped, bool vFlipped, float depth = c_PrimitiveDepth) :
+ m_Bitmap(moSprite->GetSpriteFrame(frame)), m_RotAngle(rotAngle), m_HFlipped(hFlipped), m_VFlipped(vFlipped), m_Scale(1.0f) {
+ m_StartPos = centerPos;
+ m_Player = player;
+ m_Depth = depth;
+ }
/// Constructor method for BitmapPrimitive object.
/// @param player Player screen to draw this primitive on.
@@ -602,11 +654,9 @@ namespace RTE {
/// @param hFlipped Whether the BITMAP to draw should be horizontally flipped.
/// @param vFlipped Whether the BITMAP to draw should be vertically flipped.
BitmapPrimitive(int player, const Vector& centerPos, const std::string& filePath, float rotAngle, float scale, bool hFlipped, bool vFlipped) :
- m_Bitmap(ContentFile(filePath.c_str()).GetAsBitmap()), m_RotAngle(rotAngle), m_HFlipped(hFlipped), m_VFlipped(vFlipped) {
-
+ m_Bitmap(ContentFile(filePath.c_str()).GetAsBitmap()), m_RotAngle(rotAngle), m_HFlipped(hFlipped), m_VFlipped(vFlipped), m_Scale(scale) {
m_StartPos = centerPos;
m_Player = player;
- m_Scale = scale;
}
/// Constructor method for BitmapPrimitive object.
/// @param player Player screen to draw this primitive on.
@@ -615,8 +665,12 @@ namespace RTE {
/// @param rotAngle Angle to rotate BITMAP in radians.
/// @param hFlipped Whether the BITMAP to draw should be horizontally flipped.
/// @param vFlipped Whether the BITMAP to draw should be vertically flipped.
- BitmapPrimitive(int player, const Vector& centerPos, const std::string& filePath, float rotAngle, bool hFlipped, bool vFlipped) :
- BitmapPrimitive(player, centerPos, filePath, rotAngle, 1.0f, hFlipped, vFlipped) {}
+ BitmapPrimitive(int player, const Vector& centerPos, const std::string& filePath, float rotAngle, bool hFlipped, bool vFlipped, float depth = c_PrimitiveDepth) :
+ m_Bitmap(ContentFile(filePath.c_str()).GetAsBitmap()), m_RotAngle(rotAngle), m_HFlipped(hFlipped), m_VFlipped(vFlipped), m_Scale(1.0f) {
+ m_StartPos = centerPos;
+ m_Player = player;
+ m_Depth = depth;
+ }
private:
static const PrimitiveType c_PrimitiveType; //!< Type identifier of this primitive.
diff --git a/Source/Renderer/RenderTarget.cpp b/Source/Renderer/RenderTarget.cpp
index 76a7ce462d..9765eb310a 100644
--- a/Source/Renderer/RenderTarget.cpp
+++ b/Source/Renderer/RenderTarget.cpp
@@ -14,31 +14,35 @@ using namespace RTE;
RenderTarget::RenderTarget(const FloatRect& size, const FloatRect& defaultViewport, int bitDepth, Texture2D colorTexture, bool defaultFB0) {
m_Size = size;
m_Viewport = defaultViewport;
- if (colorTexture.id != 0) {
- m_Texture = colorTexture;
- m_ColorTextureOwned = false;
- } else {
- m_Texture = {
- .id = rlLoadTexture(nullptr, size.w, size.h, bitDepth == 8 ? PIXELFORMAT_UNCOMPRESSED_GRAYSCALE : PIXELFORMAT_UNCOMPRESSED_R8G8B8A8, 1),
+ if (!defaultFB0) {
+ if (colorTexture.id != 0) {
+ m_Texture = colorTexture;
+ m_ColorTextureOwned = false;
+ } else {
+ m_Texture = {
+ .id = rlLoadTexture(nullptr, size.w, size.h, bitDepth == 8 ? PIXELFORMAT_UNCOMPRESSED_GRAYSCALE : PIXELFORMAT_UNCOMPRESSED_R8G8B8A8, 1),
+ .width = static_cast(size.w),
+ .height = static_cast(size.h),
+ .mipmaps = 0,
+ .format = bitDepth == 8 ? PIXELFORMAT_UNCOMPRESSED_GRAYSCALE : PIXELFORMAT_UNCOMPRESSED_R8G8B8A8,
+ };
+ }
+ m_Depth = {
+ .id = rlLoadTextureDepth(size.w, size.h, false),
.width = static_cast(size.w),
.height = static_cast(size.h),
.mipmaps = 0,
- .format = bitDepth == 8 ? PIXELFORMAT_UNCOMPRESSED_GRAYSCALE : PIXELFORMAT_UNCOMPRESSED_R8G8B8A8,
+ .format = GL_DEPTH_COMPONENT,
};
- }
- m_Depth = {
- .id = rlLoadTextureDepth(size.w, size.h, false),
- .width = static_cast(size.w),
- .height = static_cast(size.h),
- .mipmaps = 0,
- .format = GL_DEPTH_COMPONENT,
- };
- if (!defaultFB0) {
m_FBO = rlLoadFramebuffer();
rlEnableFramebuffer(m_FBO);
rlFramebufferAttach(m_FBO, m_Texture.id, RL_ATTACHMENT_COLOR_CHANNEL0, RL_ATTACHMENT_TEXTURE2D, 0);
rlFramebufferAttach(m_FBO, m_Depth.id, RL_ATTACHMENT_DEPTH, RL_ATTACHMENT_TEXTURE2D, 0);
rlDisableFramebuffer();
+ } else {
+ m_ColorTextureOwned = false;
+ m_Depth.id = 0;
+ m_Texture.id = 0;
}
}
@@ -52,7 +56,7 @@ RenderTarget::~RenderTarget() {
rlUnloadTexture(m_Depth.id);
}
-void RenderTarget::Begin(bool clear) {
+void RenderTarget::Begin(bool clear, float zoom) {
rlDrawRenderBatchActive();
rlResetDrawDepth();
rlEnableFramebuffer(m_FBO);
@@ -67,6 +71,9 @@ void RenderTarget::Begin(bool clear) {
rlOrtho(0.0f, m_Size.w, m_Size.h, 0.0f, c_NearDepth, c_FarDepth);
rlMatrixMode(RL_MODELVIEW);
rlLoadIdentity();
+ rlTranslatef(m_Size.w / 2, m_Size.h / 2, 0.0f);
+ rlScalef(zoom, zoom, 1.0f);
+ rlTranslatef(-m_Size.w / 2, -m_Size.h / 2, 0.0f);
if (clear) {
rlClearScreenBuffers();
diff --git a/Source/Renderer/RenderTarget.h b/Source/Renderer/RenderTarget.h
index dba5216218..9cdaf0dd2f 100644
--- a/Source/Renderer/RenderTarget.h
+++ b/Source/Renderer/RenderTarget.h
@@ -21,7 +21,7 @@ namespace RTE {
/// Enables this RenderTarget for drawing and sets up projection matrix. Draws current batch, resets draw depth and model matrix.
/// @param clear Whether to clear the target.
- void Begin(bool clear = true);
+ void Begin(bool clear = true, float zoom = 1.0f);
/// Disables this RenderTarget and flushes the active batch.
void End();
diff --git a/Source/Renderer/Shader.cpp b/Source/Renderer/Shader.cpp
index 32669f5802..0e6134253d 100644
--- a/Source/Renderer/Shader.cpp
+++ b/Source/Renderer/Shader.cpp
@@ -100,7 +100,7 @@ bool Shader::Compile(const std::string& vertexPath, const std::string& fragPath)
void Shader::Enable() {
rlEnableShader(m_ProgramID);
}
-void Shader::Begin() {
+void Shader::Begin() const {
rlSetShader(m_ProgramID, m_Locations.data());
glUseProgram(m_ProgramID);
}
@@ -200,5 +200,11 @@ void Shader::ApplyDefaultUniforms() {
m_Locations[RL_SHADER_LOC_MATRIX_MODEL] = GetUniformLocation("rteModel");
m_Locations[RL_SHADER_LOC_COLOR_DIFFUSE] = GetUniformLocation("rteColor");
m_Locations[RL_SHADER_LOC_MAP_DIFFUSE] = GetUniformLocation("rteTexture");
-
+ Enable();
+ SetMatrix4f(m_Locations[RL_SHADER_LOC_MATRIX_MVP], glm::mat4(1.0f));
+ SetMatrix4f(m_Locations[RL_SHADER_LOC_MATRIX_VIEW], glm::mat4(1.0f));
+ SetMatrix4f(m_Locations[RL_SHADER_LOC_MATRIX_PROJECTION], glm::mat4(1.0f));
+ SetMatrix4f(m_Locations[RL_SHADER_LOC_MATRIX_MODEL], glm::mat4(1.0f));
+ SetVector4f(m_Locations[RL_SHADER_LOC_COLOR_DIFFUSE], glm::vec4(1.0f));
+ SetInt(m_Locations[RL_SHADER_LOC_MAP_DIFFUSE], 0);
}
diff --git a/Source/Renderer/Shader.h b/Source/Renderer/Shader.h
index 8eb616db99..2cc9cd11fd 100644
--- a/Source/Renderer/Shader.h
+++ b/Source/Renderer/Shader.h
@@ -40,7 +40,7 @@ namespace RTE {
void Enable();
/// Begin shader draw mode. Flushes the active batch and enables this shader.
- void Begin();
+ void Begin() const;
/// Disables this shader and sets up the default raylib shader. Flushes the active batch and clears bound textures.
void End() const;
diff --git a/Source/Renderer/glad/gl.c b/Source/Renderer/glad/gl.c
index 9fdf3dc658..7589c25a93 100644
--- a/Source/Renderer/glad/gl.c
+++ b/Source/Renderer/glad/gl.c
@@ -39,8 +39,6 @@ int GLAD_GL_VERSION_4_0 = 0;
int GLAD_GL_VERSION_4_1 = 0;
int GLAD_GL_VERSION_4_2 = 0;
int GLAD_GL_VERSION_4_3 = 0;
-int GLAD_GL_ARB_ES2_compatibility = 0;
-int GLAD_GL_ARB_ES3_1_compatibility = 0;
int GLAD_GL_ARB_ES3_2_compatibility = 0;
int GLAD_GL_ARB_ES3_compatibility = 0;
int GLAD_GL_ARB_blend_func_extended = 0;
@@ -151,10 +149,11 @@ int GLAD_GL_EXT_framebuffer_sRGB = 0;
int GLAD_GL_EXT_texture_compression_s3tc = 0;
int GLAD_GL_EXT_texture_filter_anisotropic = 0;
int GLAD_GL_EXT_texture_mirror_clamp = 0;
+int GLAD_GL_KHR_blend_equation_advanced = 0;
+int GLAD_GL_KHR_blend_equation_advanced_coherent = 0;
+int GLAD_GL_KHR_debug = 0;
int GLAD_GL_KHR_texture_compression_astc_hdr = 0;
int GLAD_GL_KHR_texture_compression_astc_ldr = 0;
-int GLAD_GL_OES_compressed_paletted_texture = 0;
-int GLAD_GL_OES_fixed_point = 0;
static void _pre_call_gl_callback_default(const char *name, GLADapiproc apiproc, int len_args, ...) {
@@ -194,14 +193,14 @@ void gladSetGLPostCallback(GLADpostcallback cb) {
_post_call_gl_callback = cb;
}
-PFNGLACCUMXOESPROC glad_glAccumxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glAccumxOES(GLenum op, GLfixed value) {
- _pre_call_gl_callback("glAccumxOES", (GLADapiproc) glad_glAccumxOES, 2, op, value);
- glad_glAccumxOES(op, value);
- _post_call_gl_callback(NULL, "glAccumxOES", (GLADapiproc) glad_glAccumxOES, 2, op, value);
+PFNGLACCUMPROC glad_glAccum = NULL;
+static void GLAD_API_PTR glad_debug_impl_glAccum(GLenum op, GLfloat value) {
+ _pre_call_gl_callback("glAccum", (GLADapiproc) glad_glAccum, 2, op, value);
+ glad_glAccum(op, value);
+ _post_call_gl_callback(NULL, "glAccum", (GLADapiproc) glad_glAccum, 2, op, value);
}
-PFNGLACCUMXOESPROC glad_debug_glAccumxOES = glad_debug_impl_glAccumxOES;
+PFNGLACCUMPROC glad_debug_glAccum = glad_debug_impl_glAccum;
PFNGLACTIVESHADERPROGRAMPROC glad_glActiveShaderProgram = NULL;
static void GLAD_API_PTR glad_debug_impl_glActiveShaderProgram(GLuint pipeline, GLuint program) {
_pre_call_gl_callback("glActiveShaderProgram", (GLADapiproc) glad_glActiveShaderProgram, 2, pipeline, program);
@@ -226,14 +225,31 @@ static void GLAD_API_PTR glad_debug_impl_glActiveTextureARB(GLenum texture) {
}
PFNGLACTIVETEXTUREARBPROC glad_debug_glActiveTextureARB = glad_debug_impl_glActiveTextureARB;
-PFNGLALPHAFUNCXOESPROC glad_glAlphaFuncxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glAlphaFuncxOES(GLenum func, GLfixed ref) {
- _pre_call_gl_callback("glAlphaFuncxOES", (GLADapiproc) glad_glAlphaFuncxOES, 2, func, ref);
- glad_glAlphaFuncxOES(func, ref);
- _post_call_gl_callback(NULL, "glAlphaFuncxOES", (GLADapiproc) glad_glAlphaFuncxOES, 2, func, ref);
+PFNGLALPHAFUNCPROC glad_glAlphaFunc = NULL;
+static void GLAD_API_PTR glad_debug_impl_glAlphaFunc(GLenum func, GLfloat ref) {
+ _pre_call_gl_callback("glAlphaFunc", (GLADapiproc) glad_glAlphaFunc, 2, func, ref);
+ glad_glAlphaFunc(func, ref);
+ _post_call_gl_callback(NULL, "glAlphaFunc", (GLADapiproc) glad_glAlphaFunc, 2, func, ref);
}
-PFNGLALPHAFUNCXOESPROC glad_debug_glAlphaFuncxOES = glad_debug_impl_glAlphaFuncxOES;
+PFNGLALPHAFUNCPROC glad_debug_glAlphaFunc = glad_debug_impl_glAlphaFunc;
+PFNGLARETEXTURESRESIDENTPROC glad_glAreTexturesResident = NULL;
+static GLboolean GLAD_API_PTR glad_debug_impl_glAreTexturesResident(GLsizei n, const GLuint * textures, GLboolean * residences) {
+ GLboolean ret;
+ _pre_call_gl_callback("glAreTexturesResident", (GLADapiproc) glad_glAreTexturesResident, 3, n, textures, residences);
+ ret = glad_glAreTexturesResident(n, textures, residences);
+ _post_call_gl_callback((void*) &ret, "glAreTexturesResident", (GLADapiproc) glad_glAreTexturesResident, 3, n, textures, residences);
+ return ret;
+}
+PFNGLARETEXTURESRESIDENTPROC glad_debug_glAreTexturesResident = glad_debug_impl_glAreTexturesResident;
+PFNGLARRAYELEMENTPROC glad_glArrayElement = NULL;
+static void GLAD_API_PTR glad_debug_impl_glArrayElement(GLint i) {
+ _pre_call_gl_callback("glArrayElement", (GLADapiproc) glad_glArrayElement, 1, i);
+ glad_glArrayElement(i);
+ _post_call_gl_callback(NULL, "glArrayElement", (GLADapiproc) glad_glArrayElement, 1, i);
+
+}
+PFNGLARRAYELEMENTPROC glad_debug_glArrayElement = glad_debug_impl_glArrayElement;
PFNGLATTACHOBJECTARBPROC glad_glAttachObjectARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glAttachObjectARB(GLhandleARB containerObj, GLhandleARB obj) {
_pre_call_gl_callback("glAttachObjectARB", (GLADapiproc) glad_glAttachObjectARB, 2, containerObj, obj);
@@ -250,6 +266,14 @@ static void GLAD_API_PTR glad_debug_impl_glAttachShader(GLuint program, GLuint s
}
PFNGLATTACHSHADERPROC glad_debug_glAttachShader = glad_debug_impl_glAttachShader;
+PFNGLBEGINPROC glad_glBegin = NULL;
+static void GLAD_API_PTR glad_debug_impl_glBegin(GLenum mode) {
+ _pre_call_gl_callback("glBegin", (GLADapiproc) glad_glBegin, 1, mode);
+ glad_glBegin(mode);
+ _post_call_gl_callback(NULL, "glBegin", (GLADapiproc) glad_glBegin, 1, mode);
+
+}
+PFNGLBEGINPROC glad_debug_glBegin = glad_debug_impl_glBegin;
PFNGLBEGINCONDITIONALRENDERPROC glad_glBeginConditionalRender = NULL;
static void GLAD_API_PTR glad_debug_impl_glBeginConditionalRender(GLuint id, GLenum mode) {
_pre_call_gl_callback("glBeginConditionalRender", (GLADapiproc) glad_glBeginConditionalRender, 2, id, mode);
@@ -506,14 +530,22 @@ static void GLAD_API_PTR glad_debug_impl_glBindVertexBuffers(GLuint first, GLsiz
}
PFNGLBINDVERTEXBUFFERSPROC glad_debug_glBindVertexBuffers = glad_debug_impl_glBindVertexBuffers;
-PFNGLBITMAPXOESPROC glad_glBitmapxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glBitmapxOES(GLsizei width, GLsizei height, GLfixed xorig, GLfixed yorig, GLfixed xmove, GLfixed ymove, const GLubyte * bitmap) {
- _pre_call_gl_callback("glBitmapxOES", (GLADapiproc) glad_glBitmapxOES, 7, width, height, xorig, yorig, xmove, ymove, bitmap);
- glad_glBitmapxOES(width, height, xorig, yorig, xmove, ymove, bitmap);
- _post_call_gl_callback(NULL, "glBitmapxOES", (GLADapiproc) glad_glBitmapxOES, 7, width, height, xorig, yorig, xmove, ymove, bitmap);
+PFNGLBITMAPPROC glad_glBitmap = NULL;
+static void GLAD_API_PTR glad_debug_impl_glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte * bitmap) {
+ _pre_call_gl_callback("glBitmap", (GLADapiproc) glad_glBitmap, 7, width, height, xorig, yorig, xmove, ymove, bitmap);
+ glad_glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+ _post_call_gl_callback(NULL, "glBitmap", (GLADapiproc) glad_glBitmap, 7, width, height, xorig, yorig, xmove, ymove, bitmap);
+
+}
+PFNGLBITMAPPROC glad_debug_glBitmap = glad_debug_impl_glBitmap;
+PFNGLBLENDBARRIERKHRPROC glad_glBlendBarrierKHR = NULL;
+static void GLAD_API_PTR glad_debug_impl_glBlendBarrierKHR(void) {
+ _pre_call_gl_callback("glBlendBarrierKHR", (GLADapiproc) glad_glBlendBarrierKHR, 0);
+ glad_glBlendBarrierKHR();
+ _post_call_gl_callback(NULL, "glBlendBarrierKHR", (GLADapiproc) glad_glBlendBarrierKHR, 0);
}
-PFNGLBITMAPXOESPROC glad_debug_glBitmapxOES = glad_debug_impl_glBitmapxOES;
+PFNGLBLENDBARRIERKHRPROC glad_debug_glBlendBarrierKHR = glad_debug_impl_glBlendBarrierKHR;
PFNGLBLENDCOLORPROC glad_glBlendColor = NULL;
static void GLAD_API_PTR glad_debug_impl_glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha) {
_pre_call_gl_callback("glBlendColor", (GLADapiproc) glad_glBlendColor, 4, red, green, blue, alpha);
@@ -522,14 +554,6 @@ static void GLAD_API_PTR glad_debug_impl_glBlendColor(GLfloat red, GLfloat green
}
PFNGLBLENDCOLORPROC glad_debug_glBlendColor = glad_debug_impl_glBlendColor;
-PFNGLBLENDCOLORXOESPROC glad_glBlendColorxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glBlendColorxOES(GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha) {
- _pre_call_gl_callback("glBlendColorxOES", (GLADapiproc) glad_glBlendColorxOES, 4, red, green, blue, alpha);
- glad_glBlendColorxOES(red, green, blue, alpha);
- _post_call_gl_callback(NULL, "glBlendColorxOES", (GLADapiproc) glad_glBlendColorxOES, 4, red, green, blue, alpha);
-
-}
-PFNGLBLENDCOLORXOESPROC glad_debug_glBlendColorxOES = glad_debug_impl_glBlendColorxOES;
PFNGLBLENDEQUATIONPROC glad_glBlendEquation = NULL;
static void GLAD_API_PTR glad_debug_impl_glBlendEquation(GLenum mode) {
_pre_call_gl_callback("glBlendEquation", (GLADapiproc) glad_glBlendEquation, 1, mode);
@@ -690,6 +714,22 @@ static void GLAD_API_PTR glad_debug_impl_glBufferSubDataARB(GLenum target, GLint
}
PFNGLBUFFERSUBDATAARBPROC glad_debug_glBufferSubDataARB = glad_debug_impl_glBufferSubDataARB;
+PFNGLCALLLISTPROC glad_glCallList = NULL;
+static void GLAD_API_PTR glad_debug_impl_glCallList(GLuint list) {
+ _pre_call_gl_callback("glCallList", (GLADapiproc) glad_glCallList, 1, list);
+ glad_glCallList(list);
+ _post_call_gl_callback(NULL, "glCallList", (GLADapiproc) glad_glCallList, 1, list);
+
+}
+PFNGLCALLLISTPROC glad_debug_glCallList = glad_debug_impl_glCallList;
+PFNGLCALLLISTSPROC glad_glCallLists = NULL;
+static void GLAD_API_PTR glad_debug_impl_glCallLists(GLsizei n, GLenum type, const void * lists) {
+ _pre_call_gl_callback("glCallLists", (GLADapiproc) glad_glCallLists, 3, n, type, lists);
+ glad_glCallLists(n, type, lists);
+ _post_call_gl_callback(NULL, "glCallLists", (GLADapiproc) glad_glCallLists, 3, n, type, lists);
+
+}
+PFNGLCALLLISTSPROC glad_debug_glCallLists = glad_debug_impl_glCallLists;
PFNGLCHECKFRAMEBUFFERSTATUSPROC glad_glCheckFramebufferStatus = NULL;
static GLenum GLAD_API_PTR glad_debug_impl_glCheckFramebufferStatus(GLenum target) {
GLenum ret;
@@ -741,14 +781,14 @@ static void GLAD_API_PTR glad_debug_impl_glClear(GLbitfield mask) {
}
PFNGLCLEARPROC glad_debug_glClear = glad_debug_impl_glClear;
-PFNGLCLEARACCUMXOESPROC glad_glClearAccumxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glClearAccumxOES(GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha) {
- _pre_call_gl_callback("glClearAccumxOES", (GLADapiproc) glad_glClearAccumxOES, 4, red, green, blue, alpha);
- glad_glClearAccumxOES(red, green, blue, alpha);
- _post_call_gl_callback(NULL, "glClearAccumxOES", (GLADapiproc) glad_glClearAccumxOES, 4, red, green, blue, alpha);
+PFNGLCLEARACCUMPROC glad_glClearAccum = NULL;
+static void GLAD_API_PTR glad_debug_impl_glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha) {
+ _pre_call_gl_callback("glClearAccum", (GLADapiproc) glad_glClearAccum, 4, red, green, blue, alpha);
+ glad_glClearAccum(red, green, blue, alpha);
+ _post_call_gl_callback(NULL, "glClearAccum", (GLADapiproc) glad_glClearAccum, 4, red, green, blue, alpha);
}
-PFNGLCLEARACCUMXOESPROC glad_debug_glClearAccumxOES = glad_debug_impl_glClearAccumxOES;
+PFNGLCLEARACCUMPROC glad_debug_glClearAccum = glad_debug_impl_glClearAccum;
PFNGLCLEARBUFFERDATAPROC glad_glClearBufferData = NULL;
static void GLAD_API_PTR glad_debug_impl_glClearBufferData(GLenum target, GLenum internalformat, GLenum format, GLenum type, const void * data) {
_pre_call_gl_callback("glClearBufferData", (GLADapiproc) glad_glClearBufferData, 5, target, internalformat, format, type, data);
@@ -805,14 +845,6 @@ static void GLAD_API_PTR glad_debug_impl_glClearColor(GLfloat red, GLfloat green
}
PFNGLCLEARCOLORPROC glad_debug_glClearColor = glad_debug_impl_glClearColor;
-PFNGLCLEARCOLORXOESPROC glad_glClearColorxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glClearColorxOES(GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha) {
- _pre_call_gl_callback("glClearColorxOES", (GLADapiproc) glad_glClearColorxOES, 4, red, green, blue, alpha);
- glad_glClearColorxOES(red, green, blue, alpha);
- _post_call_gl_callback(NULL, "glClearColorxOES", (GLADapiproc) glad_glClearColorxOES, 4, red, green, blue, alpha);
-
-}
-PFNGLCLEARCOLORXOESPROC glad_debug_glClearColorxOES = glad_debug_impl_glClearColorxOES;
PFNGLCLEARDEPTHPROC glad_glClearDepth = NULL;
static void GLAD_API_PTR glad_debug_impl_glClearDepth(GLdouble depth) {
_pre_call_gl_callback("glClearDepth", (GLADapiproc) glad_glClearDepth, 1, depth);
@@ -829,14 +861,14 @@ static void GLAD_API_PTR glad_debug_impl_glClearDepthf(GLfloat d) {
}
PFNGLCLEARDEPTHFPROC glad_debug_glClearDepthf = glad_debug_impl_glClearDepthf;
-PFNGLCLEARDEPTHXOESPROC glad_glClearDepthxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glClearDepthxOES(GLfixed depth) {
- _pre_call_gl_callback("glClearDepthxOES", (GLADapiproc) glad_glClearDepthxOES, 1, depth);
- glad_glClearDepthxOES(depth);
- _post_call_gl_callback(NULL, "glClearDepthxOES", (GLADapiproc) glad_glClearDepthxOES, 1, depth);
+PFNGLCLEARINDEXPROC glad_glClearIndex = NULL;
+static void GLAD_API_PTR glad_debug_impl_glClearIndex(GLfloat c) {
+ _pre_call_gl_callback("glClearIndex", (GLADapiproc) glad_glClearIndex, 1, c);
+ glad_glClearIndex(c);
+ _post_call_gl_callback(NULL, "glClearIndex", (GLADapiproc) glad_glClearIndex, 1, c);
}
-PFNGLCLEARDEPTHXOESPROC glad_debug_glClearDepthxOES = glad_debug_impl_glClearDepthxOES;
+PFNGLCLEARINDEXPROC glad_debug_glClearIndex = glad_debug_impl_glClearIndex;
PFNGLCLEARNAMEDBUFFERDATAPROC glad_glClearNamedBufferData = NULL;
static void GLAD_API_PTR glad_debug_impl_glClearNamedBufferData(GLuint buffer, GLenum internalformat, GLenum format, GLenum type, const void * data) {
_pre_call_gl_callback("glClearNamedBufferData", (GLADapiproc) glad_glClearNamedBufferData, 5, buffer, internalformat, format, type, data);
@@ -909,6 +941,14 @@ static void GLAD_API_PTR glad_debug_impl_glClearTexSubImage(GLuint texture, GLin
}
PFNGLCLEARTEXSUBIMAGEPROC glad_debug_glClearTexSubImage = glad_debug_impl_glClearTexSubImage;
+PFNGLCLIENTACTIVETEXTUREPROC glad_glClientActiveTexture = NULL;
+static void GLAD_API_PTR glad_debug_impl_glClientActiveTexture(GLenum texture) {
+ _pre_call_gl_callback("glClientActiveTexture", (GLADapiproc) glad_glClientActiveTexture, 1, texture);
+ glad_glClientActiveTexture(texture);
+ _post_call_gl_callback(NULL, "glClientActiveTexture", (GLADapiproc) glad_glClientActiveTexture, 1, texture);
+
+}
+PFNGLCLIENTACTIVETEXTUREPROC glad_debug_glClientActiveTexture = glad_debug_impl_glClientActiveTexture;
PFNGLCLIENTACTIVETEXTUREARBPROC glad_glClientActiveTextureARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glClientActiveTextureARB(GLenum texture) {
_pre_call_gl_callback("glClientActiveTextureARB", (GLADapiproc) glad_glClientActiveTextureARB, 1, texture);
@@ -926,46 +966,270 @@ static GLenum GLAD_API_PTR glad_debug_impl_glClientWaitSync(GLsync sync, GLbitfi
return ret;
}
PFNGLCLIENTWAITSYNCPROC glad_debug_glClientWaitSync = glad_debug_impl_glClientWaitSync;
-PFNGLCLIPPLANEXOESPROC glad_glClipPlanexOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glClipPlanexOES(GLenum plane, const GLfixed * equation) {
- _pre_call_gl_callback("glClipPlanexOES", (GLADapiproc) glad_glClipPlanexOES, 2, plane, equation);
- glad_glClipPlanexOES(plane, equation);
- _post_call_gl_callback(NULL, "glClipPlanexOES", (GLADapiproc) glad_glClipPlanexOES, 2, plane, equation);
+PFNGLCLIPPLANEPROC glad_glClipPlane = NULL;
+static void GLAD_API_PTR glad_debug_impl_glClipPlane(GLenum plane, const GLdouble * equation) {
+ _pre_call_gl_callback("glClipPlane", (GLADapiproc) glad_glClipPlane, 2, plane, equation);
+ glad_glClipPlane(plane, equation);
+ _post_call_gl_callback(NULL, "glClipPlane", (GLADapiproc) glad_glClipPlane, 2, plane, equation);
+
+}
+PFNGLCLIPPLANEPROC glad_debug_glClipPlane = glad_debug_impl_glClipPlane;
+PFNGLCOLOR3BPROC glad_glColor3b = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3b(GLbyte red, GLbyte green, GLbyte blue) {
+ _pre_call_gl_callback("glColor3b", (GLADapiproc) glad_glColor3b, 3, red, green, blue);
+ glad_glColor3b(red, green, blue);
+ _post_call_gl_callback(NULL, "glColor3b", (GLADapiproc) glad_glColor3b, 3, red, green, blue);
+
+}
+PFNGLCOLOR3BPROC glad_debug_glColor3b = glad_debug_impl_glColor3b;
+PFNGLCOLOR3BVPROC glad_glColor3bv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3bv(const GLbyte * v) {
+ _pre_call_gl_callback("glColor3bv", (GLADapiproc) glad_glColor3bv, 1, v);
+ glad_glColor3bv(v);
+ _post_call_gl_callback(NULL, "glColor3bv", (GLADapiproc) glad_glColor3bv, 1, v);
+
+}
+PFNGLCOLOR3BVPROC glad_debug_glColor3bv = glad_debug_impl_glColor3bv;
+PFNGLCOLOR3DPROC glad_glColor3d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3d(GLdouble red, GLdouble green, GLdouble blue) {
+ _pre_call_gl_callback("glColor3d", (GLADapiproc) glad_glColor3d, 3, red, green, blue);
+ glad_glColor3d(red, green, blue);
+ _post_call_gl_callback(NULL, "glColor3d", (GLADapiproc) glad_glColor3d, 3, red, green, blue);
+
+}
+PFNGLCOLOR3DPROC glad_debug_glColor3d = glad_debug_impl_glColor3d;
+PFNGLCOLOR3DVPROC glad_glColor3dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3dv(const GLdouble * v) {
+ _pre_call_gl_callback("glColor3dv", (GLADapiproc) glad_glColor3dv, 1, v);
+ glad_glColor3dv(v);
+ _post_call_gl_callback(NULL, "glColor3dv", (GLADapiproc) glad_glColor3dv, 1, v);
+
+}
+PFNGLCOLOR3DVPROC glad_debug_glColor3dv = glad_debug_impl_glColor3dv;
+PFNGLCOLOR3FPROC glad_glColor3f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3f(GLfloat red, GLfloat green, GLfloat blue) {
+ _pre_call_gl_callback("glColor3f", (GLADapiproc) glad_glColor3f, 3, red, green, blue);
+ glad_glColor3f(red, green, blue);
+ _post_call_gl_callback(NULL, "glColor3f", (GLADapiproc) glad_glColor3f, 3, red, green, blue);
+
+}
+PFNGLCOLOR3FPROC glad_debug_glColor3f = glad_debug_impl_glColor3f;
+PFNGLCOLOR3FVPROC glad_glColor3fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3fv(const GLfloat * v) {
+ _pre_call_gl_callback("glColor3fv", (GLADapiproc) glad_glColor3fv, 1, v);
+ glad_glColor3fv(v);
+ _post_call_gl_callback(NULL, "glColor3fv", (GLADapiproc) glad_glColor3fv, 1, v);
+
+}
+PFNGLCOLOR3FVPROC glad_debug_glColor3fv = glad_debug_impl_glColor3fv;
+PFNGLCOLOR3IPROC glad_glColor3i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3i(GLint red, GLint green, GLint blue) {
+ _pre_call_gl_callback("glColor3i", (GLADapiproc) glad_glColor3i, 3, red, green, blue);
+ glad_glColor3i(red, green, blue);
+ _post_call_gl_callback(NULL, "glColor3i", (GLADapiproc) glad_glColor3i, 3, red, green, blue);
+
+}
+PFNGLCOLOR3IPROC glad_debug_glColor3i = glad_debug_impl_glColor3i;
+PFNGLCOLOR3IVPROC glad_glColor3iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3iv(const GLint * v) {
+ _pre_call_gl_callback("glColor3iv", (GLADapiproc) glad_glColor3iv, 1, v);
+ glad_glColor3iv(v);
+ _post_call_gl_callback(NULL, "glColor3iv", (GLADapiproc) glad_glColor3iv, 1, v);
+
+}
+PFNGLCOLOR3IVPROC glad_debug_glColor3iv = glad_debug_impl_glColor3iv;
+PFNGLCOLOR3SPROC glad_glColor3s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3s(GLshort red, GLshort green, GLshort blue) {
+ _pre_call_gl_callback("glColor3s", (GLADapiproc) glad_glColor3s, 3, red, green, blue);
+ glad_glColor3s(red, green, blue);
+ _post_call_gl_callback(NULL, "glColor3s", (GLADapiproc) glad_glColor3s, 3, red, green, blue);
+
+}
+PFNGLCOLOR3SPROC glad_debug_glColor3s = glad_debug_impl_glColor3s;
+PFNGLCOLOR3SVPROC glad_glColor3sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3sv(const GLshort * v) {
+ _pre_call_gl_callback("glColor3sv", (GLADapiproc) glad_glColor3sv, 1, v);
+ glad_glColor3sv(v);
+ _post_call_gl_callback(NULL, "glColor3sv", (GLADapiproc) glad_glColor3sv, 1, v);
+
+}
+PFNGLCOLOR3SVPROC glad_debug_glColor3sv = glad_debug_impl_glColor3sv;
+PFNGLCOLOR3UBPROC glad_glColor3ub = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3ub(GLubyte red, GLubyte green, GLubyte blue) {
+ _pre_call_gl_callback("glColor3ub", (GLADapiproc) glad_glColor3ub, 3, red, green, blue);
+ glad_glColor3ub(red, green, blue);
+ _post_call_gl_callback(NULL, "glColor3ub", (GLADapiproc) glad_glColor3ub, 3, red, green, blue);
+
+}
+PFNGLCOLOR3UBPROC glad_debug_glColor3ub = glad_debug_impl_glColor3ub;
+PFNGLCOLOR3UBVPROC glad_glColor3ubv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3ubv(const GLubyte * v) {
+ _pre_call_gl_callback("glColor3ubv", (GLADapiproc) glad_glColor3ubv, 1, v);
+ glad_glColor3ubv(v);
+ _post_call_gl_callback(NULL, "glColor3ubv", (GLADapiproc) glad_glColor3ubv, 1, v);
+
+}
+PFNGLCOLOR3UBVPROC glad_debug_glColor3ubv = glad_debug_impl_glColor3ubv;
+PFNGLCOLOR3UIPROC glad_glColor3ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3ui(GLuint red, GLuint green, GLuint blue) {
+ _pre_call_gl_callback("glColor3ui", (GLADapiproc) glad_glColor3ui, 3, red, green, blue);
+ glad_glColor3ui(red, green, blue);
+ _post_call_gl_callback(NULL, "glColor3ui", (GLADapiproc) glad_glColor3ui, 3, red, green, blue);
+
+}
+PFNGLCOLOR3UIPROC glad_debug_glColor3ui = glad_debug_impl_glColor3ui;
+PFNGLCOLOR3UIVPROC glad_glColor3uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3uiv(const GLuint * v) {
+ _pre_call_gl_callback("glColor3uiv", (GLADapiproc) glad_glColor3uiv, 1, v);
+ glad_glColor3uiv(v);
+ _post_call_gl_callback(NULL, "glColor3uiv", (GLADapiproc) glad_glColor3uiv, 1, v);
+
+}
+PFNGLCOLOR3UIVPROC glad_debug_glColor3uiv = glad_debug_impl_glColor3uiv;
+PFNGLCOLOR3USPROC glad_glColor3us = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3us(GLushort red, GLushort green, GLushort blue) {
+ _pre_call_gl_callback("glColor3us", (GLADapiproc) glad_glColor3us, 3, red, green, blue);
+ glad_glColor3us(red, green, blue);
+ _post_call_gl_callback(NULL, "glColor3us", (GLADapiproc) glad_glColor3us, 3, red, green, blue);
+
+}
+PFNGLCOLOR3USPROC glad_debug_glColor3us = glad_debug_impl_glColor3us;
+PFNGLCOLOR3USVPROC glad_glColor3usv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor3usv(const GLushort * v) {
+ _pre_call_gl_callback("glColor3usv", (GLADapiproc) glad_glColor3usv, 1, v);
+ glad_glColor3usv(v);
+ _post_call_gl_callback(NULL, "glColor3usv", (GLADapiproc) glad_glColor3usv, 1, v);
+
+}
+PFNGLCOLOR3USVPROC glad_debug_glColor3usv = glad_debug_impl_glColor3usv;
+PFNGLCOLOR4BPROC glad_glColor4b = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha) {
+ _pre_call_gl_callback("glColor4b", (GLADapiproc) glad_glColor4b, 4, red, green, blue, alpha);
+ glad_glColor4b(red, green, blue, alpha);
+ _post_call_gl_callback(NULL, "glColor4b", (GLADapiproc) glad_glColor4b, 4, red, green, blue, alpha);
+
+}
+PFNGLCOLOR4BPROC glad_debug_glColor4b = glad_debug_impl_glColor4b;
+PFNGLCOLOR4BVPROC glad_glColor4bv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4bv(const GLbyte * v) {
+ _pre_call_gl_callback("glColor4bv", (GLADapiproc) glad_glColor4bv, 1, v);
+ glad_glColor4bv(v);
+ _post_call_gl_callback(NULL, "glColor4bv", (GLADapiproc) glad_glColor4bv, 1, v);
+
+}
+PFNGLCOLOR4BVPROC glad_debug_glColor4bv = glad_debug_impl_glColor4bv;
+PFNGLCOLOR4DPROC glad_glColor4d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha) {
+ _pre_call_gl_callback("glColor4d", (GLADapiproc) glad_glColor4d, 4, red, green, blue, alpha);
+ glad_glColor4d(red, green, blue, alpha);
+ _post_call_gl_callback(NULL, "glColor4d", (GLADapiproc) glad_glColor4d, 4, red, green, blue, alpha);
+
+}
+PFNGLCOLOR4DPROC glad_debug_glColor4d = glad_debug_impl_glColor4d;
+PFNGLCOLOR4DVPROC glad_glColor4dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4dv(const GLdouble * v) {
+ _pre_call_gl_callback("glColor4dv", (GLADapiproc) glad_glColor4dv, 1, v);
+ glad_glColor4dv(v);
+ _post_call_gl_callback(NULL, "glColor4dv", (GLADapiproc) glad_glColor4dv, 1, v);
+
+}
+PFNGLCOLOR4DVPROC glad_debug_glColor4dv = glad_debug_impl_glColor4dv;
+PFNGLCOLOR4FPROC glad_glColor4f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha) {
+ _pre_call_gl_callback("glColor4f", (GLADapiproc) glad_glColor4f, 4, red, green, blue, alpha);
+ glad_glColor4f(red, green, blue, alpha);
+ _post_call_gl_callback(NULL, "glColor4f", (GLADapiproc) glad_glColor4f, 4, red, green, blue, alpha);
+
+}
+PFNGLCOLOR4FPROC glad_debug_glColor4f = glad_debug_impl_glColor4f;
+PFNGLCOLOR4FVPROC glad_glColor4fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4fv(const GLfloat * v) {
+ _pre_call_gl_callback("glColor4fv", (GLADapiproc) glad_glColor4fv, 1, v);
+ glad_glColor4fv(v);
+ _post_call_gl_callback(NULL, "glColor4fv", (GLADapiproc) glad_glColor4fv, 1, v);
+
+}
+PFNGLCOLOR4FVPROC glad_debug_glColor4fv = glad_debug_impl_glColor4fv;
+PFNGLCOLOR4IPROC glad_glColor4i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4i(GLint red, GLint green, GLint blue, GLint alpha) {
+ _pre_call_gl_callback("glColor4i", (GLADapiproc) glad_glColor4i, 4, red, green, blue, alpha);
+ glad_glColor4i(red, green, blue, alpha);
+ _post_call_gl_callback(NULL, "glColor4i", (GLADapiproc) glad_glColor4i, 4, red, green, blue, alpha);
+
+}
+PFNGLCOLOR4IPROC glad_debug_glColor4i = glad_debug_impl_glColor4i;
+PFNGLCOLOR4IVPROC glad_glColor4iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4iv(const GLint * v) {
+ _pre_call_gl_callback("glColor4iv", (GLADapiproc) glad_glColor4iv, 1, v);
+ glad_glColor4iv(v);
+ _post_call_gl_callback(NULL, "glColor4iv", (GLADapiproc) glad_glColor4iv, 1, v);
+
+}
+PFNGLCOLOR4IVPROC glad_debug_glColor4iv = glad_debug_impl_glColor4iv;
+PFNGLCOLOR4SPROC glad_glColor4s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha) {
+ _pre_call_gl_callback("glColor4s", (GLADapiproc) glad_glColor4s, 4, red, green, blue, alpha);
+ glad_glColor4s(red, green, blue, alpha);
+ _post_call_gl_callback(NULL, "glColor4s", (GLADapiproc) glad_glColor4s, 4, red, green, blue, alpha);
+
+}
+PFNGLCOLOR4SPROC glad_debug_glColor4s = glad_debug_impl_glColor4s;
+PFNGLCOLOR4SVPROC glad_glColor4sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4sv(const GLshort * v) {
+ _pre_call_gl_callback("glColor4sv", (GLADapiproc) glad_glColor4sv, 1, v);
+ glad_glColor4sv(v);
+ _post_call_gl_callback(NULL, "glColor4sv", (GLADapiproc) glad_glColor4sv, 1, v);
+
+}
+PFNGLCOLOR4SVPROC glad_debug_glColor4sv = glad_debug_impl_glColor4sv;
+PFNGLCOLOR4UBPROC glad_glColor4ub = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha) {
+ _pre_call_gl_callback("glColor4ub", (GLADapiproc) glad_glColor4ub, 4, red, green, blue, alpha);
+ glad_glColor4ub(red, green, blue, alpha);
+ _post_call_gl_callback(NULL, "glColor4ub", (GLADapiproc) glad_glColor4ub, 4, red, green, blue, alpha);
+
+}
+PFNGLCOLOR4UBPROC glad_debug_glColor4ub = glad_debug_impl_glColor4ub;
+PFNGLCOLOR4UBVPROC glad_glColor4ubv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4ubv(const GLubyte * v) {
+ _pre_call_gl_callback("glColor4ubv", (GLADapiproc) glad_glColor4ubv, 1, v);
+ glad_glColor4ubv(v);
+ _post_call_gl_callback(NULL, "glColor4ubv", (GLADapiproc) glad_glColor4ubv, 1, v);
}
-PFNGLCLIPPLANEXOESPROC glad_debug_glClipPlanexOES = glad_debug_impl_glClipPlanexOES;
-PFNGLCOLOR3XOESPROC glad_glColor3xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glColor3xOES(GLfixed red, GLfixed green, GLfixed blue) {
- _pre_call_gl_callback("glColor3xOES", (GLADapiproc) glad_glColor3xOES, 3, red, green, blue);
- glad_glColor3xOES(red, green, blue);
- _post_call_gl_callback(NULL, "glColor3xOES", (GLADapiproc) glad_glColor3xOES, 3, red, green, blue);
+PFNGLCOLOR4UBVPROC glad_debug_glColor4ubv = glad_debug_impl_glColor4ubv;
+PFNGLCOLOR4UIPROC glad_glColor4ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha) {
+ _pre_call_gl_callback("glColor4ui", (GLADapiproc) glad_glColor4ui, 4, red, green, blue, alpha);
+ glad_glColor4ui(red, green, blue, alpha);
+ _post_call_gl_callback(NULL, "glColor4ui", (GLADapiproc) glad_glColor4ui, 4, red, green, blue, alpha);
}
-PFNGLCOLOR3XOESPROC glad_debug_glColor3xOES = glad_debug_impl_glColor3xOES;
-PFNGLCOLOR3XVOESPROC glad_glColor3xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glColor3xvOES(const GLfixed * components) {
- _pre_call_gl_callback("glColor3xvOES", (GLADapiproc) glad_glColor3xvOES, 1, components);
- glad_glColor3xvOES(components);
- _post_call_gl_callback(NULL, "glColor3xvOES", (GLADapiproc) glad_glColor3xvOES, 1, components);
+PFNGLCOLOR4UIPROC glad_debug_glColor4ui = glad_debug_impl_glColor4ui;
+PFNGLCOLOR4UIVPROC glad_glColor4uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4uiv(const GLuint * v) {
+ _pre_call_gl_callback("glColor4uiv", (GLADapiproc) glad_glColor4uiv, 1, v);
+ glad_glColor4uiv(v);
+ _post_call_gl_callback(NULL, "glColor4uiv", (GLADapiproc) glad_glColor4uiv, 1, v);
}
-PFNGLCOLOR3XVOESPROC glad_debug_glColor3xvOES = glad_debug_impl_glColor3xvOES;
-PFNGLCOLOR4XOESPROC glad_glColor4xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glColor4xOES(GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha) {
- _pre_call_gl_callback("glColor4xOES", (GLADapiproc) glad_glColor4xOES, 4, red, green, blue, alpha);
- glad_glColor4xOES(red, green, blue, alpha);
- _post_call_gl_callback(NULL, "glColor4xOES", (GLADapiproc) glad_glColor4xOES, 4, red, green, blue, alpha);
+PFNGLCOLOR4UIVPROC glad_debug_glColor4uiv = glad_debug_impl_glColor4uiv;
+PFNGLCOLOR4USPROC glad_glColor4us = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha) {
+ _pre_call_gl_callback("glColor4us", (GLADapiproc) glad_glColor4us, 4, red, green, blue, alpha);
+ glad_glColor4us(red, green, blue, alpha);
+ _post_call_gl_callback(NULL, "glColor4us", (GLADapiproc) glad_glColor4us, 4, red, green, blue, alpha);
}
-PFNGLCOLOR4XOESPROC glad_debug_glColor4xOES = glad_debug_impl_glColor4xOES;
-PFNGLCOLOR4XVOESPROC glad_glColor4xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glColor4xvOES(const GLfixed * components) {
- _pre_call_gl_callback("glColor4xvOES", (GLADapiproc) glad_glColor4xvOES, 1, components);
- glad_glColor4xvOES(components);
- _post_call_gl_callback(NULL, "glColor4xvOES", (GLADapiproc) glad_glColor4xvOES, 1, components);
+PFNGLCOLOR4USPROC glad_debug_glColor4us = glad_debug_impl_glColor4us;
+PFNGLCOLOR4USVPROC glad_glColor4usv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColor4usv(const GLushort * v) {
+ _pre_call_gl_callback("glColor4usv", (GLADapiproc) glad_glColor4usv, 1, v);
+ glad_glColor4usv(v);
+ _post_call_gl_callback(NULL, "glColor4usv", (GLADapiproc) glad_glColor4usv, 1, v);
}
-PFNGLCOLOR4XVOESPROC glad_debug_glColor4xvOES = glad_debug_impl_glColor4xvOES;
+PFNGLCOLOR4USVPROC glad_debug_glColor4usv = glad_debug_impl_glColor4usv;
PFNGLCOLORMASKPROC glad_glColorMask = NULL;
static void GLAD_API_PTR glad_debug_impl_glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha) {
_pre_call_gl_callback("glColorMask", (GLADapiproc) glad_glColorMask, 4, red, green, blue, alpha);
@@ -982,6 +1246,54 @@ static void GLAD_API_PTR glad_debug_impl_glColorMaski(GLuint index, GLboolean r,
}
PFNGLCOLORMASKIPROC glad_debug_glColorMaski = glad_debug_impl_glColorMaski;
+PFNGLCOLORMATERIALPROC glad_glColorMaterial = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColorMaterial(GLenum face, GLenum mode) {
+ _pre_call_gl_callback("glColorMaterial", (GLADapiproc) glad_glColorMaterial, 2, face, mode);
+ glad_glColorMaterial(face, mode);
+ _post_call_gl_callback(NULL, "glColorMaterial", (GLADapiproc) glad_glColorMaterial, 2, face, mode);
+
+}
+PFNGLCOLORMATERIALPROC glad_debug_glColorMaterial = glad_debug_impl_glColorMaterial;
+PFNGLCOLORP3UIPROC glad_glColorP3ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColorP3ui(GLenum type, GLuint color) {
+ _pre_call_gl_callback("glColorP3ui", (GLADapiproc) glad_glColorP3ui, 2, type, color);
+ glad_glColorP3ui(type, color);
+ _post_call_gl_callback(NULL, "glColorP3ui", (GLADapiproc) glad_glColorP3ui, 2, type, color);
+
+}
+PFNGLCOLORP3UIPROC glad_debug_glColorP3ui = glad_debug_impl_glColorP3ui;
+PFNGLCOLORP3UIVPROC glad_glColorP3uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColorP3uiv(GLenum type, const GLuint * color) {
+ _pre_call_gl_callback("glColorP3uiv", (GLADapiproc) glad_glColorP3uiv, 2, type, color);
+ glad_glColorP3uiv(type, color);
+ _post_call_gl_callback(NULL, "glColorP3uiv", (GLADapiproc) glad_glColorP3uiv, 2, type, color);
+
+}
+PFNGLCOLORP3UIVPROC glad_debug_glColorP3uiv = glad_debug_impl_glColorP3uiv;
+PFNGLCOLORP4UIPROC glad_glColorP4ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColorP4ui(GLenum type, GLuint color) {
+ _pre_call_gl_callback("glColorP4ui", (GLADapiproc) glad_glColorP4ui, 2, type, color);
+ glad_glColorP4ui(type, color);
+ _post_call_gl_callback(NULL, "glColorP4ui", (GLADapiproc) glad_glColorP4ui, 2, type, color);
+
+}
+PFNGLCOLORP4UIPROC glad_debug_glColorP4ui = glad_debug_impl_glColorP4ui;
+PFNGLCOLORP4UIVPROC glad_glColorP4uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColorP4uiv(GLenum type, const GLuint * color) {
+ _pre_call_gl_callback("glColorP4uiv", (GLADapiproc) glad_glColorP4uiv, 2, type, color);
+ glad_glColorP4uiv(type, color);
+ _post_call_gl_callback(NULL, "glColorP4uiv", (GLADapiproc) glad_glColorP4uiv, 2, type, color);
+
+}
+PFNGLCOLORP4UIVPROC glad_debug_glColorP4uiv = glad_debug_impl_glColorP4uiv;
+PFNGLCOLORPOINTERPROC glad_glColorPointer = NULL;
+static void GLAD_API_PTR glad_debug_impl_glColorPointer(GLint size, GLenum type, GLsizei stride, const void * pointer) {
+ _pre_call_gl_callback("glColorPointer", (GLADapiproc) glad_glColorPointer, 4, size, type, stride, pointer);
+ glad_glColorPointer(size, type, stride, pointer);
+ _post_call_gl_callback(NULL, "glColorPointer", (GLADapiproc) glad_glColorPointer, 4, size, type, stride, pointer);
+
+}
+PFNGLCOLORPOINTERPROC glad_debug_glColorPointer = glad_debug_impl_glColorPointer;
PFNGLCOMPILESHADERPROC glad_glCompileShader = NULL;
static void GLAD_API_PTR glad_debug_impl_glCompileShader(GLuint shader) {
_pre_call_gl_callback("glCompileShader", (GLADapiproc) glad_glCompileShader, 1, shader);
@@ -1126,22 +1438,6 @@ static void GLAD_API_PTR glad_debug_impl_glCompressedTextureSubImage3D(GLuint te
}
PFNGLCOMPRESSEDTEXTURESUBIMAGE3DPROC glad_debug_glCompressedTextureSubImage3D = glad_debug_impl_glCompressedTextureSubImage3D;
-PFNGLCONVOLUTIONPARAMETERXOESPROC glad_glConvolutionParameterxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glConvolutionParameterxOES(GLenum target, GLenum pname, GLfixed param) {
- _pre_call_gl_callback("glConvolutionParameterxOES", (GLADapiproc) glad_glConvolutionParameterxOES, 3, target, pname, param);
- glad_glConvolutionParameterxOES(target, pname, param);
- _post_call_gl_callback(NULL, "glConvolutionParameterxOES", (GLADapiproc) glad_glConvolutionParameterxOES, 3, target, pname, param);
-
-}
-PFNGLCONVOLUTIONPARAMETERXOESPROC glad_debug_glConvolutionParameterxOES = glad_debug_impl_glConvolutionParameterxOES;
-PFNGLCONVOLUTIONPARAMETERXVOESPROC glad_glConvolutionParameterxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glConvolutionParameterxvOES(GLenum target, GLenum pname, const GLfixed * params) {
- _pre_call_gl_callback("glConvolutionParameterxvOES", (GLADapiproc) glad_glConvolutionParameterxvOES, 3, target, pname, params);
- glad_glConvolutionParameterxvOES(target, pname, params);
- _post_call_gl_callback(NULL, "glConvolutionParameterxvOES", (GLADapiproc) glad_glConvolutionParameterxvOES, 3, target, pname, params);
-
-}
-PFNGLCONVOLUTIONPARAMETERXVOESPROC glad_debug_glConvolutionParameterxvOES = glad_debug_impl_glConvolutionParameterxvOES;
PFNGLCOPYBUFFERSUBDATAPROC glad_glCopyBufferSubData = NULL;
static void GLAD_API_PTR glad_debug_impl_glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size) {
_pre_call_gl_callback("glCopyBufferSubData", (GLADapiproc) glad_glCopyBufferSubData, 5, readTarget, writeTarget, readOffset, writeOffset, size);
@@ -1166,6 +1462,14 @@ static void GLAD_API_PTR glad_debug_impl_glCopyNamedBufferSubData(GLuint readBuf
}
PFNGLCOPYNAMEDBUFFERSUBDATAPROC glad_debug_glCopyNamedBufferSubData = glad_debug_impl_glCopyNamedBufferSubData;
+PFNGLCOPYPIXELSPROC glad_glCopyPixels = NULL;
+static void GLAD_API_PTR glad_debug_impl_glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type) {
+ _pre_call_gl_callback("glCopyPixels", (GLADapiproc) glad_glCopyPixels, 5, x, y, width, height, type);
+ glad_glCopyPixels(x, y, width, height, type);
+ _post_call_gl_callback(NULL, "glCopyPixels", (GLADapiproc) glad_glCopyPixels, 5, x, y, width, height, type);
+
+}
+PFNGLCOPYPIXELSPROC glad_debug_glCopyPixels = glad_debug_impl_glCopyPixels;
PFNGLCOPYTEXIMAGE1DPROC glad_glCopyTexImage1D = NULL;
static void GLAD_API_PTR glad_debug_impl_glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border) {
_pre_call_gl_callback("glCopyTexImage1D", (GLADapiproc) glad_glCopyTexImage1D, 7, target, level, internalformat, x, y, width, border);
@@ -1435,6 +1739,14 @@ static void GLAD_API_PTR glad_debug_impl_glDeleteFramebuffersEXT(GLsizei n, cons
}
PFNGLDELETEFRAMEBUFFERSEXTPROC glad_debug_glDeleteFramebuffersEXT = glad_debug_impl_glDeleteFramebuffersEXT;
+PFNGLDELETELISTSPROC glad_glDeleteLists = NULL;
+static void GLAD_API_PTR glad_debug_impl_glDeleteLists(GLuint list, GLsizei range) {
+ _pre_call_gl_callback("glDeleteLists", (GLADapiproc) glad_glDeleteLists, 2, list, range);
+ glad_glDeleteLists(list, range);
+ _post_call_gl_callback(NULL, "glDeleteLists", (GLADapiproc) glad_glDeleteLists, 2, list, range);
+
+}
+PFNGLDELETELISTSPROC glad_debug_glDeleteLists = glad_debug_impl_glDeleteLists;
PFNGLDELETENAMEDSTRINGARBPROC glad_glDeleteNamedStringARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glDeleteNamedStringARB(GLint namelen, const GLchar * name) {
_pre_call_gl_callback("glDeleteNamedStringARB", (GLADapiproc) glad_glDeleteNamedStringARB, 2, namelen, name);
@@ -1603,14 +1915,6 @@ static void GLAD_API_PTR glad_debug_impl_glDepthRangef(GLfloat n, GLfloat f) {
}
PFNGLDEPTHRANGEFPROC glad_debug_glDepthRangef = glad_debug_impl_glDepthRangef;
-PFNGLDEPTHRANGEXOESPROC glad_glDepthRangexOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glDepthRangexOES(GLfixed n, GLfixed f) {
- _pre_call_gl_callback("glDepthRangexOES", (GLADapiproc) glad_glDepthRangexOES, 2, n, f);
- glad_glDepthRangexOES(n, f);
- _post_call_gl_callback(NULL, "glDepthRangexOES", (GLADapiproc) glad_glDepthRangexOES, 2, n, f);
-
-}
-PFNGLDEPTHRANGEXOESPROC glad_debug_glDepthRangexOES = glad_debug_impl_glDepthRangexOES;
PFNGLDETACHOBJECTARBPROC glad_glDetachObjectARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glDetachObjectARB(GLhandleARB containerObj, GLhandleARB attachedObj) {
_pre_call_gl_callback("glDetachObjectARB", (GLADapiproc) glad_glDetachObjectARB, 2, containerObj, attachedObj);
@@ -1635,6 +1939,14 @@ static void GLAD_API_PTR glad_debug_impl_glDisable(GLenum cap) {
}
PFNGLDISABLEPROC glad_debug_glDisable = glad_debug_impl_glDisable;
+PFNGLDISABLECLIENTSTATEPROC glad_glDisableClientState = NULL;
+static void GLAD_API_PTR glad_debug_impl_glDisableClientState(GLenum array) {
+ _pre_call_gl_callback("glDisableClientState", (GLADapiproc) glad_glDisableClientState, 1, array);
+ glad_glDisableClientState(array);
+ _post_call_gl_callback(NULL, "glDisableClientState", (GLADapiproc) glad_glDisableClientState, 1, array);
+
+}
+PFNGLDISABLECLIENTSTATEPROC glad_debug_glDisableClientState = glad_debug_impl_glDisableClientState;
PFNGLDISABLEVERTEXARRAYATTRIBPROC glad_glDisableVertexArrayAttrib = NULL;
static void GLAD_API_PTR glad_debug_impl_glDisableVertexArrayAttrib(GLuint vaobj, GLuint index) {
_pre_call_gl_callback("glDisableVertexArrayAttrib", (GLADapiproc) glad_glDisableVertexArrayAttrib, 2, vaobj, index);
@@ -1835,6 +2147,14 @@ static void GLAD_API_PTR glad_debug_impl_glDrawElementsInstancedEXT(GLenum mode,
}
PFNGLDRAWELEMENTSINSTANCEDEXTPROC glad_debug_glDrawElementsInstancedEXT = glad_debug_impl_glDrawElementsInstancedEXT;
+PFNGLDRAWPIXELSPROC glad_glDrawPixels = NULL;
+static void GLAD_API_PTR glad_debug_impl_glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const void * pixels) {
+ _pre_call_gl_callback("glDrawPixels", (GLADapiproc) glad_glDrawPixels, 5, width, height, format, type, pixels);
+ glad_glDrawPixels(width, height, format, type, pixels);
+ _post_call_gl_callback(NULL, "glDrawPixels", (GLADapiproc) glad_glDrawPixels, 5, width, height, format, type, pixels);
+
+}
+PFNGLDRAWPIXELSPROC glad_debug_glDrawPixels = glad_debug_impl_glDrawPixels;
PFNGLDRAWRANGEELEMENTSPROC glad_glDrawRangeElements = NULL;
static void GLAD_API_PTR glad_debug_impl_glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void * indices) {
_pre_call_gl_callback("glDrawRangeElements", (GLADapiproc) glad_glDrawRangeElements, 6, mode, start, end, count, type, indices);
@@ -1883,6 +2203,30 @@ static void GLAD_API_PTR glad_debug_impl_glDrawTransformFeedbackStreamInstanced(
}
PFNGLDRAWTRANSFORMFEEDBACKSTREAMINSTANCEDPROC glad_debug_glDrawTransformFeedbackStreamInstanced = glad_debug_impl_glDrawTransformFeedbackStreamInstanced;
+PFNGLEDGEFLAGPROC glad_glEdgeFlag = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEdgeFlag(GLboolean flag) {
+ _pre_call_gl_callback("glEdgeFlag", (GLADapiproc) glad_glEdgeFlag, 1, flag);
+ glad_glEdgeFlag(flag);
+ _post_call_gl_callback(NULL, "glEdgeFlag", (GLADapiproc) glad_glEdgeFlag, 1, flag);
+
+}
+PFNGLEDGEFLAGPROC glad_debug_glEdgeFlag = glad_debug_impl_glEdgeFlag;
+PFNGLEDGEFLAGPOINTERPROC glad_glEdgeFlagPointer = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEdgeFlagPointer(GLsizei stride, const void * pointer) {
+ _pre_call_gl_callback("glEdgeFlagPointer", (GLADapiproc) glad_glEdgeFlagPointer, 2, stride, pointer);
+ glad_glEdgeFlagPointer(stride, pointer);
+ _post_call_gl_callback(NULL, "glEdgeFlagPointer", (GLADapiproc) glad_glEdgeFlagPointer, 2, stride, pointer);
+
+}
+PFNGLEDGEFLAGPOINTERPROC glad_debug_glEdgeFlagPointer = glad_debug_impl_glEdgeFlagPointer;
+PFNGLEDGEFLAGVPROC glad_glEdgeFlagv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEdgeFlagv(const GLboolean * flag) {
+ _pre_call_gl_callback("glEdgeFlagv", (GLADapiproc) glad_glEdgeFlagv, 1, flag);
+ glad_glEdgeFlagv(flag);
+ _post_call_gl_callback(NULL, "glEdgeFlagv", (GLADapiproc) glad_glEdgeFlagv, 1, flag);
+
+}
+PFNGLEDGEFLAGVPROC glad_debug_glEdgeFlagv = glad_debug_impl_glEdgeFlagv;
PFNGLENABLEPROC glad_glEnable = NULL;
static void GLAD_API_PTR glad_debug_impl_glEnable(GLenum cap) {
_pre_call_gl_callback("glEnable", (GLADapiproc) glad_glEnable, 1, cap);
@@ -1891,6 +2235,14 @@ static void GLAD_API_PTR glad_debug_impl_glEnable(GLenum cap) {
}
PFNGLENABLEPROC glad_debug_glEnable = glad_debug_impl_glEnable;
+PFNGLENABLECLIENTSTATEPROC glad_glEnableClientState = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEnableClientState(GLenum array) {
+ _pre_call_gl_callback("glEnableClientState", (GLADapiproc) glad_glEnableClientState, 1, array);
+ glad_glEnableClientState(array);
+ _post_call_gl_callback(NULL, "glEnableClientState", (GLADapiproc) glad_glEnableClientState, 1, array);
+
+}
+PFNGLENABLECLIENTSTATEPROC glad_debug_glEnableClientState = glad_debug_impl_glEnableClientState;
PFNGLENABLEVERTEXARRAYATTRIBPROC glad_glEnableVertexArrayAttrib = NULL;
static void GLAD_API_PTR glad_debug_impl_glEnableVertexArrayAttrib(GLuint vaobj, GLuint index) {
_pre_call_gl_callback("glEnableVertexArrayAttrib", (GLADapiproc) glad_glEnableVertexArrayAttrib, 2, vaobj, index);
@@ -1923,6 +2275,14 @@ static void GLAD_API_PTR glad_debug_impl_glEnablei(GLenum target, GLuint index)
}
PFNGLENABLEIPROC glad_debug_glEnablei = glad_debug_impl_glEnablei;
+PFNGLENDPROC glad_glEnd = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEnd(void) {
+ _pre_call_gl_callback("glEnd", (GLADapiproc) glad_glEnd, 0);
+ glad_glEnd();
+ _post_call_gl_callback(NULL, "glEnd", (GLADapiproc) glad_glEnd, 0);
+
+}
+PFNGLENDPROC glad_debug_glEnd = glad_debug_impl_glEnd;
PFNGLENDCONDITIONALRENDERPROC glad_glEndConditionalRender = NULL;
static void GLAD_API_PTR glad_debug_impl_glEndConditionalRender(void) {
_pre_call_gl_callback("glEndConditionalRender", (GLADapiproc) glad_glEndConditionalRender, 0);
@@ -1931,6 +2291,14 @@ static void GLAD_API_PTR glad_debug_impl_glEndConditionalRender(void) {
}
PFNGLENDCONDITIONALRENDERPROC glad_debug_glEndConditionalRender = glad_debug_impl_glEndConditionalRender;
+PFNGLENDLISTPROC glad_glEndList = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEndList(void) {
+ _pre_call_gl_callback("glEndList", (GLADapiproc) glad_glEndList, 0);
+ glad_glEndList();
+ _post_call_gl_callback(NULL, "glEndList", (GLADapiproc) glad_glEndList, 0);
+
+}
+PFNGLENDLISTPROC glad_debug_glEndList = glad_debug_impl_glEndList;
PFNGLENDQUERYPROC glad_glEndQuery = NULL;
static void GLAD_API_PTR glad_debug_impl_glEndQuery(GLenum target) {
_pre_call_gl_callback("glEndQuery", (GLADapiproc) glad_glEndQuery, 1, target);
@@ -1963,38 +2331,102 @@ static void GLAD_API_PTR glad_debug_impl_glEndTransformFeedback(void) {
}
PFNGLENDTRANSFORMFEEDBACKPROC glad_debug_glEndTransformFeedback = glad_debug_impl_glEndTransformFeedback;
-PFNGLEVALCOORD1XOESPROC glad_glEvalCoord1xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glEvalCoord1xOES(GLfixed u) {
- _pre_call_gl_callback("glEvalCoord1xOES", (GLADapiproc) glad_glEvalCoord1xOES, 1, u);
- glad_glEvalCoord1xOES(u);
- _post_call_gl_callback(NULL, "glEvalCoord1xOES", (GLADapiproc) glad_glEvalCoord1xOES, 1, u);
+PFNGLEVALCOORD1DPROC glad_glEvalCoord1d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEvalCoord1d(GLdouble u) {
+ _pre_call_gl_callback("glEvalCoord1d", (GLADapiproc) glad_glEvalCoord1d, 1, u);
+ glad_glEvalCoord1d(u);
+ _post_call_gl_callback(NULL, "glEvalCoord1d", (GLADapiproc) glad_glEvalCoord1d, 1, u);
+
+}
+PFNGLEVALCOORD1DPROC glad_debug_glEvalCoord1d = glad_debug_impl_glEvalCoord1d;
+PFNGLEVALCOORD1DVPROC glad_glEvalCoord1dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEvalCoord1dv(const GLdouble * u) {
+ _pre_call_gl_callback("glEvalCoord1dv", (GLADapiproc) glad_glEvalCoord1dv, 1, u);
+ glad_glEvalCoord1dv(u);
+ _post_call_gl_callback(NULL, "glEvalCoord1dv", (GLADapiproc) glad_glEvalCoord1dv, 1, u);
+
+}
+PFNGLEVALCOORD1DVPROC glad_debug_glEvalCoord1dv = glad_debug_impl_glEvalCoord1dv;
+PFNGLEVALCOORD1FPROC glad_glEvalCoord1f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEvalCoord1f(GLfloat u) {
+ _pre_call_gl_callback("glEvalCoord1f", (GLADapiproc) glad_glEvalCoord1f, 1, u);
+ glad_glEvalCoord1f(u);
+ _post_call_gl_callback(NULL, "glEvalCoord1f", (GLADapiproc) glad_glEvalCoord1f, 1, u);
+
+}
+PFNGLEVALCOORD1FPROC glad_debug_glEvalCoord1f = glad_debug_impl_glEvalCoord1f;
+PFNGLEVALCOORD1FVPROC glad_glEvalCoord1fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEvalCoord1fv(const GLfloat * u) {
+ _pre_call_gl_callback("glEvalCoord1fv", (GLADapiproc) glad_glEvalCoord1fv, 1, u);
+ glad_glEvalCoord1fv(u);
+ _post_call_gl_callback(NULL, "glEvalCoord1fv", (GLADapiproc) glad_glEvalCoord1fv, 1, u);
+
+}
+PFNGLEVALCOORD1FVPROC glad_debug_glEvalCoord1fv = glad_debug_impl_glEvalCoord1fv;
+PFNGLEVALCOORD2DPROC glad_glEvalCoord2d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEvalCoord2d(GLdouble u, GLdouble v) {
+ _pre_call_gl_callback("glEvalCoord2d", (GLADapiproc) glad_glEvalCoord2d, 2, u, v);
+ glad_glEvalCoord2d(u, v);
+ _post_call_gl_callback(NULL, "glEvalCoord2d", (GLADapiproc) glad_glEvalCoord2d, 2, u, v);
+
+}
+PFNGLEVALCOORD2DPROC glad_debug_glEvalCoord2d = glad_debug_impl_glEvalCoord2d;
+PFNGLEVALCOORD2DVPROC glad_glEvalCoord2dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEvalCoord2dv(const GLdouble * u) {
+ _pre_call_gl_callback("glEvalCoord2dv", (GLADapiproc) glad_glEvalCoord2dv, 1, u);
+ glad_glEvalCoord2dv(u);
+ _post_call_gl_callback(NULL, "glEvalCoord2dv", (GLADapiproc) glad_glEvalCoord2dv, 1, u);
+
+}
+PFNGLEVALCOORD2DVPROC glad_debug_glEvalCoord2dv = glad_debug_impl_glEvalCoord2dv;
+PFNGLEVALCOORD2FPROC glad_glEvalCoord2f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEvalCoord2f(GLfloat u, GLfloat v) {
+ _pre_call_gl_callback("glEvalCoord2f", (GLADapiproc) glad_glEvalCoord2f, 2, u, v);
+ glad_glEvalCoord2f(u, v);
+ _post_call_gl_callback(NULL, "glEvalCoord2f", (GLADapiproc) glad_glEvalCoord2f, 2, u, v);
+
+}
+PFNGLEVALCOORD2FPROC glad_debug_glEvalCoord2f = glad_debug_impl_glEvalCoord2f;
+PFNGLEVALCOORD2FVPROC glad_glEvalCoord2fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEvalCoord2fv(const GLfloat * u) {
+ _pre_call_gl_callback("glEvalCoord2fv", (GLADapiproc) glad_glEvalCoord2fv, 1, u);
+ glad_glEvalCoord2fv(u);
+ _post_call_gl_callback(NULL, "glEvalCoord2fv", (GLADapiproc) glad_glEvalCoord2fv, 1, u);
+
+}
+PFNGLEVALCOORD2FVPROC glad_debug_glEvalCoord2fv = glad_debug_impl_glEvalCoord2fv;
+PFNGLEVALMESH1PROC glad_glEvalMesh1 = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEvalMesh1(GLenum mode, GLint i1, GLint i2) {
+ _pre_call_gl_callback("glEvalMesh1", (GLADapiproc) glad_glEvalMesh1, 3, mode, i1, i2);
+ glad_glEvalMesh1(mode, i1, i2);
+ _post_call_gl_callback(NULL, "glEvalMesh1", (GLADapiproc) glad_glEvalMesh1, 3, mode, i1, i2);
}
-PFNGLEVALCOORD1XOESPROC glad_debug_glEvalCoord1xOES = glad_debug_impl_glEvalCoord1xOES;
-PFNGLEVALCOORD1XVOESPROC glad_glEvalCoord1xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glEvalCoord1xvOES(const GLfixed * coords) {
- _pre_call_gl_callback("glEvalCoord1xvOES", (GLADapiproc) glad_glEvalCoord1xvOES, 1, coords);
- glad_glEvalCoord1xvOES(coords);
- _post_call_gl_callback(NULL, "glEvalCoord1xvOES", (GLADapiproc) glad_glEvalCoord1xvOES, 1, coords);
+PFNGLEVALMESH1PROC glad_debug_glEvalMesh1 = glad_debug_impl_glEvalMesh1;
+PFNGLEVALMESH2PROC glad_glEvalMesh2 = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2) {
+ _pre_call_gl_callback("glEvalMesh2", (GLADapiproc) glad_glEvalMesh2, 5, mode, i1, i2, j1, j2);
+ glad_glEvalMesh2(mode, i1, i2, j1, j2);
+ _post_call_gl_callback(NULL, "glEvalMesh2", (GLADapiproc) glad_glEvalMesh2, 5, mode, i1, i2, j1, j2);
}
-PFNGLEVALCOORD1XVOESPROC glad_debug_glEvalCoord1xvOES = glad_debug_impl_glEvalCoord1xvOES;
-PFNGLEVALCOORD2XOESPROC glad_glEvalCoord2xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glEvalCoord2xOES(GLfixed u, GLfixed v) {
- _pre_call_gl_callback("glEvalCoord2xOES", (GLADapiproc) glad_glEvalCoord2xOES, 2, u, v);
- glad_glEvalCoord2xOES(u, v);
- _post_call_gl_callback(NULL, "glEvalCoord2xOES", (GLADapiproc) glad_glEvalCoord2xOES, 2, u, v);
+PFNGLEVALMESH2PROC glad_debug_glEvalMesh2 = glad_debug_impl_glEvalMesh2;
+PFNGLEVALPOINT1PROC glad_glEvalPoint1 = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEvalPoint1(GLint i) {
+ _pre_call_gl_callback("glEvalPoint1", (GLADapiproc) glad_glEvalPoint1, 1, i);
+ glad_glEvalPoint1(i);
+ _post_call_gl_callback(NULL, "glEvalPoint1", (GLADapiproc) glad_glEvalPoint1, 1, i);
}
-PFNGLEVALCOORD2XOESPROC glad_debug_glEvalCoord2xOES = glad_debug_impl_glEvalCoord2xOES;
-PFNGLEVALCOORD2XVOESPROC glad_glEvalCoord2xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glEvalCoord2xvOES(const GLfixed * coords) {
- _pre_call_gl_callback("glEvalCoord2xvOES", (GLADapiproc) glad_glEvalCoord2xvOES, 1, coords);
- glad_glEvalCoord2xvOES(coords);
- _post_call_gl_callback(NULL, "glEvalCoord2xvOES", (GLADapiproc) glad_glEvalCoord2xvOES, 1, coords);
+PFNGLEVALPOINT1PROC glad_debug_glEvalPoint1 = glad_debug_impl_glEvalPoint1;
+PFNGLEVALPOINT2PROC glad_glEvalPoint2 = NULL;
+static void GLAD_API_PTR glad_debug_impl_glEvalPoint2(GLint i, GLint j) {
+ _pre_call_gl_callback("glEvalPoint2", (GLADapiproc) glad_glEvalPoint2, 2, i, j);
+ glad_glEvalPoint2(i, j);
+ _post_call_gl_callback(NULL, "glEvalPoint2", (GLADapiproc) glad_glEvalPoint2, 2, i, j);
}
-PFNGLEVALCOORD2XVOESPROC glad_debug_glEvalCoord2xvOES = glad_debug_impl_glEvalCoord2xvOES;
+PFNGLEVALPOINT2PROC glad_debug_glEvalPoint2 = glad_debug_impl_glEvalPoint2;
PFNGLEVALUATEDEPTHVALUESARBPROC glad_glEvaluateDepthValuesARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glEvaluateDepthValuesARB(void) {
_pre_call_gl_callback("glEvaluateDepthValuesARB", (GLADapiproc) glad_glEvaluateDepthValuesARB, 0);
@@ -2003,14 +2435,14 @@ static void GLAD_API_PTR glad_debug_impl_glEvaluateDepthValuesARB(void) {
}
PFNGLEVALUATEDEPTHVALUESARBPROC glad_debug_glEvaluateDepthValuesARB = glad_debug_impl_glEvaluateDepthValuesARB;
-PFNGLFEEDBACKBUFFERXOESPROC glad_glFeedbackBufferxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glFeedbackBufferxOES(GLsizei n, GLenum type, const GLfixed * buffer) {
- _pre_call_gl_callback("glFeedbackBufferxOES", (GLADapiproc) glad_glFeedbackBufferxOES, 3, n, type, buffer);
- glad_glFeedbackBufferxOES(n, type, buffer);
- _post_call_gl_callback(NULL, "glFeedbackBufferxOES", (GLADapiproc) glad_glFeedbackBufferxOES, 3, n, type, buffer);
+PFNGLFEEDBACKBUFFERPROC glad_glFeedbackBuffer = NULL;
+static void GLAD_API_PTR glad_debug_impl_glFeedbackBuffer(GLsizei size, GLenum type, GLfloat * buffer) {
+ _pre_call_gl_callback("glFeedbackBuffer", (GLADapiproc) glad_glFeedbackBuffer, 3, size, type, buffer);
+ glad_glFeedbackBuffer(size, type, buffer);
+ _post_call_gl_callback(NULL, "glFeedbackBuffer", (GLADapiproc) glad_glFeedbackBuffer, 3, size, type, buffer);
}
-PFNGLFEEDBACKBUFFERXOESPROC glad_debug_glFeedbackBufferxOES = glad_debug_impl_glFeedbackBufferxOES;
+PFNGLFEEDBACKBUFFERPROC glad_debug_glFeedbackBuffer = glad_debug_impl_glFeedbackBuffer;
PFNGLFENCESYNCPROC glad_glFenceSync = NULL;
static GLsync GLAD_API_PTR glad_debug_impl_glFenceSync(GLenum condition, GLbitfield flags) {
GLsync ret;
@@ -2052,6 +2484,14 @@ static void GLAD_API_PTR glad_debug_impl_glFlushMappedNamedBufferRange(GLuint bu
}
PFNGLFLUSHMAPPEDNAMEDBUFFERRANGEPROC glad_debug_glFlushMappedNamedBufferRange = glad_debug_impl_glFlushMappedNamedBufferRange;
+PFNGLFOGCOORDPOINTERPROC glad_glFogCoordPointer = NULL;
+static void GLAD_API_PTR glad_debug_impl_glFogCoordPointer(GLenum type, GLsizei stride, const void * pointer) {
+ _pre_call_gl_callback("glFogCoordPointer", (GLADapiproc) glad_glFogCoordPointer, 3, type, stride, pointer);
+ glad_glFogCoordPointer(type, stride, pointer);
+ _post_call_gl_callback(NULL, "glFogCoordPointer", (GLADapiproc) glad_glFogCoordPointer, 3, type, stride, pointer);
+
+}
+PFNGLFOGCOORDPOINTERPROC glad_debug_glFogCoordPointer = glad_debug_impl_glFogCoordPointer;
PFNGLFOGCOORDPOINTEREXTPROC glad_glFogCoordPointerEXT = NULL;
static void GLAD_API_PTR glad_debug_impl_glFogCoordPointerEXT(GLenum type, GLsizei stride, const void * pointer) {
_pre_call_gl_callback("glFogCoordPointerEXT", (GLADapiproc) glad_glFogCoordPointerEXT, 3, type, stride, pointer);
@@ -2060,6 +2500,14 @@ static void GLAD_API_PTR glad_debug_impl_glFogCoordPointerEXT(GLenum type, GLsiz
}
PFNGLFOGCOORDPOINTEREXTPROC glad_debug_glFogCoordPointerEXT = glad_debug_impl_glFogCoordPointerEXT;
+PFNGLFOGCOORDDPROC glad_glFogCoordd = NULL;
+static void GLAD_API_PTR glad_debug_impl_glFogCoordd(GLdouble coord) {
+ _pre_call_gl_callback("glFogCoordd", (GLADapiproc) glad_glFogCoordd, 1, coord);
+ glad_glFogCoordd(coord);
+ _post_call_gl_callback(NULL, "glFogCoordd", (GLADapiproc) glad_glFogCoordd, 1, coord);
+
+}
+PFNGLFOGCOORDDPROC glad_debug_glFogCoordd = glad_debug_impl_glFogCoordd;
PFNGLFOGCOORDDEXTPROC glad_glFogCoorddEXT = NULL;
static void GLAD_API_PTR glad_debug_impl_glFogCoorddEXT(GLdouble coord) {
_pre_call_gl_callback("glFogCoorddEXT", (GLADapiproc) glad_glFogCoorddEXT, 1, coord);
@@ -2068,6 +2516,14 @@ static void GLAD_API_PTR glad_debug_impl_glFogCoorddEXT(GLdouble coord) {
}
PFNGLFOGCOORDDEXTPROC glad_debug_glFogCoorddEXT = glad_debug_impl_glFogCoorddEXT;
+PFNGLFOGCOORDDVPROC glad_glFogCoorddv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glFogCoorddv(const GLdouble * coord) {
+ _pre_call_gl_callback("glFogCoorddv", (GLADapiproc) glad_glFogCoorddv, 1, coord);
+ glad_glFogCoorddv(coord);
+ _post_call_gl_callback(NULL, "glFogCoorddv", (GLADapiproc) glad_glFogCoorddv, 1, coord);
+
+}
+PFNGLFOGCOORDDVPROC glad_debug_glFogCoorddv = glad_debug_impl_glFogCoorddv;
PFNGLFOGCOORDDVEXTPROC glad_glFogCoorddvEXT = NULL;
static void GLAD_API_PTR glad_debug_impl_glFogCoorddvEXT(const GLdouble * coord) {
_pre_call_gl_callback("glFogCoorddvEXT", (GLADapiproc) glad_glFogCoorddvEXT, 1, coord);
@@ -2076,6 +2532,14 @@ static void GLAD_API_PTR glad_debug_impl_glFogCoorddvEXT(const GLdouble * coord)
}
PFNGLFOGCOORDDVEXTPROC glad_debug_glFogCoorddvEXT = glad_debug_impl_glFogCoorddvEXT;
+PFNGLFOGCOORDFPROC glad_glFogCoordf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glFogCoordf(GLfloat coord) {
+ _pre_call_gl_callback("glFogCoordf", (GLADapiproc) glad_glFogCoordf, 1, coord);
+ glad_glFogCoordf(coord);
+ _post_call_gl_callback(NULL, "glFogCoordf", (GLADapiproc) glad_glFogCoordf, 1, coord);
+
+}
+PFNGLFOGCOORDFPROC glad_debug_glFogCoordf = glad_debug_impl_glFogCoordf;
PFNGLFOGCOORDFEXTPROC glad_glFogCoordfEXT = NULL;
static void GLAD_API_PTR glad_debug_impl_glFogCoordfEXT(GLfloat coord) {
_pre_call_gl_callback("glFogCoordfEXT", (GLADapiproc) glad_glFogCoordfEXT, 1, coord);
@@ -2084,6 +2548,14 @@ static void GLAD_API_PTR glad_debug_impl_glFogCoordfEXT(GLfloat coord) {
}
PFNGLFOGCOORDFEXTPROC glad_debug_glFogCoordfEXT = glad_debug_impl_glFogCoordfEXT;
+PFNGLFOGCOORDFVPROC glad_glFogCoordfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glFogCoordfv(const GLfloat * coord) {
+ _pre_call_gl_callback("glFogCoordfv", (GLADapiproc) glad_glFogCoordfv, 1, coord);
+ glad_glFogCoordfv(coord);
+ _post_call_gl_callback(NULL, "glFogCoordfv", (GLADapiproc) glad_glFogCoordfv, 1, coord);
+
+}
+PFNGLFOGCOORDFVPROC glad_debug_glFogCoordfv = glad_debug_impl_glFogCoordfv;
PFNGLFOGCOORDFVEXTPROC glad_glFogCoordfvEXT = NULL;
static void GLAD_API_PTR glad_debug_impl_glFogCoordfvEXT(const GLfloat * coord) {
_pre_call_gl_callback("glFogCoordfvEXT", (GLADapiproc) glad_glFogCoordfvEXT, 1, coord);
@@ -2092,22 +2564,38 @@ static void GLAD_API_PTR glad_debug_impl_glFogCoordfvEXT(const GLfloat * coord)
}
PFNGLFOGCOORDFVEXTPROC glad_debug_glFogCoordfvEXT = glad_debug_impl_glFogCoordfvEXT;
-PFNGLFOGXOESPROC glad_glFogxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glFogxOES(GLenum pname, GLfixed param) {
- _pre_call_gl_callback("glFogxOES", (GLADapiproc) glad_glFogxOES, 2, pname, param);
- glad_glFogxOES(pname, param);
- _post_call_gl_callback(NULL, "glFogxOES", (GLADapiproc) glad_glFogxOES, 2, pname, param);
+PFNGLFOGFPROC glad_glFogf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glFogf(GLenum pname, GLfloat param) {
+ _pre_call_gl_callback("glFogf", (GLADapiproc) glad_glFogf, 2, pname, param);
+ glad_glFogf(pname, param);
+ _post_call_gl_callback(NULL, "glFogf", (GLADapiproc) glad_glFogf, 2, pname, param);
+
+}
+PFNGLFOGFPROC glad_debug_glFogf = glad_debug_impl_glFogf;
+PFNGLFOGFVPROC glad_glFogfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glFogfv(GLenum pname, const GLfloat * params) {
+ _pre_call_gl_callback("glFogfv", (GLADapiproc) glad_glFogfv, 2, pname, params);
+ glad_glFogfv(pname, params);
+ _post_call_gl_callback(NULL, "glFogfv", (GLADapiproc) glad_glFogfv, 2, pname, params);
+
+}
+PFNGLFOGFVPROC glad_debug_glFogfv = glad_debug_impl_glFogfv;
+PFNGLFOGIPROC glad_glFogi = NULL;
+static void GLAD_API_PTR glad_debug_impl_glFogi(GLenum pname, GLint param) {
+ _pre_call_gl_callback("glFogi", (GLADapiproc) glad_glFogi, 2, pname, param);
+ glad_glFogi(pname, param);
+ _post_call_gl_callback(NULL, "glFogi", (GLADapiproc) glad_glFogi, 2, pname, param);
}
-PFNGLFOGXOESPROC glad_debug_glFogxOES = glad_debug_impl_glFogxOES;
-PFNGLFOGXVOESPROC glad_glFogxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glFogxvOES(GLenum pname, const GLfixed * param) {
- _pre_call_gl_callback("glFogxvOES", (GLADapiproc) glad_glFogxvOES, 2, pname, param);
- glad_glFogxvOES(pname, param);
- _post_call_gl_callback(NULL, "glFogxvOES", (GLADapiproc) glad_glFogxvOES, 2, pname, param);
+PFNGLFOGIPROC glad_debug_glFogi = glad_debug_impl_glFogi;
+PFNGLFOGIVPROC glad_glFogiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glFogiv(GLenum pname, const GLint * params) {
+ _pre_call_gl_callback("glFogiv", (GLADapiproc) glad_glFogiv, 2, pname, params);
+ glad_glFogiv(pname, params);
+ _post_call_gl_callback(NULL, "glFogiv", (GLADapiproc) glad_glFogiv, 2, pname, params);
}
-PFNGLFOGXVOESPROC glad_debug_glFogxvOES = glad_debug_impl_glFogxvOES;
+PFNGLFOGIVPROC glad_debug_glFogiv = glad_debug_impl_glFogiv;
PFNGLFRAMEBUFFERPARAMETERIPROC glad_glFramebufferParameteri = NULL;
static void GLAD_API_PTR glad_debug_impl_glFramebufferParameteri(GLenum target, GLenum pname, GLint param) {
_pre_call_gl_callback("glFramebufferParameteri", (GLADapiproc) glad_glFramebufferParameteri, 3, target, pname, param);
@@ -2236,14 +2724,14 @@ static void GLAD_API_PTR glad_debug_impl_glFrontFace(GLenum mode) {
}
PFNGLFRONTFACEPROC glad_debug_glFrontFace = glad_debug_impl_glFrontFace;
-PFNGLFRUSTUMXOESPROC glad_glFrustumxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glFrustumxOES(GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f) {
- _pre_call_gl_callback("glFrustumxOES", (GLADapiproc) glad_glFrustumxOES, 6, l, r, b, t, n, f);
- glad_glFrustumxOES(l, r, b, t, n, f);
- _post_call_gl_callback(NULL, "glFrustumxOES", (GLADapiproc) glad_glFrustumxOES, 6, l, r, b, t, n, f);
+PFNGLFRUSTUMPROC glad_glFrustum = NULL;
+static void GLAD_API_PTR glad_debug_impl_glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar) {
+ _pre_call_gl_callback("glFrustum", (GLADapiproc) glad_glFrustum, 6, left, right, bottom, top, zNear, zFar);
+ glad_glFrustum(left, right, bottom, top, zNear, zFar);
+ _post_call_gl_callback(NULL, "glFrustum", (GLADapiproc) glad_glFrustum, 6, left, right, bottom, top, zNear, zFar);
}
-PFNGLFRUSTUMXOESPROC glad_debug_glFrustumxOES = glad_debug_impl_glFrustumxOES;
+PFNGLFRUSTUMPROC glad_debug_glFrustum = glad_debug_impl_glFrustum;
PFNGLGENBUFFERSPROC glad_glGenBuffers = NULL;
static void GLAD_API_PTR glad_debug_impl_glGenBuffers(GLsizei n, GLuint * buffers) {
_pre_call_gl_callback("glGenBuffers", (GLADapiproc) glad_glGenBuffers, 2, n, buffers);
@@ -2276,6 +2764,15 @@ static void GLAD_API_PTR glad_debug_impl_glGenFramebuffersEXT(GLsizei n, GLuint
}
PFNGLGENFRAMEBUFFERSEXTPROC glad_debug_glGenFramebuffersEXT = glad_debug_impl_glGenFramebuffersEXT;
+PFNGLGENLISTSPROC glad_glGenLists = NULL;
+static GLuint GLAD_API_PTR glad_debug_impl_glGenLists(GLsizei range) {
+ GLuint ret;
+ _pre_call_gl_callback("glGenLists", (GLADapiproc) glad_glGenLists, 1, range);
+ ret = glad_glGenLists(range);
+ _post_call_gl_callback((void*) &ret, "glGenLists", (GLADapiproc) glad_glGenLists, 1, range);
+ return ret;
+}
+PFNGLGENLISTSPROC glad_debug_glGenLists = glad_debug_impl_glGenLists;
PFNGLGENPROGRAMPIPELINESPROC glad_glGenProgramPipelines = NULL;
static void GLAD_API_PTR glad_debug_impl_glGenProgramPipelines(GLsizei n, GLuint * pipelines) {
_pre_call_gl_callback("glGenProgramPipelines", (GLADapiproc) glad_glGenProgramPipelines, 2, n, pipelines);
@@ -2582,14 +3079,14 @@ static void GLAD_API_PTR glad_debug_impl_glGetBufferSubDataARB(GLenum target, GL
}
PFNGLGETBUFFERSUBDATAARBPROC glad_debug_glGetBufferSubDataARB = glad_debug_impl_glGetBufferSubDataARB;
-PFNGLGETCLIPPLANEXOESPROC glad_glGetClipPlanexOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glGetClipPlanexOES(GLenum plane, GLfixed * equation) {
- _pre_call_gl_callback("glGetClipPlanexOES", (GLADapiproc) glad_glGetClipPlanexOES, 2, plane, equation);
- glad_glGetClipPlanexOES(plane, equation);
- _post_call_gl_callback(NULL, "glGetClipPlanexOES", (GLADapiproc) glad_glGetClipPlanexOES, 2, plane, equation);
+PFNGLGETCLIPPLANEPROC glad_glGetClipPlane = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetClipPlane(GLenum plane, GLdouble * equation) {
+ _pre_call_gl_callback("glGetClipPlane", (GLADapiproc) glad_glGetClipPlane, 2, plane, equation);
+ glad_glGetClipPlane(plane, equation);
+ _post_call_gl_callback(NULL, "glGetClipPlane", (GLADapiproc) glad_glGetClipPlane, 2, plane, equation);
}
-PFNGLGETCLIPPLANEXOESPROC glad_debug_glGetClipPlanexOES = glad_debug_impl_glGetClipPlanexOES;
+PFNGLGETCLIPPLANEPROC glad_debug_glGetClipPlane = glad_debug_impl_glGetClipPlane;
PFNGLGETCOMPRESSEDTEXIMAGEPROC glad_glGetCompressedTexImage = NULL;
static void GLAD_API_PTR glad_debug_impl_glGetCompressedTexImage(GLenum target, GLint level, void * img) {
_pre_call_gl_callback("glGetCompressedTexImage", (GLADapiproc) glad_glGetCompressedTexImage, 3, target, level, img);
@@ -2622,14 +3119,6 @@ static void GLAD_API_PTR glad_debug_impl_glGetCompressedTextureSubImage(GLuint t
}
PFNGLGETCOMPRESSEDTEXTURESUBIMAGEPROC glad_debug_glGetCompressedTextureSubImage = glad_debug_impl_glGetCompressedTextureSubImage;
-PFNGLGETCONVOLUTIONPARAMETERXVOESPROC glad_glGetConvolutionParameterxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glGetConvolutionParameterxvOES(GLenum target, GLenum pname, GLfixed * params) {
- _pre_call_gl_callback("glGetConvolutionParameterxvOES", (GLADapiproc) glad_glGetConvolutionParameterxvOES, 3, target, pname, params);
- glad_glGetConvolutionParameterxvOES(target, pname, params);
- _post_call_gl_callback(NULL, "glGetConvolutionParameterxvOES", (GLADapiproc) glad_glGetConvolutionParameterxvOES, 3, target, pname, params);
-
-}
-PFNGLGETCONVOLUTIONPARAMETERXVOESPROC glad_debug_glGetConvolutionParameterxvOES = glad_debug_impl_glGetConvolutionParameterxvOES;
PFNGLGETDEBUGMESSAGELOGPROC glad_glGetDebugMessageLog = NULL;
static GLuint GLAD_API_PTR glad_debug_impl_glGetDebugMessageLog(GLuint count, GLsizei bufSize, GLenum * sources, GLenum * types, GLuint * ids, GLenum * severities, GLsizei * lengths, GLchar * messageLog) {
GLuint ret;
@@ -2673,14 +3162,6 @@ static GLenum GLAD_API_PTR glad_debug_impl_glGetError(void) {
return ret;
}
PFNGLGETERRORPROC glad_debug_glGetError = glad_debug_impl_glGetError;
-PFNGLGETFIXEDVOESPROC glad_glGetFixedvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glGetFixedvOES(GLenum pname, GLfixed * params) {
- _pre_call_gl_callback("glGetFixedvOES", (GLADapiproc) glad_glGetFixedvOES, 2, pname, params);
- glad_glGetFixedvOES(pname, params);
- _post_call_gl_callback(NULL, "glGetFixedvOES", (GLADapiproc) glad_glGetFixedvOES, 2, pname, params);
-
-}
-PFNGLGETFIXEDVOESPROC glad_debug_glGetFixedvOES = glad_debug_impl_glGetFixedvOES;
PFNGLGETFLOATI_VPROC glad_glGetFloati_v = NULL;
static void GLAD_API_PTR glad_debug_impl_glGetFloati_v(GLenum target, GLuint index, GLfloat * data) {
_pre_call_gl_callback("glGetFloati_v", (GLADapiproc) glad_glGetFloati_v, 3, target, index, data);
@@ -2748,14 +3229,6 @@ static GLhandleARB GLAD_API_PTR glad_debug_impl_glGetHandleARB(GLenum pname) {
return ret;
}
PFNGLGETHANDLEARBPROC glad_debug_glGetHandleARB = glad_debug_impl_glGetHandleARB;
-PFNGLGETHISTOGRAMPARAMETERXVOESPROC glad_glGetHistogramParameterxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glGetHistogramParameterxvOES(GLenum target, GLenum pname, GLfixed * params) {
- _pre_call_gl_callback("glGetHistogramParameterxvOES", (GLADapiproc) glad_glGetHistogramParameterxvOES, 3, target, pname, params);
- glad_glGetHistogramParameterxvOES(target, pname, params);
- _post_call_gl_callback(NULL, "glGetHistogramParameterxvOES", (GLADapiproc) glad_glGetHistogramParameterxvOES, 3, target, pname, params);
-
-}
-PFNGLGETHISTOGRAMPARAMETERXVOESPROC glad_debug_glGetHistogramParameterxvOES = glad_debug_impl_glGetHistogramParameterxvOES;
PFNGLGETINFOLOGARBPROC glad_glGetInfoLogARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glGetInfoLogARB(GLhandleARB obj, GLsizei maxLength, GLsizei * length, GLcharARB * infoLog) {
_pre_call_gl_callback("glGetInfoLogARB", (GLADapiproc) glad_glGetInfoLogARB, 4, obj, maxLength, length, infoLog);
@@ -2812,30 +3285,62 @@ static void GLAD_API_PTR glad_debug_impl_glGetInternalformativ(GLenum target, GL
}
PFNGLGETINTERNALFORMATIVPROC glad_debug_glGetInternalformativ = glad_debug_impl_glGetInternalformativ;
-PFNGLGETLIGHTXOESPROC glad_glGetLightxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glGetLightxOES(GLenum light, GLenum pname, GLfixed * params) {
- _pre_call_gl_callback("glGetLightxOES", (GLADapiproc) glad_glGetLightxOES, 3, light, pname, params);
- glad_glGetLightxOES(light, pname, params);
- _post_call_gl_callback(NULL, "glGetLightxOES", (GLADapiproc) glad_glGetLightxOES, 3, light, pname, params);
+PFNGLGETLIGHTFVPROC glad_glGetLightfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetLightfv(GLenum light, GLenum pname, GLfloat * params) {
+ _pre_call_gl_callback("glGetLightfv", (GLADapiproc) glad_glGetLightfv, 3, light, pname, params);
+ glad_glGetLightfv(light, pname, params);
+ _post_call_gl_callback(NULL, "glGetLightfv", (GLADapiproc) glad_glGetLightfv, 3, light, pname, params);
+
+}
+PFNGLGETLIGHTFVPROC glad_debug_glGetLightfv = glad_debug_impl_glGetLightfv;
+PFNGLGETLIGHTIVPROC glad_glGetLightiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetLightiv(GLenum light, GLenum pname, GLint * params) {
+ _pre_call_gl_callback("glGetLightiv", (GLADapiproc) glad_glGetLightiv, 3, light, pname, params);
+ glad_glGetLightiv(light, pname, params);
+ _post_call_gl_callback(NULL, "glGetLightiv", (GLADapiproc) glad_glGetLightiv, 3, light, pname, params);
+
+}
+PFNGLGETLIGHTIVPROC glad_debug_glGetLightiv = glad_debug_impl_glGetLightiv;
+PFNGLGETMAPDVPROC glad_glGetMapdv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetMapdv(GLenum target, GLenum query, GLdouble * v) {
+ _pre_call_gl_callback("glGetMapdv", (GLADapiproc) glad_glGetMapdv, 3, target, query, v);
+ glad_glGetMapdv(target, query, v);
+ _post_call_gl_callback(NULL, "glGetMapdv", (GLADapiproc) glad_glGetMapdv, 3, target, query, v);
+
+}
+PFNGLGETMAPDVPROC glad_debug_glGetMapdv = glad_debug_impl_glGetMapdv;
+PFNGLGETMAPFVPROC glad_glGetMapfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetMapfv(GLenum target, GLenum query, GLfloat * v) {
+ _pre_call_gl_callback("glGetMapfv", (GLADapiproc) glad_glGetMapfv, 3, target, query, v);
+ glad_glGetMapfv(target, query, v);
+ _post_call_gl_callback(NULL, "glGetMapfv", (GLADapiproc) glad_glGetMapfv, 3, target, query, v);
+
+}
+PFNGLGETMAPFVPROC glad_debug_glGetMapfv = glad_debug_impl_glGetMapfv;
+PFNGLGETMAPIVPROC glad_glGetMapiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetMapiv(GLenum target, GLenum query, GLint * v) {
+ _pre_call_gl_callback("glGetMapiv", (GLADapiproc) glad_glGetMapiv, 3, target, query, v);
+ glad_glGetMapiv(target, query, v);
+ _post_call_gl_callback(NULL, "glGetMapiv", (GLADapiproc) glad_glGetMapiv, 3, target, query, v);
}
-PFNGLGETLIGHTXOESPROC glad_debug_glGetLightxOES = glad_debug_impl_glGetLightxOES;
-PFNGLGETMAPXVOESPROC glad_glGetMapxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glGetMapxvOES(GLenum target, GLenum query, GLfixed * v) {
- _pre_call_gl_callback("glGetMapxvOES", (GLADapiproc) glad_glGetMapxvOES, 3, target, query, v);
- glad_glGetMapxvOES(target, query, v);
- _post_call_gl_callback(NULL, "glGetMapxvOES", (GLADapiproc) glad_glGetMapxvOES, 3, target, query, v);
+PFNGLGETMAPIVPROC glad_debug_glGetMapiv = glad_debug_impl_glGetMapiv;
+PFNGLGETMATERIALFVPROC glad_glGetMaterialfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetMaterialfv(GLenum face, GLenum pname, GLfloat * params) {
+ _pre_call_gl_callback("glGetMaterialfv", (GLADapiproc) glad_glGetMaterialfv, 3, face, pname, params);
+ glad_glGetMaterialfv(face, pname, params);
+ _post_call_gl_callback(NULL, "glGetMaterialfv", (GLADapiproc) glad_glGetMaterialfv, 3, face, pname, params);
}
-PFNGLGETMAPXVOESPROC glad_debug_glGetMapxvOES = glad_debug_impl_glGetMapxvOES;
-PFNGLGETMATERIALXOESPROC glad_glGetMaterialxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glGetMaterialxOES(GLenum face, GLenum pname, GLfixed param) {
- _pre_call_gl_callback("glGetMaterialxOES", (GLADapiproc) glad_glGetMaterialxOES, 3, face, pname, param);
- glad_glGetMaterialxOES(face, pname, param);
- _post_call_gl_callback(NULL, "glGetMaterialxOES", (GLADapiproc) glad_glGetMaterialxOES, 3, face, pname, param);
+PFNGLGETMATERIALFVPROC glad_debug_glGetMaterialfv = glad_debug_impl_glGetMaterialfv;
+PFNGLGETMATERIALIVPROC glad_glGetMaterialiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetMaterialiv(GLenum face, GLenum pname, GLint * params) {
+ _pre_call_gl_callback("glGetMaterialiv", (GLADapiproc) glad_glGetMaterialiv, 3, face, pname, params);
+ glad_glGetMaterialiv(face, pname, params);
+ _post_call_gl_callback(NULL, "glGetMaterialiv", (GLADapiproc) glad_glGetMaterialiv, 3, face, pname, params);
}
-PFNGLGETMATERIALXOESPROC glad_debug_glGetMaterialxOES = glad_debug_impl_glGetMaterialxOES;
+PFNGLGETMATERIALIVPROC glad_debug_glGetMaterialiv = glad_debug_impl_glGetMaterialiv;
PFNGLGETMULTISAMPLEFVPROC glad_glGetMultisamplefv = NULL;
static void GLAD_API_PTR glad_debug_impl_glGetMultisamplefv(GLenum pname, GLuint index, GLfloat * val) {
_pre_call_gl_callback("glGetMultisamplefv", (GLADapiproc) glad_glGetMultisamplefv, 3, pname, index, val);
@@ -2948,14 +3453,30 @@ static void GLAD_API_PTR glad_debug_impl_glGetObjectPtrLabel(const void * ptr, G
}
PFNGLGETOBJECTPTRLABELPROC glad_debug_glGetObjectPtrLabel = glad_debug_impl_glGetObjectPtrLabel;
-PFNGLGETPIXELMAPXVPROC glad_glGetPixelMapxv = NULL;
-static void GLAD_API_PTR glad_debug_impl_glGetPixelMapxv(GLenum map, GLint size, GLfixed * values) {
- _pre_call_gl_callback("glGetPixelMapxv", (GLADapiproc) glad_glGetPixelMapxv, 3, map, size, values);
- glad_glGetPixelMapxv(map, size, values);
- _post_call_gl_callback(NULL, "glGetPixelMapxv", (GLADapiproc) glad_glGetPixelMapxv, 3, map, size, values);
+PFNGLGETPIXELMAPFVPROC glad_glGetPixelMapfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetPixelMapfv(GLenum map, GLfloat * values) {
+ _pre_call_gl_callback("glGetPixelMapfv", (GLADapiproc) glad_glGetPixelMapfv, 2, map, values);
+ glad_glGetPixelMapfv(map, values);
+ _post_call_gl_callback(NULL, "glGetPixelMapfv", (GLADapiproc) glad_glGetPixelMapfv, 2, map, values);
}
-PFNGLGETPIXELMAPXVPROC glad_debug_glGetPixelMapxv = glad_debug_impl_glGetPixelMapxv;
+PFNGLGETPIXELMAPFVPROC glad_debug_glGetPixelMapfv = glad_debug_impl_glGetPixelMapfv;
+PFNGLGETPIXELMAPUIVPROC glad_glGetPixelMapuiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetPixelMapuiv(GLenum map, GLuint * values) {
+ _pre_call_gl_callback("glGetPixelMapuiv", (GLADapiproc) glad_glGetPixelMapuiv, 2, map, values);
+ glad_glGetPixelMapuiv(map, values);
+ _post_call_gl_callback(NULL, "glGetPixelMapuiv", (GLADapiproc) glad_glGetPixelMapuiv, 2, map, values);
+
+}
+PFNGLGETPIXELMAPUIVPROC glad_debug_glGetPixelMapuiv = glad_debug_impl_glGetPixelMapuiv;
+PFNGLGETPIXELMAPUSVPROC glad_glGetPixelMapusv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetPixelMapusv(GLenum map, GLushort * values) {
+ _pre_call_gl_callback("glGetPixelMapusv", (GLADapiproc) glad_glGetPixelMapusv, 2, map, values);
+ glad_glGetPixelMapusv(map, values);
+ _post_call_gl_callback(NULL, "glGetPixelMapusv", (GLADapiproc) glad_glGetPixelMapusv, 2, map, values);
+
+}
+PFNGLGETPIXELMAPUSVPROC glad_debug_glGetPixelMapusv = glad_debug_impl_glGetPixelMapusv;
PFNGLGETPOINTERVPROC glad_glGetPointerv = NULL;
static void GLAD_API_PTR glad_debug_impl_glGetPointerv(GLenum pname, void ** params) {
_pre_call_gl_callback("glGetPointerv", (GLADapiproc) glad_glGetPointerv, 2, pname, params);
@@ -2964,6 +3485,14 @@ static void GLAD_API_PTR glad_debug_impl_glGetPointerv(GLenum pname, void ** par
}
PFNGLGETPOINTERVPROC glad_debug_glGetPointerv = glad_debug_impl_glGetPointerv;
+PFNGLGETPOLYGONSTIPPLEPROC glad_glGetPolygonStipple = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetPolygonStipple(GLubyte * mask) {
+ _pre_call_gl_callback("glGetPolygonStipple", (GLADapiproc) glad_glGetPolygonStipple, 1, mask);
+ glad_glGetPolygonStipple(mask);
+ _post_call_gl_callback(NULL, "glGetPolygonStipple", (GLADapiproc) glad_glGetPolygonStipple, 1, mask);
+
+}
+PFNGLGETPOLYGONSTIPPLEPROC glad_debug_glGetPolygonStipple = glad_debug_impl_glGetPolygonStipple;
PFNGLGETPROGRAMBINARYPROC glad_glGetProgramBinary = NULL;
static void GLAD_API_PTR glad_debug_impl_glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei * length, GLenum * binaryFormat, void * binary) {
_pre_call_gl_callback("glGetProgramBinary", (GLADapiproc) glad_glGetProgramBinary, 5, program, bufSize, length, binaryFormat, binary);
@@ -3347,22 +3876,46 @@ static void GLAD_API_PTR glad_debug_impl_glGetSynciv(GLsync sync, GLenum pname,
}
PFNGLGETSYNCIVPROC glad_debug_glGetSynciv = glad_debug_impl_glGetSynciv;
-PFNGLGETTEXENVXVOESPROC glad_glGetTexEnvxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glGetTexEnvxvOES(GLenum target, GLenum pname, GLfixed * params) {
- _pre_call_gl_callback("glGetTexEnvxvOES", (GLADapiproc) glad_glGetTexEnvxvOES, 3, target, pname, params);
- glad_glGetTexEnvxvOES(target, pname, params);
- _post_call_gl_callback(NULL, "glGetTexEnvxvOES", (GLADapiproc) glad_glGetTexEnvxvOES, 3, target, pname, params);
+PFNGLGETTEXENVFVPROC glad_glGetTexEnvfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetTexEnvfv(GLenum target, GLenum pname, GLfloat * params) {
+ _pre_call_gl_callback("glGetTexEnvfv", (GLADapiproc) glad_glGetTexEnvfv, 3, target, pname, params);
+ glad_glGetTexEnvfv(target, pname, params);
+ _post_call_gl_callback(NULL, "glGetTexEnvfv", (GLADapiproc) glad_glGetTexEnvfv, 3, target, pname, params);
+
+}
+PFNGLGETTEXENVFVPROC glad_debug_glGetTexEnvfv = glad_debug_impl_glGetTexEnvfv;
+PFNGLGETTEXENVIVPROC glad_glGetTexEnviv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetTexEnviv(GLenum target, GLenum pname, GLint * params) {
+ _pre_call_gl_callback("glGetTexEnviv", (GLADapiproc) glad_glGetTexEnviv, 3, target, pname, params);
+ glad_glGetTexEnviv(target, pname, params);
+ _post_call_gl_callback(NULL, "glGetTexEnviv", (GLADapiproc) glad_glGetTexEnviv, 3, target, pname, params);
}
-PFNGLGETTEXENVXVOESPROC glad_debug_glGetTexEnvxvOES = glad_debug_impl_glGetTexEnvxvOES;
-PFNGLGETTEXGENXVOESPROC glad_glGetTexGenxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glGetTexGenxvOES(GLenum coord, GLenum pname, GLfixed * params) {
- _pre_call_gl_callback("glGetTexGenxvOES", (GLADapiproc) glad_glGetTexGenxvOES, 3, coord, pname, params);
- glad_glGetTexGenxvOES(coord, pname, params);
- _post_call_gl_callback(NULL, "glGetTexGenxvOES", (GLADapiproc) glad_glGetTexGenxvOES, 3, coord, pname, params);
+PFNGLGETTEXENVIVPROC glad_debug_glGetTexEnviv = glad_debug_impl_glGetTexEnviv;
+PFNGLGETTEXGENDVPROC glad_glGetTexGendv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetTexGendv(GLenum coord, GLenum pname, GLdouble * params) {
+ _pre_call_gl_callback("glGetTexGendv", (GLADapiproc) glad_glGetTexGendv, 3, coord, pname, params);
+ glad_glGetTexGendv(coord, pname, params);
+ _post_call_gl_callback(NULL, "glGetTexGendv", (GLADapiproc) glad_glGetTexGendv, 3, coord, pname, params);
}
-PFNGLGETTEXGENXVOESPROC glad_debug_glGetTexGenxvOES = glad_debug_impl_glGetTexGenxvOES;
+PFNGLGETTEXGENDVPROC glad_debug_glGetTexGendv = glad_debug_impl_glGetTexGendv;
+PFNGLGETTEXGENFVPROC glad_glGetTexGenfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetTexGenfv(GLenum coord, GLenum pname, GLfloat * params) {
+ _pre_call_gl_callback("glGetTexGenfv", (GLADapiproc) glad_glGetTexGenfv, 3, coord, pname, params);
+ glad_glGetTexGenfv(coord, pname, params);
+ _post_call_gl_callback(NULL, "glGetTexGenfv", (GLADapiproc) glad_glGetTexGenfv, 3, coord, pname, params);
+
+}
+PFNGLGETTEXGENFVPROC glad_debug_glGetTexGenfv = glad_debug_impl_glGetTexGenfv;
+PFNGLGETTEXGENIVPROC glad_glGetTexGeniv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glGetTexGeniv(GLenum coord, GLenum pname, GLint * params) {
+ _pre_call_gl_callback("glGetTexGeniv", (GLADapiproc) glad_glGetTexGeniv, 3, coord, pname, params);
+ glad_glGetTexGeniv(coord, pname, params);
+ _post_call_gl_callback(NULL, "glGetTexGeniv", (GLADapiproc) glad_glGetTexGeniv, 3, coord, pname, params);
+
+}
+PFNGLGETTEXGENIVPROC glad_debug_glGetTexGeniv = glad_debug_impl_glGetTexGeniv;
PFNGLGETTEXIMAGEPROC glad_glGetTexImage = NULL;
static void GLAD_API_PTR glad_debug_impl_glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, void * pixels) {
_pre_call_gl_callback("glGetTexImage", (GLADapiproc) glad_glGetTexImage, 5, target, level, format, type, pixels);
@@ -3387,14 +3940,6 @@ static void GLAD_API_PTR glad_debug_impl_glGetTexLevelParameteriv(GLenum target,
}
PFNGLGETTEXLEVELPARAMETERIVPROC glad_debug_glGetTexLevelParameteriv = glad_debug_impl_glGetTexLevelParameteriv;
-PFNGLGETTEXLEVELPARAMETERXVOESPROC glad_glGetTexLevelParameterxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glGetTexLevelParameterxvOES(GLenum target, GLint level, GLenum pname, GLfixed * params) {
- _pre_call_gl_callback("glGetTexLevelParameterxvOES", (GLADapiproc) glad_glGetTexLevelParameterxvOES, 4, target, level, pname, params);
- glad_glGetTexLevelParameterxvOES(target, level, pname, params);
- _post_call_gl_callback(NULL, "glGetTexLevelParameterxvOES", (GLADapiproc) glad_glGetTexLevelParameterxvOES, 4, target, level, pname, params);
-
-}
-PFNGLGETTEXLEVELPARAMETERXVOESPROC glad_debug_glGetTexLevelParameterxvOES = glad_debug_impl_glGetTexLevelParameterxvOES;
PFNGLGETTEXPARAMETERIIVPROC glad_glGetTexParameterIiv = NULL;
static void GLAD_API_PTR glad_debug_impl_glGetTexParameterIiv(GLenum target, GLenum pname, GLint * params) {
_pre_call_gl_callback("glGetTexParameterIiv", (GLADapiproc) glad_glGetTexParameterIiv, 3, target, pname, params);
@@ -3427,14 +3972,6 @@ static void GLAD_API_PTR glad_debug_impl_glGetTexParameteriv(GLenum target, GLen
}
PFNGLGETTEXPARAMETERIVPROC glad_debug_glGetTexParameteriv = glad_debug_impl_glGetTexParameteriv;
-PFNGLGETTEXPARAMETERXVOESPROC glad_glGetTexParameterxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glGetTexParameterxvOES(GLenum target, GLenum pname, GLfixed * params) {
- _pre_call_gl_callback("glGetTexParameterxvOES", (GLADapiproc) glad_glGetTexParameterxvOES, 3, target, pname, params);
- glad_glGetTexParameterxvOES(target, pname, params);
- _post_call_gl_callback(NULL, "glGetTexParameterxvOES", (GLADapiproc) glad_glGetTexParameterxvOES, 3, target, pname, params);
-
-}
-PFNGLGETTEXPARAMETERXVOESPROC glad_debug_glGetTexParameterxvOES = glad_debug_impl_glGetTexParameterxvOES;
PFNGLGETTEXTUREIMAGEPROC glad_glGetTextureImage = NULL;
static void GLAD_API_PTR glad_debug_impl_glGetTextureImage(GLuint texture, GLint level, GLenum format, GLenum type, GLsizei bufSize, void * pixels) {
_pre_call_gl_callback("glGetTextureImage", (GLADapiproc) glad_glGetTextureImage, 6, texture, level, format, type, bufSize, pixels);
@@ -3774,22 +4311,118 @@ static void GLAD_API_PTR glad_debug_impl_glHint(GLenum target, GLenum mode) {
}
PFNGLHINTPROC glad_debug_glHint = glad_debug_impl_glHint;
-PFNGLINDEXXOESPROC glad_glIndexxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glIndexxOES(GLfixed component) {
- _pre_call_gl_callback("glIndexxOES", (GLADapiproc) glad_glIndexxOES, 1, component);
- glad_glIndexxOES(component);
- _post_call_gl_callback(NULL, "glIndexxOES", (GLADapiproc) glad_glIndexxOES, 1, component);
+PFNGLINDEXMASKPROC glad_glIndexMask = NULL;
+static void GLAD_API_PTR glad_debug_impl_glIndexMask(GLuint mask) {
+ _pre_call_gl_callback("glIndexMask", (GLADapiproc) glad_glIndexMask, 1, mask);
+ glad_glIndexMask(mask);
+ _post_call_gl_callback(NULL, "glIndexMask", (GLADapiproc) glad_glIndexMask, 1, mask);
+
+}
+PFNGLINDEXMASKPROC glad_debug_glIndexMask = glad_debug_impl_glIndexMask;
+PFNGLINDEXPOINTERPROC glad_glIndexPointer = NULL;
+static void GLAD_API_PTR glad_debug_impl_glIndexPointer(GLenum type, GLsizei stride, const void * pointer) {
+ _pre_call_gl_callback("glIndexPointer", (GLADapiproc) glad_glIndexPointer, 3, type, stride, pointer);
+ glad_glIndexPointer(type, stride, pointer);
+ _post_call_gl_callback(NULL, "glIndexPointer", (GLADapiproc) glad_glIndexPointer, 3, type, stride, pointer);
+
+}
+PFNGLINDEXPOINTERPROC glad_debug_glIndexPointer = glad_debug_impl_glIndexPointer;
+PFNGLINDEXDPROC glad_glIndexd = NULL;
+static void GLAD_API_PTR glad_debug_impl_glIndexd(GLdouble c) {
+ _pre_call_gl_callback("glIndexd", (GLADapiproc) glad_glIndexd, 1, c);
+ glad_glIndexd(c);
+ _post_call_gl_callback(NULL, "glIndexd", (GLADapiproc) glad_glIndexd, 1, c);
+
+}
+PFNGLINDEXDPROC glad_debug_glIndexd = glad_debug_impl_glIndexd;
+PFNGLINDEXDVPROC glad_glIndexdv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glIndexdv(const GLdouble * c) {
+ _pre_call_gl_callback("glIndexdv", (GLADapiproc) glad_glIndexdv, 1, c);
+ glad_glIndexdv(c);
+ _post_call_gl_callback(NULL, "glIndexdv", (GLADapiproc) glad_glIndexdv, 1, c);
+
+}
+PFNGLINDEXDVPROC glad_debug_glIndexdv = glad_debug_impl_glIndexdv;
+PFNGLINDEXFPROC glad_glIndexf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glIndexf(GLfloat c) {
+ _pre_call_gl_callback("glIndexf", (GLADapiproc) glad_glIndexf, 1, c);
+ glad_glIndexf(c);
+ _post_call_gl_callback(NULL, "glIndexf", (GLADapiproc) glad_glIndexf, 1, c);
+
+}
+PFNGLINDEXFPROC glad_debug_glIndexf = glad_debug_impl_glIndexf;
+PFNGLINDEXFVPROC glad_glIndexfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glIndexfv(const GLfloat * c) {
+ _pre_call_gl_callback("glIndexfv", (GLADapiproc) glad_glIndexfv, 1, c);
+ glad_glIndexfv(c);
+ _post_call_gl_callback(NULL, "glIndexfv", (GLADapiproc) glad_glIndexfv, 1, c);
+
+}
+PFNGLINDEXFVPROC glad_debug_glIndexfv = glad_debug_impl_glIndexfv;
+PFNGLINDEXIPROC glad_glIndexi = NULL;
+static void GLAD_API_PTR glad_debug_impl_glIndexi(GLint c) {
+ _pre_call_gl_callback("glIndexi", (GLADapiproc) glad_glIndexi, 1, c);
+ glad_glIndexi(c);
+ _post_call_gl_callback(NULL, "glIndexi", (GLADapiproc) glad_glIndexi, 1, c);
+
+}
+PFNGLINDEXIPROC glad_debug_glIndexi = glad_debug_impl_glIndexi;
+PFNGLINDEXIVPROC glad_glIndexiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glIndexiv(const GLint * c) {
+ _pre_call_gl_callback("glIndexiv", (GLADapiproc) glad_glIndexiv, 1, c);
+ glad_glIndexiv(c);
+ _post_call_gl_callback(NULL, "glIndexiv", (GLADapiproc) glad_glIndexiv, 1, c);
+
+}
+PFNGLINDEXIVPROC glad_debug_glIndexiv = glad_debug_impl_glIndexiv;
+PFNGLINDEXSPROC glad_glIndexs = NULL;
+static void GLAD_API_PTR glad_debug_impl_glIndexs(GLshort c) {
+ _pre_call_gl_callback("glIndexs", (GLADapiproc) glad_glIndexs, 1, c);
+ glad_glIndexs(c);
+ _post_call_gl_callback(NULL, "glIndexs", (GLADapiproc) glad_glIndexs, 1, c);
}
-PFNGLINDEXXOESPROC glad_debug_glIndexxOES = glad_debug_impl_glIndexxOES;
-PFNGLINDEXXVOESPROC glad_glIndexxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glIndexxvOES(const GLfixed * component) {
- _pre_call_gl_callback("glIndexxvOES", (GLADapiproc) glad_glIndexxvOES, 1, component);
- glad_glIndexxvOES(component);
- _post_call_gl_callback(NULL, "glIndexxvOES", (GLADapiproc) glad_glIndexxvOES, 1, component);
+PFNGLINDEXSPROC glad_debug_glIndexs = glad_debug_impl_glIndexs;
+PFNGLINDEXSVPROC glad_glIndexsv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glIndexsv(const GLshort * c) {
+ _pre_call_gl_callback("glIndexsv", (GLADapiproc) glad_glIndexsv, 1, c);
+ glad_glIndexsv(c);
+ _post_call_gl_callback(NULL, "glIndexsv", (GLADapiproc) glad_glIndexsv, 1, c);
}
-PFNGLINDEXXVOESPROC glad_debug_glIndexxvOES = glad_debug_impl_glIndexxvOES;
+PFNGLINDEXSVPROC glad_debug_glIndexsv = glad_debug_impl_glIndexsv;
+PFNGLINDEXUBPROC glad_glIndexub = NULL;
+static void GLAD_API_PTR glad_debug_impl_glIndexub(GLubyte c) {
+ _pre_call_gl_callback("glIndexub", (GLADapiproc) glad_glIndexub, 1, c);
+ glad_glIndexub(c);
+ _post_call_gl_callback(NULL, "glIndexub", (GLADapiproc) glad_glIndexub, 1, c);
+
+}
+PFNGLINDEXUBPROC glad_debug_glIndexub = glad_debug_impl_glIndexub;
+PFNGLINDEXUBVPROC glad_glIndexubv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glIndexubv(const GLubyte * c) {
+ _pre_call_gl_callback("glIndexubv", (GLADapiproc) glad_glIndexubv, 1, c);
+ glad_glIndexubv(c);
+ _post_call_gl_callback(NULL, "glIndexubv", (GLADapiproc) glad_glIndexubv, 1, c);
+
+}
+PFNGLINDEXUBVPROC glad_debug_glIndexubv = glad_debug_impl_glIndexubv;
+PFNGLINITNAMESPROC glad_glInitNames = NULL;
+static void GLAD_API_PTR glad_debug_impl_glInitNames(void) {
+ _pre_call_gl_callback("glInitNames", (GLADapiproc) glad_glInitNames, 0);
+ glad_glInitNames();
+ _post_call_gl_callback(NULL, "glInitNames", (GLADapiproc) glad_glInitNames, 0);
+
+}
+PFNGLINITNAMESPROC glad_debug_glInitNames = glad_debug_impl_glInitNames;
+PFNGLINTERLEAVEDARRAYSPROC glad_glInterleavedArrays = NULL;
+static void GLAD_API_PTR glad_debug_impl_glInterleavedArrays(GLenum format, GLsizei stride, const void * pointer) {
+ _pre_call_gl_callback("glInterleavedArrays", (GLADapiproc) glad_glInterleavedArrays, 3, format, stride, pointer);
+ glad_glInterleavedArrays(format, stride, pointer);
+ _post_call_gl_callback(NULL, "glInterleavedArrays", (GLADapiproc) glad_glInterleavedArrays, 3, format, stride, pointer);
+
+}
+PFNGLINTERLEAVEDARRAYSPROC glad_debug_glInterleavedArrays = glad_debug_impl_glInterleavedArrays;
PFNGLINVALIDATEBUFFERDATAPROC glad_glInvalidateBufferData = NULL;
static void GLAD_API_PTR glad_debug_impl_glInvalidateBufferData(GLuint buffer) {
_pre_call_gl_callback("glInvalidateBufferData", (GLADapiproc) glad_glInvalidateBufferData, 1, buffer);
@@ -3908,6 +4541,15 @@ static GLboolean GLAD_API_PTR glad_debug_impl_glIsFramebufferEXT(GLuint framebuf
return ret;
}
PFNGLISFRAMEBUFFEREXTPROC glad_debug_glIsFramebufferEXT = glad_debug_impl_glIsFramebufferEXT;
+PFNGLISLISTPROC glad_glIsList = NULL;
+static GLboolean GLAD_API_PTR glad_debug_impl_glIsList(GLuint list) {
+ GLboolean ret;
+ _pre_call_gl_callback("glIsList", (GLADapiproc) glad_glIsList, 1, list);
+ ret = glad_glIsList(list);
+ _post_call_gl_callback((void*) &ret, "glIsList", (GLADapiproc) glad_glIsList, 1, list);
+ return ret;
+}
+PFNGLISLISTPROC glad_debug_glIsList = glad_debug_impl_glIsList;
PFNGLISNAMEDSTRINGARBPROC glad_glIsNamedStringARB = NULL;
static GLboolean GLAD_API_PTR glad_debug_impl_glIsNamedStringARB(GLint namelen, const GLchar * name) {
GLboolean ret;
@@ -4034,38 +4676,78 @@ static GLboolean GLAD_API_PTR glad_debug_impl_glIsVertexArray(GLuint array) {
return ret;
}
PFNGLISVERTEXARRAYPROC glad_debug_glIsVertexArray = glad_debug_impl_glIsVertexArray;
-PFNGLLIGHTMODELXOESPROC glad_glLightModelxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glLightModelxOES(GLenum pname, GLfixed param) {
- _pre_call_gl_callback("glLightModelxOES", (GLADapiproc) glad_glLightModelxOES, 2, pname, param);
- glad_glLightModelxOES(pname, param);
- _post_call_gl_callback(NULL, "glLightModelxOES", (GLADapiproc) glad_glLightModelxOES, 2, pname, param);
+PFNGLLIGHTMODELFPROC glad_glLightModelf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLightModelf(GLenum pname, GLfloat param) {
+ _pre_call_gl_callback("glLightModelf", (GLADapiproc) glad_glLightModelf, 2, pname, param);
+ glad_glLightModelf(pname, param);
+ _post_call_gl_callback(NULL, "glLightModelf", (GLADapiproc) glad_glLightModelf, 2, pname, param);
+
+}
+PFNGLLIGHTMODELFPROC glad_debug_glLightModelf = glad_debug_impl_glLightModelf;
+PFNGLLIGHTMODELFVPROC glad_glLightModelfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLightModelfv(GLenum pname, const GLfloat * params) {
+ _pre_call_gl_callback("glLightModelfv", (GLADapiproc) glad_glLightModelfv, 2, pname, params);
+ glad_glLightModelfv(pname, params);
+ _post_call_gl_callback(NULL, "glLightModelfv", (GLADapiproc) glad_glLightModelfv, 2, pname, params);
+
+}
+PFNGLLIGHTMODELFVPROC glad_debug_glLightModelfv = glad_debug_impl_glLightModelfv;
+PFNGLLIGHTMODELIPROC glad_glLightModeli = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLightModeli(GLenum pname, GLint param) {
+ _pre_call_gl_callback("glLightModeli", (GLADapiproc) glad_glLightModeli, 2, pname, param);
+ glad_glLightModeli(pname, param);
+ _post_call_gl_callback(NULL, "glLightModeli", (GLADapiproc) glad_glLightModeli, 2, pname, param);
+
+}
+PFNGLLIGHTMODELIPROC glad_debug_glLightModeli = glad_debug_impl_glLightModeli;
+PFNGLLIGHTMODELIVPROC glad_glLightModeliv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLightModeliv(GLenum pname, const GLint * params) {
+ _pre_call_gl_callback("glLightModeliv", (GLADapiproc) glad_glLightModeliv, 2, pname, params);
+ glad_glLightModeliv(pname, params);
+ _post_call_gl_callback(NULL, "glLightModeliv", (GLADapiproc) glad_glLightModeliv, 2, pname, params);
+
+}
+PFNGLLIGHTMODELIVPROC glad_debug_glLightModeliv = glad_debug_impl_glLightModeliv;
+PFNGLLIGHTFPROC glad_glLightf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLightf(GLenum light, GLenum pname, GLfloat param) {
+ _pre_call_gl_callback("glLightf", (GLADapiproc) glad_glLightf, 3, light, pname, param);
+ glad_glLightf(light, pname, param);
+ _post_call_gl_callback(NULL, "glLightf", (GLADapiproc) glad_glLightf, 3, light, pname, param);
+
+}
+PFNGLLIGHTFPROC glad_debug_glLightf = glad_debug_impl_glLightf;
+PFNGLLIGHTFVPROC glad_glLightfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLightfv(GLenum light, GLenum pname, const GLfloat * params) {
+ _pre_call_gl_callback("glLightfv", (GLADapiproc) glad_glLightfv, 3, light, pname, params);
+ glad_glLightfv(light, pname, params);
+ _post_call_gl_callback(NULL, "glLightfv", (GLADapiproc) glad_glLightfv, 3, light, pname, params);
}
-PFNGLLIGHTMODELXOESPROC glad_debug_glLightModelxOES = glad_debug_impl_glLightModelxOES;
-PFNGLLIGHTMODELXVOESPROC glad_glLightModelxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glLightModelxvOES(GLenum pname, const GLfixed * param) {
- _pre_call_gl_callback("glLightModelxvOES", (GLADapiproc) glad_glLightModelxvOES, 2, pname, param);
- glad_glLightModelxvOES(pname, param);
- _post_call_gl_callback(NULL, "glLightModelxvOES", (GLADapiproc) glad_glLightModelxvOES, 2, pname, param);
+PFNGLLIGHTFVPROC glad_debug_glLightfv = glad_debug_impl_glLightfv;
+PFNGLLIGHTIPROC glad_glLighti = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLighti(GLenum light, GLenum pname, GLint param) {
+ _pre_call_gl_callback("glLighti", (GLADapiproc) glad_glLighti, 3, light, pname, param);
+ glad_glLighti(light, pname, param);
+ _post_call_gl_callback(NULL, "glLighti", (GLADapiproc) glad_glLighti, 3, light, pname, param);
}
-PFNGLLIGHTMODELXVOESPROC glad_debug_glLightModelxvOES = glad_debug_impl_glLightModelxvOES;
-PFNGLLIGHTXOESPROC glad_glLightxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glLightxOES(GLenum light, GLenum pname, GLfixed param) {
- _pre_call_gl_callback("glLightxOES", (GLADapiproc) glad_glLightxOES, 3, light, pname, param);
- glad_glLightxOES(light, pname, param);
- _post_call_gl_callback(NULL, "glLightxOES", (GLADapiproc) glad_glLightxOES, 3, light, pname, param);
+PFNGLLIGHTIPROC glad_debug_glLighti = glad_debug_impl_glLighti;
+PFNGLLIGHTIVPROC glad_glLightiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLightiv(GLenum light, GLenum pname, const GLint * params) {
+ _pre_call_gl_callback("glLightiv", (GLADapiproc) glad_glLightiv, 3, light, pname, params);
+ glad_glLightiv(light, pname, params);
+ _post_call_gl_callback(NULL, "glLightiv", (GLADapiproc) glad_glLightiv, 3, light, pname, params);
}
-PFNGLLIGHTXOESPROC glad_debug_glLightxOES = glad_debug_impl_glLightxOES;
-PFNGLLIGHTXVOESPROC glad_glLightxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glLightxvOES(GLenum light, GLenum pname, const GLfixed * params) {
- _pre_call_gl_callback("glLightxvOES", (GLADapiproc) glad_glLightxvOES, 3, light, pname, params);
- glad_glLightxvOES(light, pname, params);
- _post_call_gl_callback(NULL, "glLightxvOES", (GLADapiproc) glad_glLightxvOES, 3, light, pname, params);
+PFNGLLIGHTIVPROC glad_debug_glLightiv = glad_debug_impl_glLightiv;
+PFNGLLINESTIPPLEPROC glad_glLineStipple = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLineStipple(GLint factor, GLushort pattern) {
+ _pre_call_gl_callback("glLineStipple", (GLADapiproc) glad_glLineStipple, 2, factor, pattern);
+ glad_glLineStipple(factor, pattern);
+ _post_call_gl_callback(NULL, "glLineStipple", (GLADapiproc) glad_glLineStipple, 2, factor, pattern);
}
-PFNGLLIGHTXVOESPROC glad_debug_glLightxvOES = glad_debug_impl_glLightxvOES;
+PFNGLLINESTIPPLEPROC glad_debug_glLineStipple = glad_debug_impl_glLineStipple;
PFNGLLINEWIDTHPROC glad_glLineWidth = NULL;
static void GLAD_API_PTR glad_debug_impl_glLineWidth(GLfloat width) {
_pre_call_gl_callback("glLineWidth", (GLADapiproc) glad_glLineWidth, 1, width);
@@ -4074,14 +4756,6 @@ static void GLAD_API_PTR glad_debug_impl_glLineWidth(GLfloat width) {
}
PFNGLLINEWIDTHPROC glad_debug_glLineWidth = glad_debug_impl_glLineWidth;
-PFNGLLINEWIDTHXOESPROC glad_glLineWidthxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glLineWidthxOES(GLfixed width) {
- _pre_call_gl_callback("glLineWidthxOES", (GLADapiproc) glad_glLineWidthxOES, 1, width);
- glad_glLineWidthxOES(width);
- _post_call_gl_callback(NULL, "glLineWidthxOES", (GLADapiproc) glad_glLineWidthxOES, 1, width);
-
-}
-PFNGLLINEWIDTHXOESPROC glad_debug_glLineWidthxOES = glad_debug_impl_glLineWidthxOES;
PFNGLLINKPROGRAMPROC glad_glLinkProgram = NULL;
static void GLAD_API_PTR glad_debug_impl_glLinkProgram(GLuint program) {
_pre_call_gl_callback("glLinkProgram", (GLADapiproc) glad_glLinkProgram, 1, program);
@@ -4098,14 +4772,54 @@ static void GLAD_API_PTR glad_debug_impl_glLinkProgramARB(GLhandleARB programObj
}
PFNGLLINKPROGRAMARBPROC glad_debug_glLinkProgramARB = glad_debug_impl_glLinkProgramARB;
-PFNGLLOADMATRIXXOESPROC glad_glLoadMatrixxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glLoadMatrixxOES(const GLfixed * m) {
- _pre_call_gl_callback("glLoadMatrixxOES", (GLADapiproc) glad_glLoadMatrixxOES, 1, m);
- glad_glLoadMatrixxOES(m);
- _post_call_gl_callback(NULL, "glLoadMatrixxOES", (GLADapiproc) glad_glLoadMatrixxOES, 1, m);
+PFNGLLISTBASEPROC glad_glListBase = NULL;
+static void GLAD_API_PTR glad_debug_impl_glListBase(GLuint base) {
+ _pre_call_gl_callback("glListBase", (GLADapiproc) glad_glListBase, 1, base);
+ glad_glListBase(base);
+ _post_call_gl_callback(NULL, "glListBase", (GLADapiproc) glad_glListBase, 1, base);
+
+}
+PFNGLLISTBASEPROC glad_debug_glListBase = glad_debug_impl_glListBase;
+PFNGLLOADIDENTITYPROC glad_glLoadIdentity = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLoadIdentity(void) {
+ _pre_call_gl_callback("glLoadIdentity", (GLADapiproc) glad_glLoadIdentity, 0);
+ glad_glLoadIdentity();
+ _post_call_gl_callback(NULL, "glLoadIdentity", (GLADapiproc) glad_glLoadIdentity, 0);
+
+}
+PFNGLLOADIDENTITYPROC glad_debug_glLoadIdentity = glad_debug_impl_glLoadIdentity;
+PFNGLLOADMATRIXDPROC glad_glLoadMatrixd = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLoadMatrixd(const GLdouble * m) {
+ _pre_call_gl_callback("glLoadMatrixd", (GLADapiproc) glad_glLoadMatrixd, 1, m);
+ glad_glLoadMatrixd(m);
+ _post_call_gl_callback(NULL, "glLoadMatrixd", (GLADapiproc) glad_glLoadMatrixd, 1, m);
+
+}
+PFNGLLOADMATRIXDPROC glad_debug_glLoadMatrixd = glad_debug_impl_glLoadMatrixd;
+PFNGLLOADMATRIXFPROC glad_glLoadMatrixf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLoadMatrixf(const GLfloat * m) {
+ _pre_call_gl_callback("glLoadMatrixf", (GLADapiproc) glad_glLoadMatrixf, 1, m);
+ glad_glLoadMatrixf(m);
+ _post_call_gl_callback(NULL, "glLoadMatrixf", (GLADapiproc) glad_glLoadMatrixf, 1, m);
+
+}
+PFNGLLOADMATRIXFPROC glad_debug_glLoadMatrixf = glad_debug_impl_glLoadMatrixf;
+PFNGLLOADNAMEPROC glad_glLoadName = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLoadName(GLuint name) {
+ _pre_call_gl_callback("glLoadName", (GLADapiproc) glad_glLoadName, 1, name);
+ glad_glLoadName(name);
+ _post_call_gl_callback(NULL, "glLoadName", (GLADapiproc) glad_glLoadName, 1, name);
+
+}
+PFNGLLOADNAMEPROC glad_debug_glLoadName = glad_debug_impl_glLoadName;
+PFNGLLOADTRANSPOSEMATRIXDPROC glad_glLoadTransposeMatrixd = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLoadTransposeMatrixd(const GLdouble * m) {
+ _pre_call_gl_callback("glLoadTransposeMatrixd", (GLADapiproc) glad_glLoadTransposeMatrixd, 1, m);
+ glad_glLoadTransposeMatrixd(m);
+ _post_call_gl_callback(NULL, "glLoadTransposeMatrixd", (GLADapiproc) glad_glLoadTransposeMatrixd, 1, m);
}
-PFNGLLOADMATRIXXOESPROC glad_debug_glLoadMatrixxOES = glad_debug_impl_glLoadMatrixxOES;
+PFNGLLOADTRANSPOSEMATRIXDPROC glad_debug_glLoadTransposeMatrixd = glad_debug_impl_glLoadTransposeMatrixd;
PFNGLLOADTRANSPOSEMATRIXDARBPROC glad_glLoadTransposeMatrixdARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glLoadTransposeMatrixdARB(const GLdouble * m) {
_pre_call_gl_callback("glLoadTransposeMatrixdARB", (GLADapiproc) glad_glLoadTransposeMatrixdARB, 1, m);
@@ -4114,6 +4828,14 @@ static void GLAD_API_PTR glad_debug_impl_glLoadTransposeMatrixdARB(const GLdoubl
}
PFNGLLOADTRANSPOSEMATRIXDARBPROC glad_debug_glLoadTransposeMatrixdARB = glad_debug_impl_glLoadTransposeMatrixdARB;
+PFNGLLOADTRANSPOSEMATRIXFPROC glad_glLoadTransposeMatrixf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glLoadTransposeMatrixf(const GLfloat * m) {
+ _pre_call_gl_callback("glLoadTransposeMatrixf", (GLADapiproc) glad_glLoadTransposeMatrixf, 1, m);
+ glad_glLoadTransposeMatrixf(m);
+ _post_call_gl_callback(NULL, "glLoadTransposeMatrixf", (GLADapiproc) glad_glLoadTransposeMatrixf, 1, m);
+
+}
+PFNGLLOADTRANSPOSEMATRIXFPROC glad_debug_glLoadTransposeMatrixf = glad_debug_impl_glLoadTransposeMatrixf;
PFNGLLOADTRANSPOSEMATRIXFARBPROC glad_glLoadTransposeMatrixfARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glLoadTransposeMatrixfARB(const GLfloat * m) {
_pre_call_gl_callback("glLoadTransposeMatrixfARB", (GLADapiproc) glad_glLoadTransposeMatrixfARB, 1, m);
@@ -4122,14 +4844,6 @@ static void GLAD_API_PTR glad_debug_impl_glLoadTransposeMatrixfARB(const GLfloat
}
PFNGLLOADTRANSPOSEMATRIXFARBPROC glad_debug_glLoadTransposeMatrixfARB = glad_debug_impl_glLoadTransposeMatrixfARB;
-PFNGLLOADTRANSPOSEMATRIXXOESPROC glad_glLoadTransposeMatrixxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glLoadTransposeMatrixxOES(const GLfixed * m) {
- _pre_call_gl_callback("glLoadTransposeMatrixxOES", (GLADapiproc) glad_glLoadTransposeMatrixxOES, 1, m);
- glad_glLoadTransposeMatrixxOES(m);
- _post_call_gl_callback(NULL, "glLoadTransposeMatrixxOES", (GLADapiproc) glad_glLoadTransposeMatrixxOES, 1, m);
-
-}
-PFNGLLOADTRANSPOSEMATRIXXOESPROC glad_debug_glLoadTransposeMatrixxOES = glad_debug_impl_glLoadTransposeMatrixxOES;
PFNGLLOGICOPPROC glad_glLogicOp = NULL;
static void GLAD_API_PTR glad_debug_impl_glLogicOp(GLenum opcode) {
_pre_call_gl_callback("glLogicOp", (GLADapiproc) glad_glLogicOp, 1, opcode);
@@ -4138,22 +4852,38 @@ static void GLAD_API_PTR glad_debug_impl_glLogicOp(GLenum opcode) {
}
PFNGLLOGICOPPROC glad_debug_glLogicOp = glad_debug_impl_glLogicOp;
-PFNGLMAP1XOESPROC glad_glMap1xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMap1xOES(GLenum target, GLfixed u1, GLfixed u2, GLint stride, GLint order, GLfixed points) {
- _pre_call_gl_callback("glMap1xOES", (GLADapiproc) glad_glMap1xOES, 6, target, u1, u2, stride, order, points);
- glad_glMap1xOES(target, u1, u2, stride, order, points);
- _post_call_gl_callback(NULL, "glMap1xOES", (GLADapiproc) glad_glMap1xOES, 6, target, u1, u2, stride, order, points);
+PFNGLMAP1DPROC glad_glMap1d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble * points) {
+ _pre_call_gl_callback("glMap1d", (GLADapiproc) glad_glMap1d, 6, target, u1, u2, stride, order, points);
+ glad_glMap1d(target, u1, u2, stride, order, points);
+ _post_call_gl_callback(NULL, "glMap1d", (GLADapiproc) glad_glMap1d, 6, target, u1, u2, stride, order, points);
+
+}
+PFNGLMAP1DPROC glad_debug_glMap1d = glad_debug_impl_glMap1d;
+PFNGLMAP1FPROC glad_glMap1f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat * points) {
+ _pre_call_gl_callback("glMap1f", (GLADapiproc) glad_glMap1f, 6, target, u1, u2, stride, order, points);
+ glad_glMap1f(target, u1, u2, stride, order, points);
+ _post_call_gl_callback(NULL, "glMap1f", (GLADapiproc) glad_glMap1f, 6, target, u1, u2, stride, order, points);
+
+}
+PFNGLMAP1FPROC glad_debug_glMap1f = glad_debug_impl_glMap1f;
+PFNGLMAP2DPROC glad_glMap2d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble * points) {
+ _pre_call_gl_callback("glMap2d", (GLADapiproc) glad_glMap2d, 10, target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+ glad_glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+ _post_call_gl_callback(NULL, "glMap2d", (GLADapiproc) glad_glMap2d, 10, target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
}
-PFNGLMAP1XOESPROC glad_debug_glMap1xOES = glad_debug_impl_glMap1xOES;
-PFNGLMAP2XOESPROC glad_glMap2xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMap2xOES(GLenum target, GLfixed u1, GLfixed u2, GLint ustride, GLint uorder, GLfixed v1, GLfixed v2, GLint vstride, GLint vorder, GLfixed points) {
- _pre_call_gl_callback("glMap2xOES", (GLADapiproc) glad_glMap2xOES, 10, target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
- glad_glMap2xOES(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
- _post_call_gl_callback(NULL, "glMap2xOES", (GLADapiproc) glad_glMap2xOES, 10, target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+PFNGLMAP2DPROC glad_debug_glMap2d = glad_debug_impl_glMap2d;
+PFNGLMAP2FPROC glad_glMap2f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat * points) {
+ _pre_call_gl_callback("glMap2f", (GLADapiproc) glad_glMap2f, 10, target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+ glad_glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+ _post_call_gl_callback(NULL, "glMap2f", (GLADapiproc) glad_glMap2f, 10, target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
}
-PFNGLMAP2XOESPROC glad_debug_glMap2xOES = glad_debug_impl_glMap2xOES;
+PFNGLMAP2FPROC glad_debug_glMap2f = glad_debug_impl_glMap2f;
PFNGLMAPBUFFERPROC glad_glMapBuffer = NULL;
static void * GLAD_API_PTR glad_debug_impl_glMapBuffer(GLenum target, GLenum access) {
void * ret;
@@ -4181,22 +4911,38 @@ static void * GLAD_API_PTR glad_debug_impl_glMapBufferRange(GLenum target, GLint
return ret;
}
PFNGLMAPBUFFERRANGEPROC glad_debug_glMapBufferRange = glad_debug_impl_glMapBufferRange;
-PFNGLMAPGRID1XOESPROC glad_glMapGrid1xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMapGrid1xOES(GLint n, GLfixed u1, GLfixed u2) {
- _pre_call_gl_callback("glMapGrid1xOES", (GLADapiproc) glad_glMapGrid1xOES, 3, n, u1, u2);
- glad_glMapGrid1xOES(n, u1, u2);
- _post_call_gl_callback(NULL, "glMapGrid1xOES", (GLADapiproc) glad_glMapGrid1xOES, 3, n, u1, u2);
+PFNGLMAPGRID1DPROC glad_glMapGrid1d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMapGrid1d(GLint un, GLdouble u1, GLdouble u2) {
+ _pre_call_gl_callback("glMapGrid1d", (GLADapiproc) glad_glMapGrid1d, 3, un, u1, u2);
+ glad_glMapGrid1d(un, u1, u2);
+ _post_call_gl_callback(NULL, "glMapGrid1d", (GLADapiproc) glad_glMapGrid1d, 3, un, u1, u2);
+
+}
+PFNGLMAPGRID1DPROC glad_debug_glMapGrid1d = glad_debug_impl_glMapGrid1d;
+PFNGLMAPGRID1FPROC glad_glMapGrid1f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMapGrid1f(GLint un, GLfloat u1, GLfloat u2) {
+ _pre_call_gl_callback("glMapGrid1f", (GLADapiproc) glad_glMapGrid1f, 3, un, u1, u2);
+ glad_glMapGrid1f(un, u1, u2);
+ _post_call_gl_callback(NULL, "glMapGrid1f", (GLADapiproc) glad_glMapGrid1f, 3, un, u1, u2);
+
+}
+PFNGLMAPGRID1FPROC glad_debug_glMapGrid1f = glad_debug_impl_glMapGrid1f;
+PFNGLMAPGRID2DPROC glad_glMapGrid2d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2) {
+ _pre_call_gl_callback("glMapGrid2d", (GLADapiproc) glad_glMapGrid2d, 6, un, u1, u2, vn, v1, v2);
+ glad_glMapGrid2d(un, u1, u2, vn, v1, v2);
+ _post_call_gl_callback(NULL, "glMapGrid2d", (GLADapiproc) glad_glMapGrid2d, 6, un, u1, u2, vn, v1, v2);
}
-PFNGLMAPGRID1XOESPROC glad_debug_glMapGrid1xOES = glad_debug_impl_glMapGrid1xOES;
-PFNGLMAPGRID2XOESPROC glad_glMapGrid2xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMapGrid2xOES(GLint n, GLfixed u1, GLfixed u2, GLfixed v1, GLfixed v2) {
- _pre_call_gl_callback("glMapGrid2xOES", (GLADapiproc) glad_glMapGrid2xOES, 5, n, u1, u2, v1, v2);
- glad_glMapGrid2xOES(n, u1, u2, v1, v2);
- _post_call_gl_callback(NULL, "glMapGrid2xOES", (GLADapiproc) glad_glMapGrid2xOES, 5, n, u1, u2, v1, v2);
+PFNGLMAPGRID2DPROC glad_debug_glMapGrid2d = glad_debug_impl_glMapGrid2d;
+PFNGLMAPGRID2FPROC glad_glMapGrid2f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2) {
+ _pre_call_gl_callback("glMapGrid2f", (GLADapiproc) glad_glMapGrid2f, 6, un, u1, u2, vn, v1, v2);
+ glad_glMapGrid2f(un, u1, u2, vn, v1, v2);
+ _post_call_gl_callback(NULL, "glMapGrid2f", (GLADapiproc) glad_glMapGrid2f, 6, un, u1, u2, vn, v1, v2);
}
-PFNGLMAPGRID2XOESPROC glad_debug_glMapGrid2xOES = glad_debug_impl_glMapGrid2xOES;
+PFNGLMAPGRID2FPROC glad_debug_glMapGrid2f = glad_debug_impl_glMapGrid2f;
PFNGLMAPNAMEDBUFFERPROC glad_glMapNamedBuffer = NULL;
static void * GLAD_API_PTR glad_debug_impl_glMapNamedBuffer(GLuint buffer, GLenum access) {
void * ret;
@@ -4215,22 +4961,46 @@ static void * GLAD_API_PTR glad_debug_impl_glMapNamedBufferRange(GLuint buffer,
return ret;
}
PFNGLMAPNAMEDBUFFERRANGEPROC glad_debug_glMapNamedBufferRange = glad_debug_impl_glMapNamedBufferRange;
-PFNGLMATERIALXOESPROC glad_glMaterialxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMaterialxOES(GLenum face, GLenum pname, GLfixed param) {
- _pre_call_gl_callback("glMaterialxOES", (GLADapiproc) glad_glMaterialxOES, 3, face, pname, param);
- glad_glMaterialxOES(face, pname, param);
- _post_call_gl_callback(NULL, "glMaterialxOES", (GLADapiproc) glad_glMaterialxOES, 3, face, pname, param);
+PFNGLMATERIALFPROC glad_glMaterialf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMaterialf(GLenum face, GLenum pname, GLfloat param) {
+ _pre_call_gl_callback("glMaterialf", (GLADapiproc) glad_glMaterialf, 3, face, pname, param);
+ glad_glMaterialf(face, pname, param);
+ _post_call_gl_callback(NULL, "glMaterialf", (GLADapiproc) glad_glMaterialf, 3, face, pname, param);
+
+}
+PFNGLMATERIALFPROC glad_debug_glMaterialf = glad_debug_impl_glMaterialf;
+PFNGLMATERIALFVPROC glad_glMaterialfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMaterialfv(GLenum face, GLenum pname, const GLfloat * params) {
+ _pre_call_gl_callback("glMaterialfv", (GLADapiproc) glad_glMaterialfv, 3, face, pname, params);
+ glad_glMaterialfv(face, pname, params);
+ _post_call_gl_callback(NULL, "glMaterialfv", (GLADapiproc) glad_glMaterialfv, 3, face, pname, params);
+
+}
+PFNGLMATERIALFVPROC glad_debug_glMaterialfv = glad_debug_impl_glMaterialfv;
+PFNGLMATERIALIPROC glad_glMateriali = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMateriali(GLenum face, GLenum pname, GLint param) {
+ _pre_call_gl_callback("glMateriali", (GLADapiproc) glad_glMateriali, 3, face, pname, param);
+ glad_glMateriali(face, pname, param);
+ _post_call_gl_callback(NULL, "glMateriali", (GLADapiproc) glad_glMateriali, 3, face, pname, param);
+
+}
+PFNGLMATERIALIPROC glad_debug_glMateriali = glad_debug_impl_glMateriali;
+PFNGLMATERIALIVPROC glad_glMaterialiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMaterialiv(GLenum face, GLenum pname, const GLint * params) {
+ _pre_call_gl_callback("glMaterialiv", (GLADapiproc) glad_glMaterialiv, 3, face, pname, params);
+ glad_glMaterialiv(face, pname, params);
+ _post_call_gl_callback(NULL, "glMaterialiv", (GLADapiproc) glad_glMaterialiv, 3, face, pname, params);
}
-PFNGLMATERIALXOESPROC glad_debug_glMaterialxOES = glad_debug_impl_glMaterialxOES;
-PFNGLMATERIALXVOESPROC glad_glMaterialxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMaterialxvOES(GLenum face, GLenum pname, const GLfixed * param) {
- _pre_call_gl_callback("glMaterialxvOES", (GLADapiproc) glad_glMaterialxvOES, 3, face, pname, param);
- glad_glMaterialxvOES(face, pname, param);
- _post_call_gl_callback(NULL, "glMaterialxvOES", (GLADapiproc) glad_glMaterialxvOES, 3, face, pname, param);
+PFNGLMATERIALIVPROC glad_debug_glMaterialiv = glad_debug_impl_glMaterialiv;
+PFNGLMATRIXMODEPROC glad_glMatrixMode = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMatrixMode(GLenum mode) {
+ _pre_call_gl_callback("glMatrixMode", (GLADapiproc) glad_glMatrixMode, 1, mode);
+ glad_glMatrixMode(mode);
+ _post_call_gl_callback(NULL, "glMatrixMode", (GLADapiproc) glad_glMatrixMode, 1, mode);
}
-PFNGLMATERIALXVOESPROC glad_debug_glMaterialxvOES = glad_debug_impl_glMaterialxvOES;
+PFNGLMATRIXMODEPROC glad_debug_glMatrixMode = glad_debug_impl_glMatrixMode;
PFNGLMEMORYBARRIERPROC glad_glMemoryBarrier = NULL;
static void GLAD_API_PTR glad_debug_impl_glMemoryBarrier(GLbitfield barriers) {
_pre_call_gl_callback("glMemoryBarrier", (GLADapiproc) glad_glMemoryBarrier, 1, barriers);
@@ -4239,14 +5009,6 @@ static void GLAD_API_PTR glad_debug_impl_glMemoryBarrier(GLbitfield barriers) {
}
PFNGLMEMORYBARRIERPROC glad_debug_glMemoryBarrier = glad_debug_impl_glMemoryBarrier;
-PFNGLMEMORYBARRIERBYREGIONPROC glad_glMemoryBarrierByRegion = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMemoryBarrierByRegion(GLbitfield barriers) {
- _pre_call_gl_callback("glMemoryBarrierByRegion", (GLADapiproc) glad_glMemoryBarrierByRegion, 1, barriers);
- glad_glMemoryBarrierByRegion(barriers);
- _post_call_gl_callback(NULL, "glMemoryBarrierByRegion", (GLADapiproc) glad_glMemoryBarrierByRegion, 1, barriers);
-
-}
-PFNGLMEMORYBARRIERBYREGIONPROC glad_debug_glMemoryBarrierByRegion = glad_debug_impl_glMemoryBarrierByRegion;
PFNGLMINSAMPLESHADINGPROC glad_glMinSampleShading = NULL;
static void GLAD_API_PTR glad_debug_impl_glMinSampleShading(GLfloat value) {
_pre_call_gl_callback("glMinSampleShading", (GLADapiproc) glad_glMinSampleShading, 1, value);
@@ -4263,14 +5025,30 @@ static void GLAD_API_PTR glad_debug_impl_glMinSampleShadingARB(GLfloat value) {
}
PFNGLMINSAMPLESHADINGARBPROC glad_debug_glMinSampleShadingARB = glad_debug_impl_glMinSampleShadingARB;
-PFNGLMULTMATRIXXOESPROC glad_glMultMatrixxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMultMatrixxOES(const GLfixed * m) {
- _pre_call_gl_callback("glMultMatrixxOES", (GLADapiproc) glad_glMultMatrixxOES, 1, m);
- glad_glMultMatrixxOES(m);
- _post_call_gl_callback(NULL, "glMultMatrixxOES", (GLADapiproc) glad_glMultMatrixxOES, 1, m);
+PFNGLMULTMATRIXDPROC glad_glMultMatrixd = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultMatrixd(const GLdouble * m) {
+ _pre_call_gl_callback("glMultMatrixd", (GLADapiproc) glad_glMultMatrixd, 1, m);
+ glad_glMultMatrixd(m);
+ _post_call_gl_callback(NULL, "glMultMatrixd", (GLADapiproc) glad_glMultMatrixd, 1, m);
+
+}
+PFNGLMULTMATRIXDPROC glad_debug_glMultMatrixd = glad_debug_impl_glMultMatrixd;
+PFNGLMULTMATRIXFPROC glad_glMultMatrixf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultMatrixf(const GLfloat * m) {
+ _pre_call_gl_callback("glMultMatrixf", (GLADapiproc) glad_glMultMatrixf, 1, m);
+ glad_glMultMatrixf(m);
+ _post_call_gl_callback(NULL, "glMultMatrixf", (GLADapiproc) glad_glMultMatrixf, 1, m);
+
+}
+PFNGLMULTMATRIXFPROC glad_debug_glMultMatrixf = glad_debug_impl_glMultMatrixf;
+PFNGLMULTTRANSPOSEMATRIXDPROC glad_glMultTransposeMatrixd = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultTransposeMatrixd(const GLdouble * m) {
+ _pre_call_gl_callback("glMultTransposeMatrixd", (GLADapiproc) glad_glMultTransposeMatrixd, 1, m);
+ glad_glMultTransposeMatrixd(m);
+ _post_call_gl_callback(NULL, "glMultTransposeMatrixd", (GLADapiproc) glad_glMultTransposeMatrixd, 1, m);
}
-PFNGLMULTMATRIXXOESPROC glad_debug_glMultMatrixxOES = glad_debug_impl_glMultMatrixxOES;
+PFNGLMULTTRANSPOSEMATRIXDPROC glad_debug_glMultTransposeMatrixd = glad_debug_impl_glMultTransposeMatrixd;
PFNGLMULTTRANSPOSEMATRIXDARBPROC glad_glMultTransposeMatrixdARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultTransposeMatrixdARB(const GLdouble * m) {
_pre_call_gl_callback("glMultTransposeMatrixdARB", (GLADapiproc) glad_glMultTransposeMatrixdARB, 1, m);
@@ -4279,6 +5057,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultTransposeMatrixdARB(const GLdoubl
}
PFNGLMULTTRANSPOSEMATRIXDARBPROC glad_debug_glMultTransposeMatrixdARB = glad_debug_impl_glMultTransposeMatrixdARB;
+PFNGLMULTTRANSPOSEMATRIXFPROC glad_glMultTransposeMatrixf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultTransposeMatrixf(const GLfloat * m) {
+ _pre_call_gl_callback("glMultTransposeMatrixf", (GLADapiproc) glad_glMultTransposeMatrixf, 1, m);
+ glad_glMultTransposeMatrixf(m);
+ _post_call_gl_callback(NULL, "glMultTransposeMatrixf", (GLADapiproc) glad_glMultTransposeMatrixf, 1, m);
+
+}
+PFNGLMULTTRANSPOSEMATRIXFPROC glad_debug_glMultTransposeMatrixf = glad_debug_impl_glMultTransposeMatrixf;
PFNGLMULTTRANSPOSEMATRIXFARBPROC glad_glMultTransposeMatrixfARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultTransposeMatrixfARB(const GLfloat * m) {
_pre_call_gl_callback("glMultTransposeMatrixfARB", (GLADapiproc) glad_glMultTransposeMatrixfARB, 1, m);
@@ -4287,14 +5073,6 @@ static void GLAD_API_PTR glad_debug_impl_glMultTransposeMatrixfARB(const GLfloat
}
PFNGLMULTTRANSPOSEMATRIXFARBPROC glad_debug_glMultTransposeMatrixfARB = glad_debug_impl_glMultTransposeMatrixfARB;
-PFNGLMULTTRANSPOSEMATRIXXOESPROC glad_glMultTransposeMatrixxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMultTransposeMatrixxOES(const GLfixed * m) {
- _pre_call_gl_callback("glMultTransposeMatrixxOES", (GLADapiproc) glad_glMultTransposeMatrixxOES, 1, m);
- glad_glMultTransposeMatrixxOES(m);
- _post_call_gl_callback(NULL, "glMultTransposeMatrixxOES", (GLADapiproc) glad_glMultTransposeMatrixxOES, 1, m);
-
-}
-PFNGLMULTTRANSPOSEMATRIXXOESPROC glad_debug_glMultTransposeMatrixxOES = glad_debug_impl_glMultTransposeMatrixxOES;
PFNGLMULTIDRAWARRAYSPROC glad_glMultiDrawArrays = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiDrawArrays(GLenum mode, const GLint * first, const GLsizei * count, GLsizei drawcount) {
_pre_call_gl_callback("glMultiDrawArrays", (GLADapiproc) glad_glMultiDrawArrays, 4, mode, first, count, drawcount);
@@ -4335,6 +5113,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiDrawElementsIndirect(GLenum mode
}
PFNGLMULTIDRAWELEMENTSINDIRECTPROC glad_debug_glMultiDrawElementsIndirect = glad_debug_impl_glMultiDrawElementsIndirect;
+PFNGLMULTITEXCOORD1DPROC glad_glMultiTexCoord1d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1d(GLenum target, GLdouble s) {
+ _pre_call_gl_callback("glMultiTexCoord1d", (GLADapiproc) glad_glMultiTexCoord1d, 2, target, s);
+ glad_glMultiTexCoord1d(target, s);
+ _post_call_gl_callback(NULL, "glMultiTexCoord1d", (GLADapiproc) glad_glMultiTexCoord1d, 2, target, s);
+
+}
+PFNGLMULTITEXCOORD1DPROC glad_debug_glMultiTexCoord1d = glad_debug_impl_glMultiTexCoord1d;
PFNGLMULTITEXCOORD1DARBPROC glad_glMultiTexCoord1dARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1dARB(GLenum target, GLdouble s) {
_pre_call_gl_callback("glMultiTexCoord1dARB", (GLADapiproc) glad_glMultiTexCoord1dARB, 2, target, s);
@@ -4343,7 +5129,15 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1dARB(GLenum target, GLd
}
PFNGLMULTITEXCOORD1DARBPROC glad_debug_glMultiTexCoord1dARB = glad_debug_impl_glMultiTexCoord1dARB;
-PFNGLMULTITEXCOORD1DVARBPROC glad_glMultiTexCoord1dvARB = NULL;
+PFNGLMULTITEXCOORD1DVPROC glad_glMultiTexCoord1dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1dv(GLenum target, const GLdouble * v) {
+ _pre_call_gl_callback("glMultiTexCoord1dv", (GLADapiproc) glad_glMultiTexCoord1dv, 2, target, v);
+ glad_glMultiTexCoord1dv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord1dv", (GLADapiproc) glad_glMultiTexCoord1dv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD1DVPROC glad_debug_glMultiTexCoord1dv = glad_debug_impl_glMultiTexCoord1dv;
+PFNGLMULTITEXCOORD1DVARBPROC glad_glMultiTexCoord1dvARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1dvARB(GLenum target, const GLdouble * v) {
_pre_call_gl_callback("glMultiTexCoord1dvARB", (GLADapiproc) glad_glMultiTexCoord1dvARB, 2, target, v);
glad_glMultiTexCoord1dvARB(target, v);
@@ -4351,6 +5145,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1dvARB(GLenum target, co
}
PFNGLMULTITEXCOORD1DVARBPROC glad_debug_glMultiTexCoord1dvARB = glad_debug_impl_glMultiTexCoord1dvARB;
+PFNGLMULTITEXCOORD1FPROC glad_glMultiTexCoord1f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1f(GLenum target, GLfloat s) {
+ _pre_call_gl_callback("glMultiTexCoord1f", (GLADapiproc) glad_glMultiTexCoord1f, 2, target, s);
+ glad_glMultiTexCoord1f(target, s);
+ _post_call_gl_callback(NULL, "glMultiTexCoord1f", (GLADapiproc) glad_glMultiTexCoord1f, 2, target, s);
+
+}
+PFNGLMULTITEXCOORD1FPROC glad_debug_glMultiTexCoord1f = glad_debug_impl_glMultiTexCoord1f;
PFNGLMULTITEXCOORD1FARBPROC glad_glMultiTexCoord1fARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1fARB(GLenum target, GLfloat s) {
_pre_call_gl_callback("glMultiTexCoord1fARB", (GLADapiproc) glad_glMultiTexCoord1fARB, 2, target, s);
@@ -4359,6 +5161,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1fARB(GLenum target, GLf
}
PFNGLMULTITEXCOORD1FARBPROC glad_debug_glMultiTexCoord1fARB = glad_debug_impl_glMultiTexCoord1fARB;
+PFNGLMULTITEXCOORD1FVPROC glad_glMultiTexCoord1fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1fv(GLenum target, const GLfloat * v) {
+ _pre_call_gl_callback("glMultiTexCoord1fv", (GLADapiproc) glad_glMultiTexCoord1fv, 2, target, v);
+ glad_glMultiTexCoord1fv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord1fv", (GLADapiproc) glad_glMultiTexCoord1fv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD1FVPROC glad_debug_glMultiTexCoord1fv = glad_debug_impl_glMultiTexCoord1fv;
PFNGLMULTITEXCOORD1FVARBPROC glad_glMultiTexCoord1fvARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1fvARB(GLenum target, const GLfloat * v) {
_pre_call_gl_callback("glMultiTexCoord1fvARB", (GLADapiproc) glad_glMultiTexCoord1fvARB, 2, target, v);
@@ -4367,6 +5177,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1fvARB(GLenum target, co
}
PFNGLMULTITEXCOORD1FVARBPROC glad_debug_glMultiTexCoord1fvARB = glad_debug_impl_glMultiTexCoord1fvARB;
+PFNGLMULTITEXCOORD1IPROC glad_glMultiTexCoord1i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1i(GLenum target, GLint s) {
+ _pre_call_gl_callback("glMultiTexCoord1i", (GLADapiproc) glad_glMultiTexCoord1i, 2, target, s);
+ glad_glMultiTexCoord1i(target, s);
+ _post_call_gl_callback(NULL, "glMultiTexCoord1i", (GLADapiproc) glad_glMultiTexCoord1i, 2, target, s);
+
+}
+PFNGLMULTITEXCOORD1IPROC glad_debug_glMultiTexCoord1i = glad_debug_impl_glMultiTexCoord1i;
PFNGLMULTITEXCOORD1IARBPROC glad_glMultiTexCoord1iARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1iARB(GLenum target, GLint s) {
_pre_call_gl_callback("glMultiTexCoord1iARB", (GLADapiproc) glad_glMultiTexCoord1iARB, 2, target, s);
@@ -4375,6 +5193,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1iARB(GLenum target, GLi
}
PFNGLMULTITEXCOORD1IARBPROC glad_debug_glMultiTexCoord1iARB = glad_debug_impl_glMultiTexCoord1iARB;
+PFNGLMULTITEXCOORD1IVPROC glad_glMultiTexCoord1iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1iv(GLenum target, const GLint * v) {
+ _pre_call_gl_callback("glMultiTexCoord1iv", (GLADapiproc) glad_glMultiTexCoord1iv, 2, target, v);
+ glad_glMultiTexCoord1iv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord1iv", (GLADapiproc) glad_glMultiTexCoord1iv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD1IVPROC glad_debug_glMultiTexCoord1iv = glad_debug_impl_glMultiTexCoord1iv;
PFNGLMULTITEXCOORD1IVARBPROC glad_glMultiTexCoord1ivARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1ivARB(GLenum target, const GLint * v) {
_pre_call_gl_callback("glMultiTexCoord1ivARB", (GLADapiproc) glad_glMultiTexCoord1ivARB, 2, target, v);
@@ -4383,6 +5209,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1ivARB(GLenum target, co
}
PFNGLMULTITEXCOORD1IVARBPROC glad_debug_glMultiTexCoord1ivARB = glad_debug_impl_glMultiTexCoord1ivARB;
+PFNGLMULTITEXCOORD1SPROC glad_glMultiTexCoord1s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1s(GLenum target, GLshort s) {
+ _pre_call_gl_callback("glMultiTexCoord1s", (GLADapiproc) glad_glMultiTexCoord1s, 2, target, s);
+ glad_glMultiTexCoord1s(target, s);
+ _post_call_gl_callback(NULL, "glMultiTexCoord1s", (GLADapiproc) glad_glMultiTexCoord1s, 2, target, s);
+
+}
+PFNGLMULTITEXCOORD1SPROC glad_debug_glMultiTexCoord1s = glad_debug_impl_glMultiTexCoord1s;
PFNGLMULTITEXCOORD1SARBPROC glad_glMultiTexCoord1sARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1sARB(GLenum target, GLshort s) {
_pre_call_gl_callback("glMultiTexCoord1sARB", (GLADapiproc) glad_glMultiTexCoord1sARB, 2, target, s);
@@ -4391,6 +5225,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1sARB(GLenum target, GLs
}
PFNGLMULTITEXCOORD1SARBPROC glad_debug_glMultiTexCoord1sARB = glad_debug_impl_glMultiTexCoord1sARB;
+PFNGLMULTITEXCOORD1SVPROC glad_glMultiTexCoord1sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1sv(GLenum target, const GLshort * v) {
+ _pre_call_gl_callback("glMultiTexCoord1sv", (GLADapiproc) glad_glMultiTexCoord1sv, 2, target, v);
+ glad_glMultiTexCoord1sv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord1sv", (GLADapiproc) glad_glMultiTexCoord1sv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD1SVPROC glad_debug_glMultiTexCoord1sv = glad_debug_impl_glMultiTexCoord1sv;
PFNGLMULTITEXCOORD1SVARBPROC glad_glMultiTexCoord1svARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1svARB(GLenum target, const GLshort * v) {
_pre_call_gl_callback("glMultiTexCoord1svARB", (GLADapiproc) glad_glMultiTexCoord1svARB, 2, target, v);
@@ -4399,22 +5241,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1svARB(GLenum target, co
}
PFNGLMULTITEXCOORD1SVARBPROC glad_debug_glMultiTexCoord1svARB = glad_debug_impl_glMultiTexCoord1svARB;
-PFNGLMULTITEXCOORD1XOESPROC glad_glMultiTexCoord1xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1xOES(GLenum texture, GLfixed s) {
- _pre_call_gl_callback("glMultiTexCoord1xOES", (GLADapiproc) glad_glMultiTexCoord1xOES, 2, texture, s);
- glad_glMultiTexCoord1xOES(texture, s);
- _post_call_gl_callback(NULL, "glMultiTexCoord1xOES", (GLADapiproc) glad_glMultiTexCoord1xOES, 2, texture, s);
-
-}
-PFNGLMULTITEXCOORD1XOESPROC glad_debug_glMultiTexCoord1xOES = glad_debug_impl_glMultiTexCoord1xOES;
-PFNGLMULTITEXCOORD1XVOESPROC glad_glMultiTexCoord1xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord1xvOES(GLenum texture, const GLfixed * coords) {
- _pre_call_gl_callback("glMultiTexCoord1xvOES", (GLADapiproc) glad_glMultiTexCoord1xvOES, 2, texture, coords);
- glad_glMultiTexCoord1xvOES(texture, coords);
- _post_call_gl_callback(NULL, "glMultiTexCoord1xvOES", (GLADapiproc) glad_glMultiTexCoord1xvOES, 2, texture, coords);
+PFNGLMULTITEXCOORD2DPROC glad_glMultiTexCoord2d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t) {
+ _pre_call_gl_callback("glMultiTexCoord2d", (GLADapiproc) glad_glMultiTexCoord2d, 3, target, s, t);
+ glad_glMultiTexCoord2d(target, s, t);
+ _post_call_gl_callback(NULL, "glMultiTexCoord2d", (GLADapiproc) glad_glMultiTexCoord2d, 3, target, s, t);
}
-PFNGLMULTITEXCOORD1XVOESPROC glad_debug_glMultiTexCoord1xvOES = glad_debug_impl_glMultiTexCoord1xvOES;
+PFNGLMULTITEXCOORD2DPROC glad_debug_glMultiTexCoord2d = glad_debug_impl_glMultiTexCoord2d;
PFNGLMULTITEXCOORD2DARBPROC glad_glMultiTexCoord2dARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2dARB(GLenum target, GLdouble s, GLdouble t) {
_pre_call_gl_callback("glMultiTexCoord2dARB", (GLADapiproc) glad_glMultiTexCoord2dARB, 3, target, s, t);
@@ -4423,6 +5257,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2dARB(GLenum target, GLd
}
PFNGLMULTITEXCOORD2DARBPROC glad_debug_glMultiTexCoord2dARB = glad_debug_impl_glMultiTexCoord2dARB;
+PFNGLMULTITEXCOORD2DVPROC glad_glMultiTexCoord2dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2dv(GLenum target, const GLdouble * v) {
+ _pre_call_gl_callback("glMultiTexCoord2dv", (GLADapiproc) glad_glMultiTexCoord2dv, 2, target, v);
+ glad_glMultiTexCoord2dv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord2dv", (GLADapiproc) glad_glMultiTexCoord2dv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD2DVPROC glad_debug_glMultiTexCoord2dv = glad_debug_impl_glMultiTexCoord2dv;
PFNGLMULTITEXCOORD2DVARBPROC glad_glMultiTexCoord2dvARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2dvARB(GLenum target, const GLdouble * v) {
_pre_call_gl_callback("glMultiTexCoord2dvARB", (GLADapiproc) glad_glMultiTexCoord2dvARB, 2, target, v);
@@ -4431,6 +5273,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2dvARB(GLenum target, co
}
PFNGLMULTITEXCOORD2DVARBPROC glad_debug_glMultiTexCoord2dvARB = glad_debug_impl_glMultiTexCoord2dvARB;
+PFNGLMULTITEXCOORD2FPROC glad_glMultiTexCoord2f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t) {
+ _pre_call_gl_callback("glMultiTexCoord2f", (GLADapiproc) glad_glMultiTexCoord2f, 3, target, s, t);
+ glad_glMultiTexCoord2f(target, s, t);
+ _post_call_gl_callback(NULL, "glMultiTexCoord2f", (GLADapiproc) glad_glMultiTexCoord2f, 3, target, s, t);
+
+}
+PFNGLMULTITEXCOORD2FPROC glad_debug_glMultiTexCoord2f = glad_debug_impl_glMultiTexCoord2f;
PFNGLMULTITEXCOORD2FARBPROC glad_glMultiTexCoord2fARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2fARB(GLenum target, GLfloat s, GLfloat t) {
_pre_call_gl_callback("glMultiTexCoord2fARB", (GLADapiproc) glad_glMultiTexCoord2fARB, 3, target, s, t);
@@ -4439,6 +5289,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2fARB(GLenum target, GLf
}
PFNGLMULTITEXCOORD2FARBPROC glad_debug_glMultiTexCoord2fARB = glad_debug_impl_glMultiTexCoord2fARB;
+PFNGLMULTITEXCOORD2FVPROC glad_glMultiTexCoord2fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2fv(GLenum target, const GLfloat * v) {
+ _pre_call_gl_callback("glMultiTexCoord2fv", (GLADapiproc) glad_glMultiTexCoord2fv, 2, target, v);
+ glad_glMultiTexCoord2fv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord2fv", (GLADapiproc) glad_glMultiTexCoord2fv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD2FVPROC glad_debug_glMultiTexCoord2fv = glad_debug_impl_glMultiTexCoord2fv;
PFNGLMULTITEXCOORD2FVARBPROC glad_glMultiTexCoord2fvARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2fvARB(GLenum target, const GLfloat * v) {
_pre_call_gl_callback("glMultiTexCoord2fvARB", (GLADapiproc) glad_glMultiTexCoord2fvARB, 2, target, v);
@@ -4447,6 +5305,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2fvARB(GLenum target, co
}
PFNGLMULTITEXCOORD2FVARBPROC glad_debug_glMultiTexCoord2fvARB = glad_debug_impl_glMultiTexCoord2fvARB;
+PFNGLMULTITEXCOORD2IPROC glad_glMultiTexCoord2i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2i(GLenum target, GLint s, GLint t) {
+ _pre_call_gl_callback("glMultiTexCoord2i", (GLADapiproc) glad_glMultiTexCoord2i, 3, target, s, t);
+ glad_glMultiTexCoord2i(target, s, t);
+ _post_call_gl_callback(NULL, "glMultiTexCoord2i", (GLADapiproc) glad_glMultiTexCoord2i, 3, target, s, t);
+
+}
+PFNGLMULTITEXCOORD2IPROC glad_debug_glMultiTexCoord2i = glad_debug_impl_glMultiTexCoord2i;
PFNGLMULTITEXCOORD2IARBPROC glad_glMultiTexCoord2iARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2iARB(GLenum target, GLint s, GLint t) {
_pre_call_gl_callback("glMultiTexCoord2iARB", (GLADapiproc) glad_glMultiTexCoord2iARB, 3, target, s, t);
@@ -4455,6 +5321,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2iARB(GLenum target, GLi
}
PFNGLMULTITEXCOORD2IARBPROC glad_debug_glMultiTexCoord2iARB = glad_debug_impl_glMultiTexCoord2iARB;
+PFNGLMULTITEXCOORD2IVPROC glad_glMultiTexCoord2iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2iv(GLenum target, const GLint * v) {
+ _pre_call_gl_callback("glMultiTexCoord2iv", (GLADapiproc) glad_glMultiTexCoord2iv, 2, target, v);
+ glad_glMultiTexCoord2iv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord2iv", (GLADapiproc) glad_glMultiTexCoord2iv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD2IVPROC glad_debug_glMultiTexCoord2iv = glad_debug_impl_glMultiTexCoord2iv;
PFNGLMULTITEXCOORD2IVARBPROC glad_glMultiTexCoord2ivARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2ivARB(GLenum target, const GLint * v) {
_pre_call_gl_callback("glMultiTexCoord2ivARB", (GLADapiproc) glad_glMultiTexCoord2ivARB, 2, target, v);
@@ -4463,6 +5337,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2ivARB(GLenum target, co
}
PFNGLMULTITEXCOORD2IVARBPROC glad_debug_glMultiTexCoord2ivARB = glad_debug_impl_glMultiTexCoord2ivARB;
+PFNGLMULTITEXCOORD2SPROC glad_glMultiTexCoord2s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2s(GLenum target, GLshort s, GLshort t) {
+ _pre_call_gl_callback("glMultiTexCoord2s", (GLADapiproc) glad_glMultiTexCoord2s, 3, target, s, t);
+ glad_glMultiTexCoord2s(target, s, t);
+ _post_call_gl_callback(NULL, "glMultiTexCoord2s", (GLADapiproc) glad_glMultiTexCoord2s, 3, target, s, t);
+
+}
+PFNGLMULTITEXCOORD2SPROC glad_debug_glMultiTexCoord2s = glad_debug_impl_glMultiTexCoord2s;
PFNGLMULTITEXCOORD2SARBPROC glad_glMultiTexCoord2sARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2sARB(GLenum target, GLshort s, GLshort t) {
_pre_call_gl_callback("glMultiTexCoord2sARB", (GLADapiproc) glad_glMultiTexCoord2sARB, 3, target, s, t);
@@ -4471,6 +5353,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2sARB(GLenum target, GLs
}
PFNGLMULTITEXCOORD2SARBPROC glad_debug_glMultiTexCoord2sARB = glad_debug_impl_glMultiTexCoord2sARB;
+PFNGLMULTITEXCOORD2SVPROC glad_glMultiTexCoord2sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2sv(GLenum target, const GLshort * v) {
+ _pre_call_gl_callback("glMultiTexCoord2sv", (GLADapiproc) glad_glMultiTexCoord2sv, 2, target, v);
+ glad_glMultiTexCoord2sv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord2sv", (GLADapiproc) glad_glMultiTexCoord2sv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD2SVPROC glad_debug_glMultiTexCoord2sv = glad_debug_impl_glMultiTexCoord2sv;
PFNGLMULTITEXCOORD2SVARBPROC glad_glMultiTexCoord2svARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2svARB(GLenum target, const GLshort * v) {
_pre_call_gl_callback("glMultiTexCoord2svARB", (GLADapiproc) glad_glMultiTexCoord2svARB, 2, target, v);
@@ -4479,22 +5369,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2svARB(GLenum target, co
}
PFNGLMULTITEXCOORD2SVARBPROC glad_debug_glMultiTexCoord2svARB = glad_debug_impl_glMultiTexCoord2svARB;
-PFNGLMULTITEXCOORD2XOESPROC glad_glMultiTexCoord2xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2xOES(GLenum texture, GLfixed s, GLfixed t) {
- _pre_call_gl_callback("glMultiTexCoord2xOES", (GLADapiproc) glad_glMultiTexCoord2xOES, 3, texture, s, t);
- glad_glMultiTexCoord2xOES(texture, s, t);
- _post_call_gl_callback(NULL, "glMultiTexCoord2xOES", (GLADapiproc) glad_glMultiTexCoord2xOES, 3, texture, s, t);
-
-}
-PFNGLMULTITEXCOORD2XOESPROC glad_debug_glMultiTexCoord2xOES = glad_debug_impl_glMultiTexCoord2xOES;
-PFNGLMULTITEXCOORD2XVOESPROC glad_glMultiTexCoord2xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord2xvOES(GLenum texture, const GLfixed * coords) {
- _pre_call_gl_callback("glMultiTexCoord2xvOES", (GLADapiproc) glad_glMultiTexCoord2xvOES, 2, texture, coords);
- glad_glMultiTexCoord2xvOES(texture, coords);
- _post_call_gl_callback(NULL, "glMultiTexCoord2xvOES", (GLADapiproc) glad_glMultiTexCoord2xvOES, 2, texture, coords);
+PFNGLMULTITEXCOORD3DPROC glad_glMultiTexCoord3d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r) {
+ _pre_call_gl_callback("glMultiTexCoord3d", (GLADapiproc) glad_glMultiTexCoord3d, 4, target, s, t, r);
+ glad_glMultiTexCoord3d(target, s, t, r);
+ _post_call_gl_callback(NULL, "glMultiTexCoord3d", (GLADapiproc) glad_glMultiTexCoord3d, 4, target, s, t, r);
}
-PFNGLMULTITEXCOORD2XVOESPROC glad_debug_glMultiTexCoord2xvOES = glad_debug_impl_glMultiTexCoord2xvOES;
+PFNGLMULTITEXCOORD3DPROC glad_debug_glMultiTexCoord3d = glad_debug_impl_glMultiTexCoord3d;
PFNGLMULTITEXCOORD3DARBPROC glad_glMultiTexCoord3dARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3dARB(GLenum target, GLdouble s, GLdouble t, GLdouble r) {
_pre_call_gl_callback("glMultiTexCoord3dARB", (GLADapiproc) glad_glMultiTexCoord3dARB, 4, target, s, t, r);
@@ -4503,6 +5385,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3dARB(GLenum target, GLd
}
PFNGLMULTITEXCOORD3DARBPROC glad_debug_glMultiTexCoord3dARB = glad_debug_impl_glMultiTexCoord3dARB;
+PFNGLMULTITEXCOORD3DVPROC glad_glMultiTexCoord3dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3dv(GLenum target, const GLdouble * v) {
+ _pre_call_gl_callback("glMultiTexCoord3dv", (GLADapiproc) glad_glMultiTexCoord3dv, 2, target, v);
+ glad_glMultiTexCoord3dv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord3dv", (GLADapiproc) glad_glMultiTexCoord3dv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD3DVPROC glad_debug_glMultiTexCoord3dv = glad_debug_impl_glMultiTexCoord3dv;
PFNGLMULTITEXCOORD3DVARBPROC glad_glMultiTexCoord3dvARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3dvARB(GLenum target, const GLdouble * v) {
_pre_call_gl_callback("glMultiTexCoord3dvARB", (GLADapiproc) glad_glMultiTexCoord3dvARB, 2, target, v);
@@ -4511,6 +5401,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3dvARB(GLenum target, co
}
PFNGLMULTITEXCOORD3DVARBPROC glad_debug_glMultiTexCoord3dvARB = glad_debug_impl_glMultiTexCoord3dvARB;
+PFNGLMULTITEXCOORD3FPROC glad_glMultiTexCoord3f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r) {
+ _pre_call_gl_callback("glMultiTexCoord3f", (GLADapiproc) glad_glMultiTexCoord3f, 4, target, s, t, r);
+ glad_glMultiTexCoord3f(target, s, t, r);
+ _post_call_gl_callback(NULL, "glMultiTexCoord3f", (GLADapiproc) glad_glMultiTexCoord3f, 4, target, s, t, r);
+
+}
+PFNGLMULTITEXCOORD3FPROC glad_debug_glMultiTexCoord3f = glad_debug_impl_glMultiTexCoord3f;
PFNGLMULTITEXCOORD3FARBPROC glad_glMultiTexCoord3fARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3fARB(GLenum target, GLfloat s, GLfloat t, GLfloat r) {
_pre_call_gl_callback("glMultiTexCoord3fARB", (GLADapiproc) glad_glMultiTexCoord3fARB, 4, target, s, t, r);
@@ -4519,6 +5417,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3fARB(GLenum target, GLf
}
PFNGLMULTITEXCOORD3FARBPROC glad_debug_glMultiTexCoord3fARB = glad_debug_impl_glMultiTexCoord3fARB;
+PFNGLMULTITEXCOORD3FVPROC glad_glMultiTexCoord3fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3fv(GLenum target, const GLfloat * v) {
+ _pre_call_gl_callback("glMultiTexCoord3fv", (GLADapiproc) glad_glMultiTexCoord3fv, 2, target, v);
+ glad_glMultiTexCoord3fv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord3fv", (GLADapiproc) glad_glMultiTexCoord3fv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD3FVPROC glad_debug_glMultiTexCoord3fv = glad_debug_impl_glMultiTexCoord3fv;
PFNGLMULTITEXCOORD3FVARBPROC glad_glMultiTexCoord3fvARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3fvARB(GLenum target, const GLfloat * v) {
_pre_call_gl_callback("glMultiTexCoord3fvARB", (GLADapiproc) glad_glMultiTexCoord3fvARB, 2, target, v);
@@ -4527,6 +5433,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3fvARB(GLenum target, co
}
PFNGLMULTITEXCOORD3FVARBPROC glad_debug_glMultiTexCoord3fvARB = glad_debug_impl_glMultiTexCoord3fvARB;
+PFNGLMULTITEXCOORD3IPROC glad_glMultiTexCoord3i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r) {
+ _pre_call_gl_callback("glMultiTexCoord3i", (GLADapiproc) glad_glMultiTexCoord3i, 4, target, s, t, r);
+ glad_glMultiTexCoord3i(target, s, t, r);
+ _post_call_gl_callback(NULL, "glMultiTexCoord3i", (GLADapiproc) glad_glMultiTexCoord3i, 4, target, s, t, r);
+
+}
+PFNGLMULTITEXCOORD3IPROC glad_debug_glMultiTexCoord3i = glad_debug_impl_glMultiTexCoord3i;
PFNGLMULTITEXCOORD3IARBPROC glad_glMultiTexCoord3iARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3iARB(GLenum target, GLint s, GLint t, GLint r) {
_pre_call_gl_callback("glMultiTexCoord3iARB", (GLADapiproc) glad_glMultiTexCoord3iARB, 4, target, s, t, r);
@@ -4535,6 +5449,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3iARB(GLenum target, GLi
}
PFNGLMULTITEXCOORD3IARBPROC glad_debug_glMultiTexCoord3iARB = glad_debug_impl_glMultiTexCoord3iARB;
+PFNGLMULTITEXCOORD3IVPROC glad_glMultiTexCoord3iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3iv(GLenum target, const GLint * v) {
+ _pre_call_gl_callback("glMultiTexCoord3iv", (GLADapiproc) glad_glMultiTexCoord3iv, 2, target, v);
+ glad_glMultiTexCoord3iv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord3iv", (GLADapiproc) glad_glMultiTexCoord3iv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD3IVPROC glad_debug_glMultiTexCoord3iv = glad_debug_impl_glMultiTexCoord3iv;
PFNGLMULTITEXCOORD3IVARBPROC glad_glMultiTexCoord3ivARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3ivARB(GLenum target, const GLint * v) {
_pre_call_gl_callback("glMultiTexCoord3ivARB", (GLADapiproc) glad_glMultiTexCoord3ivARB, 2, target, v);
@@ -4543,6 +5465,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3ivARB(GLenum target, co
}
PFNGLMULTITEXCOORD3IVARBPROC glad_debug_glMultiTexCoord3ivARB = glad_debug_impl_glMultiTexCoord3ivARB;
+PFNGLMULTITEXCOORD3SPROC glad_glMultiTexCoord3s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r) {
+ _pre_call_gl_callback("glMultiTexCoord3s", (GLADapiproc) glad_glMultiTexCoord3s, 4, target, s, t, r);
+ glad_glMultiTexCoord3s(target, s, t, r);
+ _post_call_gl_callback(NULL, "glMultiTexCoord3s", (GLADapiproc) glad_glMultiTexCoord3s, 4, target, s, t, r);
+
+}
+PFNGLMULTITEXCOORD3SPROC glad_debug_glMultiTexCoord3s = glad_debug_impl_glMultiTexCoord3s;
PFNGLMULTITEXCOORD3SARBPROC glad_glMultiTexCoord3sARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3sARB(GLenum target, GLshort s, GLshort t, GLshort r) {
_pre_call_gl_callback("glMultiTexCoord3sARB", (GLADapiproc) glad_glMultiTexCoord3sARB, 4, target, s, t, r);
@@ -4551,6 +5481,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3sARB(GLenum target, GLs
}
PFNGLMULTITEXCOORD3SARBPROC glad_debug_glMultiTexCoord3sARB = glad_debug_impl_glMultiTexCoord3sARB;
+PFNGLMULTITEXCOORD3SVPROC glad_glMultiTexCoord3sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3sv(GLenum target, const GLshort * v) {
+ _pre_call_gl_callback("glMultiTexCoord3sv", (GLADapiproc) glad_glMultiTexCoord3sv, 2, target, v);
+ glad_glMultiTexCoord3sv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord3sv", (GLADapiproc) glad_glMultiTexCoord3sv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD3SVPROC glad_debug_glMultiTexCoord3sv = glad_debug_impl_glMultiTexCoord3sv;
PFNGLMULTITEXCOORD3SVARBPROC glad_glMultiTexCoord3svARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3svARB(GLenum target, const GLshort * v) {
_pre_call_gl_callback("glMultiTexCoord3svARB", (GLADapiproc) glad_glMultiTexCoord3svARB, 2, target, v);
@@ -4559,22 +5497,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3svARB(GLenum target, co
}
PFNGLMULTITEXCOORD3SVARBPROC glad_debug_glMultiTexCoord3svARB = glad_debug_impl_glMultiTexCoord3svARB;
-PFNGLMULTITEXCOORD3XOESPROC glad_glMultiTexCoord3xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3xOES(GLenum texture, GLfixed s, GLfixed t, GLfixed r) {
- _pre_call_gl_callback("glMultiTexCoord3xOES", (GLADapiproc) glad_glMultiTexCoord3xOES, 4, texture, s, t, r);
- glad_glMultiTexCoord3xOES(texture, s, t, r);
- _post_call_gl_callback(NULL, "glMultiTexCoord3xOES", (GLADapiproc) glad_glMultiTexCoord3xOES, 4, texture, s, t, r);
-
-}
-PFNGLMULTITEXCOORD3XOESPROC glad_debug_glMultiTexCoord3xOES = glad_debug_impl_glMultiTexCoord3xOES;
-PFNGLMULTITEXCOORD3XVOESPROC glad_glMultiTexCoord3xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord3xvOES(GLenum texture, const GLfixed * coords) {
- _pre_call_gl_callback("glMultiTexCoord3xvOES", (GLADapiproc) glad_glMultiTexCoord3xvOES, 2, texture, coords);
- glad_glMultiTexCoord3xvOES(texture, coords);
- _post_call_gl_callback(NULL, "glMultiTexCoord3xvOES", (GLADapiproc) glad_glMultiTexCoord3xvOES, 2, texture, coords);
+PFNGLMULTITEXCOORD4DPROC glad_glMultiTexCoord4d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q) {
+ _pre_call_gl_callback("glMultiTexCoord4d", (GLADapiproc) glad_glMultiTexCoord4d, 5, target, s, t, r, q);
+ glad_glMultiTexCoord4d(target, s, t, r, q);
+ _post_call_gl_callback(NULL, "glMultiTexCoord4d", (GLADapiproc) glad_glMultiTexCoord4d, 5, target, s, t, r, q);
}
-PFNGLMULTITEXCOORD3XVOESPROC glad_debug_glMultiTexCoord3xvOES = glad_debug_impl_glMultiTexCoord3xvOES;
+PFNGLMULTITEXCOORD4DPROC glad_debug_glMultiTexCoord4d = glad_debug_impl_glMultiTexCoord4d;
PFNGLMULTITEXCOORD4DARBPROC glad_glMultiTexCoord4dARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4dARB(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q) {
_pre_call_gl_callback("glMultiTexCoord4dARB", (GLADapiproc) glad_glMultiTexCoord4dARB, 5, target, s, t, r, q);
@@ -4583,6 +5513,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4dARB(GLenum target, GLd
}
PFNGLMULTITEXCOORD4DARBPROC glad_debug_glMultiTexCoord4dARB = glad_debug_impl_glMultiTexCoord4dARB;
+PFNGLMULTITEXCOORD4DVPROC glad_glMultiTexCoord4dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4dv(GLenum target, const GLdouble * v) {
+ _pre_call_gl_callback("glMultiTexCoord4dv", (GLADapiproc) glad_glMultiTexCoord4dv, 2, target, v);
+ glad_glMultiTexCoord4dv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord4dv", (GLADapiproc) glad_glMultiTexCoord4dv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD4DVPROC glad_debug_glMultiTexCoord4dv = glad_debug_impl_glMultiTexCoord4dv;
PFNGLMULTITEXCOORD4DVARBPROC glad_glMultiTexCoord4dvARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4dvARB(GLenum target, const GLdouble * v) {
_pre_call_gl_callback("glMultiTexCoord4dvARB", (GLADapiproc) glad_glMultiTexCoord4dvARB, 2, target, v);
@@ -4591,6 +5529,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4dvARB(GLenum target, co
}
PFNGLMULTITEXCOORD4DVARBPROC glad_debug_glMultiTexCoord4dvARB = glad_debug_impl_glMultiTexCoord4dvARB;
+PFNGLMULTITEXCOORD4FPROC glad_glMultiTexCoord4f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q) {
+ _pre_call_gl_callback("glMultiTexCoord4f", (GLADapiproc) glad_glMultiTexCoord4f, 5, target, s, t, r, q);
+ glad_glMultiTexCoord4f(target, s, t, r, q);
+ _post_call_gl_callback(NULL, "glMultiTexCoord4f", (GLADapiproc) glad_glMultiTexCoord4f, 5, target, s, t, r, q);
+
+}
+PFNGLMULTITEXCOORD4FPROC glad_debug_glMultiTexCoord4f = glad_debug_impl_glMultiTexCoord4f;
PFNGLMULTITEXCOORD4FARBPROC glad_glMultiTexCoord4fARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4fARB(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q) {
_pre_call_gl_callback("glMultiTexCoord4fARB", (GLADapiproc) glad_glMultiTexCoord4fARB, 5, target, s, t, r, q);
@@ -4599,6 +5545,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4fARB(GLenum target, GLf
}
PFNGLMULTITEXCOORD4FARBPROC glad_debug_glMultiTexCoord4fARB = glad_debug_impl_glMultiTexCoord4fARB;
+PFNGLMULTITEXCOORD4FVPROC glad_glMultiTexCoord4fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4fv(GLenum target, const GLfloat * v) {
+ _pre_call_gl_callback("glMultiTexCoord4fv", (GLADapiproc) glad_glMultiTexCoord4fv, 2, target, v);
+ glad_glMultiTexCoord4fv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord4fv", (GLADapiproc) glad_glMultiTexCoord4fv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD4FVPROC glad_debug_glMultiTexCoord4fv = glad_debug_impl_glMultiTexCoord4fv;
PFNGLMULTITEXCOORD4FVARBPROC glad_glMultiTexCoord4fvARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4fvARB(GLenum target, const GLfloat * v) {
_pre_call_gl_callback("glMultiTexCoord4fvARB", (GLADapiproc) glad_glMultiTexCoord4fvARB, 2, target, v);
@@ -4607,6 +5561,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4fvARB(GLenum target, co
}
PFNGLMULTITEXCOORD4FVARBPROC glad_debug_glMultiTexCoord4fvARB = glad_debug_impl_glMultiTexCoord4fvARB;
+PFNGLMULTITEXCOORD4IPROC glad_glMultiTexCoord4i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q) {
+ _pre_call_gl_callback("glMultiTexCoord4i", (GLADapiproc) glad_glMultiTexCoord4i, 5, target, s, t, r, q);
+ glad_glMultiTexCoord4i(target, s, t, r, q);
+ _post_call_gl_callback(NULL, "glMultiTexCoord4i", (GLADapiproc) glad_glMultiTexCoord4i, 5, target, s, t, r, q);
+
+}
+PFNGLMULTITEXCOORD4IPROC glad_debug_glMultiTexCoord4i = glad_debug_impl_glMultiTexCoord4i;
PFNGLMULTITEXCOORD4IARBPROC glad_glMultiTexCoord4iARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4iARB(GLenum target, GLint s, GLint t, GLint r, GLint q) {
_pre_call_gl_callback("glMultiTexCoord4iARB", (GLADapiproc) glad_glMultiTexCoord4iARB, 5, target, s, t, r, q);
@@ -4615,6 +5577,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4iARB(GLenum target, GLi
}
PFNGLMULTITEXCOORD4IARBPROC glad_debug_glMultiTexCoord4iARB = glad_debug_impl_glMultiTexCoord4iARB;
+PFNGLMULTITEXCOORD4IVPROC glad_glMultiTexCoord4iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4iv(GLenum target, const GLint * v) {
+ _pre_call_gl_callback("glMultiTexCoord4iv", (GLADapiproc) glad_glMultiTexCoord4iv, 2, target, v);
+ glad_glMultiTexCoord4iv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord4iv", (GLADapiproc) glad_glMultiTexCoord4iv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD4IVPROC glad_debug_glMultiTexCoord4iv = glad_debug_impl_glMultiTexCoord4iv;
PFNGLMULTITEXCOORD4IVARBPROC glad_glMultiTexCoord4ivARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4ivARB(GLenum target, const GLint * v) {
_pre_call_gl_callback("glMultiTexCoord4ivARB", (GLADapiproc) glad_glMultiTexCoord4ivARB, 2, target, v);
@@ -4623,6 +5593,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4ivARB(GLenum target, co
}
PFNGLMULTITEXCOORD4IVARBPROC glad_debug_glMultiTexCoord4ivARB = glad_debug_impl_glMultiTexCoord4ivARB;
+PFNGLMULTITEXCOORD4SPROC glad_glMultiTexCoord4s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q) {
+ _pre_call_gl_callback("glMultiTexCoord4s", (GLADapiproc) glad_glMultiTexCoord4s, 5, target, s, t, r, q);
+ glad_glMultiTexCoord4s(target, s, t, r, q);
+ _post_call_gl_callback(NULL, "glMultiTexCoord4s", (GLADapiproc) glad_glMultiTexCoord4s, 5, target, s, t, r, q);
+
+}
+PFNGLMULTITEXCOORD4SPROC glad_debug_glMultiTexCoord4s = glad_debug_impl_glMultiTexCoord4s;
PFNGLMULTITEXCOORD4SARBPROC glad_glMultiTexCoord4sARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4sARB(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q) {
_pre_call_gl_callback("glMultiTexCoord4sARB", (GLADapiproc) glad_glMultiTexCoord4sARB, 5, target, s, t, r, q);
@@ -4631,6 +5609,14 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4sARB(GLenum target, GLs
}
PFNGLMULTITEXCOORD4SARBPROC glad_debug_glMultiTexCoord4sARB = glad_debug_impl_glMultiTexCoord4sARB;
+PFNGLMULTITEXCOORD4SVPROC glad_glMultiTexCoord4sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4sv(GLenum target, const GLshort * v) {
+ _pre_call_gl_callback("glMultiTexCoord4sv", (GLADapiproc) glad_glMultiTexCoord4sv, 2, target, v);
+ glad_glMultiTexCoord4sv(target, v);
+ _post_call_gl_callback(NULL, "glMultiTexCoord4sv", (GLADapiproc) glad_glMultiTexCoord4sv, 2, target, v);
+
+}
+PFNGLMULTITEXCOORD4SVPROC glad_debug_glMultiTexCoord4sv = glad_debug_impl_glMultiTexCoord4sv;
PFNGLMULTITEXCOORD4SVARBPROC glad_glMultiTexCoord4svARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4svARB(GLenum target, const GLshort * v) {
_pre_call_gl_callback("glMultiTexCoord4svARB", (GLADapiproc) glad_glMultiTexCoord4svARB, 2, target, v);
@@ -4639,22 +5625,70 @@ static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4svARB(GLenum target, co
}
PFNGLMULTITEXCOORD4SVARBPROC glad_debug_glMultiTexCoord4svARB = glad_debug_impl_glMultiTexCoord4svARB;
-PFNGLMULTITEXCOORD4XOESPROC glad_glMultiTexCoord4xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4xOES(GLenum texture, GLfixed s, GLfixed t, GLfixed r, GLfixed q) {
- _pre_call_gl_callback("glMultiTexCoord4xOES", (GLADapiproc) glad_glMultiTexCoord4xOES, 5, texture, s, t, r, q);
- glad_glMultiTexCoord4xOES(texture, s, t, r, q);
- _post_call_gl_callback(NULL, "glMultiTexCoord4xOES", (GLADapiproc) glad_glMultiTexCoord4xOES, 5, texture, s, t, r, q);
+PFNGLMULTITEXCOORDP1UIPROC glad_glMultiTexCoordP1ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords) {
+ _pre_call_gl_callback("glMultiTexCoordP1ui", (GLADapiproc) glad_glMultiTexCoordP1ui, 3, texture, type, coords);
+ glad_glMultiTexCoordP1ui(texture, type, coords);
+ _post_call_gl_callback(NULL, "glMultiTexCoordP1ui", (GLADapiproc) glad_glMultiTexCoordP1ui, 3, texture, type, coords);
+
+}
+PFNGLMULTITEXCOORDP1UIPROC glad_debug_glMultiTexCoordP1ui = glad_debug_impl_glMultiTexCoordP1ui;
+PFNGLMULTITEXCOORDP1UIVPROC glad_glMultiTexCoordP1uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint * coords) {
+ _pre_call_gl_callback("glMultiTexCoordP1uiv", (GLADapiproc) glad_glMultiTexCoordP1uiv, 3, texture, type, coords);
+ glad_glMultiTexCoordP1uiv(texture, type, coords);
+ _post_call_gl_callback(NULL, "glMultiTexCoordP1uiv", (GLADapiproc) glad_glMultiTexCoordP1uiv, 3, texture, type, coords);
+
+}
+PFNGLMULTITEXCOORDP1UIVPROC glad_debug_glMultiTexCoordP1uiv = glad_debug_impl_glMultiTexCoordP1uiv;
+PFNGLMULTITEXCOORDP2UIPROC glad_glMultiTexCoordP2ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords) {
+ _pre_call_gl_callback("glMultiTexCoordP2ui", (GLADapiproc) glad_glMultiTexCoordP2ui, 3, texture, type, coords);
+ glad_glMultiTexCoordP2ui(texture, type, coords);
+ _post_call_gl_callback(NULL, "glMultiTexCoordP2ui", (GLADapiproc) glad_glMultiTexCoordP2ui, 3, texture, type, coords);
+
+}
+PFNGLMULTITEXCOORDP2UIPROC glad_debug_glMultiTexCoordP2ui = glad_debug_impl_glMultiTexCoordP2ui;
+PFNGLMULTITEXCOORDP2UIVPROC glad_glMultiTexCoordP2uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint * coords) {
+ _pre_call_gl_callback("glMultiTexCoordP2uiv", (GLADapiproc) glad_glMultiTexCoordP2uiv, 3, texture, type, coords);
+ glad_glMultiTexCoordP2uiv(texture, type, coords);
+ _post_call_gl_callback(NULL, "glMultiTexCoordP2uiv", (GLADapiproc) glad_glMultiTexCoordP2uiv, 3, texture, type, coords);
+
+}
+PFNGLMULTITEXCOORDP2UIVPROC glad_debug_glMultiTexCoordP2uiv = glad_debug_impl_glMultiTexCoordP2uiv;
+PFNGLMULTITEXCOORDP3UIPROC glad_glMultiTexCoordP3ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords) {
+ _pre_call_gl_callback("glMultiTexCoordP3ui", (GLADapiproc) glad_glMultiTexCoordP3ui, 3, texture, type, coords);
+ glad_glMultiTexCoordP3ui(texture, type, coords);
+ _post_call_gl_callback(NULL, "glMultiTexCoordP3ui", (GLADapiproc) glad_glMultiTexCoordP3ui, 3, texture, type, coords);
}
-PFNGLMULTITEXCOORD4XOESPROC glad_debug_glMultiTexCoord4xOES = glad_debug_impl_glMultiTexCoord4xOES;
-PFNGLMULTITEXCOORD4XVOESPROC glad_glMultiTexCoord4xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glMultiTexCoord4xvOES(GLenum texture, const GLfixed * coords) {
- _pre_call_gl_callback("glMultiTexCoord4xvOES", (GLADapiproc) glad_glMultiTexCoord4xvOES, 2, texture, coords);
- glad_glMultiTexCoord4xvOES(texture, coords);
- _post_call_gl_callback(NULL, "glMultiTexCoord4xvOES", (GLADapiproc) glad_glMultiTexCoord4xvOES, 2, texture, coords);
+PFNGLMULTITEXCOORDP3UIPROC glad_debug_glMultiTexCoordP3ui = glad_debug_impl_glMultiTexCoordP3ui;
+PFNGLMULTITEXCOORDP3UIVPROC glad_glMultiTexCoordP3uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint * coords) {
+ _pre_call_gl_callback("glMultiTexCoordP3uiv", (GLADapiproc) glad_glMultiTexCoordP3uiv, 3, texture, type, coords);
+ glad_glMultiTexCoordP3uiv(texture, type, coords);
+ _post_call_gl_callback(NULL, "glMultiTexCoordP3uiv", (GLADapiproc) glad_glMultiTexCoordP3uiv, 3, texture, type, coords);
}
-PFNGLMULTITEXCOORD4XVOESPROC glad_debug_glMultiTexCoord4xvOES = glad_debug_impl_glMultiTexCoord4xvOES;
+PFNGLMULTITEXCOORDP3UIVPROC glad_debug_glMultiTexCoordP3uiv = glad_debug_impl_glMultiTexCoordP3uiv;
+PFNGLMULTITEXCOORDP4UIPROC glad_glMultiTexCoordP4ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords) {
+ _pre_call_gl_callback("glMultiTexCoordP4ui", (GLADapiproc) glad_glMultiTexCoordP4ui, 3, texture, type, coords);
+ glad_glMultiTexCoordP4ui(texture, type, coords);
+ _post_call_gl_callback(NULL, "glMultiTexCoordP4ui", (GLADapiproc) glad_glMultiTexCoordP4ui, 3, texture, type, coords);
+
+}
+PFNGLMULTITEXCOORDP4UIPROC glad_debug_glMultiTexCoordP4ui = glad_debug_impl_glMultiTexCoordP4ui;
+PFNGLMULTITEXCOORDP4UIVPROC glad_glMultiTexCoordP4uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint * coords) {
+ _pre_call_gl_callback("glMultiTexCoordP4uiv", (GLADapiproc) glad_glMultiTexCoordP4uiv, 3, texture, type, coords);
+ glad_glMultiTexCoordP4uiv(texture, type, coords);
+ _post_call_gl_callback(NULL, "glMultiTexCoordP4uiv", (GLADapiproc) glad_glMultiTexCoordP4uiv, 3, texture, type, coords);
+
+}
+PFNGLMULTITEXCOORDP4UIVPROC glad_debug_glMultiTexCoordP4uiv = glad_debug_impl_glMultiTexCoordP4uiv;
PFNGLNAMEDBUFFERDATAPROC glad_glNamedBufferData = NULL;
static void GLAD_API_PTR glad_debug_impl_glNamedBufferData(GLuint buffer, GLsizeiptr size, const void * data, GLenum usage) {
_pre_call_gl_callback("glNamedBufferData", (GLADapiproc) glad_glNamedBufferData, 4, buffer, size, data, usage);
@@ -4767,22 +5801,118 @@ static void GLAD_API_PTR glad_debug_impl_glNamedStringARB(GLenum type, GLint nam
}
PFNGLNAMEDSTRINGARBPROC glad_debug_glNamedStringARB = glad_debug_impl_glNamedStringARB;
-PFNGLNORMAL3XOESPROC glad_glNormal3xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glNormal3xOES(GLfixed nx, GLfixed ny, GLfixed nz) {
- _pre_call_gl_callback("glNormal3xOES", (GLADapiproc) glad_glNormal3xOES, 3, nx, ny, nz);
- glad_glNormal3xOES(nx, ny, nz);
- _post_call_gl_callback(NULL, "glNormal3xOES", (GLADapiproc) glad_glNormal3xOES, 3, nx, ny, nz);
+PFNGLNEWLISTPROC glad_glNewList = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNewList(GLuint list, GLenum mode) {
+ _pre_call_gl_callback("glNewList", (GLADapiproc) glad_glNewList, 2, list, mode);
+ glad_glNewList(list, mode);
+ _post_call_gl_callback(NULL, "glNewList", (GLADapiproc) glad_glNewList, 2, list, mode);
+
+}
+PFNGLNEWLISTPROC glad_debug_glNewList = glad_debug_impl_glNewList;
+PFNGLNORMAL3BPROC glad_glNormal3b = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz) {
+ _pre_call_gl_callback("glNormal3b", (GLADapiproc) glad_glNormal3b, 3, nx, ny, nz);
+ glad_glNormal3b(nx, ny, nz);
+ _post_call_gl_callback(NULL, "glNormal3b", (GLADapiproc) glad_glNormal3b, 3, nx, ny, nz);
}
-PFNGLNORMAL3XOESPROC glad_debug_glNormal3xOES = glad_debug_impl_glNormal3xOES;
-PFNGLNORMAL3XVOESPROC glad_glNormal3xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glNormal3xvOES(const GLfixed * coords) {
- _pre_call_gl_callback("glNormal3xvOES", (GLADapiproc) glad_glNormal3xvOES, 1, coords);
- glad_glNormal3xvOES(coords);
- _post_call_gl_callback(NULL, "glNormal3xvOES", (GLADapiproc) glad_glNormal3xvOES, 1, coords);
+PFNGLNORMAL3BPROC glad_debug_glNormal3b = glad_debug_impl_glNormal3b;
+PFNGLNORMAL3BVPROC glad_glNormal3bv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNormal3bv(const GLbyte * v) {
+ _pre_call_gl_callback("glNormal3bv", (GLADapiproc) glad_glNormal3bv, 1, v);
+ glad_glNormal3bv(v);
+ _post_call_gl_callback(NULL, "glNormal3bv", (GLADapiproc) glad_glNormal3bv, 1, v);
}
-PFNGLNORMAL3XVOESPROC glad_debug_glNormal3xvOES = glad_debug_impl_glNormal3xvOES;
+PFNGLNORMAL3BVPROC glad_debug_glNormal3bv = glad_debug_impl_glNormal3bv;
+PFNGLNORMAL3DPROC glad_glNormal3d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz) {
+ _pre_call_gl_callback("glNormal3d", (GLADapiproc) glad_glNormal3d, 3, nx, ny, nz);
+ glad_glNormal3d(nx, ny, nz);
+ _post_call_gl_callback(NULL, "glNormal3d", (GLADapiproc) glad_glNormal3d, 3, nx, ny, nz);
+
+}
+PFNGLNORMAL3DPROC glad_debug_glNormal3d = glad_debug_impl_glNormal3d;
+PFNGLNORMAL3DVPROC glad_glNormal3dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNormal3dv(const GLdouble * v) {
+ _pre_call_gl_callback("glNormal3dv", (GLADapiproc) glad_glNormal3dv, 1, v);
+ glad_glNormal3dv(v);
+ _post_call_gl_callback(NULL, "glNormal3dv", (GLADapiproc) glad_glNormal3dv, 1, v);
+
+}
+PFNGLNORMAL3DVPROC glad_debug_glNormal3dv = glad_debug_impl_glNormal3dv;
+PFNGLNORMAL3FPROC glad_glNormal3f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz) {
+ _pre_call_gl_callback("glNormal3f", (GLADapiproc) glad_glNormal3f, 3, nx, ny, nz);
+ glad_glNormal3f(nx, ny, nz);
+ _post_call_gl_callback(NULL, "glNormal3f", (GLADapiproc) glad_glNormal3f, 3, nx, ny, nz);
+
+}
+PFNGLNORMAL3FPROC glad_debug_glNormal3f = glad_debug_impl_glNormal3f;
+PFNGLNORMAL3FVPROC glad_glNormal3fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNormal3fv(const GLfloat * v) {
+ _pre_call_gl_callback("glNormal3fv", (GLADapiproc) glad_glNormal3fv, 1, v);
+ glad_glNormal3fv(v);
+ _post_call_gl_callback(NULL, "glNormal3fv", (GLADapiproc) glad_glNormal3fv, 1, v);
+
+}
+PFNGLNORMAL3FVPROC glad_debug_glNormal3fv = glad_debug_impl_glNormal3fv;
+PFNGLNORMAL3IPROC glad_glNormal3i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNormal3i(GLint nx, GLint ny, GLint nz) {
+ _pre_call_gl_callback("glNormal3i", (GLADapiproc) glad_glNormal3i, 3, nx, ny, nz);
+ glad_glNormal3i(nx, ny, nz);
+ _post_call_gl_callback(NULL, "glNormal3i", (GLADapiproc) glad_glNormal3i, 3, nx, ny, nz);
+
+}
+PFNGLNORMAL3IPROC glad_debug_glNormal3i = glad_debug_impl_glNormal3i;
+PFNGLNORMAL3IVPROC glad_glNormal3iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNormal3iv(const GLint * v) {
+ _pre_call_gl_callback("glNormal3iv", (GLADapiproc) glad_glNormal3iv, 1, v);
+ glad_glNormal3iv(v);
+ _post_call_gl_callback(NULL, "glNormal3iv", (GLADapiproc) glad_glNormal3iv, 1, v);
+
+}
+PFNGLNORMAL3IVPROC glad_debug_glNormal3iv = glad_debug_impl_glNormal3iv;
+PFNGLNORMAL3SPROC glad_glNormal3s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNormal3s(GLshort nx, GLshort ny, GLshort nz) {
+ _pre_call_gl_callback("glNormal3s", (GLADapiproc) glad_glNormal3s, 3, nx, ny, nz);
+ glad_glNormal3s(nx, ny, nz);
+ _post_call_gl_callback(NULL, "glNormal3s", (GLADapiproc) glad_glNormal3s, 3, nx, ny, nz);
+
+}
+PFNGLNORMAL3SPROC glad_debug_glNormal3s = glad_debug_impl_glNormal3s;
+PFNGLNORMAL3SVPROC glad_glNormal3sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNormal3sv(const GLshort * v) {
+ _pre_call_gl_callback("glNormal3sv", (GLADapiproc) glad_glNormal3sv, 1, v);
+ glad_glNormal3sv(v);
+ _post_call_gl_callback(NULL, "glNormal3sv", (GLADapiproc) glad_glNormal3sv, 1, v);
+
+}
+PFNGLNORMAL3SVPROC glad_debug_glNormal3sv = glad_debug_impl_glNormal3sv;
+PFNGLNORMALP3UIPROC glad_glNormalP3ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNormalP3ui(GLenum type, GLuint coords) {
+ _pre_call_gl_callback("glNormalP3ui", (GLADapiproc) glad_glNormalP3ui, 2, type, coords);
+ glad_glNormalP3ui(type, coords);
+ _post_call_gl_callback(NULL, "glNormalP3ui", (GLADapiproc) glad_glNormalP3ui, 2, type, coords);
+
+}
+PFNGLNORMALP3UIPROC glad_debug_glNormalP3ui = glad_debug_impl_glNormalP3ui;
+PFNGLNORMALP3UIVPROC glad_glNormalP3uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNormalP3uiv(GLenum type, const GLuint * coords) {
+ _pre_call_gl_callback("glNormalP3uiv", (GLADapiproc) glad_glNormalP3uiv, 2, type, coords);
+ glad_glNormalP3uiv(type, coords);
+ _post_call_gl_callback(NULL, "glNormalP3uiv", (GLADapiproc) glad_glNormalP3uiv, 2, type, coords);
+
+}
+PFNGLNORMALP3UIVPROC glad_debug_glNormalP3uiv = glad_debug_impl_glNormalP3uiv;
+PFNGLNORMALPOINTERPROC glad_glNormalPointer = NULL;
+static void GLAD_API_PTR glad_debug_impl_glNormalPointer(GLenum type, GLsizei stride, const void * pointer) {
+ _pre_call_gl_callback("glNormalPointer", (GLADapiproc) glad_glNormalPointer, 3, type, stride, pointer);
+ glad_glNormalPointer(type, stride, pointer);
+ _post_call_gl_callback(NULL, "glNormalPointer", (GLADapiproc) glad_glNormalPointer, 3, type, stride, pointer);
+
+}
+PFNGLNORMALPOINTERPROC glad_debug_glNormalPointer = glad_debug_impl_glNormalPointer;
PFNGLOBJECTLABELPROC glad_glObjectLabel = NULL;
static void GLAD_API_PTR glad_debug_impl_glObjectLabel(GLenum identifier, GLuint name, GLsizei length, const GLchar * label) {
_pre_call_gl_callback("glObjectLabel", (GLADapiproc) glad_glObjectLabel, 4, identifier, name, length, label);
@@ -4799,22 +5929,22 @@ static void GLAD_API_PTR glad_debug_impl_glObjectPtrLabel(const void * ptr, GLsi
}
PFNGLOBJECTPTRLABELPROC glad_debug_glObjectPtrLabel = glad_debug_impl_glObjectPtrLabel;
-PFNGLORTHOXOESPROC glad_glOrthoxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glOrthoxOES(GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f) {
- _pre_call_gl_callback("glOrthoxOES", (GLADapiproc) glad_glOrthoxOES, 6, l, r, b, t, n, f);
- glad_glOrthoxOES(l, r, b, t, n, f);
- _post_call_gl_callback(NULL, "glOrthoxOES", (GLADapiproc) glad_glOrthoxOES, 6, l, r, b, t, n, f);
+PFNGLORTHOPROC glad_glOrtho = NULL;
+static void GLAD_API_PTR glad_debug_impl_glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar) {
+ _pre_call_gl_callback("glOrtho", (GLADapiproc) glad_glOrtho, 6, left, right, bottom, top, zNear, zFar);
+ glad_glOrtho(left, right, bottom, top, zNear, zFar);
+ _post_call_gl_callback(NULL, "glOrtho", (GLADapiproc) glad_glOrtho, 6, left, right, bottom, top, zNear, zFar);
}
-PFNGLORTHOXOESPROC glad_debug_glOrthoxOES = glad_debug_impl_glOrthoxOES;
-PFNGLPASSTHROUGHXOESPROC glad_glPassThroughxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glPassThroughxOES(GLfixed token) {
- _pre_call_gl_callback("glPassThroughxOES", (GLADapiproc) glad_glPassThroughxOES, 1, token);
- glad_glPassThroughxOES(token);
- _post_call_gl_callback(NULL, "glPassThroughxOES", (GLADapiproc) glad_glPassThroughxOES, 1, token);
+PFNGLORTHOPROC glad_debug_glOrtho = glad_debug_impl_glOrtho;
+PFNGLPASSTHROUGHPROC glad_glPassThrough = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPassThrough(GLfloat token) {
+ _pre_call_gl_callback("glPassThrough", (GLADapiproc) glad_glPassThrough, 1, token);
+ glad_glPassThrough(token);
+ _post_call_gl_callback(NULL, "glPassThrough", (GLADapiproc) glad_glPassThrough, 1, token);
}
-PFNGLPASSTHROUGHXOESPROC glad_debug_glPassThroughxOES = glad_debug_impl_glPassThroughxOES;
+PFNGLPASSTHROUGHPROC glad_debug_glPassThrough = glad_debug_impl_glPassThrough;
PFNGLPATCHPARAMETERFVPROC glad_glPatchParameterfv = NULL;
static void GLAD_API_PTR glad_debug_impl_glPatchParameterfv(GLenum pname, const GLfloat * values) {
_pre_call_gl_callback("glPatchParameterfv", (GLADapiproc) glad_glPatchParameterfv, 2, pname, values);
@@ -4839,14 +5969,30 @@ static void GLAD_API_PTR glad_debug_impl_glPauseTransformFeedback(void) {
}
PFNGLPAUSETRANSFORMFEEDBACKPROC glad_debug_glPauseTransformFeedback = glad_debug_impl_glPauseTransformFeedback;
-PFNGLPIXELMAPXPROC glad_glPixelMapx = NULL;
-static void GLAD_API_PTR glad_debug_impl_glPixelMapx(GLenum map, GLint size, const GLfixed * values) {
- _pre_call_gl_callback("glPixelMapx", (GLADapiproc) glad_glPixelMapx, 3, map, size, values);
- glad_glPixelMapx(map, size, values);
- _post_call_gl_callback(NULL, "glPixelMapx", (GLADapiproc) glad_glPixelMapx, 3, map, size, values);
+PFNGLPIXELMAPFVPROC glad_glPixelMapfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPixelMapfv(GLenum map, GLsizei mapsize, const GLfloat * values) {
+ _pre_call_gl_callback("glPixelMapfv", (GLADapiproc) glad_glPixelMapfv, 3, map, mapsize, values);
+ glad_glPixelMapfv(map, mapsize, values);
+ _post_call_gl_callback(NULL, "glPixelMapfv", (GLADapiproc) glad_glPixelMapfv, 3, map, mapsize, values);
}
-PFNGLPIXELMAPXPROC glad_debug_glPixelMapx = glad_debug_impl_glPixelMapx;
+PFNGLPIXELMAPFVPROC glad_debug_glPixelMapfv = glad_debug_impl_glPixelMapfv;
+PFNGLPIXELMAPUIVPROC glad_glPixelMapuiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPixelMapuiv(GLenum map, GLsizei mapsize, const GLuint * values) {
+ _pre_call_gl_callback("glPixelMapuiv", (GLADapiproc) glad_glPixelMapuiv, 3, map, mapsize, values);
+ glad_glPixelMapuiv(map, mapsize, values);
+ _post_call_gl_callback(NULL, "glPixelMapuiv", (GLADapiproc) glad_glPixelMapuiv, 3, map, mapsize, values);
+
+}
+PFNGLPIXELMAPUIVPROC glad_debug_glPixelMapuiv = glad_debug_impl_glPixelMapuiv;
+PFNGLPIXELMAPUSVPROC glad_glPixelMapusv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPixelMapusv(GLenum map, GLsizei mapsize, const GLushort * values) {
+ _pre_call_gl_callback("glPixelMapusv", (GLADapiproc) glad_glPixelMapusv, 3, map, mapsize, values);
+ glad_glPixelMapusv(map, mapsize, values);
+ _post_call_gl_callback(NULL, "glPixelMapusv", (GLADapiproc) glad_glPixelMapusv, 3, map, mapsize, values);
+
+}
+PFNGLPIXELMAPUSVPROC glad_debug_glPixelMapusv = glad_debug_impl_glPixelMapusv;
PFNGLPIXELSTOREFPROC glad_glPixelStoref = NULL;
static void GLAD_API_PTR glad_debug_impl_glPixelStoref(GLenum pname, GLfloat param) {
_pre_call_gl_callback("glPixelStoref", (GLADapiproc) glad_glPixelStoref, 2, pname, param);
@@ -4863,30 +6009,30 @@ static void GLAD_API_PTR glad_debug_impl_glPixelStorei(GLenum pname, GLint param
}
PFNGLPIXELSTOREIPROC glad_debug_glPixelStorei = glad_debug_impl_glPixelStorei;
-PFNGLPIXELSTOREXPROC glad_glPixelStorex = NULL;
-static void GLAD_API_PTR glad_debug_impl_glPixelStorex(GLenum pname, GLfixed param) {
- _pre_call_gl_callback("glPixelStorex", (GLADapiproc) glad_glPixelStorex, 2, pname, param);
- glad_glPixelStorex(pname, param);
- _post_call_gl_callback(NULL, "glPixelStorex", (GLADapiproc) glad_glPixelStorex, 2, pname, param);
+PFNGLPIXELTRANSFERFPROC glad_glPixelTransferf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPixelTransferf(GLenum pname, GLfloat param) {
+ _pre_call_gl_callback("glPixelTransferf", (GLADapiproc) glad_glPixelTransferf, 2, pname, param);
+ glad_glPixelTransferf(pname, param);
+ _post_call_gl_callback(NULL, "glPixelTransferf", (GLADapiproc) glad_glPixelTransferf, 2, pname, param);
}
-PFNGLPIXELSTOREXPROC glad_debug_glPixelStorex = glad_debug_impl_glPixelStorex;
-PFNGLPIXELTRANSFERXOESPROC glad_glPixelTransferxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glPixelTransferxOES(GLenum pname, GLfixed param) {
- _pre_call_gl_callback("glPixelTransferxOES", (GLADapiproc) glad_glPixelTransferxOES, 2, pname, param);
- glad_glPixelTransferxOES(pname, param);
- _post_call_gl_callback(NULL, "glPixelTransferxOES", (GLADapiproc) glad_glPixelTransferxOES, 2, pname, param);
+PFNGLPIXELTRANSFERFPROC glad_debug_glPixelTransferf = glad_debug_impl_glPixelTransferf;
+PFNGLPIXELTRANSFERIPROC glad_glPixelTransferi = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPixelTransferi(GLenum pname, GLint param) {
+ _pre_call_gl_callback("glPixelTransferi", (GLADapiproc) glad_glPixelTransferi, 2, pname, param);
+ glad_glPixelTransferi(pname, param);
+ _post_call_gl_callback(NULL, "glPixelTransferi", (GLADapiproc) glad_glPixelTransferi, 2, pname, param);
}
-PFNGLPIXELTRANSFERXOESPROC glad_debug_glPixelTransferxOES = glad_debug_impl_glPixelTransferxOES;
-PFNGLPIXELZOOMXOESPROC glad_glPixelZoomxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glPixelZoomxOES(GLfixed xfactor, GLfixed yfactor) {
- _pre_call_gl_callback("glPixelZoomxOES", (GLADapiproc) glad_glPixelZoomxOES, 2, xfactor, yfactor);
- glad_glPixelZoomxOES(xfactor, yfactor);
- _post_call_gl_callback(NULL, "glPixelZoomxOES", (GLADapiproc) glad_glPixelZoomxOES, 2, xfactor, yfactor);
+PFNGLPIXELTRANSFERIPROC glad_debug_glPixelTransferi = glad_debug_impl_glPixelTransferi;
+PFNGLPIXELZOOMPROC glad_glPixelZoom = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPixelZoom(GLfloat xfactor, GLfloat yfactor) {
+ _pre_call_gl_callback("glPixelZoom", (GLADapiproc) glad_glPixelZoom, 2, xfactor, yfactor);
+ glad_glPixelZoom(xfactor, yfactor);
+ _post_call_gl_callback(NULL, "glPixelZoom", (GLADapiproc) glad_glPixelZoom, 2, xfactor, yfactor);
}
-PFNGLPIXELZOOMXOESPROC glad_debug_glPixelZoomxOES = glad_debug_impl_glPixelZoomxOES;
+PFNGLPIXELZOOMPROC glad_debug_glPixelZoom = glad_debug_impl_glPixelZoom;
PFNGLPOINTPARAMETERFPROC glad_glPointParameterf = NULL;
static void GLAD_API_PTR glad_debug_impl_glPointParameterf(GLenum pname, GLfloat param) {
_pre_call_gl_callback("glPointParameterf", (GLADapiproc) glad_glPointParameterf, 2, pname, param);
@@ -4919,14 +6065,6 @@ static void GLAD_API_PTR glad_debug_impl_glPointParameteriv(GLenum pname, const
}
PFNGLPOINTPARAMETERIVPROC glad_debug_glPointParameteriv = glad_debug_impl_glPointParameteriv;
-PFNGLPOINTPARAMETERXVOESPROC glad_glPointParameterxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glPointParameterxvOES(GLenum pname, const GLfixed * params) {
- _pre_call_gl_callback("glPointParameterxvOES", (GLADapiproc) glad_glPointParameterxvOES, 2, pname, params);
- glad_glPointParameterxvOES(pname, params);
- _post_call_gl_callback(NULL, "glPointParameterxvOES", (GLADapiproc) glad_glPointParameterxvOES, 2, pname, params);
-
-}
-PFNGLPOINTPARAMETERXVOESPROC glad_debug_glPointParameterxvOES = glad_debug_impl_glPointParameterxvOES;
PFNGLPOINTSIZEPROC glad_glPointSize = NULL;
static void GLAD_API_PTR glad_debug_impl_glPointSize(GLfloat size) {
_pre_call_gl_callback("glPointSize", (GLADapiproc) glad_glPointSize, 1, size);
@@ -4935,14 +6073,6 @@ static void GLAD_API_PTR glad_debug_impl_glPointSize(GLfloat size) {
}
PFNGLPOINTSIZEPROC glad_debug_glPointSize = glad_debug_impl_glPointSize;
-PFNGLPOINTSIZEXOESPROC glad_glPointSizexOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glPointSizexOES(GLfixed size) {
- _pre_call_gl_callback("glPointSizexOES", (GLADapiproc) glad_glPointSizexOES, 1, size);
- glad_glPointSizexOES(size);
- _post_call_gl_callback(NULL, "glPointSizexOES", (GLADapiproc) glad_glPointSizexOES, 1, size);
-
-}
-PFNGLPOINTSIZEXOESPROC glad_debug_glPointSizexOES = glad_debug_impl_glPointSizexOES;
PFNGLPOLYGONMODEPROC glad_glPolygonMode = NULL;
static void GLAD_API_PTR glad_debug_impl_glPolygonMode(GLenum face, GLenum mode) {
_pre_call_gl_callback("glPolygonMode", (GLADapiproc) glad_glPolygonMode, 2, face, mode);
@@ -4959,14 +6089,30 @@ static void GLAD_API_PTR glad_debug_impl_glPolygonOffset(GLfloat factor, GLfloat
}
PFNGLPOLYGONOFFSETPROC glad_debug_glPolygonOffset = glad_debug_impl_glPolygonOffset;
-PFNGLPOLYGONOFFSETXOESPROC glad_glPolygonOffsetxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glPolygonOffsetxOES(GLfixed factor, GLfixed units) {
- _pre_call_gl_callback("glPolygonOffsetxOES", (GLADapiproc) glad_glPolygonOffsetxOES, 2, factor, units);
- glad_glPolygonOffsetxOES(factor, units);
- _post_call_gl_callback(NULL, "glPolygonOffsetxOES", (GLADapiproc) glad_glPolygonOffsetxOES, 2, factor, units);
+PFNGLPOLYGONSTIPPLEPROC glad_glPolygonStipple = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPolygonStipple(const GLubyte * mask) {
+ _pre_call_gl_callback("glPolygonStipple", (GLADapiproc) glad_glPolygonStipple, 1, mask);
+ glad_glPolygonStipple(mask);
+ _post_call_gl_callback(NULL, "glPolygonStipple", (GLADapiproc) glad_glPolygonStipple, 1, mask);
+
+}
+PFNGLPOLYGONSTIPPLEPROC glad_debug_glPolygonStipple = glad_debug_impl_glPolygonStipple;
+PFNGLPOPATTRIBPROC glad_glPopAttrib = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPopAttrib(void) {
+ _pre_call_gl_callback("glPopAttrib", (GLADapiproc) glad_glPopAttrib, 0);
+ glad_glPopAttrib();
+ _post_call_gl_callback(NULL, "glPopAttrib", (GLADapiproc) glad_glPopAttrib, 0);
}
-PFNGLPOLYGONOFFSETXOESPROC glad_debug_glPolygonOffsetxOES = glad_debug_impl_glPolygonOffsetxOES;
+PFNGLPOPATTRIBPROC glad_debug_glPopAttrib = glad_debug_impl_glPopAttrib;
+PFNGLPOPCLIENTATTRIBPROC glad_glPopClientAttrib = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPopClientAttrib(void) {
+ _pre_call_gl_callback("glPopClientAttrib", (GLADapiproc) glad_glPopClientAttrib, 0);
+ glad_glPopClientAttrib();
+ _post_call_gl_callback(NULL, "glPopClientAttrib", (GLADapiproc) glad_glPopClientAttrib, 0);
+
+}
+PFNGLPOPCLIENTATTRIBPROC glad_debug_glPopClientAttrib = glad_debug_impl_glPopClientAttrib;
PFNGLPOPDEBUGGROUPPROC glad_glPopDebugGroup = NULL;
static void GLAD_API_PTR glad_debug_impl_glPopDebugGroup(void) {
_pre_call_gl_callback("glPopDebugGroup", (GLADapiproc) glad_glPopDebugGroup, 0);
@@ -4975,6 +6121,22 @@ static void GLAD_API_PTR glad_debug_impl_glPopDebugGroup(void) {
}
PFNGLPOPDEBUGGROUPPROC glad_debug_glPopDebugGroup = glad_debug_impl_glPopDebugGroup;
+PFNGLPOPMATRIXPROC glad_glPopMatrix = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPopMatrix(void) {
+ _pre_call_gl_callback("glPopMatrix", (GLADapiproc) glad_glPopMatrix, 0);
+ glad_glPopMatrix();
+ _post_call_gl_callback(NULL, "glPopMatrix", (GLADapiproc) glad_glPopMatrix, 0);
+
+}
+PFNGLPOPMATRIXPROC glad_debug_glPopMatrix = glad_debug_impl_glPopMatrix;
+PFNGLPOPNAMEPROC glad_glPopName = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPopName(void) {
+ _pre_call_gl_callback("glPopName", (GLADapiproc) glad_glPopName, 0);
+ glad_glPopName();
+ _post_call_gl_callback(NULL, "glPopName", (GLADapiproc) glad_glPopName, 0);
+
+}
+PFNGLPOPNAMEPROC glad_debug_glPopName = glad_debug_impl_glPopName;
PFNGLPRIMITIVEBOUNDINGBOXARBPROC glad_glPrimitiveBoundingBoxARB = NULL;
static void GLAD_API_PTR glad_debug_impl_glPrimitiveBoundingBoxARB(GLfloat minX, GLfloat minY, GLfloat minZ, GLfloat minW, GLfloat maxX, GLfloat maxY, GLfloat maxZ, GLfloat maxW) {
_pre_call_gl_callback("glPrimitiveBoundingBoxARB", (GLADapiproc) glad_glPrimitiveBoundingBoxARB, 8, minX, minY, minZ, minW, maxX, maxY, maxZ, maxW);
@@ -4991,14 +6153,14 @@ static void GLAD_API_PTR glad_debug_impl_glPrimitiveRestartIndex(GLuint index) {
}
PFNGLPRIMITIVERESTARTINDEXPROC glad_debug_glPrimitiveRestartIndex = glad_debug_impl_glPrimitiveRestartIndex;
-PFNGLPRIORITIZETEXTURESXOESPROC glad_glPrioritizeTexturesxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glPrioritizeTexturesxOES(GLsizei n, const GLuint * textures, const GLfixed * priorities) {
- _pre_call_gl_callback("glPrioritizeTexturesxOES", (GLADapiproc) glad_glPrioritizeTexturesxOES, 3, n, textures, priorities);
- glad_glPrioritizeTexturesxOES(n, textures, priorities);
- _post_call_gl_callback(NULL, "glPrioritizeTexturesxOES", (GLADapiproc) glad_glPrioritizeTexturesxOES, 3, n, textures, priorities);
+PFNGLPRIORITIZETEXTURESPROC glad_glPrioritizeTextures = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPrioritizeTextures(GLsizei n, const GLuint * textures, const GLfloat * priorities) {
+ _pre_call_gl_callback("glPrioritizeTextures", (GLADapiproc) glad_glPrioritizeTextures, 3, n, textures, priorities);
+ glad_glPrioritizeTextures(n, textures, priorities);
+ _post_call_gl_callback(NULL, "glPrioritizeTextures", (GLADapiproc) glad_glPrioritizeTextures, 3, n, textures, priorities);
}
-PFNGLPRIORITIZETEXTURESXOESPROC glad_debug_glPrioritizeTexturesxOES = glad_debug_impl_glPrioritizeTexturesxOES;
+PFNGLPRIORITIZETEXTURESPROC glad_debug_glPrioritizeTextures = glad_debug_impl_glPrioritizeTextures;
PFNGLPROGRAMBINARYPROC glad_glProgramBinary = NULL;
static void GLAD_API_PTR glad_debug_impl_glProgramBinary(GLuint program, GLenum binaryFormat, const void * binary, GLsizei length) {
_pre_call_gl_callback("glProgramBinary", (GLADapiproc) glad_glProgramBinary, 4, program, binaryFormat, binary, length);
@@ -5631,6 +6793,22 @@ static void GLAD_API_PTR glad_debug_impl_glProvokingVertex(GLenum mode) {
}
PFNGLPROVOKINGVERTEXPROC glad_debug_glProvokingVertex = glad_debug_impl_glProvokingVertex;
+PFNGLPUSHATTRIBPROC glad_glPushAttrib = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPushAttrib(GLbitfield mask) {
+ _pre_call_gl_callback("glPushAttrib", (GLADapiproc) glad_glPushAttrib, 1, mask);
+ glad_glPushAttrib(mask);
+ _post_call_gl_callback(NULL, "glPushAttrib", (GLADapiproc) glad_glPushAttrib, 1, mask);
+
+}
+PFNGLPUSHATTRIBPROC glad_debug_glPushAttrib = glad_debug_impl_glPushAttrib;
+PFNGLPUSHCLIENTATTRIBPROC glad_glPushClientAttrib = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPushClientAttrib(GLbitfield mask) {
+ _pre_call_gl_callback("glPushClientAttrib", (GLADapiproc) glad_glPushClientAttrib, 1, mask);
+ glad_glPushClientAttrib(mask);
+ _post_call_gl_callback(NULL, "glPushClientAttrib", (GLADapiproc) glad_glPushClientAttrib, 1, mask);
+
+}
+PFNGLPUSHCLIENTATTRIBPROC glad_debug_glPushClientAttrib = glad_debug_impl_glPushClientAttrib;
PFNGLPUSHDEBUGGROUPPROC glad_glPushDebugGroup = NULL;
static void GLAD_API_PTR glad_debug_impl_glPushDebugGroup(GLenum source, GLuint id, GLsizei length, const GLchar * message) {
_pre_call_gl_callback("glPushDebugGroup", (GLADapiproc) glad_glPushDebugGroup, 4, source, id, length, message);
@@ -5639,6 +6817,22 @@ static void GLAD_API_PTR glad_debug_impl_glPushDebugGroup(GLenum source, GLuint
}
PFNGLPUSHDEBUGGROUPPROC glad_debug_glPushDebugGroup = glad_debug_impl_glPushDebugGroup;
+PFNGLPUSHMATRIXPROC glad_glPushMatrix = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPushMatrix(void) {
+ _pre_call_gl_callback("glPushMatrix", (GLADapiproc) glad_glPushMatrix, 0);
+ glad_glPushMatrix();
+ _post_call_gl_callback(NULL, "glPushMatrix", (GLADapiproc) glad_glPushMatrix, 0);
+
+}
+PFNGLPUSHMATRIXPROC glad_debug_glPushMatrix = glad_debug_impl_glPushMatrix;
+PFNGLPUSHNAMEPROC glad_glPushName = NULL;
+static void GLAD_API_PTR glad_debug_impl_glPushName(GLuint name) {
+ _pre_call_gl_callback("glPushName", (GLADapiproc) glad_glPushName, 1, name);
+ glad_glPushName(name);
+ _post_call_gl_callback(NULL, "glPushName", (GLADapiproc) glad_glPushName, 1, name);
+
+}
+PFNGLPUSHNAMEPROC glad_debug_glPushName = glad_debug_impl_glPushName;
PFNGLQUERYCOUNTERPROC glad_glQueryCounter = NULL;
static void GLAD_API_PTR glad_debug_impl_glQueryCounter(GLuint id, GLenum target) {
_pre_call_gl_callback("glQueryCounter", (GLADapiproc) glad_glQueryCounter, 2, id, target);
@@ -5647,54 +6841,198 @@ static void GLAD_API_PTR glad_debug_impl_glQueryCounter(GLuint id, GLenum target
}
PFNGLQUERYCOUNTERPROC glad_debug_glQueryCounter = glad_debug_impl_glQueryCounter;
-PFNGLRASTERPOS2XOESPROC glad_glRasterPos2xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glRasterPos2xOES(GLfixed x, GLfixed y) {
- _pre_call_gl_callback("glRasterPos2xOES", (GLADapiproc) glad_glRasterPos2xOES, 2, x, y);
- glad_glRasterPos2xOES(x, y);
- _post_call_gl_callback(NULL, "glRasterPos2xOES", (GLADapiproc) glad_glRasterPos2xOES, 2, x, y);
+PFNGLRASTERPOS2DPROC glad_glRasterPos2d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos2d(GLdouble x, GLdouble y) {
+ _pre_call_gl_callback("glRasterPos2d", (GLADapiproc) glad_glRasterPos2d, 2, x, y);
+ glad_glRasterPos2d(x, y);
+ _post_call_gl_callback(NULL, "glRasterPos2d", (GLADapiproc) glad_glRasterPos2d, 2, x, y);
+
+}
+PFNGLRASTERPOS2DPROC glad_debug_glRasterPos2d = glad_debug_impl_glRasterPos2d;
+PFNGLRASTERPOS2DVPROC glad_glRasterPos2dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos2dv(const GLdouble * v) {
+ _pre_call_gl_callback("glRasterPos2dv", (GLADapiproc) glad_glRasterPos2dv, 1, v);
+ glad_glRasterPos2dv(v);
+ _post_call_gl_callback(NULL, "glRasterPos2dv", (GLADapiproc) glad_glRasterPos2dv, 1, v);
+
+}
+PFNGLRASTERPOS2DVPROC glad_debug_glRasterPos2dv = glad_debug_impl_glRasterPos2dv;
+PFNGLRASTERPOS2FPROC glad_glRasterPos2f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos2f(GLfloat x, GLfloat y) {
+ _pre_call_gl_callback("glRasterPos2f", (GLADapiproc) glad_glRasterPos2f, 2, x, y);
+ glad_glRasterPos2f(x, y);
+ _post_call_gl_callback(NULL, "glRasterPos2f", (GLADapiproc) glad_glRasterPos2f, 2, x, y);
+
+}
+PFNGLRASTERPOS2FPROC glad_debug_glRasterPos2f = glad_debug_impl_glRasterPos2f;
+PFNGLRASTERPOS2FVPROC glad_glRasterPos2fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos2fv(const GLfloat * v) {
+ _pre_call_gl_callback("glRasterPos2fv", (GLADapiproc) glad_glRasterPos2fv, 1, v);
+ glad_glRasterPos2fv(v);
+ _post_call_gl_callback(NULL, "glRasterPos2fv", (GLADapiproc) glad_glRasterPos2fv, 1, v);
+
+}
+PFNGLRASTERPOS2FVPROC glad_debug_glRasterPos2fv = glad_debug_impl_glRasterPos2fv;
+PFNGLRASTERPOS2IPROC glad_glRasterPos2i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos2i(GLint x, GLint y) {
+ _pre_call_gl_callback("glRasterPos2i", (GLADapiproc) glad_glRasterPos2i, 2, x, y);
+ glad_glRasterPos2i(x, y);
+ _post_call_gl_callback(NULL, "glRasterPos2i", (GLADapiproc) glad_glRasterPos2i, 2, x, y);
+
+}
+PFNGLRASTERPOS2IPROC glad_debug_glRasterPos2i = glad_debug_impl_glRasterPos2i;
+PFNGLRASTERPOS2IVPROC glad_glRasterPos2iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos2iv(const GLint * v) {
+ _pre_call_gl_callback("glRasterPos2iv", (GLADapiproc) glad_glRasterPos2iv, 1, v);
+ glad_glRasterPos2iv(v);
+ _post_call_gl_callback(NULL, "glRasterPos2iv", (GLADapiproc) glad_glRasterPos2iv, 1, v);
+
+}
+PFNGLRASTERPOS2IVPROC glad_debug_glRasterPos2iv = glad_debug_impl_glRasterPos2iv;
+PFNGLRASTERPOS2SPROC glad_glRasterPos2s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos2s(GLshort x, GLshort y) {
+ _pre_call_gl_callback("glRasterPos2s", (GLADapiproc) glad_glRasterPos2s, 2, x, y);
+ glad_glRasterPos2s(x, y);
+ _post_call_gl_callback(NULL, "glRasterPos2s", (GLADapiproc) glad_glRasterPos2s, 2, x, y);
+
+}
+PFNGLRASTERPOS2SPROC glad_debug_glRasterPos2s = glad_debug_impl_glRasterPos2s;
+PFNGLRASTERPOS2SVPROC glad_glRasterPos2sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos2sv(const GLshort * v) {
+ _pre_call_gl_callback("glRasterPos2sv", (GLADapiproc) glad_glRasterPos2sv, 1, v);
+ glad_glRasterPos2sv(v);
+ _post_call_gl_callback(NULL, "glRasterPos2sv", (GLADapiproc) glad_glRasterPos2sv, 1, v);
+
+}
+PFNGLRASTERPOS2SVPROC glad_debug_glRasterPos2sv = glad_debug_impl_glRasterPos2sv;
+PFNGLRASTERPOS3DPROC glad_glRasterPos3d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos3d(GLdouble x, GLdouble y, GLdouble z) {
+ _pre_call_gl_callback("glRasterPos3d", (GLADapiproc) glad_glRasterPos3d, 3, x, y, z);
+ glad_glRasterPos3d(x, y, z);
+ _post_call_gl_callback(NULL, "glRasterPos3d", (GLADapiproc) glad_glRasterPos3d, 3, x, y, z);
+
+}
+PFNGLRASTERPOS3DPROC glad_debug_glRasterPos3d = glad_debug_impl_glRasterPos3d;
+PFNGLRASTERPOS3DVPROC glad_glRasterPos3dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos3dv(const GLdouble * v) {
+ _pre_call_gl_callback("glRasterPos3dv", (GLADapiproc) glad_glRasterPos3dv, 1, v);
+ glad_glRasterPos3dv(v);
+ _post_call_gl_callback(NULL, "glRasterPos3dv", (GLADapiproc) glad_glRasterPos3dv, 1, v);
+
+}
+PFNGLRASTERPOS3DVPROC glad_debug_glRasterPos3dv = glad_debug_impl_glRasterPos3dv;
+PFNGLRASTERPOS3FPROC glad_glRasterPos3f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos3f(GLfloat x, GLfloat y, GLfloat z) {
+ _pre_call_gl_callback("glRasterPos3f", (GLADapiproc) glad_glRasterPos3f, 3, x, y, z);
+ glad_glRasterPos3f(x, y, z);
+ _post_call_gl_callback(NULL, "glRasterPos3f", (GLADapiproc) glad_glRasterPos3f, 3, x, y, z);
+
+}
+PFNGLRASTERPOS3FPROC glad_debug_glRasterPos3f = glad_debug_impl_glRasterPos3f;
+PFNGLRASTERPOS3FVPROC glad_glRasterPos3fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos3fv(const GLfloat * v) {
+ _pre_call_gl_callback("glRasterPos3fv", (GLADapiproc) glad_glRasterPos3fv, 1, v);
+ glad_glRasterPos3fv(v);
+ _post_call_gl_callback(NULL, "glRasterPos3fv", (GLADapiproc) glad_glRasterPos3fv, 1, v);
+
+}
+PFNGLRASTERPOS3FVPROC glad_debug_glRasterPos3fv = glad_debug_impl_glRasterPos3fv;
+PFNGLRASTERPOS3IPROC glad_glRasterPos3i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos3i(GLint x, GLint y, GLint z) {
+ _pre_call_gl_callback("glRasterPos3i", (GLADapiproc) glad_glRasterPos3i, 3, x, y, z);
+ glad_glRasterPos3i(x, y, z);
+ _post_call_gl_callback(NULL, "glRasterPos3i", (GLADapiproc) glad_glRasterPos3i, 3, x, y, z);
+
+}
+PFNGLRASTERPOS3IPROC glad_debug_glRasterPos3i = glad_debug_impl_glRasterPos3i;
+PFNGLRASTERPOS3IVPROC glad_glRasterPos3iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos3iv(const GLint * v) {
+ _pre_call_gl_callback("glRasterPos3iv", (GLADapiproc) glad_glRasterPos3iv, 1, v);
+ glad_glRasterPos3iv(v);
+ _post_call_gl_callback(NULL, "glRasterPos3iv", (GLADapiproc) glad_glRasterPos3iv, 1, v);
+
+}
+PFNGLRASTERPOS3IVPROC glad_debug_glRasterPos3iv = glad_debug_impl_glRasterPos3iv;
+PFNGLRASTERPOS3SPROC glad_glRasterPos3s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos3s(GLshort x, GLshort y, GLshort z) {
+ _pre_call_gl_callback("glRasterPos3s", (GLADapiproc) glad_glRasterPos3s, 3, x, y, z);
+ glad_glRasterPos3s(x, y, z);
+ _post_call_gl_callback(NULL, "glRasterPos3s", (GLADapiproc) glad_glRasterPos3s, 3, x, y, z);
+
+}
+PFNGLRASTERPOS3SPROC glad_debug_glRasterPos3s = glad_debug_impl_glRasterPos3s;
+PFNGLRASTERPOS3SVPROC glad_glRasterPos3sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos3sv(const GLshort * v) {
+ _pre_call_gl_callback("glRasterPos3sv", (GLADapiproc) glad_glRasterPos3sv, 1, v);
+ glad_glRasterPos3sv(v);
+ _post_call_gl_callback(NULL, "glRasterPos3sv", (GLADapiproc) glad_glRasterPos3sv, 1, v);
}
-PFNGLRASTERPOS2XOESPROC glad_debug_glRasterPos2xOES = glad_debug_impl_glRasterPos2xOES;
-PFNGLRASTERPOS2XVOESPROC glad_glRasterPos2xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glRasterPos2xvOES(const GLfixed * coords) {
- _pre_call_gl_callback("glRasterPos2xvOES", (GLADapiproc) glad_glRasterPos2xvOES, 1, coords);
- glad_glRasterPos2xvOES(coords);
- _post_call_gl_callback(NULL, "glRasterPos2xvOES", (GLADapiproc) glad_glRasterPos2xvOES, 1, coords);
+PFNGLRASTERPOS3SVPROC glad_debug_glRasterPos3sv = glad_debug_impl_glRasterPos3sv;
+PFNGLRASTERPOS4DPROC glad_glRasterPos4d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w) {
+ _pre_call_gl_callback("glRasterPos4d", (GLADapiproc) glad_glRasterPos4d, 4, x, y, z, w);
+ glad_glRasterPos4d(x, y, z, w);
+ _post_call_gl_callback(NULL, "glRasterPos4d", (GLADapiproc) glad_glRasterPos4d, 4, x, y, z, w);
}
-PFNGLRASTERPOS2XVOESPROC glad_debug_glRasterPos2xvOES = glad_debug_impl_glRasterPos2xvOES;
-PFNGLRASTERPOS3XOESPROC glad_glRasterPos3xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glRasterPos3xOES(GLfixed x, GLfixed y, GLfixed z) {
- _pre_call_gl_callback("glRasterPos3xOES", (GLADapiproc) glad_glRasterPos3xOES, 3, x, y, z);
- glad_glRasterPos3xOES(x, y, z);
- _post_call_gl_callback(NULL, "glRasterPos3xOES", (GLADapiproc) glad_glRasterPos3xOES, 3, x, y, z);
+PFNGLRASTERPOS4DPROC glad_debug_glRasterPos4d = glad_debug_impl_glRasterPos4d;
+PFNGLRASTERPOS4DVPROC glad_glRasterPos4dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos4dv(const GLdouble * v) {
+ _pre_call_gl_callback("glRasterPos4dv", (GLADapiproc) glad_glRasterPos4dv, 1, v);
+ glad_glRasterPos4dv(v);
+ _post_call_gl_callback(NULL, "glRasterPos4dv", (GLADapiproc) glad_glRasterPos4dv, 1, v);
}
-PFNGLRASTERPOS3XOESPROC glad_debug_glRasterPos3xOES = glad_debug_impl_glRasterPos3xOES;
-PFNGLRASTERPOS3XVOESPROC glad_glRasterPos3xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glRasterPos3xvOES(const GLfixed * coords) {
- _pre_call_gl_callback("glRasterPos3xvOES", (GLADapiproc) glad_glRasterPos3xvOES, 1, coords);
- glad_glRasterPos3xvOES(coords);
- _post_call_gl_callback(NULL, "glRasterPos3xvOES", (GLADapiproc) glad_glRasterPos3xvOES, 1, coords);
+PFNGLRASTERPOS4DVPROC glad_debug_glRasterPos4dv = glad_debug_impl_glRasterPos4dv;
+PFNGLRASTERPOS4FPROC glad_glRasterPos4f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w) {
+ _pre_call_gl_callback("glRasterPos4f", (GLADapiproc) glad_glRasterPos4f, 4, x, y, z, w);
+ glad_glRasterPos4f(x, y, z, w);
+ _post_call_gl_callback(NULL, "glRasterPos4f", (GLADapiproc) glad_glRasterPos4f, 4, x, y, z, w);
}
-PFNGLRASTERPOS3XVOESPROC glad_debug_glRasterPos3xvOES = glad_debug_impl_glRasterPos3xvOES;
-PFNGLRASTERPOS4XOESPROC glad_glRasterPos4xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glRasterPos4xOES(GLfixed x, GLfixed y, GLfixed z, GLfixed w) {
- _pre_call_gl_callback("glRasterPos4xOES", (GLADapiproc) glad_glRasterPos4xOES, 4, x, y, z, w);
- glad_glRasterPos4xOES(x, y, z, w);
- _post_call_gl_callback(NULL, "glRasterPos4xOES", (GLADapiproc) glad_glRasterPos4xOES, 4, x, y, z, w);
+PFNGLRASTERPOS4FPROC glad_debug_glRasterPos4f = glad_debug_impl_glRasterPos4f;
+PFNGLRASTERPOS4FVPROC glad_glRasterPos4fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos4fv(const GLfloat * v) {
+ _pre_call_gl_callback("glRasterPos4fv", (GLADapiproc) glad_glRasterPos4fv, 1, v);
+ glad_glRasterPos4fv(v);
+ _post_call_gl_callback(NULL, "glRasterPos4fv", (GLADapiproc) glad_glRasterPos4fv, 1, v);
}
-PFNGLRASTERPOS4XOESPROC glad_debug_glRasterPos4xOES = glad_debug_impl_glRasterPos4xOES;
-PFNGLRASTERPOS4XVOESPROC glad_glRasterPos4xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glRasterPos4xvOES(const GLfixed * coords) {
- _pre_call_gl_callback("glRasterPos4xvOES", (GLADapiproc) glad_glRasterPos4xvOES, 1, coords);
- glad_glRasterPos4xvOES(coords);
- _post_call_gl_callback(NULL, "glRasterPos4xvOES", (GLADapiproc) glad_glRasterPos4xvOES, 1, coords);
+PFNGLRASTERPOS4FVPROC glad_debug_glRasterPos4fv = glad_debug_impl_glRasterPos4fv;
+PFNGLRASTERPOS4IPROC glad_glRasterPos4i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos4i(GLint x, GLint y, GLint z, GLint w) {
+ _pre_call_gl_callback("glRasterPos4i", (GLADapiproc) glad_glRasterPos4i, 4, x, y, z, w);
+ glad_glRasterPos4i(x, y, z, w);
+ _post_call_gl_callback(NULL, "glRasterPos4i", (GLADapiproc) glad_glRasterPos4i, 4, x, y, z, w);
}
-PFNGLRASTERPOS4XVOESPROC glad_debug_glRasterPos4xvOES = glad_debug_impl_glRasterPos4xvOES;
+PFNGLRASTERPOS4IPROC glad_debug_glRasterPos4i = glad_debug_impl_glRasterPos4i;
+PFNGLRASTERPOS4IVPROC glad_glRasterPos4iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos4iv(const GLint * v) {
+ _pre_call_gl_callback("glRasterPos4iv", (GLADapiproc) glad_glRasterPos4iv, 1, v);
+ glad_glRasterPos4iv(v);
+ _post_call_gl_callback(NULL, "glRasterPos4iv", (GLADapiproc) glad_glRasterPos4iv, 1, v);
+
+}
+PFNGLRASTERPOS4IVPROC glad_debug_glRasterPos4iv = glad_debug_impl_glRasterPos4iv;
+PFNGLRASTERPOS4SPROC glad_glRasterPos4s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w) {
+ _pre_call_gl_callback("glRasterPos4s", (GLADapiproc) glad_glRasterPos4s, 4, x, y, z, w);
+ glad_glRasterPos4s(x, y, z, w);
+ _post_call_gl_callback(NULL, "glRasterPos4s", (GLADapiproc) glad_glRasterPos4s, 4, x, y, z, w);
+
+}
+PFNGLRASTERPOS4SPROC glad_debug_glRasterPos4s = glad_debug_impl_glRasterPos4s;
+PFNGLRASTERPOS4SVPROC glad_glRasterPos4sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRasterPos4sv(const GLshort * v) {
+ _pre_call_gl_callback("glRasterPos4sv", (GLADapiproc) glad_glRasterPos4sv, 1, v);
+ glad_glRasterPos4sv(v);
+ _post_call_gl_callback(NULL, "glRasterPos4sv", (GLADapiproc) glad_glRasterPos4sv, 1, v);
+
+}
+PFNGLRASTERPOS4SVPROC glad_debug_glRasterPos4sv = glad_debug_impl_glRasterPos4sv;
PFNGLREADBUFFERPROC glad_glReadBuffer = NULL;
static void GLAD_API_PTR glad_debug_impl_glReadBuffer(GLenum src) {
_pre_call_gl_callback("glReadBuffer", (GLADapiproc) glad_glReadBuffer, 1, src);
@@ -5711,22 +7049,70 @@ static void GLAD_API_PTR glad_debug_impl_glReadPixels(GLint x, GLint y, GLsizei
}
PFNGLREADPIXELSPROC glad_debug_glReadPixels = glad_debug_impl_glReadPixels;
-PFNGLRECTXOESPROC glad_glRectxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glRectxOES(GLfixed x1, GLfixed y1, GLfixed x2, GLfixed y2) {
- _pre_call_gl_callback("glRectxOES", (GLADapiproc) glad_glRectxOES, 4, x1, y1, x2, y2);
- glad_glRectxOES(x1, y1, x2, y2);
- _post_call_gl_callback(NULL, "glRectxOES", (GLADapiproc) glad_glRectxOES, 4, x1, y1, x2, y2);
+PFNGLRECTDPROC glad_glRectd = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2) {
+ _pre_call_gl_callback("glRectd", (GLADapiproc) glad_glRectd, 4, x1, y1, x2, y2);
+ glad_glRectd(x1, y1, x2, y2);
+ _post_call_gl_callback(NULL, "glRectd", (GLADapiproc) glad_glRectd, 4, x1, y1, x2, y2);
}
-PFNGLRECTXOESPROC glad_debug_glRectxOES = glad_debug_impl_glRectxOES;
-PFNGLRECTXVOESPROC glad_glRectxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glRectxvOES(const GLfixed * v1, const GLfixed * v2) {
- _pre_call_gl_callback("glRectxvOES", (GLADapiproc) glad_glRectxvOES, 2, v1, v2);
- glad_glRectxvOES(v1, v2);
- _post_call_gl_callback(NULL, "glRectxvOES", (GLADapiproc) glad_glRectxvOES, 2, v1, v2);
+PFNGLRECTDPROC glad_debug_glRectd = glad_debug_impl_glRectd;
+PFNGLRECTDVPROC glad_glRectdv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRectdv(const GLdouble * v1, const GLdouble * v2) {
+ _pre_call_gl_callback("glRectdv", (GLADapiproc) glad_glRectdv, 2, v1, v2);
+ glad_glRectdv(v1, v2);
+ _post_call_gl_callback(NULL, "glRectdv", (GLADapiproc) glad_glRectdv, 2, v1, v2);
}
-PFNGLRECTXVOESPROC glad_debug_glRectxvOES = glad_debug_impl_glRectxvOES;
+PFNGLRECTDVPROC glad_debug_glRectdv = glad_debug_impl_glRectdv;
+PFNGLRECTFPROC glad_glRectf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2) {
+ _pre_call_gl_callback("glRectf", (GLADapiproc) glad_glRectf, 4, x1, y1, x2, y2);
+ glad_glRectf(x1, y1, x2, y2);
+ _post_call_gl_callback(NULL, "glRectf", (GLADapiproc) glad_glRectf, 4, x1, y1, x2, y2);
+
+}
+PFNGLRECTFPROC glad_debug_glRectf = glad_debug_impl_glRectf;
+PFNGLRECTFVPROC glad_glRectfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRectfv(const GLfloat * v1, const GLfloat * v2) {
+ _pre_call_gl_callback("glRectfv", (GLADapiproc) glad_glRectfv, 2, v1, v2);
+ glad_glRectfv(v1, v2);
+ _post_call_gl_callback(NULL, "glRectfv", (GLADapiproc) glad_glRectfv, 2, v1, v2);
+
+}
+PFNGLRECTFVPROC glad_debug_glRectfv = glad_debug_impl_glRectfv;
+PFNGLRECTIPROC glad_glRecti = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRecti(GLint x1, GLint y1, GLint x2, GLint y2) {
+ _pre_call_gl_callback("glRecti", (GLADapiproc) glad_glRecti, 4, x1, y1, x2, y2);
+ glad_glRecti(x1, y1, x2, y2);
+ _post_call_gl_callback(NULL, "glRecti", (GLADapiproc) glad_glRecti, 4, x1, y1, x2, y2);
+
+}
+PFNGLRECTIPROC glad_debug_glRecti = glad_debug_impl_glRecti;
+PFNGLRECTIVPROC glad_glRectiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRectiv(const GLint * v1, const GLint * v2) {
+ _pre_call_gl_callback("glRectiv", (GLADapiproc) glad_glRectiv, 2, v1, v2);
+ glad_glRectiv(v1, v2);
+ _post_call_gl_callback(NULL, "glRectiv", (GLADapiproc) glad_glRectiv, 2, v1, v2);
+
+}
+PFNGLRECTIVPROC glad_debug_glRectiv = glad_debug_impl_glRectiv;
+PFNGLRECTSPROC glad_glRects = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2) {
+ _pre_call_gl_callback("glRects", (GLADapiproc) glad_glRects, 4, x1, y1, x2, y2);
+ glad_glRects(x1, y1, x2, y2);
+ _post_call_gl_callback(NULL, "glRects", (GLADapiproc) glad_glRects, 4, x1, y1, x2, y2);
+
+}
+PFNGLRECTSPROC glad_debug_glRects = glad_debug_impl_glRects;
+PFNGLRECTSVPROC glad_glRectsv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRectsv(const GLshort * v1, const GLshort * v2) {
+ _pre_call_gl_callback("glRectsv", (GLADapiproc) glad_glRectsv, 2, v1, v2);
+ glad_glRectsv(v1, v2);
+ _post_call_gl_callback(NULL, "glRectsv", (GLADapiproc) glad_glRectsv, 2, v1, v2);
+
+}
+PFNGLRECTSVPROC glad_debug_glRectsv = glad_debug_impl_glRectsv;
PFNGLRELEASESHADERCOMPILERPROC glad_glReleaseShaderCompiler = NULL;
static void GLAD_API_PTR glad_debug_impl_glReleaseShaderCompiler(void) {
_pre_call_gl_callback("glReleaseShaderCompiler", (GLADapiproc) glad_glReleaseShaderCompiler, 0);
@@ -5735,6 +7121,15 @@ static void GLAD_API_PTR glad_debug_impl_glReleaseShaderCompiler(void) {
}
PFNGLRELEASESHADERCOMPILERPROC glad_debug_glReleaseShaderCompiler = glad_debug_impl_glReleaseShaderCompiler;
+PFNGLRENDERMODEPROC glad_glRenderMode = NULL;
+static GLint GLAD_API_PTR glad_debug_impl_glRenderMode(GLenum mode) {
+ GLint ret;
+ _pre_call_gl_callback("glRenderMode", (GLADapiproc) glad_glRenderMode, 1, mode);
+ ret = glad_glRenderMode(mode);
+ _post_call_gl_callback((void*) &ret, "glRenderMode", (GLADapiproc) glad_glRenderMode, 1, mode);
+ return ret;
+}
+PFNGLRENDERMODEPROC glad_debug_glRenderMode = glad_debug_impl_glRenderMode;
PFNGLRENDERBUFFERSTORAGEPROC glad_glRenderbufferStorage = NULL;
static void GLAD_API_PTR glad_debug_impl_glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height) {
_pre_call_gl_callback("glRenderbufferStorage", (GLADapiproc) glad_glRenderbufferStorage, 4, target, internalformat, width, height);
@@ -5775,14 +7170,22 @@ static void GLAD_API_PTR glad_debug_impl_glResumeTransformFeedback(void) {
}
PFNGLRESUMETRANSFORMFEEDBACKPROC glad_debug_glResumeTransformFeedback = glad_debug_impl_glResumeTransformFeedback;
-PFNGLROTATEXOESPROC glad_glRotatexOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glRotatexOES(GLfixed angle, GLfixed x, GLfixed y, GLfixed z) {
- _pre_call_gl_callback("glRotatexOES", (GLADapiproc) glad_glRotatexOES, 4, angle, x, y, z);
- glad_glRotatexOES(angle, x, y, z);
- _post_call_gl_callback(NULL, "glRotatexOES", (GLADapiproc) glad_glRotatexOES, 4, angle, x, y, z);
+PFNGLROTATEDPROC glad_glRotated = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z) {
+ _pre_call_gl_callback("glRotated", (GLADapiproc) glad_glRotated, 4, angle, x, y, z);
+ glad_glRotated(angle, x, y, z);
+ _post_call_gl_callback(NULL, "glRotated", (GLADapiproc) glad_glRotated, 4, angle, x, y, z);
+
+}
+PFNGLROTATEDPROC glad_debug_glRotated = glad_debug_impl_glRotated;
+PFNGLROTATEFPROC glad_glRotatef = NULL;
+static void GLAD_API_PTR glad_debug_impl_glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z) {
+ _pre_call_gl_callback("glRotatef", (GLADapiproc) glad_glRotatef, 4, angle, x, y, z);
+ glad_glRotatef(angle, x, y, z);
+ _post_call_gl_callback(NULL, "glRotatef", (GLADapiproc) glad_glRotatef, 4, angle, x, y, z);
}
-PFNGLROTATEXOESPROC glad_debug_glRotatexOES = glad_debug_impl_glRotatexOES;
+PFNGLROTATEFPROC glad_debug_glRotatef = glad_debug_impl_glRotatef;
PFNGLSAMPLECOVERAGEPROC glad_glSampleCoverage = NULL;
static void GLAD_API_PTR glad_debug_impl_glSampleCoverage(GLfloat value, GLboolean invert) {
_pre_call_gl_callback("glSampleCoverage", (GLADapiproc) glad_glSampleCoverage, 2, value, invert);
@@ -5855,14 +7258,22 @@ static void GLAD_API_PTR glad_debug_impl_glSamplerParameteriv(GLuint sampler, GL
}
PFNGLSAMPLERPARAMETERIVPROC glad_debug_glSamplerParameteriv = glad_debug_impl_glSamplerParameteriv;
-PFNGLSCALEXOESPROC glad_glScalexOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glScalexOES(GLfixed x, GLfixed y, GLfixed z) {
- _pre_call_gl_callback("glScalexOES", (GLADapiproc) glad_glScalexOES, 3, x, y, z);
- glad_glScalexOES(x, y, z);
- _post_call_gl_callback(NULL, "glScalexOES", (GLADapiproc) glad_glScalexOES, 3, x, y, z);
+PFNGLSCALEDPROC glad_glScaled = NULL;
+static void GLAD_API_PTR glad_debug_impl_glScaled(GLdouble x, GLdouble y, GLdouble z) {
+ _pre_call_gl_callback("glScaled", (GLADapiproc) glad_glScaled, 3, x, y, z);
+ glad_glScaled(x, y, z);
+ _post_call_gl_callback(NULL, "glScaled", (GLADapiproc) glad_glScaled, 3, x, y, z);
+
+}
+PFNGLSCALEDPROC glad_debug_glScaled = glad_debug_impl_glScaled;
+PFNGLSCALEFPROC glad_glScalef = NULL;
+static void GLAD_API_PTR glad_debug_impl_glScalef(GLfloat x, GLfloat y, GLfloat z) {
+ _pre_call_gl_callback("glScalef", (GLADapiproc) glad_glScalef, 3, x, y, z);
+ glad_glScalef(x, y, z);
+ _post_call_gl_callback(NULL, "glScalef", (GLADapiproc) glad_glScalef, 3, x, y, z);
}
-PFNGLSCALEXOESPROC glad_debug_glScalexOES = glad_debug_impl_glScalexOES;
+PFNGLSCALEFPROC glad_debug_glScalef = glad_debug_impl_glScalef;
PFNGLSCISSORPROC glad_glScissor = NULL;
static void GLAD_API_PTR glad_debug_impl_glScissor(GLint x, GLint y, GLsizei width, GLsizei height) {
_pre_call_gl_callback("glScissor", (GLADapiproc) glad_glScissor, 4, x, y, width, height);
@@ -5895,6 +7306,174 @@ static void GLAD_API_PTR glad_debug_impl_glScissorIndexedv(GLuint index, const G
}
PFNGLSCISSORINDEXEDVPROC glad_debug_glScissorIndexedv = glad_debug_impl_glScissorIndexedv;
+PFNGLSECONDARYCOLOR3BPROC glad_glSecondaryColor3b = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue) {
+ _pre_call_gl_callback("glSecondaryColor3b", (GLADapiproc) glad_glSecondaryColor3b, 3, red, green, blue);
+ glad_glSecondaryColor3b(red, green, blue);
+ _post_call_gl_callback(NULL, "glSecondaryColor3b", (GLADapiproc) glad_glSecondaryColor3b, 3, red, green, blue);
+
+}
+PFNGLSECONDARYCOLOR3BPROC glad_debug_glSecondaryColor3b = glad_debug_impl_glSecondaryColor3b;
+PFNGLSECONDARYCOLOR3BVPROC glad_glSecondaryColor3bv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3bv(const GLbyte * v) {
+ _pre_call_gl_callback("glSecondaryColor3bv", (GLADapiproc) glad_glSecondaryColor3bv, 1, v);
+ glad_glSecondaryColor3bv(v);
+ _post_call_gl_callback(NULL, "glSecondaryColor3bv", (GLADapiproc) glad_glSecondaryColor3bv, 1, v);
+
+}
+PFNGLSECONDARYCOLOR3BVPROC glad_debug_glSecondaryColor3bv = glad_debug_impl_glSecondaryColor3bv;
+PFNGLSECONDARYCOLOR3DPROC glad_glSecondaryColor3d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue) {
+ _pre_call_gl_callback("glSecondaryColor3d", (GLADapiproc) glad_glSecondaryColor3d, 3, red, green, blue);
+ glad_glSecondaryColor3d(red, green, blue);
+ _post_call_gl_callback(NULL, "glSecondaryColor3d", (GLADapiproc) glad_glSecondaryColor3d, 3, red, green, blue);
+
+}
+PFNGLSECONDARYCOLOR3DPROC glad_debug_glSecondaryColor3d = glad_debug_impl_glSecondaryColor3d;
+PFNGLSECONDARYCOLOR3DVPROC glad_glSecondaryColor3dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3dv(const GLdouble * v) {
+ _pre_call_gl_callback("glSecondaryColor3dv", (GLADapiproc) glad_glSecondaryColor3dv, 1, v);
+ glad_glSecondaryColor3dv(v);
+ _post_call_gl_callback(NULL, "glSecondaryColor3dv", (GLADapiproc) glad_glSecondaryColor3dv, 1, v);
+
+}
+PFNGLSECONDARYCOLOR3DVPROC glad_debug_glSecondaryColor3dv = glad_debug_impl_glSecondaryColor3dv;
+PFNGLSECONDARYCOLOR3FPROC glad_glSecondaryColor3f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue) {
+ _pre_call_gl_callback("glSecondaryColor3f", (GLADapiproc) glad_glSecondaryColor3f, 3, red, green, blue);
+ glad_glSecondaryColor3f(red, green, blue);
+ _post_call_gl_callback(NULL, "glSecondaryColor3f", (GLADapiproc) glad_glSecondaryColor3f, 3, red, green, blue);
+
+}
+PFNGLSECONDARYCOLOR3FPROC glad_debug_glSecondaryColor3f = glad_debug_impl_glSecondaryColor3f;
+PFNGLSECONDARYCOLOR3FVPROC glad_glSecondaryColor3fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3fv(const GLfloat * v) {
+ _pre_call_gl_callback("glSecondaryColor3fv", (GLADapiproc) glad_glSecondaryColor3fv, 1, v);
+ glad_glSecondaryColor3fv(v);
+ _post_call_gl_callback(NULL, "glSecondaryColor3fv", (GLADapiproc) glad_glSecondaryColor3fv, 1, v);
+
+}
+PFNGLSECONDARYCOLOR3FVPROC glad_debug_glSecondaryColor3fv = glad_debug_impl_glSecondaryColor3fv;
+PFNGLSECONDARYCOLOR3IPROC glad_glSecondaryColor3i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3i(GLint red, GLint green, GLint blue) {
+ _pre_call_gl_callback("glSecondaryColor3i", (GLADapiproc) glad_glSecondaryColor3i, 3, red, green, blue);
+ glad_glSecondaryColor3i(red, green, blue);
+ _post_call_gl_callback(NULL, "glSecondaryColor3i", (GLADapiproc) glad_glSecondaryColor3i, 3, red, green, blue);
+
+}
+PFNGLSECONDARYCOLOR3IPROC glad_debug_glSecondaryColor3i = glad_debug_impl_glSecondaryColor3i;
+PFNGLSECONDARYCOLOR3IVPROC glad_glSecondaryColor3iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3iv(const GLint * v) {
+ _pre_call_gl_callback("glSecondaryColor3iv", (GLADapiproc) glad_glSecondaryColor3iv, 1, v);
+ glad_glSecondaryColor3iv(v);
+ _post_call_gl_callback(NULL, "glSecondaryColor3iv", (GLADapiproc) glad_glSecondaryColor3iv, 1, v);
+
+}
+PFNGLSECONDARYCOLOR3IVPROC glad_debug_glSecondaryColor3iv = glad_debug_impl_glSecondaryColor3iv;
+PFNGLSECONDARYCOLOR3SPROC glad_glSecondaryColor3s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3s(GLshort red, GLshort green, GLshort blue) {
+ _pre_call_gl_callback("glSecondaryColor3s", (GLADapiproc) glad_glSecondaryColor3s, 3, red, green, blue);
+ glad_glSecondaryColor3s(red, green, blue);
+ _post_call_gl_callback(NULL, "glSecondaryColor3s", (GLADapiproc) glad_glSecondaryColor3s, 3, red, green, blue);
+
+}
+PFNGLSECONDARYCOLOR3SPROC glad_debug_glSecondaryColor3s = glad_debug_impl_glSecondaryColor3s;
+PFNGLSECONDARYCOLOR3SVPROC glad_glSecondaryColor3sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3sv(const GLshort * v) {
+ _pre_call_gl_callback("glSecondaryColor3sv", (GLADapiproc) glad_glSecondaryColor3sv, 1, v);
+ glad_glSecondaryColor3sv(v);
+ _post_call_gl_callback(NULL, "glSecondaryColor3sv", (GLADapiproc) glad_glSecondaryColor3sv, 1, v);
+
+}
+PFNGLSECONDARYCOLOR3SVPROC glad_debug_glSecondaryColor3sv = glad_debug_impl_glSecondaryColor3sv;
+PFNGLSECONDARYCOLOR3UBPROC glad_glSecondaryColor3ub = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue) {
+ _pre_call_gl_callback("glSecondaryColor3ub", (GLADapiproc) glad_glSecondaryColor3ub, 3, red, green, blue);
+ glad_glSecondaryColor3ub(red, green, blue);
+ _post_call_gl_callback(NULL, "glSecondaryColor3ub", (GLADapiproc) glad_glSecondaryColor3ub, 3, red, green, blue);
+
+}
+PFNGLSECONDARYCOLOR3UBPROC glad_debug_glSecondaryColor3ub = glad_debug_impl_glSecondaryColor3ub;
+PFNGLSECONDARYCOLOR3UBVPROC glad_glSecondaryColor3ubv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3ubv(const GLubyte * v) {
+ _pre_call_gl_callback("glSecondaryColor3ubv", (GLADapiproc) glad_glSecondaryColor3ubv, 1, v);
+ glad_glSecondaryColor3ubv(v);
+ _post_call_gl_callback(NULL, "glSecondaryColor3ubv", (GLADapiproc) glad_glSecondaryColor3ubv, 1, v);
+
+}
+PFNGLSECONDARYCOLOR3UBVPROC glad_debug_glSecondaryColor3ubv = glad_debug_impl_glSecondaryColor3ubv;
+PFNGLSECONDARYCOLOR3UIPROC glad_glSecondaryColor3ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue) {
+ _pre_call_gl_callback("glSecondaryColor3ui", (GLADapiproc) glad_glSecondaryColor3ui, 3, red, green, blue);
+ glad_glSecondaryColor3ui(red, green, blue);
+ _post_call_gl_callback(NULL, "glSecondaryColor3ui", (GLADapiproc) glad_glSecondaryColor3ui, 3, red, green, blue);
+
+}
+PFNGLSECONDARYCOLOR3UIPROC glad_debug_glSecondaryColor3ui = glad_debug_impl_glSecondaryColor3ui;
+PFNGLSECONDARYCOLOR3UIVPROC glad_glSecondaryColor3uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3uiv(const GLuint * v) {
+ _pre_call_gl_callback("glSecondaryColor3uiv", (GLADapiproc) glad_glSecondaryColor3uiv, 1, v);
+ glad_glSecondaryColor3uiv(v);
+ _post_call_gl_callback(NULL, "glSecondaryColor3uiv", (GLADapiproc) glad_glSecondaryColor3uiv, 1, v);
+
+}
+PFNGLSECONDARYCOLOR3UIVPROC glad_debug_glSecondaryColor3uiv = glad_debug_impl_glSecondaryColor3uiv;
+PFNGLSECONDARYCOLOR3USPROC glad_glSecondaryColor3us = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3us(GLushort red, GLushort green, GLushort blue) {
+ _pre_call_gl_callback("glSecondaryColor3us", (GLADapiproc) glad_glSecondaryColor3us, 3, red, green, blue);
+ glad_glSecondaryColor3us(red, green, blue);
+ _post_call_gl_callback(NULL, "glSecondaryColor3us", (GLADapiproc) glad_glSecondaryColor3us, 3, red, green, blue);
+
+}
+PFNGLSECONDARYCOLOR3USPROC glad_debug_glSecondaryColor3us = glad_debug_impl_glSecondaryColor3us;
+PFNGLSECONDARYCOLOR3USVPROC glad_glSecondaryColor3usv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColor3usv(const GLushort * v) {
+ _pre_call_gl_callback("glSecondaryColor3usv", (GLADapiproc) glad_glSecondaryColor3usv, 1, v);
+ glad_glSecondaryColor3usv(v);
+ _post_call_gl_callback(NULL, "glSecondaryColor3usv", (GLADapiproc) glad_glSecondaryColor3usv, 1, v);
+
+}
+PFNGLSECONDARYCOLOR3USVPROC glad_debug_glSecondaryColor3usv = glad_debug_impl_glSecondaryColor3usv;
+PFNGLSECONDARYCOLORP3UIPROC glad_glSecondaryColorP3ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColorP3ui(GLenum type, GLuint color) {
+ _pre_call_gl_callback("glSecondaryColorP3ui", (GLADapiproc) glad_glSecondaryColorP3ui, 2, type, color);
+ glad_glSecondaryColorP3ui(type, color);
+ _post_call_gl_callback(NULL, "glSecondaryColorP3ui", (GLADapiproc) glad_glSecondaryColorP3ui, 2, type, color);
+
+}
+PFNGLSECONDARYCOLORP3UIPROC glad_debug_glSecondaryColorP3ui = glad_debug_impl_glSecondaryColorP3ui;
+PFNGLSECONDARYCOLORP3UIVPROC glad_glSecondaryColorP3uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColorP3uiv(GLenum type, const GLuint * color) {
+ _pre_call_gl_callback("glSecondaryColorP3uiv", (GLADapiproc) glad_glSecondaryColorP3uiv, 2, type, color);
+ glad_glSecondaryColorP3uiv(type, color);
+ _post_call_gl_callback(NULL, "glSecondaryColorP3uiv", (GLADapiproc) glad_glSecondaryColorP3uiv, 2, type, color);
+
+}
+PFNGLSECONDARYCOLORP3UIVPROC glad_debug_glSecondaryColorP3uiv = glad_debug_impl_glSecondaryColorP3uiv;
+PFNGLSECONDARYCOLORPOINTERPROC glad_glSecondaryColorPointer = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const void * pointer) {
+ _pre_call_gl_callback("glSecondaryColorPointer", (GLADapiproc) glad_glSecondaryColorPointer, 4, size, type, stride, pointer);
+ glad_glSecondaryColorPointer(size, type, stride, pointer);
+ _post_call_gl_callback(NULL, "glSecondaryColorPointer", (GLADapiproc) glad_glSecondaryColorPointer, 4, size, type, stride, pointer);
+
+}
+PFNGLSECONDARYCOLORPOINTERPROC glad_debug_glSecondaryColorPointer = glad_debug_impl_glSecondaryColorPointer;
+PFNGLSELECTBUFFERPROC glad_glSelectBuffer = NULL;
+static void GLAD_API_PTR glad_debug_impl_glSelectBuffer(GLsizei size, GLuint * buffer) {
+ _pre_call_gl_callback("glSelectBuffer", (GLADapiproc) glad_glSelectBuffer, 2, size, buffer);
+ glad_glSelectBuffer(size, buffer);
+ _post_call_gl_callback(NULL, "glSelectBuffer", (GLADapiproc) glad_glSelectBuffer, 2, size, buffer);
+
+}
+PFNGLSELECTBUFFERPROC glad_debug_glSelectBuffer = glad_debug_impl_glSelectBuffer;
+PFNGLSHADEMODELPROC glad_glShadeModel = NULL;
+static void GLAD_API_PTR glad_debug_impl_glShadeModel(GLenum mode) {
+ _pre_call_gl_callback("glShadeModel", (GLADapiproc) glad_glShadeModel, 1, mode);
+ glad_glShadeModel(mode);
+ _post_call_gl_callback(NULL, "glShadeModel", (GLADapiproc) glad_glShadeModel, 1, mode);
+
+}
+PFNGLSHADEMODELPROC glad_debug_glShadeModel = glad_debug_impl_glShadeModel;
PFNGLSHADERBINARYPROC glad_glShaderBinary = NULL;
static void GLAD_API_PTR glad_debug_impl_glShaderBinary(GLsizei count, const GLuint * shaders, GLenum binaryFormat, const void * binary, GLsizei length) {
_pre_call_gl_callback("glShaderBinary", (GLADapiproc) glad_glShaderBinary, 5, count, shaders, binaryFormat, binary, length);
@@ -5999,102 +7578,414 @@ static void GLAD_API_PTR glad_debug_impl_glTexBufferRange(GLenum target, GLenum
}
PFNGLTEXBUFFERRANGEPROC glad_debug_glTexBufferRange = glad_debug_impl_glTexBufferRange;
-PFNGLTEXCOORD1XOESPROC glad_glTexCoord1xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexCoord1xOES(GLfixed s) {
- _pre_call_gl_callback("glTexCoord1xOES", (GLADapiproc) glad_glTexCoord1xOES, 1, s);
- glad_glTexCoord1xOES(s);
- _post_call_gl_callback(NULL, "glTexCoord1xOES", (GLADapiproc) glad_glTexCoord1xOES, 1, s);
+PFNGLTEXCOORD1DPROC glad_glTexCoord1d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord1d(GLdouble s) {
+ _pre_call_gl_callback("glTexCoord1d", (GLADapiproc) glad_glTexCoord1d, 1, s);
+ glad_glTexCoord1d(s);
+ _post_call_gl_callback(NULL, "glTexCoord1d", (GLADapiproc) glad_glTexCoord1d, 1, s);
+
+}
+PFNGLTEXCOORD1DPROC glad_debug_glTexCoord1d = glad_debug_impl_glTexCoord1d;
+PFNGLTEXCOORD1DVPROC glad_glTexCoord1dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord1dv(const GLdouble * v) {
+ _pre_call_gl_callback("glTexCoord1dv", (GLADapiproc) glad_glTexCoord1dv, 1, v);
+ glad_glTexCoord1dv(v);
+ _post_call_gl_callback(NULL, "glTexCoord1dv", (GLADapiproc) glad_glTexCoord1dv, 1, v);
+
+}
+PFNGLTEXCOORD1DVPROC glad_debug_glTexCoord1dv = glad_debug_impl_glTexCoord1dv;
+PFNGLTEXCOORD1FPROC glad_glTexCoord1f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord1f(GLfloat s) {
+ _pre_call_gl_callback("glTexCoord1f", (GLADapiproc) glad_glTexCoord1f, 1, s);
+ glad_glTexCoord1f(s);
+ _post_call_gl_callback(NULL, "glTexCoord1f", (GLADapiproc) glad_glTexCoord1f, 1, s);
+
+}
+PFNGLTEXCOORD1FPROC glad_debug_glTexCoord1f = glad_debug_impl_glTexCoord1f;
+PFNGLTEXCOORD1FVPROC glad_glTexCoord1fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord1fv(const GLfloat * v) {
+ _pre_call_gl_callback("glTexCoord1fv", (GLADapiproc) glad_glTexCoord1fv, 1, v);
+ glad_glTexCoord1fv(v);
+ _post_call_gl_callback(NULL, "glTexCoord1fv", (GLADapiproc) glad_glTexCoord1fv, 1, v);
+
+}
+PFNGLTEXCOORD1FVPROC glad_debug_glTexCoord1fv = glad_debug_impl_glTexCoord1fv;
+PFNGLTEXCOORD1IPROC glad_glTexCoord1i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord1i(GLint s) {
+ _pre_call_gl_callback("glTexCoord1i", (GLADapiproc) glad_glTexCoord1i, 1, s);
+ glad_glTexCoord1i(s);
+ _post_call_gl_callback(NULL, "glTexCoord1i", (GLADapiproc) glad_glTexCoord1i, 1, s);
+
+}
+PFNGLTEXCOORD1IPROC glad_debug_glTexCoord1i = glad_debug_impl_glTexCoord1i;
+PFNGLTEXCOORD1IVPROC glad_glTexCoord1iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord1iv(const GLint * v) {
+ _pre_call_gl_callback("glTexCoord1iv", (GLADapiproc) glad_glTexCoord1iv, 1, v);
+ glad_glTexCoord1iv(v);
+ _post_call_gl_callback(NULL, "glTexCoord1iv", (GLADapiproc) glad_glTexCoord1iv, 1, v);
+
+}
+PFNGLTEXCOORD1IVPROC glad_debug_glTexCoord1iv = glad_debug_impl_glTexCoord1iv;
+PFNGLTEXCOORD1SPROC glad_glTexCoord1s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord1s(GLshort s) {
+ _pre_call_gl_callback("glTexCoord1s", (GLADapiproc) glad_glTexCoord1s, 1, s);
+ glad_glTexCoord1s(s);
+ _post_call_gl_callback(NULL, "glTexCoord1s", (GLADapiproc) glad_glTexCoord1s, 1, s);
+
+}
+PFNGLTEXCOORD1SPROC glad_debug_glTexCoord1s = glad_debug_impl_glTexCoord1s;
+PFNGLTEXCOORD1SVPROC glad_glTexCoord1sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord1sv(const GLshort * v) {
+ _pre_call_gl_callback("glTexCoord1sv", (GLADapiproc) glad_glTexCoord1sv, 1, v);
+ glad_glTexCoord1sv(v);
+ _post_call_gl_callback(NULL, "glTexCoord1sv", (GLADapiproc) glad_glTexCoord1sv, 1, v);
+
+}
+PFNGLTEXCOORD1SVPROC glad_debug_glTexCoord1sv = glad_debug_impl_glTexCoord1sv;
+PFNGLTEXCOORD2DPROC glad_glTexCoord2d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord2d(GLdouble s, GLdouble t) {
+ _pre_call_gl_callback("glTexCoord2d", (GLADapiproc) glad_glTexCoord2d, 2, s, t);
+ glad_glTexCoord2d(s, t);
+ _post_call_gl_callback(NULL, "glTexCoord2d", (GLADapiproc) glad_glTexCoord2d, 2, s, t);
+
+}
+PFNGLTEXCOORD2DPROC glad_debug_glTexCoord2d = glad_debug_impl_glTexCoord2d;
+PFNGLTEXCOORD2DVPROC glad_glTexCoord2dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord2dv(const GLdouble * v) {
+ _pre_call_gl_callback("glTexCoord2dv", (GLADapiproc) glad_glTexCoord2dv, 1, v);
+ glad_glTexCoord2dv(v);
+ _post_call_gl_callback(NULL, "glTexCoord2dv", (GLADapiproc) glad_glTexCoord2dv, 1, v);
+
+}
+PFNGLTEXCOORD2DVPROC glad_debug_glTexCoord2dv = glad_debug_impl_glTexCoord2dv;
+PFNGLTEXCOORD2FPROC glad_glTexCoord2f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord2f(GLfloat s, GLfloat t) {
+ _pre_call_gl_callback("glTexCoord2f", (GLADapiproc) glad_glTexCoord2f, 2, s, t);
+ glad_glTexCoord2f(s, t);
+ _post_call_gl_callback(NULL, "glTexCoord2f", (GLADapiproc) glad_glTexCoord2f, 2, s, t);
+
+}
+PFNGLTEXCOORD2FPROC glad_debug_glTexCoord2f = glad_debug_impl_glTexCoord2f;
+PFNGLTEXCOORD2FVPROC glad_glTexCoord2fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord2fv(const GLfloat * v) {
+ _pre_call_gl_callback("glTexCoord2fv", (GLADapiproc) glad_glTexCoord2fv, 1, v);
+ glad_glTexCoord2fv(v);
+ _post_call_gl_callback(NULL, "glTexCoord2fv", (GLADapiproc) glad_glTexCoord2fv, 1, v);
+
+}
+PFNGLTEXCOORD2FVPROC glad_debug_glTexCoord2fv = glad_debug_impl_glTexCoord2fv;
+PFNGLTEXCOORD2IPROC glad_glTexCoord2i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord2i(GLint s, GLint t) {
+ _pre_call_gl_callback("glTexCoord2i", (GLADapiproc) glad_glTexCoord2i, 2, s, t);
+ glad_glTexCoord2i(s, t);
+ _post_call_gl_callback(NULL, "glTexCoord2i", (GLADapiproc) glad_glTexCoord2i, 2, s, t);
+
+}
+PFNGLTEXCOORD2IPROC glad_debug_glTexCoord2i = glad_debug_impl_glTexCoord2i;
+PFNGLTEXCOORD2IVPROC glad_glTexCoord2iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord2iv(const GLint * v) {
+ _pre_call_gl_callback("glTexCoord2iv", (GLADapiproc) glad_glTexCoord2iv, 1, v);
+ glad_glTexCoord2iv(v);
+ _post_call_gl_callback(NULL, "glTexCoord2iv", (GLADapiproc) glad_glTexCoord2iv, 1, v);
+
+}
+PFNGLTEXCOORD2IVPROC glad_debug_glTexCoord2iv = glad_debug_impl_glTexCoord2iv;
+PFNGLTEXCOORD2SPROC glad_glTexCoord2s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord2s(GLshort s, GLshort t) {
+ _pre_call_gl_callback("glTexCoord2s", (GLADapiproc) glad_glTexCoord2s, 2, s, t);
+ glad_glTexCoord2s(s, t);
+ _post_call_gl_callback(NULL, "glTexCoord2s", (GLADapiproc) glad_glTexCoord2s, 2, s, t);
+
+}
+PFNGLTEXCOORD2SPROC glad_debug_glTexCoord2s = glad_debug_impl_glTexCoord2s;
+PFNGLTEXCOORD2SVPROC glad_glTexCoord2sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord2sv(const GLshort * v) {
+ _pre_call_gl_callback("glTexCoord2sv", (GLADapiproc) glad_glTexCoord2sv, 1, v);
+ glad_glTexCoord2sv(v);
+ _post_call_gl_callback(NULL, "glTexCoord2sv", (GLADapiproc) glad_glTexCoord2sv, 1, v);
+
+}
+PFNGLTEXCOORD2SVPROC glad_debug_glTexCoord2sv = glad_debug_impl_glTexCoord2sv;
+PFNGLTEXCOORD3DPROC glad_glTexCoord3d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord3d(GLdouble s, GLdouble t, GLdouble r) {
+ _pre_call_gl_callback("glTexCoord3d", (GLADapiproc) glad_glTexCoord3d, 3, s, t, r);
+ glad_glTexCoord3d(s, t, r);
+ _post_call_gl_callback(NULL, "glTexCoord3d", (GLADapiproc) glad_glTexCoord3d, 3, s, t, r);
+
+}
+PFNGLTEXCOORD3DPROC glad_debug_glTexCoord3d = glad_debug_impl_glTexCoord3d;
+PFNGLTEXCOORD3DVPROC glad_glTexCoord3dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord3dv(const GLdouble * v) {
+ _pre_call_gl_callback("glTexCoord3dv", (GLADapiproc) glad_glTexCoord3dv, 1, v);
+ glad_glTexCoord3dv(v);
+ _post_call_gl_callback(NULL, "glTexCoord3dv", (GLADapiproc) glad_glTexCoord3dv, 1, v);
}
-PFNGLTEXCOORD1XOESPROC glad_debug_glTexCoord1xOES = glad_debug_impl_glTexCoord1xOES;
-PFNGLTEXCOORD1XVOESPROC glad_glTexCoord1xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexCoord1xvOES(const GLfixed * coords) {
- _pre_call_gl_callback("glTexCoord1xvOES", (GLADapiproc) glad_glTexCoord1xvOES, 1, coords);
- glad_glTexCoord1xvOES(coords);
- _post_call_gl_callback(NULL, "glTexCoord1xvOES", (GLADapiproc) glad_glTexCoord1xvOES, 1, coords);
+PFNGLTEXCOORD3DVPROC glad_debug_glTexCoord3dv = glad_debug_impl_glTexCoord3dv;
+PFNGLTEXCOORD3FPROC glad_glTexCoord3f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord3f(GLfloat s, GLfloat t, GLfloat r) {
+ _pre_call_gl_callback("glTexCoord3f", (GLADapiproc) glad_glTexCoord3f, 3, s, t, r);
+ glad_glTexCoord3f(s, t, r);
+ _post_call_gl_callback(NULL, "glTexCoord3f", (GLADapiproc) glad_glTexCoord3f, 3, s, t, r);
}
-PFNGLTEXCOORD1XVOESPROC glad_debug_glTexCoord1xvOES = glad_debug_impl_glTexCoord1xvOES;
-PFNGLTEXCOORD2XOESPROC glad_glTexCoord2xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexCoord2xOES(GLfixed s, GLfixed t) {
- _pre_call_gl_callback("glTexCoord2xOES", (GLADapiproc) glad_glTexCoord2xOES, 2, s, t);
- glad_glTexCoord2xOES(s, t);
- _post_call_gl_callback(NULL, "glTexCoord2xOES", (GLADapiproc) glad_glTexCoord2xOES, 2, s, t);
+PFNGLTEXCOORD3FPROC glad_debug_glTexCoord3f = glad_debug_impl_glTexCoord3f;
+PFNGLTEXCOORD3FVPROC glad_glTexCoord3fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord3fv(const GLfloat * v) {
+ _pre_call_gl_callback("glTexCoord3fv", (GLADapiproc) glad_glTexCoord3fv, 1, v);
+ glad_glTexCoord3fv(v);
+ _post_call_gl_callback(NULL, "glTexCoord3fv", (GLADapiproc) glad_glTexCoord3fv, 1, v);
}
-PFNGLTEXCOORD2XOESPROC glad_debug_glTexCoord2xOES = glad_debug_impl_glTexCoord2xOES;
-PFNGLTEXCOORD2XVOESPROC glad_glTexCoord2xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexCoord2xvOES(const GLfixed * coords) {
- _pre_call_gl_callback("glTexCoord2xvOES", (GLADapiproc) glad_glTexCoord2xvOES, 1, coords);
- glad_glTexCoord2xvOES(coords);
- _post_call_gl_callback(NULL, "glTexCoord2xvOES", (GLADapiproc) glad_glTexCoord2xvOES, 1, coords);
+PFNGLTEXCOORD3FVPROC glad_debug_glTexCoord3fv = glad_debug_impl_glTexCoord3fv;
+PFNGLTEXCOORD3IPROC glad_glTexCoord3i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord3i(GLint s, GLint t, GLint r) {
+ _pre_call_gl_callback("glTexCoord3i", (GLADapiproc) glad_glTexCoord3i, 3, s, t, r);
+ glad_glTexCoord3i(s, t, r);
+ _post_call_gl_callback(NULL, "glTexCoord3i", (GLADapiproc) glad_glTexCoord3i, 3, s, t, r);
}
-PFNGLTEXCOORD2XVOESPROC glad_debug_glTexCoord2xvOES = glad_debug_impl_glTexCoord2xvOES;
-PFNGLTEXCOORD3XOESPROC glad_glTexCoord3xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexCoord3xOES(GLfixed s, GLfixed t, GLfixed r) {
- _pre_call_gl_callback("glTexCoord3xOES", (GLADapiproc) glad_glTexCoord3xOES, 3, s, t, r);
- glad_glTexCoord3xOES(s, t, r);
- _post_call_gl_callback(NULL, "glTexCoord3xOES", (GLADapiproc) glad_glTexCoord3xOES, 3, s, t, r);
+PFNGLTEXCOORD3IPROC glad_debug_glTexCoord3i = glad_debug_impl_glTexCoord3i;
+PFNGLTEXCOORD3IVPROC glad_glTexCoord3iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord3iv(const GLint * v) {
+ _pre_call_gl_callback("glTexCoord3iv", (GLADapiproc) glad_glTexCoord3iv, 1, v);
+ glad_glTexCoord3iv(v);
+ _post_call_gl_callback(NULL, "glTexCoord3iv", (GLADapiproc) glad_glTexCoord3iv, 1, v);
}
-PFNGLTEXCOORD3XOESPROC glad_debug_glTexCoord3xOES = glad_debug_impl_glTexCoord3xOES;
-PFNGLTEXCOORD3XVOESPROC glad_glTexCoord3xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexCoord3xvOES(const GLfixed * coords) {
- _pre_call_gl_callback("glTexCoord3xvOES", (GLADapiproc) glad_glTexCoord3xvOES, 1, coords);
- glad_glTexCoord3xvOES(coords);
- _post_call_gl_callback(NULL, "glTexCoord3xvOES", (GLADapiproc) glad_glTexCoord3xvOES, 1, coords);
+PFNGLTEXCOORD3IVPROC glad_debug_glTexCoord3iv = glad_debug_impl_glTexCoord3iv;
+PFNGLTEXCOORD3SPROC glad_glTexCoord3s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord3s(GLshort s, GLshort t, GLshort r) {
+ _pre_call_gl_callback("glTexCoord3s", (GLADapiproc) glad_glTexCoord3s, 3, s, t, r);
+ glad_glTexCoord3s(s, t, r);
+ _post_call_gl_callback(NULL, "glTexCoord3s", (GLADapiproc) glad_glTexCoord3s, 3, s, t, r);
}
-PFNGLTEXCOORD3XVOESPROC glad_debug_glTexCoord3xvOES = glad_debug_impl_glTexCoord3xvOES;
-PFNGLTEXCOORD4XOESPROC glad_glTexCoord4xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexCoord4xOES(GLfixed s, GLfixed t, GLfixed r, GLfixed q) {
- _pre_call_gl_callback("glTexCoord4xOES", (GLADapiproc) glad_glTexCoord4xOES, 4, s, t, r, q);
- glad_glTexCoord4xOES(s, t, r, q);
- _post_call_gl_callback(NULL, "glTexCoord4xOES", (GLADapiproc) glad_glTexCoord4xOES, 4, s, t, r, q);
+PFNGLTEXCOORD3SPROC glad_debug_glTexCoord3s = glad_debug_impl_glTexCoord3s;
+PFNGLTEXCOORD3SVPROC glad_glTexCoord3sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord3sv(const GLshort * v) {
+ _pre_call_gl_callback("glTexCoord3sv", (GLADapiproc) glad_glTexCoord3sv, 1, v);
+ glad_glTexCoord3sv(v);
+ _post_call_gl_callback(NULL, "glTexCoord3sv", (GLADapiproc) glad_glTexCoord3sv, 1, v);
}
-PFNGLTEXCOORD4XOESPROC glad_debug_glTexCoord4xOES = glad_debug_impl_glTexCoord4xOES;
-PFNGLTEXCOORD4XVOESPROC glad_glTexCoord4xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexCoord4xvOES(const GLfixed * coords) {
- _pre_call_gl_callback("glTexCoord4xvOES", (GLADapiproc) glad_glTexCoord4xvOES, 1, coords);
- glad_glTexCoord4xvOES(coords);
- _post_call_gl_callback(NULL, "glTexCoord4xvOES", (GLADapiproc) glad_glTexCoord4xvOES, 1, coords);
+PFNGLTEXCOORD3SVPROC glad_debug_glTexCoord3sv = glad_debug_impl_glTexCoord3sv;
+PFNGLTEXCOORD4DPROC glad_glTexCoord4d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q) {
+ _pre_call_gl_callback("glTexCoord4d", (GLADapiproc) glad_glTexCoord4d, 4, s, t, r, q);
+ glad_glTexCoord4d(s, t, r, q);
+ _post_call_gl_callback(NULL, "glTexCoord4d", (GLADapiproc) glad_glTexCoord4d, 4, s, t, r, q);
}
-PFNGLTEXCOORD4XVOESPROC glad_debug_glTexCoord4xvOES = glad_debug_impl_glTexCoord4xvOES;
-PFNGLTEXENVXOESPROC glad_glTexEnvxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexEnvxOES(GLenum target, GLenum pname, GLfixed param) {
- _pre_call_gl_callback("glTexEnvxOES", (GLADapiproc) glad_glTexEnvxOES, 3, target, pname, param);
- glad_glTexEnvxOES(target, pname, param);
- _post_call_gl_callback(NULL, "glTexEnvxOES", (GLADapiproc) glad_glTexEnvxOES, 3, target, pname, param);
+PFNGLTEXCOORD4DPROC glad_debug_glTexCoord4d = glad_debug_impl_glTexCoord4d;
+PFNGLTEXCOORD4DVPROC glad_glTexCoord4dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord4dv(const GLdouble * v) {
+ _pre_call_gl_callback("glTexCoord4dv", (GLADapiproc) glad_glTexCoord4dv, 1, v);
+ glad_glTexCoord4dv(v);
+ _post_call_gl_callback(NULL, "glTexCoord4dv", (GLADapiproc) glad_glTexCoord4dv, 1, v);
}
-PFNGLTEXENVXOESPROC glad_debug_glTexEnvxOES = glad_debug_impl_glTexEnvxOES;
-PFNGLTEXENVXVOESPROC glad_glTexEnvxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexEnvxvOES(GLenum target, GLenum pname, const GLfixed * params) {
- _pre_call_gl_callback("glTexEnvxvOES", (GLADapiproc) glad_glTexEnvxvOES, 3, target, pname, params);
- glad_glTexEnvxvOES(target, pname, params);
- _post_call_gl_callback(NULL, "glTexEnvxvOES", (GLADapiproc) glad_glTexEnvxvOES, 3, target, pname, params);
+PFNGLTEXCOORD4DVPROC glad_debug_glTexCoord4dv = glad_debug_impl_glTexCoord4dv;
+PFNGLTEXCOORD4FPROC glad_glTexCoord4f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q) {
+ _pre_call_gl_callback("glTexCoord4f", (GLADapiproc) glad_glTexCoord4f, 4, s, t, r, q);
+ glad_glTexCoord4f(s, t, r, q);
+ _post_call_gl_callback(NULL, "glTexCoord4f", (GLADapiproc) glad_glTexCoord4f, 4, s, t, r, q);
}
-PFNGLTEXENVXVOESPROC glad_debug_glTexEnvxvOES = glad_debug_impl_glTexEnvxvOES;
-PFNGLTEXGENXOESPROC glad_glTexGenxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexGenxOES(GLenum coord, GLenum pname, GLfixed param) {
- _pre_call_gl_callback("glTexGenxOES", (GLADapiproc) glad_glTexGenxOES, 3, coord, pname, param);
- glad_glTexGenxOES(coord, pname, param);
- _post_call_gl_callback(NULL, "glTexGenxOES", (GLADapiproc) glad_glTexGenxOES, 3, coord, pname, param);
+PFNGLTEXCOORD4FPROC glad_debug_glTexCoord4f = glad_debug_impl_glTexCoord4f;
+PFNGLTEXCOORD4FVPROC glad_glTexCoord4fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord4fv(const GLfloat * v) {
+ _pre_call_gl_callback("glTexCoord4fv", (GLADapiproc) glad_glTexCoord4fv, 1, v);
+ glad_glTexCoord4fv(v);
+ _post_call_gl_callback(NULL, "glTexCoord4fv", (GLADapiproc) glad_glTexCoord4fv, 1, v);
}
-PFNGLTEXGENXOESPROC glad_debug_glTexGenxOES = glad_debug_impl_glTexGenxOES;
-PFNGLTEXGENXVOESPROC glad_glTexGenxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexGenxvOES(GLenum coord, GLenum pname, const GLfixed * params) {
- _pre_call_gl_callback("glTexGenxvOES", (GLADapiproc) glad_glTexGenxvOES, 3, coord, pname, params);
- glad_glTexGenxvOES(coord, pname, params);
- _post_call_gl_callback(NULL, "glTexGenxvOES", (GLADapiproc) glad_glTexGenxvOES, 3, coord, pname, params);
+PFNGLTEXCOORD4FVPROC glad_debug_glTexCoord4fv = glad_debug_impl_glTexCoord4fv;
+PFNGLTEXCOORD4IPROC glad_glTexCoord4i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord4i(GLint s, GLint t, GLint r, GLint q) {
+ _pre_call_gl_callback("glTexCoord4i", (GLADapiproc) glad_glTexCoord4i, 4, s, t, r, q);
+ glad_glTexCoord4i(s, t, r, q);
+ _post_call_gl_callback(NULL, "glTexCoord4i", (GLADapiproc) glad_glTexCoord4i, 4, s, t, r, q);
}
-PFNGLTEXGENXVOESPROC glad_debug_glTexGenxvOES = glad_debug_impl_glTexGenxvOES;
+PFNGLTEXCOORD4IPROC glad_debug_glTexCoord4i = glad_debug_impl_glTexCoord4i;
+PFNGLTEXCOORD4IVPROC glad_glTexCoord4iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord4iv(const GLint * v) {
+ _pre_call_gl_callback("glTexCoord4iv", (GLADapiproc) glad_glTexCoord4iv, 1, v);
+ glad_glTexCoord4iv(v);
+ _post_call_gl_callback(NULL, "glTexCoord4iv", (GLADapiproc) glad_glTexCoord4iv, 1, v);
+
+}
+PFNGLTEXCOORD4IVPROC glad_debug_glTexCoord4iv = glad_debug_impl_glTexCoord4iv;
+PFNGLTEXCOORD4SPROC glad_glTexCoord4s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q) {
+ _pre_call_gl_callback("glTexCoord4s", (GLADapiproc) glad_glTexCoord4s, 4, s, t, r, q);
+ glad_glTexCoord4s(s, t, r, q);
+ _post_call_gl_callback(NULL, "glTexCoord4s", (GLADapiproc) glad_glTexCoord4s, 4, s, t, r, q);
+
+}
+PFNGLTEXCOORD4SPROC glad_debug_glTexCoord4s = glad_debug_impl_glTexCoord4s;
+PFNGLTEXCOORD4SVPROC glad_glTexCoord4sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoord4sv(const GLshort * v) {
+ _pre_call_gl_callback("glTexCoord4sv", (GLADapiproc) glad_glTexCoord4sv, 1, v);
+ glad_glTexCoord4sv(v);
+ _post_call_gl_callback(NULL, "glTexCoord4sv", (GLADapiproc) glad_glTexCoord4sv, 1, v);
+
+}
+PFNGLTEXCOORD4SVPROC glad_debug_glTexCoord4sv = glad_debug_impl_glTexCoord4sv;
+PFNGLTEXCOORDP1UIPROC glad_glTexCoordP1ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoordP1ui(GLenum type, GLuint coords) {
+ _pre_call_gl_callback("glTexCoordP1ui", (GLADapiproc) glad_glTexCoordP1ui, 2, type, coords);
+ glad_glTexCoordP1ui(type, coords);
+ _post_call_gl_callback(NULL, "glTexCoordP1ui", (GLADapiproc) glad_glTexCoordP1ui, 2, type, coords);
+
+}
+PFNGLTEXCOORDP1UIPROC glad_debug_glTexCoordP1ui = glad_debug_impl_glTexCoordP1ui;
+PFNGLTEXCOORDP1UIVPROC glad_glTexCoordP1uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoordP1uiv(GLenum type, const GLuint * coords) {
+ _pre_call_gl_callback("glTexCoordP1uiv", (GLADapiproc) glad_glTexCoordP1uiv, 2, type, coords);
+ glad_glTexCoordP1uiv(type, coords);
+ _post_call_gl_callback(NULL, "glTexCoordP1uiv", (GLADapiproc) glad_glTexCoordP1uiv, 2, type, coords);
+
+}
+PFNGLTEXCOORDP1UIVPROC glad_debug_glTexCoordP1uiv = glad_debug_impl_glTexCoordP1uiv;
+PFNGLTEXCOORDP2UIPROC glad_glTexCoordP2ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoordP2ui(GLenum type, GLuint coords) {
+ _pre_call_gl_callback("glTexCoordP2ui", (GLADapiproc) glad_glTexCoordP2ui, 2, type, coords);
+ glad_glTexCoordP2ui(type, coords);
+ _post_call_gl_callback(NULL, "glTexCoordP2ui", (GLADapiproc) glad_glTexCoordP2ui, 2, type, coords);
+
+}
+PFNGLTEXCOORDP2UIPROC glad_debug_glTexCoordP2ui = glad_debug_impl_glTexCoordP2ui;
+PFNGLTEXCOORDP2UIVPROC glad_glTexCoordP2uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoordP2uiv(GLenum type, const GLuint * coords) {
+ _pre_call_gl_callback("glTexCoordP2uiv", (GLADapiproc) glad_glTexCoordP2uiv, 2, type, coords);
+ glad_glTexCoordP2uiv(type, coords);
+ _post_call_gl_callback(NULL, "glTexCoordP2uiv", (GLADapiproc) glad_glTexCoordP2uiv, 2, type, coords);
+
+}
+PFNGLTEXCOORDP2UIVPROC glad_debug_glTexCoordP2uiv = glad_debug_impl_glTexCoordP2uiv;
+PFNGLTEXCOORDP3UIPROC glad_glTexCoordP3ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoordP3ui(GLenum type, GLuint coords) {
+ _pre_call_gl_callback("glTexCoordP3ui", (GLADapiproc) glad_glTexCoordP3ui, 2, type, coords);
+ glad_glTexCoordP3ui(type, coords);
+ _post_call_gl_callback(NULL, "glTexCoordP3ui", (GLADapiproc) glad_glTexCoordP3ui, 2, type, coords);
+
+}
+PFNGLTEXCOORDP3UIPROC glad_debug_glTexCoordP3ui = glad_debug_impl_glTexCoordP3ui;
+PFNGLTEXCOORDP3UIVPROC glad_glTexCoordP3uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoordP3uiv(GLenum type, const GLuint * coords) {
+ _pre_call_gl_callback("glTexCoordP3uiv", (GLADapiproc) glad_glTexCoordP3uiv, 2, type, coords);
+ glad_glTexCoordP3uiv(type, coords);
+ _post_call_gl_callback(NULL, "glTexCoordP3uiv", (GLADapiproc) glad_glTexCoordP3uiv, 2, type, coords);
+
+}
+PFNGLTEXCOORDP3UIVPROC glad_debug_glTexCoordP3uiv = glad_debug_impl_glTexCoordP3uiv;
+PFNGLTEXCOORDP4UIPROC glad_glTexCoordP4ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoordP4ui(GLenum type, GLuint coords) {
+ _pre_call_gl_callback("glTexCoordP4ui", (GLADapiproc) glad_glTexCoordP4ui, 2, type, coords);
+ glad_glTexCoordP4ui(type, coords);
+ _post_call_gl_callback(NULL, "glTexCoordP4ui", (GLADapiproc) glad_glTexCoordP4ui, 2, type, coords);
+
+}
+PFNGLTEXCOORDP4UIPROC glad_debug_glTexCoordP4ui = glad_debug_impl_glTexCoordP4ui;
+PFNGLTEXCOORDP4UIVPROC glad_glTexCoordP4uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoordP4uiv(GLenum type, const GLuint * coords) {
+ _pre_call_gl_callback("glTexCoordP4uiv", (GLADapiproc) glad_glTexCoordP4uiv, 2, type, coords);
+ glad_glTexCoordP4uiv(type, coords);
+ _post_call_gl_callback(NULL, "glTexCoordP4uiv", (GLADapiproc) glad_glTexCoordP4uiv, 2, type, coords);
+
+}
+PFNGLTEXCOORDP4UIVPROC glad_debug_glTexCoordP4uiv = glad_debug_impl_glTexCoordP4uiv;
+PFNGLTEXCOORDPOINTERPROC glad_glTexCoordPointer = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const void * pointer) {
+ _pre_call_gl_callback("glTexCoordPointer", (GLADapiproc) glad_glTexCoordPointer, 4, size, type, stride, pointer);
+ glad_glTexCoordPointer(size, type, stride, pointer);
+ _post_call_gl_callback(NULL, "glTexCoordPointer", (GLADapiproc) glad_glTexCoordPointer, 4, size, type, stride, pointer);
+
+}
+PFNGLTEXCOORDPOINTERPROC glad_debug_glTexCoordPointer = glad_debug_impl_glTexCoordPointer;
+PFNGLTEXENVFPROC glad_glTexEnvf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexEnvf(GLenum target, GLenum pname, GLfloat param) {
+ _pre_call_gl_callback("glTexEnvf", (GLADapiproc) glad_glTexEnvf, 3, target, pname, param);
+ glad_glTexEnvf(target, pname, param);
+ _post_call_gl_callback(NULL, "glTexEnvf", (GLADapiproc) glad_glTexEnvf, 3, target, pname, param);
+
+}
+PFNGLTEXENVFPROC glad_debug_glTexEnvf = glad_debug_impl_glTexEnvf;
+PFNGLTEXENVFVPROC glad_glTexEnvfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexEnvfv(GLenum target, GLenum pname, const GLfloat * params) {
+ _pre_call_gl_callback("glTexEnvfv", (GLADapiproc) glad_glTexEnvfv, 3, target, pname, params);
+ glad_glTexEnvfv(target, pname, params);
+ _post_call_gl_callback(NULL, "glTexEnvfv", (GLADapiproc) glad_glTexEnvfv, 3, target, pname, params);
+
+}
+PFNGLTEXENVFVPROC glad_debug_glTexEnvfv = glad_debug_impl_glTexEnvfv;
+PFNGLTEXENVIPROC glad_glTexEnvi = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexEnvi(GLenum target, GLenum pname, GLint param) {
+ _pre_call_gl_callback("glTexEnvi", (GLADapiproc) glad_glTexEnvi, 3, target, pname, param);
+ glad_glTexEnvi(target, pname, param);
+ _post_call_gl_callback(NULL, "glTexEnvi", (GLADapiproc) glad_glTexEnvi, 3, target, pname, param);
+
+}
+PFNGLTEXENVIPROC glad_debug_glTexEnvi = glad_debug_impl_glTexEnvi;
+PFNGLTEXENVIVPROC glad_glTexEnviv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexEnviv(GLenum target, GLenum pname, const GLint * params) {
+ _pre_call_gl_callback("glTexEnviv", (GLADapiproc) glad_glTexEnviv, 3, target, pname, params);
+ glad_glTexEnviv(target, pname, params);
+ _post_call_gl_callback(NULL, "glTexEnviv", (GLADapiproc) glad_glTexEnviv, 3, target, pname, params);
+
+}
+PFNGLTEXENVIVPROC glad_debug_glTexEnviv = glad_debug_impl_glTexEnviv;
+PFNGLTEXGENDPROC glad_glTexGend = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexGend(GLenum coord, GLenum pname, GLdouble param) {
+ _pre_call_gl_callback("glTexGend", (GLADapiproc) glad_glTexGend, 3, coord, pname, param);
+ glad_glTexGend(coord, pname, param);
+ _post_call_gl_callback(NULL, "glTexGend", (GLADapiproc) glad_glTexGend, 3, coord, pname, param);
+
+}
+PFNGLTEXGENDPROC glad_debug_glTexGend = glad_debug_impl_glTexGend;
+PFNGLTEXGENDVPROC glad_glTexGendv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexGendv(GLenum coord, GLenum pname, const GLdouble * params) {
+ _pre_call_gl_callback("glTexGendv", (GLADapiproc) glad_glTexGendv, 3, coord, pname, params);
+ glad_glTexGendv(coord, pname, params);
+ _post_call_gl_callback(NULL, "glTexGendv", (GLADapiproc) glad_glTexGendv, 3, coord, pname, params);
+
+}
+PFNGLTEXGENDVPROC glad_debug_glTexGendv = glad_debug_impl_glTexGendv;
+PFNGLTEXGENFPROC glad_glTexGenf = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexGenf(GLenum coord, GLenum pname, GLfloat param) {
+ _pre_call_gl_callback("glTexGenf", (GLADapiproc) glad_glTexGenf, 3, coord, pname, param);
+ glad_glTexGenf(coord, pname, param);
+ _post_call_gl_callback(NULL, "glTexGenf", (GLADapiproc) glad_glTexGenf, 3, coord, pname, param);
+
+}
+PFNGLTEXGENFPROC glad_debug_glTexGenf = glad_debug_impl_glTexGenf;
+PFNGLTEXGENFVPROC glad_glTexGenfv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexGenfv(GLenum coord, GLenum pname, const GLfloat * params) {
+ _pre_call_gl_callback("glTexGenfv", (GLADapiproc) glad_glTexGenfv, 3, coord, pname, params);
+ glad_glTexGenfv(coord, pname, params);
+ _post_call_gl_callback(NULL, "glTexGenfv", (GLADapiproc) glad_glTexGenfv, 3, coord, pname, params);
+
+}
+PFNGLTEXGENFVPROC glad_debug_glTexGenfv = glad_debug_impl_glTexGenfv;
+PFNGLTEXGENIPROC glad_glTexGeni = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexGeni(GLenum coord, GLenum pname, GLint param) {
+ _pre_call_gl_callback("glTexGeni", (GLADapiproc) glad_glTexGeni, 3, coord, pname, param);
+ glad_glTexGeni(coord, pname, param);
+ _post_call_gl_callback(NULL, "glTexGeni", (GLADapiproc) glad_glTexGeni, 3, coord, pname, param);
+
+}
+PFNGLTEXGENIPROC glad_debug_glTexGeni = glad_debug_impl_glTexGeni;
+PFNGLTEXGENIVPROC glad_glTexGeniv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTexGeniv(GLenum coord, GLenum pname, const GLint * params) {
+ _pre_call_gl_callback("glTexGeniv", (GLADapiproc) glad_glTexGeniv, 3, coord, pname, params);
+ glad_glTexGeniv(coord, pname, params);
+ _post_call_gl_callback(NULL, "glTexGeniv", (GLADapiproc) glad_glTexGeniv, 3, coord, pname, params);
+
+}
+PFNGLTEXGENIVPROC glad_debug_glTexGeniv = glad_debug_impl_glTexGeniv;
PFNGLTEXIMAGE1DPROC glad_glTexImage1D = NULL;
static void GLAD_API_PTR glad_debug_impl_glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const void * pixels) {
_pre_call_gl_callback("glTexImage1D", (GLADapiproc) glad_glTexImage1D, 8, target, level, internalformat, width, border, format, type, pixels);
@@ -6183,22 +8074,6 @@ static void GLAD_API_PTR glad_debug_impl_glTexParameteriv(GLenum target, GLenum
}
PFNGLTEXPARAMETERIVPROC glad_debug_glTexParameteriv = glad_debug_impl_glTexParameteriv;
-PFNGLTEXPARAMETERXOESPROC glad_glTexParameterxOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexParameterxOES(GLenum target, GLenum pname, GLfixed param) {
- _pre_call_gl_callback("glTexParameterxOES", (GLADapiproc) glad_glTexParameterxOES, 3, target, pname, param);
- glad_glTexParameterxOES(target, pname, param);
- _post_call_gl_callback(NULL, "glTexParameterxOES", (GLADapiproc) glad_glTexParameterxOES, 3, target, pname, param);
-
-}
-PFNGLTEXPARAMETERXOESPROC glad_debug_glTexParameterxOES = glad_debug_impl_glTexParameterxOES;
-PFNGLTEXPARAMETERXVOESPROC glad_glTexParameterxvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTexParameterxvOES(GLenum target, GLenum pname, const GLfixed * params) {
- _pre_call_gl_callback("glTexParameterxvOES", (GLADapiproc) glad_glTexParameterxvOES, 3, target, pname, params);
- glad_glTexParameterxvOES(target, pname, params);
- _post_call_gl_callback(NULL, "glTexParameterxvOES", (GLADapiproc) glad_glTexParameterxvOES, 3, target, pname, params);
-
-}
-PFNGLTEXPARAMETERXVOESPROC glad_debug_glTexParameterxvOES = glad_debug_impl_glTexParameterxvOES;
PFNGLTEXSTORAGE1DPROC glad_glTexStorage1D = NULL;
static void GLAD_API_PTR glad_debug_impl_glTexStorage1D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width) {
_pre_call_gl_callback("glTexStorage1D", (GLADapiproc) glad_glTexStorage1D, 4, target, levels, internalformat, width);
@@ -6423,14 +8298,22 @@ static void GLAD_API_PTR glad_debug_impl_glTransformFeedbackVaryings(GLuint prog
}
PFNGLTRANSFORMFEEDBACKVARYINGSPROC glad_debug_glTransformFeedbackVaryings = glad_debug_impl_glTransformFeedbackVaryings;
-PFNGLTRANSLATEXOESPROC glad_glTranslatexOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glTranslatexOES(GLfixed x, GLfixed y, GLfixed z) {
- _pre_call_gl_callback("glTranslatexOES", (GLADapiproc) glad_glTranslatexOES, 3, x, y, z);
- glad_glTranslatexOES(x, y, z);
- _post_call_gl_callback(NULL, "glTranslatexOES", (GLADapiproc) glad_glTranslatexOES, 3, x, y, z);
+PFNGLTRANSLATEDPROC glad_glTranslated = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTranslated(GLdouble x, GLdouble y, GLdouble z) {
+ _pre_call_gl_callback("glTranslated", (GLADapiproc) glad_glTranslated, 3, x, y, z);
+ glad_glTranslated(x, y, z);
+ _post_call_gl_callback(NULL, "glTranslated", (GLADapiproc) glad_glTranslated, 3, x, y, z);
+
+}
+PFNGLTRANSLATEDPROC glad_debug_glTranslated = glad_debug_impl_glTranslated;
+PFNGLTRANSLATEFPROC glad_glTranslatef = NULL;
+static void GLAD_API_PTR glad_debug_impl_glTranslatef(GLfloat x, GLfloat y, GLfloat z) {
+ _pre_call_gl_callback("glTranslatef", (GLADapiproc) glad_glTranslatef, 3, x, y, z);
+ glad_glTranslatef(x, y, z);
+ _post_call_gl_callback(NULL, "glTranslatef", (GLADapiproc) glad_glTranslatef, 3, x, y, z);
}
-PFNGLTRANSLATEXOESPROC glad_debug_glTranslatexOES = glad_debug_impl_glTranslatexOES;
+PFNGLTRANSLATEFPROC glad_debug_glTranslatef = glad_debug_impl_glTranslatef;
PFNGLUNIFORM1DPROC glad_glUniform1d = NULL;
static void GLAD_API_PTR glad_debug_impl_glUniform1d(GLint location, GLdouble x) {
_pre_call_gl_callback("glUniform1d", (GLADapiproc) glad_glUniform1d, 2, location, x);
@@ -7202,54 +9085,198 @@ static void GLAD_API_PTR glad_debug_impl_glValidateProgramPipeline(GLuint pipeli
}
PFNGLVALIDATEPROGRAMPIPELINEPROC glad_debug_glValidateProgramPipeline = glad_debug_impl_glValidateProgramPipeline;
-PFNGLVERTEX2XOESPROC glad_glVertex2xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glVertex2xOES(GLfixed x) {
- _pre_call_gl_callback("glVertex2xOES", (GLADapiproc) glad_glVertex2xOES, 1, x);
- glad_glVertex2xOES(x);
- _post_call_gl_callback(NULL, "glVertex2xOES", (GLADapiproc) glad_glVertex2xOES, 1, x);
+PFNGLVERTEX2DPROC glad_glVertex2d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex2d(GLdouble x, GLdouble y) {
+ _pre_call_gl_callback("glVertex2d", (GLADapiproc) glad_glVertex2d, 2, x, y);
+ glad_glVertex2d(x, y);
+ _post_call_gl_callback(NULL, "glVertex2d", (GLADapiproc) glad_glVertex2d, 2, x, y);
}
-PFNGLVERTEX2XOESPROC glad_debug_glVertex2xOES = glad_debug_impl_glVertex2xOES;
-PFNGLVERTEX2XVOESPROC glad_glVertex2xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glVertex2xvOES(const GLfixed * coords) {
- _pre_call_gl_callback("glVertex2xvOES", (GLADapiproc) glad_glVertex2xvOES, 1, coords);
- glad_glVertex2xvOES(coords);
- _post_call_gl_callback(NULL, "glVertex2xvOES", (GLADapiproc) glad_glVertex2xvOES, 1, coords);
+PFNGLVERTEX2DPROC glad_debug_glVertex2d = glad_debug_impl_glVertex2d;
+PFNGLVERTEX2DVPROC glad_glVertex2dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex2dv(const GLdouble * v) {
+ _pre_call_gl_callback("glVertex2dv", (GLADapiproc) glad_glVertex2dv, 1, v);
+ glad_glVertex2dv(v);
+ _post_call_gl_callback(NULL, "glVertex2dv", (GLADapiproc) glad_glVertex2dv, 1, v);
}
-PFNGLVERTEX2XVOESPROC glad_debug_glVertex2xvOES = glad_debug_impl_glVertex2xvOES;
-PFNGLVERTEX3XOESPROC glad_glVertex3xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glVertex3xOES(GLfixed x, GLfixed y) {
- _pre_call_gl_callback("glVertex3xOES", (GLADapiproc) glad_glVertex3xOES, 2, x, y);
- glad_glVertex3xOES(x, y);
- _post_call_gl_callback(NULL, "glVertex3xOES", (GLADapiproc) glad_glVertex3xOES, 2, x, y);
+PFNGLVERTEX2DVPROC glad_debug_glVertex2dv = glad_debug_impl_glVertex2dv;
+PFNGLVERTEX2FPROC glad_glVertex2f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex2f(GLfloat x, GLfloat y) {
+ _pre_call_gl_callback("glVertex2f", (GLADapiproc) glad_glVertex2f, 2, x, y);
+ glad_glVertex2f(x, y);
+ _post_call_gl_callback(NULL, "glVertex2f", (GLADapiproc) glad_glVertex2f, 2, x, y);
}
-PFNGLVERTEX3XOESPROC glad_debug_glVertex3xOES = glad_debug_impl_glVertex3xOES;
-PFNGLVERTEX3XVOESPROC glad_glVertex3xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glVertex3xvOES(const GLfixed * coords) {
- _pre_call_gl_callback("glVertex3xvOES", (GLADapiproc) glad_glVertex3xvOES, 1, coords);
- glad_glVertex3xvOES(coords);
- _post_call_gl_callback(NULL, "glVertex3xvOES", (GLADapiproc) glad_glVertex3xvOES, 1, coords);
+PFNGLVERTEX2FPROC glad_debug_glVertex2f = glad_debug_impl_glVertex2f;
+PFNGLVERTEX2FVPROC glad_glVertex2fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex2fv(const GLfloat * v) {
+ _pre_call_gl_callback("glVertex2fv", (GLADapiproc) glad_glVertex2fv, 1, v);
+ glad_glVertex2fv(v);
+ _post_call_gl_callback(NULL, "glVertex2fv", (GLADapiproc) glad_glVertex2fv, 1, v);
}
-PFNGLVERTEX3XVOESPROC glad_debug_glVertex3xvOES = glad_debug_impl_glVertex3xvOES;
-PFNGLVERTEX4XOESPROC glad_glVertex4xOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glVertex4xOES(GLfixed x, GLfixed y, GLfixed z) {
- _pre_call_gl_callback("glVertex4xOES", (GLADapiproc) glad_glVertex4xOES, 3, x, y, z);
- glad_glVertex4xOES(x, y, z);
- _post_call_gl_callback(NULL, "glVertex4xOES", (GLADapiproc) glad_glVertex4xOES, 3, x, y, z);
+PFNGLVERTEX2FVPROC glad_debug_glVertex2fv = glad_debug_impl_glVertex2fv;
+PFNGLVERTEX2IPROC glad_glVertex2i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex2i(GLint x, GLint y) {
+ _pre_call_gl_callback("glVertex2i", (GLADapiproc) glad_glVertex2i, 2, x, y);
+ glad_glVertex2i(x, y);
+ _post_call_gl_callback(NULL, "glVertex2i", (GLADapiproc) glad_glVertex2i, 2, x, y);
}
-PFNGLVERTEX4XOESPROC glad_debug_glVertex4xOES = glad_debug_impl_glVertex4xOES;
-PFNGLVERTEX4XVOESPROC glad_glVertex4xvOES = NULL;
-static void GLAD_API_PTR glad_debug_impl_glVertex4xvOES(const GLfixed * coords) {
- _pre_call_gl_callback("glVertex4xvOES", (GLADapiproc) glad_glVertex4xvOES, 1, coords);
- glad_glVertex4xvOES(coords);
- _post_call_gl_callback(NULL, "glVertex4xvOES", (GLADapiproc) glad_glVertex4xvOES, 1, coords);
+PFNGLVERTEX2IPROC glad_debug_glVertex2i = glad_debug_impl_glVertex2i;
+PFNGLVERTEX2IVPROC glad_glVertex2iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex2iv(const GLint * v) {
+ _pre_call_gl_callback("glVertex2iv", (GLADapiproc) glad_glVertex2iv, 1, v);
+ glad_glVertex2iv(v);
+ _post_call_gl_callback(NULL, "glVertex2iv", (GLADapiproc) glad_glVertex2iv, 1, v);
}
-PFNGLVERTEX4XVOESPROC glad_debug_glVertex4xvOES = glad_debug_impl_glVertex4xvOES;
+PFNGLVERTEX2IVPROC glad_debug_glVertex2iv = glad_debug_impl_glVertex2iv;
+PFNGLVERTEX2SPROC glad_glVertex2s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex2s(GLshort x, GLshort y) {
+ _pre_call_gl_callback("glVertex2s", (GLADapiproc) glad_glVertex2s, 2, x, y);
+ glad_glVertex2s(x, y);
+ _post_call_gl_callback(NULL, "glVertex2s", (GLADapiproc) glad_glVertex2s, 2, x, y);
+
+}
+PFNGLVERTEX2SPROC glad_debug_glVertex2s = glad_debug_impl_glVertex2s;
+PFNGLVERTEX2SVPROC glad_glVertex2sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex2sv(const GLshort * v) {
+ _pre_call_gl_callback("glVertex2sv", (GLADapiproc) glad_glVertex2sv, 1, v);
+ glad_glVertex2sv(v);
+ _post_call_gl_callback(NULL, "glVertex2sv", (GLADapiproc) glad_glVertex2sv, 1, v);
+
+}
+PFNGLVERTEX2SVPROC glad_debug_glVertex2sv = glad_debug_impl_glVertex2sv;
+PFNGLVERTEX3DPROC glad_glVertex3d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex3d(GLdouble x, GLdouble y, GLdouble z) {
+ _pre_call_gl_callback("glVertex3d", (GLADapiproc) glad_glVertex3d, 3, x, y, z);
+ glad_glVertex3d(x, y, z);
+ _post_call_gl_callback(NULL, "glVertex3d", (GLADapiproc) glad_glVertex3d, 3, x, y, z);
+
+}
+PFNGLVERTEX3DPROC glad_debug_glVertex3d = glad_debug_impl_glVertex3d;
+PFNGLVERTEX3DVPROC glad_glVertex3dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex3dv(const GLdouble * v) {
+ _pre_call_gl_callback("glVertex3dv", (GLADapiproc) glad_glVertex3dv, 1, v);
+ glad_glVertex3dv(v);
+ _post_call_gl_callback(NULL, "glVertex3dv", (GLADapiproc) glad_glVertex3dv, 1, v);
+
+}
+PFNGLVERTEX3DVPROC glad_debug_glVertex3dv = glad_debug_impl_glVertex3dv;
+PFNGLVERTEX3FPROC glad_glVertex3f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex3f(GLfloat x, GLfloat y, GLfloat z) {
+ _pre_call_gl_callback("glVertex3f", (GLADapiproc) glad_glVertex3f, 3, x, y, z);
+ glad_glVertex3f(x, y, z);
+ _post_call_gl_callback(NULL, "glVertex3f", (GLADapiproc) glad_glVertex3f, 3, x, y, z);
+
+}
+PFNGLVERTEX3FPROC glad_debug_glVertex3f = glad_debug_impl_glVertex3f;
+PFNGLVERTEX3FVPROC glad_glVertex3fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex3fv(const GLfloat * v) {
+ _pre_call_gl_callback("glVertex3fv", (GLADapiproc) glad_glVertex3fv, 1, v);
+ glad_glVertex3fv(v);
+ _post_call_gl_callback(NULL, "glVertex3fv", (GLADapiproc) glad_glVertex3fv, 1, v);
+
+}
+PFNGLVERTEX3FVPROC glad_debug_glVertex3fv = glad_debug_impl_glVertex3fv;
+PFNGLVERTEX3IPROC glad_glVertex3i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex3i(GLint x, GLint y, GLint z) {
+ _pre_call_gl_callback("glVertex3i", (GLADapiproc) glad_glVertex3i, 3, x, y, z);
+ glad_glVertex3i(x, y, z);
+ _post_call_gl_callback(NULL, "glVertex3i", (GLADapiproc) glad_glVertex3i, 3, x, y, z);
+
+}
+PFNGLVERTEX3IPROC glad_debug_glVertex3i = glad_debug_impl_glVertex3i;
+PFNGLVERTEX3IVPROC glad_glVertex3iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex3iv(const GLint * v) {
+ _pre_call_gl_callback("glVertex3iv", (GLADapiproc) glad_glVertex3iv, 1, v);
+ glad_glVertex3iv(v);
+ _post_call_gl_callback(NULL, "glVertex3iv", (GLADapiproc) glad_glVertex3iv, 1, v);
+
+}
+PFNGLVERTEX3IVPROC glad_debug_glVertex3iv = glad_debug_impl_glVertex3iv;
+PFNGLVERTEX3SPROC glad_glVertex3s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex3s(GLshort x, GLshort y, GLshort z) {
+ _pre_call_gl_callback("glVertex3s", (GLADapiproc) glad_glVertex3s, 3, x, y, z);
+ glad_glVertex3s(x, y, z);
+ _post_call_gl_callback(NULL, "glVertex3s", (GLADapiproc) glad_glVertex3s, 3, x, y, z);
+
+}
+PFNGLVERTEX3SPROC glad_debug_glVertex3s = glad_debug_impl_glVertex3s;
+PFNGLVERTEX3SVPROC glad_glVertex3sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex3sv(const GLshort * v) {
+ _pre_call_gl_callback("glVertex3sv", (GLADapiproc) glad_glVertex3sv, 1, v);
+ glad_glVertex3sv(v);
+ _post_call_gl_callback(NULL, "glVertex3sv", (GLADapiproc) glad_glVertex3sv, 1, v);
+
+}
+PFNGLVERTEX3SVPROC glad_debug_glVertex3sv = glad_debug_impl_glVertex3sv;
+PFNGLVERTEX4DPROC glad_glVertex4d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w) {
+ _pre_call_gl_callback("glVertex4d", (GLADapiproc) glad_glVertex4d, 4, x, y, z, w);
+ glad_glVertex4d(x, y, z, w);
+ _post_call_gl_callback(NULL, "glVertex4d", (GLADapiproc) glad_glVertex4d, 4, x, y, z, w);
+
+}
+PFNGLVERTEX4DPROC glad_debug_glVertex4d = glad_debug_impl_glVertex4d;
+PFNGLVERTEX4DVPROC glad_glVertex4dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex4dv(const GLdouble * v) {
+ _pre_call_gl_callback("glVertex4dv", (GLADapiproc) glad_glVertex4dv, 1, v);
+ glad_glVertex4dv(v);
+ _post_call_gl_callback(NULL, "glVertex4dv", (GLADapiproc) glad_glVertex4dv, 1, v);
+
+}
+PFNGLVERTEX4DVPROC glad_debug_glVertex4dv = glad_debug_impl_glVertex4dv;
+PFNGLVERTEX4FPROC glad_glVertex4f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w) {
+ _pre_call_gl_callback("glVertex4f", (GLADapiproc) glad_glVertex4f, 4, x, y, z, w);
+ glad_glVertex4f(x, y, z, w);
+ _post_call_gl_callback(NULL, "glVertex4f", (GLADapiproc) glad_glVertex4f, 4, x, y, z, w);
+
+}
+PFNGLVERTEX4FPROC glad_debug_glVertex4f = glad_debug_impl_glVertex4f;
+PFNGLVERTEX4FVPROC glad_glVertex4fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex4fv(const GLfloat * v) {
+ _pre_call_gl_callback("glVertex4fv", (GLADapiproc) glad_glVertex4fv, 1, v);
+ glad_glVertex4fv(v);
+ _post_call_gl_callback(NULL, "glVertex4fv", (GLADapiproc) glad_glVertex4fv, 1, v);
+
+}
+PFNGLVERTEX4FVPROC glad_debug_glVertex4fv = glad_debug_impl_glVertex4fv;
+PFNGLVERTEX4IPROC glad_glVertex4i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex4i(GLint x, GLint y, GLint z, GLint w) {
+ _pre_call_gl_callback("glVertex4i", (GLADapiproc) glad_glVertex4i, 4, x, y, z, w);
+ glad_glVertex4i(x, y, z, w);
+ _post_call_gl_callback(NULL, "glVertex4i", (GLADapiproc) glad_glVertex4i, 4, x, y, z, w);
+
+}
+PFNGLVERTEX4IPROC glad_debug_glVertex4i = glad_debug_impl_glVertex4i;
+PFNGLVERTEX4IVPROC glad_glVertex4iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex4iv(const GLint * v) {
+ _pre_call_gl_callback("glVertex4iv", (GLADapiproc) glad_glVertex4iv, 1, v);
+ glad_glVertex4iv(v);
+ _post_call_gl_callback(NULL, "glVertex4iv", (GLADapiproc) glad_glVertex4iv, 1, v);
+
+}
+PFNGLVERTEX4IVPROC glad_debug_glVertex4iv = glad_debug_impl_glVertex4iv;
+PFNGLVERTEX4SPROC glad_glVertex4s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w) {
+ _pre_call_gl_callback("glVertex4s", (GLADapiproc) glad_glVertex4s, 4, x, y, z, w);
+ glad_glVertex4s(x, y, z, w);
+ _post_call_gl_callback(NULL, "glVertex4s", (GLADapiproc) glad_glVertex4s, 4, x, y, z, w);
+
+}
+PFNGLVERTEX4SPROC glad_debug_glVertex4s = glad_debug_impl_glVertex4s;
+PFNGLVERTEX4SVPROC glad_glVertex4sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertex4sv(const GLshort * v) {
+ _pre_call_gl_callback("glVertex4sv", (GLADapiproc) glad_glVertex4sv, 1, v);
+ glad_glVertex4sv(v);
+ _post_call_gl_callback(NULL, "glVertex4sv", (GLADapiproc) glad_glVertex4sv, 1, v);
+
+}
+PFNGLVERTEX4SVPROC glad_debug_glVertex4sv = glad_debug_impl_glVertex4sv;
PFNGLVERTEXARRAYATTRIBBINDINGPROC glad_glVertexArrayAttribBinding = NULL;
static void GLAD_API_PTR glad_debug_impl_glVertexArrayAttribBinding(GLuint vaobj, GLuint attribindex, GLuint bindingindex) {
_pre_call_gl_callback("glVertexArrayAttribBinding", (GLADapiproc) glad_glVertexArrayAttribBinding, 3, vaobj, attribindex, bindingindex);
@@ -8266,6 +10293,62 @@ static void GLAD_API_PTR glad_debug_impl_glVertexBindingDivisor(GLuint bindingin
}
PFNGLVERTEXBINDINGDIVISORPROC glad_debug_glVertexBindingDivisor = glad_debug_impl_glVertexBindingDivisor;
+PFNGLVERTEXP2UIPROC glad_glVertexP2ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertexP2ui(GLenum type, GLuint value) {
+ _pre_call_gl_callback("glVertexP2ui", (GLADapiproc) glad_glVertexP2ui, 2, type, value);
+ glad_glVertexP2ui(type, value);
+ _post_call_gl_callback(NULL, "glVertexP2ui", (GLADapiproc) glad_glVertexP2ui, 2, type, value);
+
+}
+PFNGLVERTEXP2UIPROC glad_debug_glVertexP2ui = glad_debug_impl_glVertexP2ui;
+PFNGLVERTEXP2UIVPROC glad_glVertexP2uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertexP2uiv(GLenum type, const GLuint * value) {
+ _pre_call_gl_callback("glVertexP2uiv", (GLADapiproc) glad_glVertexP2uiv, 2, type, value);
+ glad_glVertexP2uiv(type, value);
+ _post_call_gl_callback(NULL, "glVertexP2uiv", (GLADapiproc) glad_glVertexP2uiv, 2, type, value);
+
+}
+PFNGLVERTEXP2UIVPROC glad_debug_glVertexP2uiv = glad_debug_impl_glVertexP2uiv;
+PFNGLVERTEXP3UIPROC glad_glVertexP3ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertexP3ui(GLenum type, GLuint value) {
+ _pre_call_gl_callback("glVertexP3ui", (GLADapiproc) glad_glVertexP3ui, 2, type, value);
+ glad_glVertexP3ui(type, value);
+ _post_call_gl_callback(NULL, "glVertexP3ui", (GLADapiproc) glad_glVertexP3ui, 2, type, value);
+
+}
+PFNGLVERTEXP3UIPROC glad_debug_glVertexP3ui = glad_debug_impl_glVertexP3ui;
+PFNGLVERTEXP3UIVPROC glad_glVertexP3uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertexP3uiv(GLenum type, const GLuint * value) {
+ _pre_call_gl_callback("glVertexP3uiv", (GLADapiproc) glad_glVertexP3uiv, 2, type, value);
+ glad_glVertexP3uiv(type, value);
+ _post_call_gl_callback(NULL, "glVertexP3uiv", (GLADapiproc) glad_glVertexP3uiv, 2, type, value);
+
+}
+PFNGLVERTEXP3UIVPROC glad_debug_glVertexP3uiv = glad_debug_impl_glVertexP3uiv;
+PFNGLVERTEXP4UIPROC glad_glVertexP4ui = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertexP4ui(GLenum type, GLuint value) {
+ _pre_call_gl_callback("glVertexP4ui", (GLADapiproc) glad_glVertexP4ui, 2, type, value);
+ glad_glVertexP4ui(type, value);
+ _post_call_gl_callback(NULL, "glVertexP4ui", (GLADapiproc) glad_glVertexP4ui, 2, type, value);
+
+}
+PFNGLVERTEXP4UIPROC glad_debug_glVertexP4ui = glad_debug_impl_glVertexP4ui;
+PFNGLVERTEXP4UIVPROC glad_glVertexP4uiv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertexP4uiv(GLenum type, const GLuint * value) {
+ _pre_call_gl_callback("glVertexP4uiv", (GLADapiproc) glad_glVertexP4uiv, 2, type, value);
+ glad_glVertexP4uiv(type, value);
+ _post_call_gl_callback(NULL, "glVertexP4uiv", (GLADapiproc) glad_glVertexP4uiv, 2, type, value);
+
+}
+PFNGLVERTEXP4UIVPROC glad_debug_glVertexP4uiv = glad_debug_impl_glVertexP4uiv;
+PFNGLVERTEXPOINTERPROC glad_glVertexPointer = NULL;
+static void GLAD_API_PTR glad_debug_impl_glVertexPointer(GLint size, GLenum type, GLsizei stride, const void * pointer) {
+ _pre_call_gl_callback("glVertexPointer", (GLADapiproc) glad_glVertexPointer, 4, size, type, stride, pointer);
+ glad_glVertexPointer(size, type, stride, pointer);
+ _post_call_gl_callback(NULL, "glVertexPointer", (GLADapiproc) glad_glVertexPointer, 4, size, type, stride, pointer);
+
+}
+PFNGLVERTEXPOINTERPROC glad_debug_glVertexPointer = glad_debug_impl_glVertexPointer;
PFNGLVIEWPORTPROC glad_glViewport = NULL;
static void GLAD_API_PTR glad_debug_impl_glViewport(GLint x, GLint y, GLsizei width, GLsizei height) {
_pre_call_gl_callback("glViewport", (GLADapiproc) glad_glViewport, 4, x, y, width, height);
@@ -8306,75 +10389,477 @@ static void GLAD_API_PTR glad_debug_impl_glWaitSync(GLsync sync, GLbitfield flag
}
PFNGLWAITSYNCPROC glad_debug_glWaitSync = glad_debug_impl_glWaitSync;
+PFNGLWINDOWPOS2DPROC glad_glWindowPos2d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos2d(GLdouble x, GLdouble y) {
+ _pre_call_gl_callback("glWindowPos2d", (GLADapiproc) glad_glWindowPos2d, 2, x, y);
+ glad_glWindowPos2d(x, y);
+ _post_call_gl_callback(NULL, "glWindowPos2d", (GLADapiproc) glad_glWindowPos2d, 2, x, y);
+
+}
+PFNGLWINDOWPOS2DPROC glad_debug_glWindowPos2d = glad_debug_impl_glWindowPos2d;
+PFNGLWINDOWPOS2DVPROC glad_glWindowPos2dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos2dv(const GLdouble * v) {
+ _pre_call_gl_callback("glWindowPos2dv", (GLADapiproc) glad_glWindowPos2dv, 1, v);
+ glad_glWindowPos2dv(v);
+ _post_call_gl_callback(NULL, "glWindowPos2dv", (GLADapiproc) glad_glWindowPos2dv, 1, v);
+
+}
+PFNGLWINDOWPOS2DVPROC glad_debug_glWindowPos2dv = glad_debug_impl_glWindowPos2dv;
+PFNGLWINDOWPOS2FPROC glad_glWindowPos2f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos2f(GLfloat x, GLfloat y) {
+ _pre_call_gl_callback("glWindowPos2f", (GLADapiproc) glad_glWindowPos2f, 2, x, y);
+ glad_glWindowPos2f(x, y);
+ _post_call_gl_callback(NULL, "glWindowPos2f", (GLADapiproc) glad_glWindowPos2f, 2, x, y);
+
+}
+PFNGLWINDOWPOS2FPROC glad_debug_glWindowPos2f = glad_debug_impl_glWindowPos2f;
+PFNGLWINDOWPOS2FVPROC glad_glWindowPos2fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos2fv(const GLfloat * v) {
+ _pre_call_gl_callback("glWindowPos2fv", (GLADapiproc) glad_glWindowPos2fv, 1, v);
+ glad_glWindowPos2fv(v);
+ _post_call_gl_callback(NULL, "glWindowPos2fv", (GLADapiproc) glad_glWindowPos2fv, 1, v);
+
+}
+PFNGLWINDOWPOS2FVPROC glad_debug_glWindowPos2fv = glad_debug_impl_glWindowPos2fv;
+PFNGLWINDOWPOS2IPROC glad_glWindowPos2i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos2i(GLint x, GLint y) {
+ _pre_call_gl_callback("glWindowPos2i", (GLADapiproc) glad_glWindowPos2i, 2, x, y);
+ glad_glWindowPos2i(x, y);
+ _post_call_gl_callback(NULL, "glWindowPos2i", (GLADapiproc) glad_glWindowPos2i, 2, x, y);
+
+}
+PFNGLWINDOWPOS2IPROC glad_debug_glWindowPos2i = glad_debug_impl_glWindowPos2i;
+PFNGLWINDOWPOS2IVPROC glad_glWindowPos2iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos2iv(const GLint * v) {
+ _pre_call_gl_callback("glWindowPos2iv", (GLADapiproc) glad_glWindowPos2iv, 1, v);
+ glad_glWindowPos2iv(v);
+ _post_call_gl_callback(NULL, "glWindowPos2iv", (GLADapiproc) glad_glWindowPos2iv, 1, v);
+
+}
+PFNGLWINDOWPOS2IVPROC glad_debug_glWindowPos2iv = glad_debug_impl_glWindowPos2iv;
+PFNGLWINDOWPOS2SPROC glad_glWindowPos2s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos2s(GLshort x, GLshort y) {
+ _pre_call_gl_callback("glWindowPos2s", (GLADapiproc) glad_glWindowPos2s, 2, x, y);
+ glad_glWindowPos2s(x, y);
+ _post_call_gl_callback(NULL, "glWindowPos2s", (GLADapiproc) glad_glWindowPos2s, 2, x, y);
+
+}
+PFNGLWINDOWPOS2SPROC glad_debug_glWindowPos2s = glad_debug_impl_glWindowPos2s;
+PFNGLWINDOWPOS2SVPROC glad_glWindowPos2sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos2sv(const GLshort * v) {
+ _pre_call_gl_callback("glWindowPos2sv", (GLADapiproc) glad_glWindowPos2sv, 1, v);
+ glad_glWindowPos2sv(v);
+ _post_call_gl_callback(NULL, "glWindowPos2sv", (GLADapiproc) glad_glWindowPos2sv, 1, v);
+
+}
+PFNGLWINDOWPOS2SVPROC glad_debug_glWindowPos2sv = glad_debug_impl_glWindowPos2sv;
+PFNGLWINDOWPOS3DPROC glad_glWindowPos3d = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos3d(GLdouble x, GLdouble y, GLdouble z) {
+ _pre_call_gl_callback("glWindowPos3d", (GLADapiproc) glad_glWindowPos3d, 3, x, y, z);
+ glad_glWindowPos3d(x, y, z);
+ _post_call_gl_callback(NULL, "glWindowPos3d", (GLADapiproc) glad_glWindowPos3d, 3, x, y, z);
+
+}
+PFNGLWINDOWPOS3DPROC glad_debug_glWindowPos3d = glad_debug_impl_glWindowPos3d;
+PFNGLWINDOWPOS3DVPROC glad_glWindowPos3dv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos3dv(const GLdouble * v) {
+ _pre_call_gl_callback("glWindowPos3dv", (GLADapiproc) glad_glWindowPos3dv, 1, v);
+ glad_glWindowPos3dv(v);
+ _post_call_gl_callback(NULL, "glWindowPos3dv", (GLADapiproc) glad_glWindowPos3dv, 1, v);
+
+}
+PFNGLWINDOWPOS3DVPROC glad_debug_glWindowPos3dv = glad_debug_impl_glWindowPos3dv;
+PFNGLWINDOWPOS3FPROC glad_glWindowPos3f = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos3f(GLfloat x, GLfloat y, GLfloat z) {
+ _pre_call_gl_callback("glWindowPos3f", (GLADapiproc) glad_glWindowPos3f, 3, x, y, z);
+ glad_glWindowPos3f(x, y, z);
+ _post_call_gl_callback(NULL, "glWindowPos3f", (GLADapiproc) glad_glWindowPos3f, 3, x, y, z);
+
+}
+PFNGLWINDOWPOS3FPROC glad_debug_glWindowPos3f = glad_debug_impl_glWindowPos3f;
+PFNGLWINDOWPOS3FVPROC glad_glWindowPos3fv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos3fv(const GLfloat * v) {
+ _pre_call_gl_callback("glWindowPos3fv", (GLADapiproc) glad_glWindowPos3fv, 1, v);
+ glad_glWindowPos3fv(v);
+ _post_call_gl_callback(NULL, "glWindowPos3fv", (GLADapiproc) glad_glWindowPos3fv, 1, v);
+
+}
+PFNGLWINDOWPOS3FVPROC glad_debug_glWindowPos3fv = glad_debug_impl_glWindowPos3fv;
+PFNGLWINDOWPOS3IPROC glad_glWindowPos3i = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos3i(GLint x, GLint y, GLint z) {
+ _pre_call_gl_callback("glWindowPos3i", (GLADapiproc) glad_glWindowPos3i, 3, x, y, z);
+ glad_glWindowPos3i(x, y, z);
+ _post_call_gl_callback(NULL, "glWindowPos3i", (GLADapiproc) glad_glWindowPos3i, 3, x, y, z);
+
+}
+PFNGLWINDOWPOS3IPROC glad_debug_glWindowPos3i = glad_debug_impl_glWindowPos3i;
+PFNGLWINDOWPOS3IVPROC glad_glWindowPos3iv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos3iv(const GLint * v) {
+ _pre_call_gl_callback("glWindowPos3iv", (GLADapiproc) glad_glWindowPos3iv, 1, v);
+ glad_glWindowPos3iv(v);
+ _post_call_gl_callback(NULL, "glWindowPos3iv", (GLADapiproc) glad_glWindowPos3iv, 1, v);
+
+}
+PFNGLWINDOWPOS3IVPROC glad_debug_glWindowPos3iv = glad_debug_impl_glWindowPos3iv;
+PFNGLWINDOWPOS3SPROC glad_glWindowPos3s = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos3s(GLshort x, GLshort y, GLshort z) {
+ _pre_call_gl_callback("glWindowPos3s", (GLADapiproc) glad_glWindowPos3s, 3, x, y, z);
+ glad_glWindowPos3s(x, y, z);
+ _post_call_gl_callback(NULL, "glWindowPos3s", (GLADapiproc) glad_glWindowPos3s, 3, x, y, z);
+
+}
+PFNGLWINDOWPOS3SPROC glad_debug_glWindowPos3s = glad_debug_impl_glWindowPos3s;
+PFNGLWINDOWPOS3SVPROC glad_glWindowPos3sv = NULL;
+static void GLAD_API_PTR glad_debug_impl_glWindowPos3sv(const GLshort * v) {
+ _pre_call_gl_callback("glWindowPos3sv", (GLADapiproc) glad_glWindowPos3sv, 1, v);
+ glad_glWindowPos3sv(v);
+ _post_call_gl_callback(NULL, "glWindowPos3sv", (GLADapiproc) glad_glWindowPos3sv, 1, v);
+
+}
+PFNGLWINDOWPOS3SVPROC glad_debug_glWindowPos3sv = glad_debug_impl_glWindowPos3sv;
static void glad_gl_load_GL_VERSION_1_0( GLADuserptrloadfunc load, void* userptr) {
if(!GLAD_GL_VERSION_1_0) return;
+ glad_glAccum = (PFNGLACCUMPROC) load(userptr, "glAccum");
+ glad_glAlphaFunc = (PFNGLALPHAFUNCPROC) load(userptr, "glAlphaFunc");
+ glad_glBegin = (PFNGLBEGINPROC) load(userptr, "glBegin");
+ glad_glBitmap = (PFNGLBITMAPPROC) load(userptr, "glBitmap");
glad_glBlendFunc = (PFNGLBLENDFUNCPROC) load(userptr, "glBlendFunc");
+ glad_glCallList = (PFNGLCALLLISTPROC) load(userptr, "glCallList");
+ glad_glCallLists = (PFNGLCALLLISTSPROC) load(userptr, "glCallLists");
glad_glClear = (PFNGLCLEARPROC) load(userptr, "glClear");
+ glad_glClearAccum = (PFNGLCLEARACCUMPROC) load(userptr, "glClearAccum");
glad_glClearColor = (PFNGLCLEARCOLORPROC) load(userptr, "glClearColor");
glad_glClearDepth = (PFNGLCLEARDEPTHPROC) load(userptr, "glClearDepth");
+ glad_glClearIndex = (PFNGLCLEARINDEXPROC) load(userptr, "glClearIndex");
glad_glClearStencil = (PFNGLCLEARSTENCILPROC) load(userptr, "glClearStencil");
+ glad_glClipPlane = (PFNGLCLIPPLANEPROC) load(userptr, "glClipPlane");
+ glad_glColor3b = (PFNGLCOLOR3BPROC) load(userptr, "glColor3b");
+ glad_glColor3bv = (PFNGLCOLOR3BVPROC) load(userptr, "glColor3bv");
+ glad_glColor3d = (PFNGLCOLOR3DPROC) load(userptr, "glColor3d");
+ glad_glColor3dv = (PFNGLCOLOR3DVPROC) load(userptr, "glColor3dv");
+ glad_glColor3f = (PFNGLCOLOR3FPROC) load(userptr, "glColor3f");
+ glad_glColor3fv = (PFNGLCOLOR3FVPROC) load(userptr, "glColor3fv");
+ glad_glColor3i = (PFNGLCOLOR3IPROC) load(userptr, "glColor3i");
+ glad_glColor3iv = (PFNGLCOLOR3IVPROC) load(userptr, "glColor3iv");
+ glad_glColor3s = (PFNGLCOLOR3SPROC) load(userptr, "glColor3s");
+ glad_glColor3sv = (PFNGLCOLOR3SVPROC) load(userptr, "glColor3sv");
+ glad_glColor3ub = (PFNGLCOLOR3UBPROC) load(userptr, "glColor3ub");
+ glad_glColor3ubv = (PFNGLCOLOR3UBVPROC) load(userptr, "glColor3ubv");
+ glad_glColor3ui = (PFNGLCOLOR3UIPROC) load(userptr, "glColor3ui");
+ glad_glColor3uiv = (PFNGLCOLOR3UIVPROC) load(userptr, "glColor3uiv");
+ glad_glColor3us = (PFNGLCOLOR3USPROC) load(userptr, "glColor3us");
+ glad_glColor3usv = (PFNGLCOLOR3USVPROC) load(userptr, "glColor3usv");
+ glad_glColor4b = (PFNGLCOLOR4BPROC) load(userptr, "glColor4b");
+ glad_glColor4bv = (PFNGLCOLOR4BVPROC) load(userptr, "glColor4bv");
+ glad_glColor4d = (PFNGLCOLOR4DPROC) load(userptr, "glColor4d");
+ glad_glColor4dv = (PFNGLCOLOR4DVPROC) load(userptr, "glColor4dv");
+ glad_glColor4f = (PFNGLCOLOR4FPROC) load(userptr, "glColor4f");
+ glad_glColor4fv = (PFNGLCOLOR4FVPROC) load(userptr, "glColor4fv");
+ glad_glColor4i = (PFNGLCOLOR4IPROC) load(userptr, "glColor4i");
+ glad_glColor4iv = (PFNGLCOLOR4IVPROC) load(userptr, "glColor4iv");
+ glad_glColor4s = (PFNGLCOLOR4SPROC) load(userptr, "glColor4s");
+ glad_glColor4sv = (PFNGLCOLOR4SVPROC) load(userptr, "glColor4sv");
+ glad_glColor4ub = (PFNGLCOLOR4UBPROC) load(userptr, "glColor4ub");
+ glad_glColor4ubv = (PFNGLCOLOR4UBVPROC) load(userptr, "glColor4ubv");
+ glad_glColor4ui = (PFNGLCOLOR4UIPROC) load(userptr, "glColor4ui");
+ glad_glColor4uiv = (PFNGLCOLOR4UIVPROC) load(userptr, "glColor4uiv");
+ glad_glColor4us = (PFNGLCOLOR4USPROC) load(userptr, "glColor4us");
+ glad_glColor4usv = (PFNGLCOLOR4USVPROC) load(userptr, "glColor4usv");
glad_glColorMask = (PFNGLCOLORMASKPROC) load(userptr, "glColorMask");
+ glad_glColorMaterial = (PFNGLCOLORMATERIALPROC) load(userptr, "glColorMaterial");
+ glad_glCopyPixels = (PFNGLCOPYPIXELSPROC) load(userptr, "glCopyPixels");
glad_glCullFace = (PFNGLCULLFACEPROC) load(userptr, "glCullFace");
+ glad_glDeleteLists = (PFNGLDELETELISTSPROC) load(userptr, "glDeleteLists");
glad_glDepthFunc = (PFNGLDEPTHFUNCPROC) load(userptr, "glDepthFunc");
glad_glDepthMask = (PFNGLDEPTHMASKPROC) load(userptr, "glDepthMask");
glad_glDepthRange = (PFNGLDEPTHRANGEPROC) load(userptr, "glDepthRange");
glad_glDisable = (PFNGLDISABLEPROC) load(userptr, "glDisable");
glad_glDrawBuffer = (PFNGLDRAWBUFFERPROC) load(userptr, "glDrawBuffer");
+ glad_glDrawPixels = (PFNGLDRAWPIXELSPROC) load(userptr, "glDrawPixels");
+ glad_glEdgeFlag = (PFNGLEDGEFLAGPROC) load(userptr, "glEdgeFlag");
+ glad_glEdgeFlagv = (PFNGLEDGEFLAGVPROC) load(userptr, "glEdgeFlagv");
glad_glEnable = (PFNGLENABLEPROC) load(userptr, "glEnable");
+ glad_glEnd = (PFNGLENDPROC) load(userptr, "glEnd");
+ glad_glEndList = (PFNGLENDLISTPROC) load(userptr, "glEndList");
+ glad_glEvalCoord1d = (PFNGLEVALCOORD1DPROC) load(userptr, "glEvalCoord1d");
+ glad_glEvalCoord1dv = (PFNGLEVALCOORD1DVPROC) load(userptr, "glEvalCoord1dv");
+ glad_glEvalCoord1f = (PFNGLEVALCOORD1FPROC) load(userptr, "glEvalCoord1f");
+ glad_glEvalCoord1fv = (PFNGLEVALCOORD1FVPROC) load(userptr, "glEvalCoord1fv");
+ glad_glEvalCoord2d = (PFNGLEVALCOORD2DPROC) load(userptr, "glEvalCoord2d");
+ glad_glEvalCoord2dv = (PFNGLEVALCOORD2DVPROC) load(userptr, "glEvalCoord2dv");
+ glad_glEvalCoord2f = (PFNGLEVALCOORD2FPROC) load(userptr, "glEvalCoord2f");
+ glad_glEvalCoord2fv = (PFNGLEVALCOORD2FVPROC) load(userptr, "glEvalCoord2fv");
+ glad_glEvalMesh1 = (PFNGLEVALMESH1PROC) load(userptr, "glEvalMesh1");
+ glad_glEvalMesh2 = (PFNGLEVALMESH2PROC) load(userptr, "glEvalMesh2");
+ glad_glEvalPoint1 = (PFNGLEVALPOINT1PROC) load(userptr, "glEvalPoint1");
+ glad_glEvalPoint2 = (PFNGLEVALPOINT2PROC) load(userptr, "glEvalPoint2");
+ glad_glFeedbackBuffer = (PFNGLFEEDBACKBUFFERPROC) load(userptr, "glFeedbackBuffer");
glad_glFinish = (PFNGLFINISHPROC) load(userptr, "glFinish");
glad_glFlush = (PFNGLFLUSHPROC) load(userptr, "glFlush");
+ glad_glFogf = (PFNGLFOGFPROC) load(userptr, "glFogf");
+ glad_glFogfv = (PFNGLFOGFVPROC) load(userptr, "glFogfv");
+ glad_glFogi = (PFNGLFOGIPROC) load(userptr, "glFogi");
+ glad_glFogiv = (PFNGLFOGIVPROC) load(userptr, "glFogiv");
glad_glFrontFace = (PFNGLFRONTFACEPROC) load(userptr, "glFrontFace");
+ glad_glFrustum = (PFNGLFRUSTUMPROC) load(userptr, "glFrustum");
+ glad_glGenLists = (PFNGLGENLISTSPROC) load(userptr, "glGenLists");
glad_glGetBooleanv = (PFNGLGETBOOLEANVPROC) load(userptr, "glGetBooleanv");
+ glad_glGetClipPlane = (PFNGLGETCLIPPLANEPROC) load(userptr, "glGetClipPlane");
glad_glGetDoublev = (PFNGLGETDOUBLEVPROC) load(userptr, "glGetDoublev");
glad_glGetError = (PFNGLGETERRORPROC) load(userptr, "glGetError");
glad_glGetFloatv = (PFNGLGETFLOATVPROC) load(userptr, "glGetFloatv");
glad_glGetIntegerv = (PFNGLGETINTEGERVPROC) load(userptr, "glGetIntegerv");
+ glad_glGetLightfv = (PFNGLGETLIGHTFVPROC) load(userptr, "glGetLightfv");
+ glad_glGetLightiv = (PFNGLGETLIGHTIVPROC) load(userptr, "glGetLightiv");
+ glad_glGetMapdv = (PFNGLGETMAPDVPROC) load(userptr, "glGetMapdv");
+ glad_glGetMapfv = (PFNGLGETMAPFVPROC) load(userptr, "glGetMapfv");
+ glad_glGetMapiv = (PFNGLGETMAPIVPROC) load(userptr, "glGetMapiv");
+ glad_glGetMaterialfv = (PFNGLGETMATERIALFVPROC) load(userptr, "glGetMaterialfv");
+ glad_glGetMaterialiv = (PFNGLGETMATERIALIVPROC) load(userptr, "glGetMaterialiv");
+ glad_glGetPixelMapfv = (PFNGLGETPIXELMAPFVPROC) load(userptr, "glGetPixelMapfv");
+ glad_glGetPixelMapuiv = (PFNGLGETPIXELMAPUIVPROC) load(userptr, "glGetPixelMapuiv");
+ glad_glGetPixelMapusv = (PFNGLGETPIXELMAPUSVPROC) load(userptr, "glGetPixelMapusv");
+ glad_glGetPolygonStipple = (PFNGLGETPOLYGONSTIPPLEPROC) load(userptr, "glGetPolygonStipple");
glad_glGetString = (PFNGLGETSTRINGPROC) load(userptr, "glGetString");
+ glad_glGetTexEnvfv = (PFNGLGETTEXENVFVPROC) load(userptr, "glGetTexEnvfv");
+ glad_glGetTexEnviv = (PFNGLGETTEXENVIVPROC) load(userptr, "glGetTexEnviv");
+ glad_glGetTexGendv = (PFNGLGETTEXGENDVPROC) load(userptr, "glGetTexGendv");
+ glad_glGetTexGenfv = (PFNGLGETTEXGENFVPROC) load(userptr, "glGetTexGenfv");
+ glad_glGetTexGeniv = (PFNGLGETTEXGENIVPROC) load(userptr, "glGetTexGeniv");
glad_glGetTexImage = (PFNGLGETTEXIMAGEPROC) load(userptr, "glGetTexImage");
glad_glGetTexLevelParameterfv = (PFNGLGETTEXLEVELPARAMETERFVPROC) load(userptr, "glGetTexLevelParameterfv");
glad_glGetTexLevelParameteriv = (PFNGLGETTEXLEVELPARAMETERIVPROC) load(userptr, "glGetTexLevelParameteriv");
glad_glGetTexParameterfv = (PFNGLGETTEXPARAMETERFVPROC) load(userptr, "glGetTexParameterfv");
glad_glGetTexParameteriv = (PFNGLGETTEXPARAMETERIVPROC) load(userptr, "glGetTexParameteriv");
glad_glHint = (PFNGLHINTPROC) load(userptr, "glHint");
+ glad_glIndexMask = (PFNGLINDEXMASKPROC) load(userptr, "glIndexMask");
+ glad_glIndexd = (PFNGLINDEXDPROC) load(userptr, "glIndexd");
+ glad_glIndexdv = (PFNGLINDEXDVPROC) load(userptr, "glIndexdv");
+ glad_glIndexf = (PFNGLINDEXFPROC) load(userptr, "glIndexf");
+ glad_glIndexfv = (PFNGLINDEXFVPROC) load(userptr, "glIndexfv");
+ glad_glIndexi = (PFNGLINDEXIPROC) load(userptr, "glIndexi");
+ glad_glIndexiv = (PFNGLINDEXIVPROC) load(userptr, "glIndexiv");
+ glad_glIndexs = (PFNGLINDEXSPROC) load(userptr, "glIndexs");
+ glad_glIndexsv = (PFNGLINDEXSVPROC) load(userptr, "glIndexsv");
+ glad_glInitNames = (PFNGLINITNAMESPROC) load(userptr, "glInitNames");
glad_glIsEnabled = (PFNGLISENABLEDPROC) load(userptr, "glIsEnabled");
+ glad_glIsList = (PFNGLISLISTPROC) load(userptr, "glIsList");
+ glad_glLightModelf = (PFNGLLIGHTMODELFPROC) load(userptr, "glLightModelf");
+ glad_glLightModelfv = (PFNGLLIGHTMODELFVPROC) load(userptr, "glLightModelfv");
+ glad_glLightModeli = (PFNGLLIGHTMODELIPROC) load(userptr, "glLightModeli");
+ glad_glLightModeliv = (PFNGLLIGHTMODELIVPROC) load(userptr, "glLightModeliv");
+ glad_glLightf = (PFNGLLIGHTFPROC) load(userptr, "glLightf");
+ glad_glLightfv = (PFNGLLIGHTFVPROC) load(userptr, "glLightfv");
+ glad_glLighti = (PFNGLLIGHTIPROC) load(userptr, "glLighti");
+ glad_glLightiv = (PFNGLLIGHTIVPROC) load(userptr, "glLightiv");
+ glad_glLineStipple = (PFNGLLINESTIPPLEPROC) load(userptr, "glLineStipple");
glad_glLineWidth = (PFNGLLINEWIDTHPROC) load(userptr, "glLineWidth");
+ glad_glListBase = (PFNGLLISTBASEPROC) load(userptr, "glListBase");
+ glad_glLoadIdentity = (PFNGLLOADIDENTITYPROC) load(userptr, "glLoadIdentity");
+ glad_glLoadMatrixd = (PFNGLLOADMATRIXDPROC) load(userptr, "glLoadMatrixd");
+ glad_glLoadMatrixf = (PFNGLLOADMATRIXFPROC) load(userptr, "glLoadMatrixf");
+ glad_glLoadName = (PFNGLLOADNAMEPROC) load(userptr, "glLoadName");
glad_glLogicOp = (PFNGLLOGICOPPROC) load(userptr, "glLogicOp");
+ glad_glMap1d = (PFNGLMAP1DPROC) load(userptr, "glMap1d");
+ glad_glMap1f = (PFNGLMAP1FPROC) load(userptr, "glMap1f");
+ glad_glMap2d = (PFNGLMAP2DPROC) load(userptr, "glMap2d");
+ glad_glMap2f = (PFNGLMAP2FPROC) load(userptr, "glMap2f");
+ glad_glMapGrid1d = (PFNGLMAPGRID1DPROC) load(userptr, "glMapGrid1d");
+ glad_glMapGrid1f = (PFNGLMAPGRID1FPROC) load(userptr, "glMapGrid1f");
+ glad_glMapGrid2d = (PFNGLMAPGRID2DPROC) load(userptr, "glMapGrid2d");
+ glad_glMapGrid2f = (PFNGLMAPGRID2FPROC) load(userptr, "glMapGrid2f");
+ glad_glMaterialf = (PFNGLMATERIALFPROC) load(userptr, "glMaterialf");
+ glad_glMaterialfv = (PFNGLMATERIALFVPROC) load(userptr, "glMaterialfv");
+ glad_glMateriali = (PFNGLMATERIALIPROC) load(userptr, "glMateriali");
+ glad_glMaterialiv = (PFNGLMATERIALIVPROC) load(userptr, "glMaterialiv");
+ glad_glMatrixMode = (PFNGLMATRIXMODEPROC) load(userptr, "glMatrixMode");
+ glad_glMultMatrixd = (PFNGLMULTMATRIXDPROC) load(userptr, "glMultMatrixd");
+ glad_glMultMatrixf = (PFNGLMULTMATRIXFPROC) load(userptr, "glMultMatrixf");
+ glad_glNewList = (PFNGLNEWLISTPROC) load(userptr, "glNewList");
+ glad_glNormal3b = (PFNGLNORMAL3BPROC) load(userptr, "glNormal3b");
+ glad_glNormal3bv = (PFNGLNORMAL3BVPROC) load(userptr, "glNormal3bv");
+ glad_glNormal3d = (PFNGLNORMAL3DPROC) load(userptr, "glNormal3d");
+ glad_glNormal3dv = (PFNGLNORMAL3DVPROC) load(userptr, "glNormal3dv");
+ glad_glNormal3f = (PFNGLNORMAL3FPROC) load(userptr, "glNormal3f");
+ glad_glNormal3fv = (PFNGLNORMAL3FVPROC) load(userptr, "glNormal3fv");
+ glad_glNormal3i = (PFNGLNORMAL3IPROC) load(userptr, "glNormal3i");
+ glad_glNormal3iv = (PFNGLNORMAL3IVPROC) load(userptr, "glNormal3iv");
+ glad_glNormal3s = (PFNGLNORMAL3SPROC) load(userptr, "glNormal3s");
+ glad_glNormal3sv = (PFNGLNORMAL3SVPROC) load(userptr, "glNormal3sv");
+ glad_glOrtho = (PFNGLORTHOPROC) load(userptr, "glOrtho");
+ glad_glPassThrough = (PFNGLPASSTHROUGHPROC) load(userptr, "glPassThrough");
+ glad_glPixelMapfv = (PFNGLPIXELMAPFVPROC) load(userptr, "glPixelMapfv");
+ glad_glPixelMapuiv = (PFNGLPIXELMAPUIVPROC) load(userptr, "glPixelMapuiv");
+ glad_glPixelMapusv = (PFNGLPIXELMAPUSVPROC) load(userptr, "glPixelMapusv");
glad_glPixelStoref = (PFNGLPIXELSTOREFPROC) load(userptr, "glPixelStoref");
glad_glPixelStorei = (PFNGLPIXELSTOREIPROC) load(userptr, "glPixelStorei");
+ glad_glPixelTransferf = (PFNGLPIXELTRANSFERFPROC) load(userptr, "glPixelTransferf");
+ glad_glPixelTransferi = (PFNGLPIXELTRANSFERIPROC) load(userptr, "glPixelTransferi");
+ glad_glPixelZoom = (PFNGLPIXELZOOMPROC) load(userptr, "glPixelZoom");
glad_glPointSize = (PFNGLPOINTSIZEPROC) load(userptr, "glPointSize");
glad_glPolygonMode = (PFNGLPOLYGONMODEPROC) load(userptr, "glPolygonMode");
+ glad_glPolygonStipple = (PFNGLPOLYGONSTIPPLEPROC) load(userptr, "glPolygonStipple");
+ glad_glPopAttrib = (PFNGLPOPATTRIBPROC) load(userptr, "glPopAttrib");
+ glad_glPopMatrix = (PFNGLPOPMATRIXPROC) load(userptr, "glPopMatrix");
+ glad_glPopName = (PFNGLPOPNAMEPROC) load(userptr, "glPopName");
+ glad_glPushAttrib = (PFNGLPUSHATTRIBPROC) load(userptr, "glPushAttrib");
+ glad_glPushMatrix = (PFNGLPUSHMATRIXPROC) load(userptr, "glPushMatrix");
+ glad_glPushName = (PFNGLPUSHNAMEPROC) load(userptr, "glPushName");
+ glad_glRasterPos2d = (PFNGLRASTERPOS2DPROC) load(userptr, "glRasterPos2d");
+ glad_glRasterPos2dv = (PFNGLRASTERPOS2DVPROC) load(userptr, "glRasterPos2dv");
+ glad_glRasterPos2f = (PFNGLRASTERPOS2FPROC) load(userptr, "glRasterPos2f");
+ glad_glRasterPos2fv = (PFNGLRASTERPOS2FVPROC) load(userptr, "glRasterPos2fv");
+ glad_glRasterPos2i = (PFNGLRASTERPOS2IPROC) load(userptr, "glRasterPos2i");
+ glad_glRasterPos2iv = (PFNGLRASTERPOS2IVPROC) load(userptr, "glRasterPos2iv");
+ glad_glRasterPos2s = (PFNGLRASTERPOS2SPROC) load(userptr, "glRasterPos2s");
+ glad_glRasterPos2sv = (PFNGLRASTERPOS2SVPROC) load(userptr, "glRasterPos2sv");
+ glad_glRasterPos3d = (PFNGLRASTERPOS3DPROC) load(userptr, "glRasterPos3d");
+ glad_glRasterPos3dv = (PFNGLRASTERPOS3DVPROC) load(userptr, "glRasterPos3dv");
+ glad_glRasterPos3f = (PFNGLRASTERPOS3FPROC) load(userptr, "glRasterPos3f");
+ glad_glRasterPos3fv = (PFNGLRASTERPOS3FVPROC) load(userptr, "glRasterPos3fv");
+ glad_glRasterPos3i = (PFNGLRASTERPOS3IPROC) load(userptr, "glRasterPos3i");
+ glad_glRasterPos3iv = (PFNGLRASTERPOS3IVPROC) load(userptr, "glRasterPos3iv");
+ glad_glRasterPos3s = (PFNGLRASTERPOS3SPROC) load(userptr, "glRasterPos3s");
+ glad_glRasterPos3sv = (PFNGLRASTERPOS3SVPROC) load(userptr, "glRasterPos3sv");
+ glad_glRasterPos4d = (PFNGLRASTERPOS4DPROC) load(userptr, "glRasterPos4d");
+ glad_glRasterPos4dv = (PFNGLRASTERPOS4DVPROC) load(userptr, "glRasterPos4dv");
+ glad_glRasterPos4f = (PFNGLRASTERPOS4FPROC) load(userptr, "glRasterPos4f");
+ glad_glRasterPos4fv = (PFNGLRASTERPOS4FVPROC) load(userptr, "glRasterPos4fv");
+ glad_glRasterPos4i = (PFNGLRASTERPOS4IPROC) load(userptr, "glRasterPos4i");
+ glad_glRasterPos4iv = (PFNGLRASTERPOS4IVPROC) load(userptr, "glRasterPos4iv");
+ glad_glRasterPos4s = (PFNGLRASTERPOS4SPROC) load(userptr, "glRasterPos4s");
+ glad_glRasterPos4sv = (PFNGLRASTERPOS4SVPROC) load(userptr, "glRasterPos4sv");
glad_glReadBuffer = (PFNGLREADBUFFERPROC) load(userptr, "glReadBuffer");
glad_glReadPixels = (PFNGLREADPIXELSPROC) load(userptr, "glReadPixels");
+ glad_glRectd = (PFNGLRECTDPROC) load(userptr, "glRectd");
+ glad_glRectdv = (PFNGLRECTDVPROC) load(userptr, "glRectdv");
+ glad_glRectf = (PFNGLRECTFPROC) load(userptr, "glRectf");
+ glad_glRectfv = (PFNGLRECTFVPROC) load(userptr, "glRectfv");
+ glad_glRecti = (PFNGLRECTIPROC) load(userptr, "glRecti");
+ glad_glRectiv = (PFNGLRECTIVPROC) load(userptr, "glRectiv");
+ glad_glRects = (PFNGLRECTSPROC) load(userptr, "glRects");
+ glad_glRectsv = (PFNGLRECTSVPROC) load(userptr, "glRectsv");
+ glad_glRenderMode = (PFNGLRENDERMODEPROC) load(userptr, "glRenderMode");
+ glad_glRotated = (PFNGLROTATEDPROC) load(userptr, "glRotated");
+ glad_glRotatef = (PFNGLROTATEFPROC) load(userptr, "glRotatef");
+ glad_glScaled = (PFNGLSCALEDPROC) load(userptr, "glScaled");
+ glad_glScalef = (PFNGLSCALEFPROC) load(userptr, "glScalef");
glad_glScissor = (PFNGLSCISSORPROC) load(userptr, "glScissor");
+ glad_glSelectBuffer = (PFNGLSELECTBUFFERPROC) load(userptr, "glSelectBuffer");
+ glad_glShadeModel = (PFNGLSHADEMODELPROC) load(userptr, "glShadeModel");
glad_glStencilFunc = (PFNGLSTENCILFUNCPROC) load(userptr, "glStencilFunc");
glad_glStencilMask = (PFNGLSTENCILMASKPROC) load(userptr, "glStencilMask");
glad_glStencilOp = (PFNGLSTENCILOPPROC) load(userptr, "glStencilOp");
+ glad_glTexCoord1d = (PFNGLTEXCOORD1DPROC) load(userptr, "glTexCoord1d");
+ glad_glTexCoord1dv = (PFNGLTEXCOORD1DVPROC) load(userptr, "glTexCoord1dv");
+ glad_glTexCoord1f = (PFNGLTEXCOORD1FPROC) load(userptr, "glTexCoord1f");
+ glad_glTexCoord1fv = (PFNGLTEXCOORD1FVPROC) load(userptr, "glTexCoord1fv");
+ glad_glTexCoord1i = (PFNGLTEXCOORD1IPROC) load(userptr, "glTexCoord1i");
+ glad_glTexCoord1iv = (PFNGLTEXCOORD1IVPROC) load(userptr, "glTexCoord1iv");
+ glad_glTexCoord1s = (PFNGLTEXCOORD1SPROC) load(userptr, "glTexCoord1s");
+ glad_glTexCoord1sv = (PFNGLTEXCOORD1SVPROC) load(userptr, "glTexCoord1sv");
+ glad_glTexCoord2d = (PFNGLTEXCOORD2DPROC) load(userptr, "glTexCoord2d");
+ glad_glTexCoord2dv = (PFNGLTEXCOORD2DVPROC) load(userptr, "glTexCoord2dv");
+ glad_glTexCoord2f = (PFNGLTEXCOORD2FPROC) load(userptr, "glTexCoord2f");
+ glad_glTexCoord2fv = (PFNGLTEXCOORD2FVPROC) load(userptr, "glTexCoord2fv");
+ glad_glTexCoord2i = (PFNGLTEXCOORD2IPROC) load(userptr, "glTexCoord2i");
+ glad_glTexCoord2iv = (PFNGLTEXCOORD2IVPROC) load(userptr, "glTexCoord2iv");
+ glad_glTexCoord2s = (PFNGLTEXCOORD2SPROC) load(userptr, "glTexCoord2s");
+ glad_glTexCoord2sv = (PFNGLTEXCOORD2SVPROC) load(userptr, "glTexCoord2sv");
+ glad_glTexCoord3d = (PFNGLTEXCOORD3DPROC) load(userptr, "glTexCoord3d");
+ glad_glTexCoord3dv = (PFNGLTEXCOORD3DVPROC) load(userptr, "glTexCoord3dv");
+ glad_glTexCoord3f = (PFNGLTEXCOORD3FPROC) load(userptr, "glTexCoord3f");
+ glad_glTexCoord3fv = (PFNGLTEXCOORD3FVPROC) load(userptr, "glTexCoord3fv");
+ glad_glTexCoord3i = (PFNGLTEXCOORD3IPROC) load(userptr, "glTexCoord3i");
+ glad_glTexCoord3iv = (PFNGLTEXCOORD3IVPROC) load(userptr, "glTexCoord3iv");
+ glad_glTexCoord3s = (PFNGLTEXCOORD3SPROC) load(userptr, "glTexCoord3s");
+ glad_glTexCoord3sv = (PFNGLTEXCOORD3SVPROC) load(userptr, "glTexCoord3sv");
+ glad_glTexCoord4d = (PFNGLTEXCOORD4DPROC) load(userptr, "glTexCoord4d");
+ glad_glTexCoord4dv = (PFNGLTEXCOORD4DVPROC) load(userptr, "glTexCoord4dv");
+ glad_glTexCoord4f = (PFNGLTEXCOORD4FPROC) load(userptr, "glTexCoord4f");
+ glad_glTexCoord4fv = (PFNGLTEXCOORD4FVPROC) load(userptr, "glTexCoord4fv");
+ glad_glTexCoord4i = (PFNGLTEXCOORD4IPROC) load(userptr, "glTexCoord4i");
+ glad_glTexCoord4iv = (PFNGLTEXCOORD4IVPROC) load(userptr, "glTexCoord4iv");
+ glad_glTexCoord4s = (PFNGLTEXCOORD4SPROC) load(userptr, "glTexCoord4s");
+ glad_glTexCoord4sv = (PFNGLTEXCOORD4SVPROC) load(userptr, "glTexCoord4sv");
+ glad_glTexEnvf = (PFNGLTEXENVFPROC) load(userptr, "glTexEnvf");
+ glad_glTexEnvfv = (PFNGLTEXENVFVPROC) load(userptr, "glTexEnvfv");
+ glad_glTexEnvi = (PFNGLTEXENVIPROC) load(userptr, "glTexEnvi");
+ glad_glTexEnviv = (PFNGLTEXENVIVPROC) load(userptr, "glTexEnviv");
+ glad_glTexGend = (PFNGLTEXGENDPROC) load(userptr, "glTexGend");
+ glad_glTexGendv = (PFNGLTEXGENDVPROC) load(userptr, "glTexGendv");
+ glad_glTexGenf = (PFNGLTEXGENFPROC) load(userptr, "glTexGenf");
+ glad_glTexGenfv = (PFNGLTEXGENFVPROC) load(userptr, "glTexGenfv");
+ glad_glTexGeni = (PFNGLTEXGENIPROC) load(userptr, "glTexGeni");
+ glad_glTexGeniv = (PFNGLTEXGENIVPROC) load(userptr, "glTexGeniv");
glad_glTexImage1D = (PFNGLTEXIMAGE1DPROC) load(userptr, "glTexImage1D");
glad_glTexImage2D = (PFNGLTEXIMAGE2DPROC) load(userptr, "glTexImage2D");
glad_glTexParameterf = (PFNGLTEXPARAMETERFPROC) load(userptr, "glTexParameterf");
glad_glTexParameterfv = (PFNGLTEXPARAMETERFVPROC) load(userptr, "glTexParameterfv");
glad_glTexParameteri = (PFNGLTEXPARAMETERIPROC) load(userptr, "glTexParameteri");
glad_glTexParameteriv = (PFNGLTEXPARAMETERIVPROC) load(userptr, "glTexParameteriv");
+ glad_glTranslated = (PFNGLTRANSLATEDPROC) load(userptr, "glTranslated");
+ glad_glTranslatef = (PFNGLTRANSLATEFPROC) load(userptr, "glTranslatef");
+ glad_glVertex2d = (PFNGLVERTEX2DPROC) load(userptr, "glVertex2d");
+ glad_glVertex2dv = (PFNGLVERTEX2DVPROC) load(userptr, "glVertex2dv");
+ glad_glVertex2f = (PFNGLVERTEX2FPROC) load(userptr, "glVertex2f");
+ glad_glVertex2fv = (PFNGLVERTEX2FVPROC) load(userptr, "glVertex2fv");
+ glad_glVertex2i = (PFNGLVERTEX2IPROC) load(userptr, "glVertex2i");
+ glad_glVertex2iv = (PFNGLVERTEX2IVPROC) load(userptr, "glVertex2iv");
+ glad_glVertex2s = (PFNGLVERTEX2SPROC) load(userptr, "glVertex2s");
+ glad_glVertex2sv = (PFNGLVERTEX2SVPROC) load(userptr, "glVertex2sv");
+ glad_glVertex3d = (PFNGLVERTEX3DPROC) load(userptr, "glVertex3d");
+ glad_glVertex3dv = (PFNGLVERTEX3DVPROC) load(userptr, "glVertex3dv");
+ glad_glVertex3f = (PFNGLVERTEX3FPROC) load(userptr, "glVertex3f");
+ glad_glVertex3fv = (PFNGLVERTEX3FVPROC) load(userptr, "glVertex3fv");
+ glad_glVertex3i = (PFNGLVERTEX3IPROC) load(userptr, "glVertex3i");
+ glad_glVertex3iv = (PFNGLVERTEX3IVPROC) load(userptr, "glVertex3iv");
+ glad_glVertex3s = (PFNGLVERTEX3SPROC) load(userptr, "glVertex3s");
+ glad_glVertex3sv = (PFNGLVERTEX3SVPROC) load(userptr, "glVertex3sv");
+ glad_glVertex4d = (PFNGLVERTEX4DPROC) load(userptr, "glVertex4d");
+ glad_glVertex4dv = (PFNGLVERTEX4DVPROC) load(userptr, "glVertex4dv");
+ glad_glVertex4f = (PFNGLVERTEX4FPROC) load(userptr, "glVertex4f");
+ glad_glVertex4fv = (PFNGLVERTEX4FVPROC) load(userptr, "glVertex4fv");
+ glad_glVertex4i = (PFNGLVERTEX4IPROC) load(userptr, "glVertex4i");
+ glad_glVertex4iv = (PFNGLVERTEX4IVPROC) load(userptr, "glVertex4iv");
+ glad_glVertex4s = (PFNGLVERTEX4SPROC) load(userptr, "glVertex4s");
+ glad_glVertex4sv = (PFNGLVERTEX4SVPROC) load(userptr, "glVertex4sv");
glad_glViewport = (PFNGLVIEWPORTPROC) load(userptr, "glViewport");
}
static void glad_gl_load_GL_VERSION_1_1( GLADuserptrloadfunc load, void* userptr) {
if(!GLAD_GL_VERSION_1_1) return;
+ glad_glAreTexturesResident = (PFNGLARETEXTURESRESIDENTPROC) load(userptr, "glAreTexturesResident");
+ glad_glArrayElement = (PFNGLARRAYELEMENTPROC) load(userptr, "glArrayElement");
glad_glBindTexture = (PFNGLBINDTEXTUREPROC) load(userptr, "glBindTexture");
+ glad_glColorPointer = (PFNGLCOLORPOINTERPROC) load(userptr, "glColorPointer");
glad_glCopyTexImage1D = (PFNGLCOPYTEXIMAGE1DPROC) load(userptr, "glCopyTexImage1D");
glad_glCopyTexImage2D = (PFNGLCOPYTEXIMAGE2DPROC) load(userptr, "glCopyTexImage2D");
glad_glCopyTexSubImage1D = (PFNGLCOPYTEXSUBIMAGE1DPROC) load(userptr, "glCopyTexSubImage1D");
glad_glCopyTexSubImage2D = (PFNGLCOPYTEXSUBIMAGE2DPROC) load(userptr, "glCopyTexSubImage2D");
glad_glDeleteTextures = (PFNGLDELETETEXTURESPROC) load(userptr, "glDeleteTextures");
+ glad_glDisableClientState = (PFNGLDISABLECLIENTSTATEPROC) load(userptr, "glDisableClientState");
glad_glDrawArrays = (PFNGLDRAWARRAYSPROC) load(userptr, "glDrawArrays");
glad_glDrawElements = (PFNGLDRAWELEMENTSPROC) load(userptr, "glDrawElements");
+ glad_glEdgeFlagPointer = (PFNGLEDGEFLAGPOINTERPROC) load(userptr, "glEdgeFlagPointer");
+ glad_glEnableClientState = (PFNGLENABLECLIENTSTATEPROC) load(userptr, "glEnableClientState");
glad_glGenTextures = (PFNGLGENTEXTURESPROC) load(userptr, "glGenTextures");
glad_glGetPointerv = (PFNGLGETPOINTERVPROC) load(userptr, "glGetPointerv");
+ glad_glIndexPointer = (PFNGLINDEXPOINTERPROC) load(userptr, "glIndexPointer");
+ glad_glIndexub = (PFNGLINDEXUBPROC) load(userptr, "glIndexub");
+ glad_glIndexubv = (PFNGLINDEXUBVPROC) load(userptr, "glIndexubv");
+ glad_glInterleavedArrays = (PFNGLINTERLEAVEDARRAYSPROC) load(userptr, "glInterleavedArrays");
glad_glIsTexture = (PFNGLISTEXTUREPROC) load(userptr, "glIsTexture");
+ glad_glNormalPointer = (PFNGLNORMALPOINTERPROC) load(userptr, "glNormalPointer");
glad_glPolygonOffset = (PFNGLPOLYGONOFFSETPROC) load(userptr, "glPolygonOffset");
+ glad_glPopClientAttrib = (PFNGLPOPCLIENTATTRIBPROC) load(userptr, "glPopClientAttrib");
+ glad_glPrioritizeTextures = (PFNGLPRIORITIZETEXTURESPROC) load(userptr, "glPrioritizeTextures");
+ glad_glPushClientAttrib = (PFNGLPUSHCLIENTATTRIBPROC) load(userptr, "glPushClientAttrib");
+ glad_glTexCoordPointer = (PFNGLTEXCOORDPOINTERPROC) load(userptr, "glTexCoordPointer");
glad_glTexSubImage1D = (PFNGLTEXSUBIMAGE1DPROC) load(userptr, "glTexSubImage1D");
glad_glTexSubImage2D = (PFNGLTEXSUBIMAGE2DPROC) load(userptr, "glTexSubImage2D");
+ glad_glVertexPointer = (PFNGLVERTEXPOINTERPROC) load(userptr, "glVertexPointer");
}
static void glad_gl_load_GL_VERSION_1_2( GLADuserptrloadfunc load, void* userptr) {
if(!GLAD_GL_VERSION_1_2) return;
@@ -8386,6 +10871,7 @@ static void glad_gl_load_GL_VERSION_1_2( GLADuserptrloadfunc load, void* userptr
static void glad_gl_load_GL_VERSION_1_3( GLADuserptrloadfunc load, void* userptr) {
if(!GLAD_GL_VERSION_1_3) return;
glad_glActiveTexture = (PFNGLACTIVETEXTUREPROC) load(userptr, "glActiveTexture");
+ glad_glClientActiveTexture = (PFNGLCLIENTACTIVETEXTUREPROC) load(userptr, "glClientActiveTexture");
glad_glCompressedTexImage1D = (PFNGLCOMPRESSEDTEXIMAGE1DPROC) load(userptr, "glCompressedTexImage1D");
glad_glCompressedTexImage2D = (PFNGLCOMPRESSEDTEXIMAGE2DPROC) load(userptr, "glCompressedTexImage2D");
glad_glCompressedTexImage3D = (PFNGLCOMPRESSEDTEXIMAGE3DPROC) load(userptr, "glCompressedTexImage3D");
@@ -8393,6 +10879,42 @@ static void glad_gl_load_GL_VERSION_1_3( GLADuserptrloadfunc load, void* userptr
glad_glCompressedTexSubImage2D = (PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) load(userptr, "glCompressedTexSubImage2D");
glad_glCompressedTexSubImage3D = (PFNGLCOMPRESSEDTEXSUBIMAGE3DPROC) load(userptr, "glCompressedTexSubImage3D");
glad_glGetCompressedTexImage = (PFNGLGETCOMPRESSEDTEXIMAGEPROC) load(userptr, "glGetCompressedTexImage");
+ glad_glLoadTransposeMatrixd = (PFNGLLOADTRANSPOSEMATRIXDPROC) load(userptr, "glLoadTransposeMatrixd");
+ glad_glLoadTransposeMatrixf = (PFNGLLOADTRANSPOSEMATRIXFPROC) load(userptr, "glLoadTransposeMatrixf");
+ glad_glMultTransposeMatrixd = (PFNGLMULTTRANSPOSEMATRIXDPROC) load(userptr, "glMultTransposeMatrixd");
+ glad_glMultTransposeMatrixf = (PFNGLMULTTRANSPOSEMATRIXFPROC) load(userptr, "glMultTransposeMatrixf");
+ glad_glMultiTexCoord1d = (PFNGLMULTITEXCOORD1DPROC) load(userptr, "glMultiTexCoord1d");
+ glad_glMultiTexCoord1dv = (PFNGLMULTITEXCOORD1DVPROC) load(userptr, "glMultiTexCoord1dv");
+ glad_glMultiTexCoord1f = (PFNGLMULTITEXCOORD1FPROC) load(userptr, "glMultiTexCoord1f");
+ glad_glMultiTexCoord1fv = (PFNGLMULTITEXCOORD1FVPROC) load(userptr, "glMultiTexCoord1fv");
+ glad_glMultiTexCoord1i = (PFNGLMULTITEXCOORD1IPROC) load(userptr, "glMultiTexCoord1i");
+ glad_glMultiTexCoord1iv = (PFNGLMULTITEXCOORD1IVPROC) load(userptr, "glMultiTexCoord1iv");
+ glad_glMultiTexCoord1s = (PFNGLMULTITEXCOORD1SPROC) load(userptr, "glMultiTexCoord1s");
+ glad_glMultiTexCoord1sv = (PFNGLMULTITEXCOORD1SVPROC) load(userptr, "glMultiTexCoord1sv");
+ glad_glMultiTexCoord2d = (PFNGLMULTITEXCOORD2DPROC) load(userptr, "glMultiTexCoord2d");
+ glad_glMultiTexCoord2dv = (PFNGLMULTITEXCOORD2DVPROC) load(userptr, "glMultiTexCoord2dv");
+ glad_glMultiTexCoord2f = (PFNGLMULTITEXCOORD2FPROC) load(userptr, "glMultiTexCoord2f");
+ glad_glMultiTexCoord2fv = (PFNGLMULTITEXCOORD2FVPROC) load(userptr, "glMultiTexCoord2fv");
+ glad_glMultiTexCoord2i = (PFNGLMULTITEXCOORD2IPROC) load(userptr, "glMultiTexCoord2i");
+ glad_glMultiTexCoord2iv = (PFNGLMULTITEXCOORD2IVPROC) load(userptr, "glMultiTexCoord2iv");
+ glad_glMultiTexCoord2s = (PFNGLMULTITEXCOORD2SPROC) load(userptr, "glMultiTexCoord2s");
+ glad_glMultiTexCoord2sv = (PFNGLMULTITEXCOORD2SVPROC) load(userptr, "glMultiTexCoord2sv");
+ glad_glMultiTexCoord3d = (PFNGLMULTITEXCOORD3DPROC) load(userptr, "glMultiTexCoord3d");
+ glad_glMultiTexCoord3dv = (PFNGLMULTITEXCOORD3DVPROC) load(userptr, "glMultiTexCoord3dv");
+ glad_glMultiTexCoord3f = (PFNGLMULTITEXCOORD3FPROC) load(userptr, "glMultiTexCoord3f");
+ glad_glMultiTexCoord3fv = (PFNGLMULTITEXCOORD3FVPROC) load(userptr, "glMultiTexCoord3fv");
+ glad_glMultiTexCoord3i = (PFNGLMULTITEXCOORD3IPROC) load(userptr, "glMultiTexCoord3i");
+ glad_glMultiTexCoord3iv = (PFNGLMULTITEXCOORD3IVPROC) load(userptr, "glMultiTexCoord3iv");
+ glad_glMultiTexCoord3s = (PFNGLMULTITEXCOORD3SPROC) load(userptr, "glMultiTexCoord3s");
+ glad_glMultiTexCoord3sv = (PFNGLMULTITEXCOORD3SVPROC) load(userptr, "glMultiTexCoord3sv");
+ glad_glMultiTexCoord4d = (PFNGLMULTITEXCOORD4DPROC) load(userptr, "glMultiTexCoord4d");
+ glad_glMultiTexCoord4dv = (PFNGLMULTITEXCOORD4DVPROC) load(userptr, "glMultiTexCoord4dv");
+ glad_glMultiTexCoord4f = (PFNGLMULTITEXCOORD4FPROC) load(userptr, "glMultiTexCoord4f");
+ glad_glMultiTexCoord4fv = (PFNGLMULTITEXCOORD4FVPROC) load(userptr, "glMultiTexCoord4fv");
+ glad_glMultiTexCoord4i = (PFNGLMULTITEXCOORD4IPROC) load(userptr, "glMultiTexCoord4i");
+ glad_glMultiTexCoord4iv = (PFNGLMULTITEXCOORD4IVPROC) load(userptr, "glMultiTexCoord4iv");
+ glad_glMultiTexCoord4s = (PFNGLMULTITEXCOORD4SPROC) load(userptr, "glMultiTexCoord4s");
+ glad_glMultiTexCoord4sv = (PFNGLMULTITEXCOORD4SVPROC) load(userptr, "glMultiTexCoord4sv");
glad_glSampleCoverage = (PFNGLSAMPLECOVERAGEPROC) load(userptr, "glSampleCoverage");
}
static void glad_gl_load_GL_VERSION_1_4( GLADuserptrloadfunc load, void* userptr) {
@@ -8400,12 +10922,50 @@ static void glad_gl_load_GL_VERSION_1_4( GLADuserptrloadfunc load, void* userptr
glad_glBlendColor = (PFNGLBLENDCOLORPROC) load(userptr, "glBlendColor");
glad_glBlendEquation = (PFNGLBLENDEQUATIONPROC) load(userptr, "glBlendEquation");
glad_glBlendFuncSeparate = (PFNGLBLENDFUNCSEPARATEPROC) load(userptr, "glBlendFuncSeparate");
+ glad_glFogCoordPointer = (PFNGLFOGCOORDPOINTERPROC) load(userptr, "glFogCoordPointer");
+ glad_glFogCoordd = (PFNGLFOGCOORDDPROC) load(userptr, "glFogCoordd");
+ glad_glFogCoorddv = (PFNGLFOGCOORDDVPROC) load(userptr, "glFogCoorddv");
+ glad_glFogCoordf = (PFNGLFOGCOORDFPROC) load(userptr, "glFogCoordf");
+ glad_glFogCoordfv = (PFNGLFOGCOORDFVPROC) load(userptr, "glFogCoordfv");
glad_glMultiDrawArrays = (PFNGLMULTIDRAWARRAYSPROC) load(userptr, "glMultiDrawArrays");
glad_glMultiDrawElements = (PFNGLMULTIDRAWELEMENTSPROC) load(userptr, "glMultiDrawElements");
glad_glPointParameterf = (PFNGLPOINTPARAMETERFPROC) load(userptr, "glPointParameterf");
glad_glPointParameterfv = (PFNGLPOINTPARAMETERFVPROC) load(userptr, "glPointParameterfv");
glad_glPointParameteri = (PFNGLPOINTPARAMETERIPROC) load(userptr, "glPointParameteri");
glad_glPointParameteriv = (PFNGLPOINTPARAMETERIVPROC) load(userptr, "glPointParameteriv");
+ glad_glSecondaryColor3b = (PFNGLSECONDARYCOLOR3BPROC) load(userptr, "glSecondaryColor3b");
+ glad_glSecondaryColor3bv = (PFNGLSECONDARYCOLOR3BVPROC) load(userptr, "glSecondaryColor3bv");
+ glad_glSecondaryColor3d = (PFNGLSECONDARYCOLOR3DPROC) load(userptr, "glSecondaryColor3d");
+ glad_glSecondaryColor3dv = (PFNGLSECONDARYCOLOR3DVPROC) load(userptr, "glSecondaryColor3dv");
+ glad_glSecondaryColor3f = (PFNGLSECONDARYCOLOR3FPROC) load(userptr, "glSecondaryColor3f");
+ glad_glSecondaryColor3fv = (PFNGLSECONDARYCOLOR3FVPROC) load(userptr, "glSecondaryColor3fv");
+ glad_glSecondaryColor3i = (PFNGLSECONDARYCOLOR3IPROC) load(userptr, "glSecondaryColor3i");
+ glad_glSecondaryColor3iv = (PFNGLSECONDARYCOLOR3IVPROC) load(userptr, "glSecondaryColor3iv");
+ glad_glSecondaryColor3s = (PFNGLSECONDARYCOLOR3SPROC) load(userptr, "glSecondaryColor3s");
+ glad_glSecondaryColor3sv = (PFNGLSECONDARYCOLOR3SVPROC) load(userptr, "glSecondaryColor3sv");
+ glad_glSecondaryColor3ub = (PFNGLSECONDARYCOLOR3UBPROC) load(userptr, "glSecondaryColor3ub");
+ glad_glSecondaryColor3ubv = (PFNGLSECONDARYCOLOR3UBVPROC) load(userptr, "glSecondaryColor3ubv");
+ glad_glSecondaryColor3ui = (PFNGLSECONDARYCOLOR3UIPROC) load(userptr, "glSecondaryColor3ui");
+ glad_glSecondaryColor3uiv = (PFNGLSECONDARYCOLOR3UIVPROC) load(userptr, "glSecondaryColor3uiv");
+ glad_glSecondaryColor3us = (PFNGLSECONDARYCOLOR3USPROC) load(userptr, "glSecondaryColor3us");
+ glad_glSecondaryColor3usv = (PFNGLSECONDARYCOLOR3USVPROC) load(userptr, "glSecondaryColor3usv");
+ glad_glSecondaryColorPointer = (PFNGLSECONDARYCOLORPOINTERPROC) load(userptr, "glSecondaryColorPointer");
+ glad_glWindowPos2d = (PFNGLWINDOWPOS2DPROC) load(userptr, "glWindowPos2d");
+ glad_glWindowPos2dv = (PFNGLWINDOWPOS2DVPROC) load(userptr, "glWindowPos2dv");
+ glad_glWindowPos2f = (PFNGLWINDOWPOS2FPROC) load(userptr, "glWindowPos2f");
+ glad_glWindowPos2fv = (PFNGLWINDOWPOS2FVPROC) load(userptr, "glWindowPos2fv");
+ glad_glWindowPos2i = (PFNGLWINDOWPOS2IPROC) load(userptr, "glWindowPos2i");
+ glad_glWindowPos2iv = (PFNGLWINDOWPOS2IVPROC) load(userptr, "glWindowPos2iv");
+ glad_glWindowPos2s = (PFNGLWINDOWPOS2SPROC) load(userptr, "glWindowPos2s");
+ glad_glWindowPos2sv = (PFNGLWINDOWPOS2SVPROC) load(userptr, "glWindowPos2sv");
+ glad_glWindowPos3d = (PFNGLWINDOWPOS3DPROC) load(userptr, "glWindowPos3d");
+ glad_glWindowPos3dv = (PFNGLWINDOWPOS3DVPROC) load(userptr, "glWindowPos3dv");
+ glad_glWindowPos3f = (PFNGLWINDOWPOS3FPROC) load(userptr, "glWindowPos3f");
+ glad_glWindowPos3fv = (PFNGLWINDOWPOS3FVPROC) load(userptr, "glWindowPos3fv");
+ glad_glWindowPos3i = (PFNGLWINDOWPOS3IPROC) load(userptr, "glWindowPos3i");
+ glad_glWindowPos3iv = (PFNGLWINDOWPOS3IVPROC) load(userptr, "glWindowPos3iv");
+ glad_glWindowPos3s = (PFNGLWINDOWPOS3SPROC) load(userptr, "glWindowPos3s");
+ glad_glWindowPos3sv = (PFNGLWINDOWPOS3SVPROC) load(userptr, "glWindowPos3sv");
}
static void glad_gl_load_GL_VERSION_1_5( GLADuserptrloadfunc load, void* userptr) {
if(!GLAD_GL_VERSION_1_5) return;
@@ -8665,6 +11225,10 @@ static void glad_gl_load_GL_VERSION_3_3( GLADuserptrloadfunc load, void* userptr
if(!GLAD_GL_VERSION_3_3) return;
glad_glBindFragDataLocationIndexed = (PFNGLBINDFRAGDATALOCATIONINDEXEDPROC) load(userptr, "glBindFragDataLocationIndexed");
glad_glBindSampler = (PFNGLBINDSAMPLERPROC) load(userptr, "glBindSampler");
+ glad_glColorP3ui = (PFNGLCOLORP3UIPROC) load(userptr, "glColorP3ui");
+ glad_glColorP3uiv = (PFNGLCOLORP3UIVPROC) load(userptr, "glColorP3uiv");
+ glad_glColorP4ui = (PFNGLCOLORP4UIPROC) load(userptr, "glColorP4ui");
+ glad_glColorP4uiv = (PFNGLCOLORP4UIVPROC) load(userptr, "glColorP4uiv");
glad_glDeleteSamplers = (PFNGLDELETESAMPLERSPROC) load(userptr, "glDeleteSamplers");
glad_glGenSamplers = (PFNGLGENSAMPLERSPROC) load(userptr, "glGenSamplers");
glad_glGetFragDataIndex = (PFNGLGETFRAGDATAINDEXPROC) load(userptr, "glGetFragDataIndex");
@@ -8675,6 +11239,16 @@ static void glad_gl_load_GL_VERSION_3_3( GLADuserptrloadfunc load, void* userptr
glad_glGetSamplerParameterfv = (PFNGLGETSAMPLERPARAMETERFVPROC) load(userptr, "glGetSamplerParameterfv");
glad_glGetSamplerParameteriv = (PFNGLGETSAMPLERPARAMETERIVPROC) load(userptr, "glGetSamplerParameteriv");
glad_glIsSampler = (PFNGLISSAMPLERPROC) load(userptr, "glIsSampler");
+ glad_glMultiTexCoordP1ui = (PFNGLMULTITEXCOORDP1UIPROC) load(userptr, "glMultiTexCoordP1ui");
+ glad_glMultiTexCoordP1uiv = (PFNGLMULTITEXCOORDP1UIVPROC) load(userptr, "glMultiTexCoordP1uiv");
+ glad_glMultiTexCoordP2ui = (PFNGLMULTITEXCOORDP2UIPROC) load(userptr, "glMultiTexCoordP2ui");
+ glad_glMultiTexCoordP2uiv = (PFNGLMULTITEXCOORDP2UIVPROC) load(userptr, "glMultiTexCoordP2uiv");
+ glad_glMultiTexCoordP3ui = (PFNGLMULTITEXCOORDP3UIPROC) load(userptr, "glMultiTexCoordP3ui");
+ glad_glMultiTexCoordP3uiv = (PFNGLMULTITEXCOORDP3UIVPROC) load(userptr, "glMultiTexCoordP3uiv");
+ glad_glMultiTexCoordP4ui = (PFNGLMULTITEXCOORDP4UIPROC) load(userptr, "glMultiTexCoordP4ui");
+ glad_glMultiTexCoordP4uiv = (PFNGLMULTITEXCOORDP4UIVPROC) load(userptr, "glMultiTexCoordP4uiv");
+ glad_glNormalP3ui = (PFNGLNORMALP3UIPROC) load(userptr, "glNormalP3ui");
+ glad_glNormalP3uiv = (PFNGLNORMALP3UIVPROC) load(userptr, "glNormalP3uiv");
glad_glQueryCounter = (PFNGLQUERYCOUNTERPROC) load(userptr, "glQueryCounter");
glad_glSamplerParameterIiv = (PFNGLSAMPLERPARAMETERIIVPROC) load(userptr, "glSamplerParameterIiv");
glad_glSamplerParameterIuiv = (PFNGLSAMPLERPARAMETERIUIVPROC) load(userptr, "glSamplerParameterIuiv");
@@ -8682,6 +11256,16 @@ static void glad_gl_load_GL_VERSION_3_3( GLADuserptrloadfunc load, void* userptr
glad_glSamplerParameterfv = (PFNGLSAMPLERPARAMETERFVPROC) load(userptr, "glSamplerParameterfv");
glad_glSamplerParameteri = (PFNGLSAMPLERPARAMETERIPROC) load(userptr, "glSamplerParameteri");
glad_glSamplerParameteriv = (PFNGLSAMPLERPARAMETERIVPROC) load(userptr, "glSamplerParameteriv");
+ glad_glSecondaryColorP3ui = (PFNGLSECONDARYCOLORP3UIPROC) load(userptr, "glSecondaryColorP3ui");
+ glad_glSecondaryColorP3uiv = (PFNGLSECONDARYCOLORP3UIVPROC) load(userptr, "glSecondaryColorP3uiv");
+ glad_glTexCoordP1ui = (PFNGLTEXCOORDP1UIPROC) load(userptr, "glTexCoordP1ui");
+ glad_glTexCoordP1uiv = (PFNGLTEXCOORDP1UIVPROC) load(userptr, "glTexCoordP1uiv");
+ glad_glTexCoordP2ui = (PFNGLTEXCOORDP2UIPROC) load(userptr, "glTexCoordP2ui");
+ glad_glTexCoordP2uiv = (PFNGLTEXCOORDP2UIVPROC) load(userptr, "glTexCoordP2uiv");
+ glad_glTexCoordP3ui = (PFNGLTEXCOORDP3UIPROC) load(userptr, "glTexCoordP3ui");
+ glad_glTexCoordP3uiv = (PFNGLTEXCOORDP3UIVPROC) load(userptr, "glTexCoordP3uiv");
+ glad_glTexCoordP4ui = (PFNGLTEXCOORDP4UIPROC) load(userptr, "glTexCoordP4ui");
+ glad_glTexCoordP4uiv = (PFNGLTEXCOORDP4UIVPROC) load(userptr, "glTexCoordP4uiv");
glad_glVertexAttribDivisor = (PFNGLVERTEXATTRIBDIVISORPROC) load(userptr, "glVertexAttribDivisor");
glad_glVertexAttribP1ui = (PFNGLVERTEXATTRIBP1UIPROC) load(userptr, "glVertexAttribP1ui");
glad_glVertexAttribP1uiv = (PFNGLVERTEXATTRIBP1UIVPROC) load(userptr, "glVertexAttribP1uiv");
@@ -8691,6 +11275,12 @@ static void glad_gl_load_GL_VERSION_3_3( GLADuserptrloadfunc load, void* userptr
glad_glVertexAttribP3uiv = (PFNGLVERTEXATTRIBP3UIVPROC) load(userptr, "glVertexAttribP3uiv");
glad_glVertexAttribP4ui = (PFNGLVERTEXATTRIBP4UIPROC) load(userptr, "glVertexAttribP4ui");
glad_glVertexAttribP4uiv = (PFNGLVERTEXATTRIBP4UIVPROC) load(userptr, "glVertexAttribP4uiv");
+ glad_glVertexP2ui = (PFNGLVERTEXP2UIPROC) load(userptr, "glVertexP2ui");
+ glad_glVertexP2uiv = (PFNGLVERTEXP2UIVPROC) load(userptr, "glVertexP2uiv");
+ glad_glVertexP3ui = (PFNGLVERTEXP3UIPROC) load(userptr, "glVertexP3ui");
+ glad_glVertexP3uiv = (PFNGLVERTEXP3UIVPROC) load(userptr, "glVertexP3uiv");
+ glad_glVertexP4ui = (PFNGLVERTEXP4UIPROC) load(userptr, "glVertexP4ui");
+ glad_glVertexP4uiv = (PFNGLVERTEXP4UIVPROC) load(userptr, "glVertexP4uiv");
}
static void glad_gl_load_GL_VERSION_4_0( GLADuserptrloadfunc load, void* userptr) {
if(!GLAD_GL_VERSION_4_0) return;
@@ -8894,18 +11484,6 @@ static void glad_gl_load_GL_VERSION_4_3( GLADuserptrloadfunc load, void* userptr
glad_glVertexAttribLFormat = (PFNGLVERTEXATTRIBLFORMATPROC) load(userptr, "glVertexAttribLFormat");
glad_glVertexBindingDivisor = (PFNGLVERTEXBINDINGDIVISORPROC) load(userptr, "glVertexBindingDivisor");
}
-static void glad_gl_load_GL_ARB_ES2_compatibility( GLADuserptrloadfunc load, void* userptr) {
- if(!GLAD_GL_ARB_ES2_compatibility) return;
- glad_glClearDepthf = (PFNGLCLEARDEPTHFPROC) load(userptr, "glClearDepthf");
- glad_glDepthRangef = (PFNGLDEPTHRANGEFPROC) load(userptr, "glDepthRangef");
- glad_glGetShaderPrecisionFormat = (PFNGLGETSHADERPRECISIONFORMATPROC) load(userptr, "glGetShaderPrecisionFormat");
- glad_glReleaseShaderCompiler = (PFNGLRELEASESHADERCOMPILERPROC) load(userptr, "glReleaseShaderCompiler");
- glad_glShaderBinary = (PFNGLSHADERBINARYPROC) load(userptr, "glShaderBinary");
-}
-static void glad_gl_load_GL_ARB_ES3_1_compatibility( GLADuserptrloadfunc load, void* userptr) {
- if(!GLAD_GL_ARB_ES3_1_compatibility) return;
- glad_glMemoryBarrierByRegion = (PFNGLMEMORYBARRIERBYREGIONPROC) load(userptr, "glMemoryBarrierByRegion");
-}
static void glad_gl_load_GL_ARB_ES3_2_compatibility( GLADuserptrloadfunc load, void* userptr) {
if(!GLAD_GL_ARB_ES3_2_compatibility) return;
glad_glPrimitiveBoundingBoxARB = (PFNGLPRIMITIVEBOUNDINGBOXARBPROC) load(userptr, "glPrimitiveBoundingBoxARB");
@@ -9617,111 +12195,23 @@ static void glad_gl_load_GL_EXT_framebuffer_object( GLADuserptrloadfunc load, vo
glad_glIsRenderbufferEXT = (PFNGLISRENDERBUFFEREXTPROC) load(userptr, "glIsRenderbufferEXT");
glad_glRenderbufferStorageEXT = (PFNGLRENDERBUFFERSTORAGEEXTPROC) load(userptr, "glRenderbufferStorageEXT");
}
-static void glad_gl_load_GL_OES_fixed_point( GLADuserptrloadfunc load, void* userptr) {
- if(!GLAD_GL_OES_fixed_point) return;
- glad_glAccumxOES = (PFNGLACCUMXOESPROC) load(userptr, "glAccumxOES");
- glad_glAlphaFuncxOES = (PFNGLALPHAFUNCXOESPROC) load(userptr, "glAlphaFuncxOES");
- glad_glBitmapxOES = (PFNGLBITMAPXOESPROC) load(userptr, "glBitmapxOES");
- glad_glBlendColorxOES = (PFNGLBLENDCOLORXOESPROC) load(userptr, "glBlendColorxOES");
- glad_glClearAccumxOES = (PFNGLCLEARACCUMXOESPROC) load(userptr, "glClearAccumxOES");
- glad_glClearColorxOES = (PFNGLCLEARCOLORXOESPROC) load(userptr, "glClearColorxOES");
- glad_glClearDepthxOES = (PFNGLCLEARDEPTHXOESPROC) load(userptr, "glClearDepthxOES");
- glad_glClipPlanexOES = (PFNGLCLIPPLANEXOESPROC) load(userptr, "glClipPlanexOES");
- glad_glColor3xOES = (PFNGLCOLOR3XOESPROC) load(userptr, "glColor3xOES");
- glad_glColor3xvOES = (PFNGLCOLOR3XVOESPROC) load(userptr, "glColor3xvOES");
- glad_glColor4xOES = (PFNGLCOLOR4XOESPROC) load(userptr, "glColor4xOES");
- glad_glColor4xvOES = (PFNGLCOLOR4XVOESPROC) load(userptr, "glColor4xvOES");
- glad_glConvolutionParameterxOES = (PFNGLCONVOLUTIONPARAMETERXOESPROC) load(userptr, "glConvolutionParameterxOES");
- glad_glConvolutionParameterxvOES = (PFNGLCONVOLUTIONPARAMETERXVOESPROC) load(userptr, "glConvolutionParameterxvOES");
- glad_glDepthRangexOES = (PFNGLDEPTHRANGEXOESPROC) load(userptr, "glDepthRangexOES");
- glad_glEvalCoord1xOES = (PFNGLEVALCOORD1XOESPROC) load(userptr, "glEvalCoord1xOES");
- glad_glEvalCoord1xvOES = (PFNGLEVALCOORD1XVOESPROC) load(userptr, "glEvalCoord1xvOES");
- glad_glEvalCoord2xOES = (PFNGLEVALCOORD2XOESPROC) load(userptr, "glEvalCoord2xOES");
- glad_glEvalCoord2xvOES = (PFNGLEVALCOORD2XVOESPROC) load(userptr, "glEvalCoord2xvOES");
- glad_glFeedbackBufferxOES = (PFNGLFEEDBACKBUFFERXOESPROC) load(userptr, "glFeedbackBufferxOES");
- glad_glFogxOES = (PFNGLFOGXOESPROC) load(userptr, "glFogxOES");
- glad_glFogxvOES = (PFNGLFOGXVOESPROC) load(userptr, "glFogxvOES");
- glad_glFrustumxOES = (PFNGLFRUSTUMXOESPROC) load(userptr, "glFrustumxOES");
- glad_glGetClipPlanexOES = (PFNGLGETCLIPPLANEXOESPROC) load(userptr, "glGetClipPlanexOES");
- glad_glGetConvolutionParameterxvOES = (PFNGLGETCONVOLUTIONPARAMETERXVOESPROC) load(userptr, "glGetConvolutionParameterxvOES");
- glad_glGetFixedvOES = (PFNGLGETFIXEDVOESPROC) load(userptr, "glGetFixedvOES");
- glad_glGetHistogramParameterxvOES = (PFNGLGETHISTOGRAMPARAMETERXVOESPROC) load(userptr, "glGetHistogramParameterxvOES");
- glad_glGetLightxOES = (PFNGLGETLIGHTXOESPROC) load(userptr, "glGetLightxOES");
- glad_glGetMapxvOES = (PFNGLGETMAPXVOESPROC) load(userptr, "glGetMapxvOES");
- glad_glGetMaterialxOES = (PFNGLGETMATERIALXOESPROC) load(userptr, "glGetMaterialxOES");
- glad_glGetPixelMapxv = (PFNGLGETPIXELMAPXVPROC) load(userptr, "glGetPixelMapxv");
- glad_glGetTexEnvxvOES = (PFNGLGETTEXENVXVOESPROC) load(userptr, "glGetTexEnvxvOES");
- glad_glGetTexGenxvOES = (PFNGLGETTEXGENXVOESPROC) load(userptr, "glGetTexGenxvOES");
- glad_glGetTexLevelParameterxvOES = (PFNGLGETTEXLEVELPARAMETERXVOESPROC) load(userptr, "glGetTexLevelParameterxvOES");
- glad_glGetTexParameterxvOES = (PFNGLGETTEXPARAMETERXVOESPROC) load(userptr, "glGetTexParameterxvOES");
- glad_glIndexxOES = (PFNGLINDEXXOESPROC) load(userptr, "glIndexxOES");
- glad_glIndexxvOES = (PFNGLINDEXXVOESPROC) load(userptr, "glIndexxvOES");
- glad_glLightModelxOES = (PFNGLLIGHTMODELXOESPROC) load(userptr, "glLightModelxOES");
- glad_glLightModelxvOES = (PFNGLLIGHTMODELXVOESPROC) load(userptr, "glLightModelxvOES");
- glad_glLightxOES = (PFNGLLIGHTXOESPROC) load(userptr, "glLightxOES");
- glad_glLightxvOES = (PFNGLLIGHTXVOESPROC) load(userptr, "glLightxvOES");
- glad_glLineWidthxOES = (PFNGLLINEWIDTHXOESPROC) load(userptr, "glLineWidthxOES");
- glad_glLoadMatrixxOES = (PFNGLLOADMATRIXXOESPROC) load(userptr, "glLoadMatrixxOES");
- glad_glLoadTransposeMatrixxOES = (PFNGLLOADTRANSPOSEMATRIXXOESPROC) load(userptr, "glLoadTransposeMatrixxOES");
- glad_glMap1xOES = (PFNGLMAP1XOESPROC) load(userptr, "glMap1xOES");
- glad_glMap2xOES = (PFNGLMAP2XOESPROC) load(userptr, "glMap2xOES");
- glad_glMapGrid1xOES = (PFNGLMAPGRID1XOESPROC) load(userptr, "glMapGrid1xOES");
- glad_glMapGrid2xOES = (PFNGLMAPGRID2XOESPROC) load(userptr, "glMapGrid2xOES");
- glad_glMaterialxOES = (PFNGLMATERIALXOESPROC) load(userptr, "glMaterialxOES");
- glad_glMaterialxvOES = (PFNGLMATERIALXVOESPROC) load(userptr, "glMaterialxvOES");
- glad_glMultMatrixxOES = (PFNGLMULTMATRIXXOESPROC) load(userptr, "glMultMatrixxOES");
- glad_glMultTransposeMatrixxOES = (PFNGLMULTTRANSPOSEMATRIXXOESPROC) load(userptr, "glMultTransposeMatrixxOES");
- glad_glMultiTexCoord1xOES = (PFNGLMULTITEXCOORD1XOESPROC) load(userptr, "glMultiTexCoord1xOES");
- glad_glMultiTexCoord1xvOES = (PFNGLMULTITEXCOORD1XVOESPROC) load(userptr, "glMultiTexCoord1xvOES");
- glad_glMultiTexCoord2xOES = (PFNGLMULTITEXCOORD2XOESPROC) load(userptr, "glMultiTexCoord2xOES");
- glad_glMultiTexCoord2xvOES = (PFNGLMULTITEXCOORD2XVOESPROC) load(userptr, "glMultiTexCoord2xvOES");
- glad_glMultiTexCoord3xOES = (PFNGLMULTITEXCOORD3XOESPROC) load(userptr, "glMultiTexCoord3xOES");
- glad_glMultiTexCoord3xvOES = (PFNGLMULTITEXCOORD3XVOESPROC) load(userptr, "glMultiTexCoord3xvOES");
- glad_glMultiTexCoord4xOES = (PFNGLMULTITEXCOORD4XOESPROC) load(userptr, "glMultiTexCoord4xOES");
- glad_glMultiTexCoord4xvOES = (PFNGLMULTITEXCOORD4XVOESPROC) load(userptr, "glMultiTexCoord4xvOES");
- glad_glNormal3xOES = (PFNGLNORMAL3XOESPROC) load(userptr, "glNormal3xOES");
- glad_glNormal3xvOES = (PFNGLNORMAL3XVOESPROC) load(userptr, "glNormal3xvOES");
- glad_glOrthoxOES = (PFNGLORTHOXOESPROC) load(userptr, "glOrthoxOES");
- glad_glPassThroughxOES = (PFNGLPASSTHROUGHXOESPROC) load(userptr, "glPassThroughxOES");
- glad_glPixelMapx = (PFNGLPIXELMAPXPROC) load(userptr, "glPixelMapx");
- glad_glPixelStorex = (PFNGLPIXELSTOREXPROC) load(userptr, "glPixelStorex");
- glad_glPixelTransferxOES = (PFNGLPIXELTRANSFERXOESPROC) load(userptr, "glPixelTransferxOES");
- glad_glPixelZoomxOES = (PFNGLPIXELZOOMXOESPROC) load(userptr, "glPixelZoomxOES");
- glad_glPointParameterxvOES = (PFNGLPOINTPARAMETERXVOESPROC) load(userptr, "glPointParameterxvOES");
- glad_glPointSizexOES = (PFNGLPOINTSIZEXOESPROC) load(userptr, "glPointSizexOES");
- glad_glPolygonOffsetxOES = (PFNGLPOLYGONOFFSETXOESPROC) load(userptr, "glPolygonOffsetxOES");
- glad_glPrioritizeTexturesxOES = (PFNGLPRIORITIZETEXTURESXOESPROC) load(userptr, "glPrioritizeTexturesxOES");
- glad_glRasterPos2xOES = (PFNGLRASTERPOS2XOESPROC) load(userptr, "glRasterPos2xOES");
- glad_glRasterPos2xvOES = (PFNGLRASTERPOS2XVOESPROC) load(userptr, "glRasterPos2xvOES");
- glad_glRasterPos3xOES = (PFNGLRASTERPOS3XOESPROC) load(userptr, "glRasterPos3xOES");
- glad_glRasterPos3xvOES = (PFNGLRASTERPOS3XVOESPROC) load(userptr, "glRasterPos3xvOES");
- glad_glRasterPos4xOES = (PFNGLRASTERPOS4XOESPROC) load(userptr, "glRasterPos4xOES");
- glad_glRasterPos4xvOES = (PFNGLRASTERPOS4XVOESPROC) load(userptr, "glRasterPos4xvOES");
- glad_glRectxOES = (PFNGLRECTXOESPROC) load(userptr, "glRectxOES");
- glad_glRectxvOES = (PFNGLRECTXVOESPROC) load(userptr, "glRectxvOES");
- glad_glRotatexOES = (PFNGLROTATEXOESPROC) load(userptr, "glRotatexOES");
- glad_glScalexOES = (PFNGLSCALEXOESPROC) load(userptr, "glScalexOES");
- glad_glTexCoord1xOES = (PFNGLTEXCOORD1XOESPROC) load(userptr, "glTexCoord1xOES");
- glad_glTexCoord1xvOES = (PFNGLTEXCOORD1XVOESPROC) load(userptr, "glTexCoord1xvOES");
- glad_glTexCoord2xOES = (PFNGLTEXCOORD2XOESPROC) load(userptr, "glTexCoord2xOES");
- glad_glTexCoord2xvOES = (PFNGLTEXCOORD2XVOESPROC) load(userptr, "glTexCoord2xvOES");
- glad_glTexCoord3xOES = (PFNGLTEXCOORD3XOESPROC) load(userptr, "glTexCoord3xOES");
- glad_glTexCoord3xvOES = (PFNGLTEXCOORD3XVOESPROC) load(userptr, "glTexCoord3xvOES");
- glad_glTexCoord4xOES = (PFNGLTEXCOORD4XOESPROC) load(userptr, "glTexCoord4xOES");
- glad_glTexCoord4xvOES = (PFNGLTEXCOORD4XVOESPROC) load(userptr, "glTexCoord4xvOES");
- glad_glTexEnvxOES = (PFNGLTEXENVXOESPROC) load(userptr, "glTexEnvxOES");
- glad_glTexEnvxvOES = (PFNGLTEXENVXVOESPROC) load(userptr, "glTexEnvxvOES");
- glad_glTexGenxOES = (PFNGLTEXGENXOESPROC) load(userptr, "glTexGenxOES");
- glad_glTexGenxvOES = (PFNGLTEXGENXVOESPROC) load(userptr, "glTexGenxvOES");
- glad_glTexParameterxOES = (PFNGLTEXPARAMETERXOESPROC) load(userptr, "glTexParameterxOES");
- glad_glTexParameterxvOES = (PFNGLTEXPARAMETERXVOESPROC) load(userptr, "glTexParameterxvOES");
- glad_glTranslatexOES = (PFNGLTRANSLATEXOESPROC) load(userptr, "glTranslatexOES");
- glad_glVertex2xOES = (PFNGLVERTEX2XOESPROC) load(userptr, "glVertex2xOES");
- glad_glVertex2xvOES = (PFNGLVERTEX2XVOESPROC) load(userptr, "glVertex2xvOES");
- glad_glVertex3xOES = (PFNGLVERTEX3XOESPROC) load(userptr, "glVertex3xOES");
- glad_glVertex3xvOES = (PFNGLVERTEX3XVOESPROC) load(userptr, "glVertex3xvOES");
- glad_glVertex4xOES = (PFNGLVERTEX4XOESPROC) load(userptr, "glVertex4xOES");
- glad_glVertex4xvOES = (PFNGLVERTEX4XVOESPROC) load(userptr, "glVertex4xvOES");
+static void glad_gl_load_GL_KHR_blend_equation_advanced( GLADuserptrloadfunc load, void* userptr) {
+ if(!GLAD_GL_KHR_blend_equation_advanced) return;
+ glad_glBlendBarrierKHR = (PFNGLBLENDBARRIERKHRPROC) load(userptr, "glBlendBarrierKHR");
+}
+static void glad_gl_load_GL_KHR_debug( GLADuserptrloadfunc load, void* userptr) {
+ if(!GLAD_GL_KHR_debug) return;
+ glad_glDebugMessageCallback = (PFNGLDEBUGMESSAGECALLBACKPROC) load(userptr, "glDebugMessageCallback");
+ glad_glDebugMessageControl = (PFNGLDEBUGMESSAGECONTROLPROC) load(userptr, "glDebugMessageControl");
+ glad_glDebugMessageInsert = (PFNGLDEBUGMESSAGEINSERTPROC) load(userptr, "glDebugMessageInsert");
+ glad_glGetDebugMessageLog = (PFNGLGETDEBUGMESSAGELOGPROC) load(userptr, "glGetDebugMessageLog");
+ glad_glGetObjectLabel = (PFNGLGETOBJECTLABELPROC) load(userptr, "glGetObjectLabel");
+ glad_glGetObjectPtrLabel = (PFNGLGETOBJECTPTRLABELPROC) load(userptr, "glGetObjectPtrLabel");
+ glad_glGetPointerv = (PFNGLGETPOINTERVPROC) load(userptr, "glGetPointerv");
+ glad_glObjectLabel = (PFNGLOBJECTLABELPROC) load(userptr, "glObjectLabel");
+ glad_glObjectPtrLabel = (PFNGLOBJECTPTRLABELPROC) load(userptr, "glObjectPtrLabel");
+ glad_glPopDebugGroup = (PFNGLPOPDEBUGGROUPPROC) load(userptr, "glPopDebugGroup");
+ glad_glPushDebugGroup = (PFNGLPUSHDEBUGGROUPPROC) load(userptr, "glPushDebugGroup");
}
@@ -9818,8 +12308,6 @@ static int glad_gl_find_extensions_gl(void) {
char **exts_i = NULL;
if (!glad_gl_get_extensions(&exts, &exts_i)) return 0;
- GLAD_GL_ARB_ES2_compatibility = glad_gl_has_extension(exts, exts_i, "GL_ARB_ES2_compatibility");
- GLAD_GL_ARB_ES3_1_compatibility = glad_gl_has_extension(exts, exts_i, "GL_ARB_ES3_1_compatibility");
GLAD_GL_ARB_ES3_2_compatibility = glad_gl_has_extension(exts, exts_i, "GL_ARB_ES3_2_compatibility");
GLAD_GL_ARB_ES3_compatibility = glad_gl_has_extension(exts, exts_i, "GL_ARB_ES3_compatibility");
GLAD_GL_ARB_blend_func_extended = glad_gl_has_extension(exts, exts_i, "GL_ARB_blend_func_extended");
@@ -9930,10 +12418,11 @@ static int glad_gl_find_extensions_gl(void) {
GLAD_GL_EXT_texture_compression_s3tc = glad_gl_has_extension(exts, exts_i, "GL_EXT_texture_compression_s3tc");
GLAD_GL_EXT_texture_filter_anisotropic = glad_gl_has_extension(exts, exts_i, "GL_EXT_texture_filter_anisotropic");
GLAD_GL_EXT_texture_mirror_clamp = glad_gl_has_extension(exts, exts_i, "GL_EXT_texture_mirror_clamp");
+ GLAD_GL_KHR_blend_equation_advanced = glad_gl_has_extension(exts, exts_i, "GL_KHR_blend_equation_advanced");
+ GLAD_GL_KHR_blend_equation_advanced_coherent = glad_gl_has_extension(exts, exts_i, "GL_KHR_blend_equation_advanced_coherent");
+ GLAD_GL_KHR_debug = glad_gl_has_extension(exts, exts_i, "GL_KHR_debug");
GLAD_GL_KHR_texture_compression_astc_hdr = glad_gl_has_extension(exts, exts_i, "GL_KHR_texture_compression_astc_hdr");
GLAD_GL_KHR_texture_compression_astc_ldr = glad_gl_has_extension(exts, exts_i, "GL_KHR_texture_compression_astc_ldr");
- GLAD_GL_OES_compressed_paletted_texture = glad_gl_has_extension(exts, exts_i, "GL_OES_compressed_paletted_texture");
- GLAD_GL_OES_fixed_point = glad_gl_has_extension(exts, exts_i, "GL_OES_fixed_point");
glad_gl_free_extensions(exts_i);
@@ -10009,8 +12498,6 @@ int gladLoadGLUserPtr( GLADuserptrloadfunc load, void *userptr) {
glad_gl_load_GL_VERSION_4_3(load, userptr);
if (!glad_gl_find_extensions_gl()) return 0;
- glad_gl_load_GL_ARB_ES2_compatibility(load, userptr);
- glad_gl_load_GL_ARB_ES3_1_compatibility(load, userptr);
glad_gl_load_GL_ARB_ES3_2_compatibility(load, userptr);
glad_gl_load_GL_ARB_blend_func_extended(load, userptr);
glad_gl_load_GL_ARB_buffer_storage(load, userptr);
@@ -10071,7 +12558,8 @@ int gladLoadGLUserPtr( GLADuserptrloadfunc load, void *userptr) {
glad_gl_load_GL_EXT_framebuffer_blit(load, userptr);
glad_gl_load_GL_EXT_framebuffer_multisample(load, userptr);
glad_gl_load_GL_EXT_framebuffer_object(load, userptr);
- glad_gl_load_GL_OES_fixed_point(load, userptr);
+ glad_gl_load_GL_KHR_blend_equation_advanced(load, userptr);
+ glad_gl_load_GL_KHR_debug(load, userptr);
@@ -10087,13 +12575,16 @@ int gladLoadGL( GLADloadfunc load) {
void gladInstallGLDebug(void) {
- glad_debug_glAccumxOES = glad_debug_impl_glAccumxOES;
+ glad_debug_glAccum = glad_debug_impl_glAccum;
glad_debug_glActiveShaderProgram = glad_debug_impl_glActiveShaderProgram;
glad_debug_glActiveTexture = glad_debug_impl_glActiveTexture;
glad_debug_glActiveTextureARB = glad_debug_impl_glActiveTextureARB;
- glad_debug_glAlphaFuncxOES = glad_debug_impl_glAlphaFuncxOES;
+ glad_debug_glAlphaFunc = glad_debug_impl_glAlphaFunc;
+ glad_debug_glAreTexturesResident = glad_debug_impl_glAreTexturesResident;
+ glad_debug_glArrayElement = glad_debug_impl_glArrayElement;
glad_debug_glAttachObjectARB = glad_debug_impl_glAttachObjectARB;
glad_debug_glAttachShader = glad_debug_impl_glAttachShader;
+ glad_debug_glBegin = glad_debug_impl_glBegin;
glad_debug_glBeginConditionalRender = glad_debug_impl_glBeginConditionalRender;
glad_debug_glBeginQuery = glad_debug_impl_glBeginQuery;
glad_debug_glBeginQueryARB = glad_debug_impl_glBeginQueryARB;
@@ -10126,9 +12617,9 @@ void gladInstallGLDebug(void) {
glad_debug_glBindVertexArray = glad_debug_impl_glBindVertexArray;
glad_debug_glBindVertexBuffer = glad_debug_impl_glBindVertexBuffer;
glad_debug_glBindVertexBuffers = glad_debug_impl_glBindVertexBuffers;
- glad_debug_glBitmapxOES = glad_debug_impl_glBitmapxOES;
+ glad_debug_glBitmap = glad_debug_impl_glBitmap;
+ glad_debug_glBlendBarrierKHR = glad_debug_impl_glBlendBarrierKHR;
glad_debug_glBlendColor = glad_debug_impl_glBlendColor;
- glad_debug_glBlendColorxOES = glad_debug_impl_glBlendColorxOES;
glad_debug_glBlendEquation = glad_debug_impl_glBlendEquation;
glad_debug_glBlendEquationSeparate = glad_debug_impl_glBlendEquationSeparate;
glad_debug_glBlendEquationSeparatei = glad_debug_impl_glBlendEquationSeparatei;
@@ -10149,13 +12640,15 @@ void gladInstallGLDebug(void) {
glad_debug_glBufferStorage = glad_debug_impl_glBufferStorage;
glad_debug_glBufferSubData = glad_debug_impl_glBufferSubData;
glad_debug_glBufferSubDataARB = glad_debug_impl_glBufferSubDataARB;
+ glad_debug_glCallList = glad_debug_impl_glCallList;
+ glad_debug_glCallLists = glad_debug_impl_glCallLists;
glad_debug_glCheckFramebufferStatus = glad_debug_impl_glCheckFramebufferStatus;
glad_debug_glCheckFramebufferStatusEXT = glad_debug_impl_glCheckFramebufferStatusEXT;
glad_debug_glCheckNamedFramebufferStatus = glad_debug_impl_glCheckNamedFramebufferStatus;
glad_debug_glClampColor = glad_debug_impl_glClampColor;
glad_debug_glClampColorARB = glad_debug_impl_glClampColorARB;
glad_debug_glClear = glad_debug_impl_glClear;
- glad_debug_glClearAccumxOES = glad_debug_impl_glClearAccumxOES;
+ glad_debug_glClearAccum = glad_debug_impl_glClearAccum;
glad_debug_glClearBufferData = glad_debug_impl_glClearBufferData;
glad_debug_glClearBufferSubData = glad_debug_impl_glClearBufferSubData;
glad_debug_glClearBufferfi = glad_debug_impl_glClearBufferfi;
@@ -10163,10 +12656,9 @@ void gladInstallGLDebug(void) {
glad_debug_glClearBufferiv = glad_debug_impl_glClearBufferiv;
glad_debug_glClearBufferuiv = glad_debug_impl_glClearBufferuiv;
glad_debug_glClearColor = glad_debug_impl_glClearColor;
- glad_debug_glClearColorxOES = glad_debug_impl_glClearColorxOES;
glad_debug_glClearDepth = glad_debug_impl_glClearDepth;
glad_debug_glClearDepthf = glad_debug_impl_glClearDepthf;
- glad_debug_glClearDepthxOES = glad_debug_impl_glClearDepthxOES;
+ glad_debug_glClearIndex = glad_debug_impl_glClearIndex;
glad_debug_glClearNamedBufferData = glad_debug_impl_glClearNamedBufferData;
glad_debug_glClearNamedBufferSubData = glad_debug_impl_glClearNamedBufferSubData;
glad_debug_glClearNamedFramebufferfi = glad_debug_impl_glClearNamedFramebufferfi;
@@ -10176,15 +12668,50 @@ void gladInstallGLDebug(void) {
glad_debug_glClearStencil = glad_debug_impl_glClearStencil;
glad_debug_glClearTexImage = glad_debug_impl_glClearTexImage;
glad_debug_glClearTexSubImage = glad_debug_impl_glClearTexSubImage;
+ glad_debug_glClientActiveTexture = glad_debug_impl_glClientActiveTexture;
glad_debug_glClientActiveTextureARB = glad_debug_impl_glClientActiveTextureARB;
glad_debug_glClientWaitSync = glad_debug_impl_glClientWaitSync;
- glad_debug_glClipPlanexOES = glad_debug_impl_glClipPlanexOES;
- glad_debug_glColor3xOES = glad_debug_impl_glColor3xOES;
- glad_debug_glColor3xvOES = glad_debug_impl_glColor3xvOES;
- glad_debug_glColor4xOES = glad_debug_impl_glColor4xOES;
- glad_debug_glColor4xvOES = glad_debug_impl_glColor4xvOES;
+ glad_debug_glClipPlane = glad_debug_impl_glClipPlane;
+ glad_debug_glColor3b = glad_debug_impl_glColor3b;
+ glad_debug_glColor3bv = glad_debug_impl_glColor3bv;
+ glad_debug_glColor3d = glad_debug_impl_glColor3d;
+ glad_debug_glColor3dv = glad_debug_impl_glColor3dv;
+ glad_debug_glColor3f = glad_debug_impl_glColor3f;
+ glad_debug_glColor3fv = glad_debug_impl_glColor3fv;
+ glad_debug_glColor3i = glad_debug_impl_glColor3i;
+ glad_debug_glColor3iv = glad_debug_impl_glColor3iv;
+ glad_debug_glColor3s = glad_debug_impl_glColor3s;
+ glad_debug_glColor3sv = glad_debug_impl_glColor3sv;
+ glad_debug_glColor3ub = glad_debug_impl_glColor3ub;
+ glad_debug_glColor3ubv = glad_debug_impl_glColor3ubv;
+ glad_debug_glColor3ui = glad_debug_impl_glColor3ui;
+ glad_debug_glColor3uiv = glad_debug_impl_glColor3uiv;
+ glad_debug_glColor3us = glad_debug_impl_glColor3us;
+ glad_debug_glColor3usv = glad_debug_impl_glColor3usv;
+ glad_debug_glColor4b = glad_debug_impl_glColor4b;
+ glad_debug_glColor4bv = glad_debug_impl_glColor4bv;
+ glad_debug_glColor4d = glad_debug_impl_glColor4d;
+ glad_debug_glColor4dv = glad_debug_impl_glColor4dv;
+ glad_debug_glColor4f = glad_debug_impl_glColor4f;
+ glad_debug_glColor4fv = glad_debug_impl_glColor4fv;
+ glad_debug_glColor4i = glad_debug_impl_glColor4i;
+ glad_debug_glColor4iv = glad_debug_impl_glColor4iv;
+ glad_debug_glColor4s = glad_debug_impl_glColor4s;
+ glad_debug_glColor4sv = glad_debug_impl_glColor4sv;
+ glad_debug_glColor4ub = glad_debug_impl_glColor4ub;
+ glad_debug_glColor4ubv = glad_debug_impl_glColor4ubv;
+ glad_debug_glColor4ui = glad_debug_impl_glColor4ui;
+ glad_debug_glColor4uiv = glad_debug_impl_glColor4uiv;
+ glad_debug_glColor4us = glad_debug_impl_glColor4us;
+ glad_debug_glColor4usv = glad_debug_impl_glColor4usv;
glad_debug_glColorMask = glad_debug_impl_glColorMask;
glad_debug_glColorMaski = glad_debug_impl_glColorMaski;
+ glad_debug_glColorMaterial = glad_debug_impl_glColorMaterial;
+ glad_debug_glColorP3ui = glad_debug_impl_glColorP3ui;
+ glad_debug_glColorP3uiv = glad_debug_impl_glColorP3uiv;
+ glad_debug_glColorP4ui = glad_debug_impl_glColorP4ui;
+ glad_debug_glColorP4uiv = glad_debug_impl_glColorP4uiv;
+ glad_debug_glColorPointer = glad_debug_impl_glColorPointer;
glad_debug_glCompileShader = glad_debug_impl_glCompileShader;
glad_debug_glCompileShaderARB = glad_debug_impl_glCompileShaderARB;
glad_debug_glCompileShaderIncludeARB = glad_debug_impl_glCompileShaderIncludeARB;
@@ -10203,11 +12730,10 @@ void gladInstallGLDebug(void) {
glad_debug_glCompressedTextureSubImage1D = glad_debug_impl_glCompressedTextureSubImage1D;
glad_debug_glCompressedTextureSubImage2D = glad_debug_impl_glCompressedTextureSubImage2D;
glad_debug_glCompressedTextureSubImage3D = glad_debug_impl_glCompressedTextureSubImage3D;
- glad_debug_glConvolutionParameterxOES = glad_debug_impl_glConvolutionParameterxOES;
- glad_debug_glConvolutionParameterxvOES = glad_debug_impl_glConvolutionParameterxvOES;
glad_debug_glCopyBufferSubData = glad_debug_impl_glCopyBufferSubData;
glad_debug_glCopyImageSubData = glad_debug_impl_glCopyImageSubData;
glad_debug_glCopyNamedBufferSubData = glad_debug_impl_glCopyNamedBufferSubData;
+ glad_debug_glCopyPixels = glad_debug_impl_glCopyPixels;
glad_debug_glCopyTexImage1D = glad_debug_impl_glCopyTexImage1D;
glad_debug_glCopyTexImage2D = glad_debug_impl_glCopyTexImage2D;
glad_debug_glCopyTexSubImage1D = glad_debug_impl_glCopyTexSubImage1D;
@@ -10241,6 +12767,7 @@ void gladInstallGLDebug(void) {
glad_debug_glDeleteBuffersARB = glad_debug_impl_glDeleteBuffersARB;
glad_debug_glDeleteFramebuffers = glad_debug_impl_glDeleteFramebuffers;
glad_debug_glDeleteFramebuffersEXT = glad_debug_impl_glDeleteFramebuffersEXT;
+ glad_debug_glDeleteLists = glad_debug_impl_glDeleteLists;
glad_debug_glDeleteNamedStringARB = glad_debug_impl_glDeleteNamedStringARB;
glad_debug_glDeleteObjectARB = glad_debug_impl_glDeleteObjectARB;
glad_debug_glDeleteProgram = glad_debug_impl_glDeleteProgram;
@@ -10262,10 +12789,10 @@ void gladInstallGLDebug(void) {
glad_debug_glDepthRangeArrayv = glad_debug_impl_glDepthRangeArrayv;
glad_debug_glDepthRangeIndexed = glad_debug_impl_glDepthRangeIndexed;
glad_debug_glDepthRangef = glad_debug_impl_glDepthRangef;
- glad_debug_glDepthRangexOES = glad_debug_impl_glDepthRangexOES;
glad_debug_glDetachObjectARB = glad_debug_impl_glDetachObjectARB;
glad_debug_glDetachShader = glad_debug_impl_glDetachShader;
glad_debug_glDisable = glad_debug_impl_glDisable;
+ glad_debug_glDisableClientState = glad_debug_impl_glDisableClientState;
glad_debug_glDisableVertexArrayAttrib = glad_debug_impl_glDisableVertexArrayAttrib;
glad_debug_glDisableVertexAttribArray = glad_debug_impl_glDisableVertexAttribArray;
glad_debug_glDisableVertexAttribArrayARB = glad_debug_impl_glDisableVertexAttribArrayARB;
@@ -10291,40 +12818,62 @@ void gladInstallGLDebug(void) {
glad_debug_glDrawElementsInstancedBaseVertex = glad_debug_impl_glDrawElementsInstancedBaseVertex;
glad_debug_glDrawElementsInstancedBaseVertexBaseInstance = glad_debug_impl_glDrawElementsInstancedBaseVertexBaseInstance;
glad_debug_glDrawElementsInstancedEXT = glad_debug_impl_glDrawElementsInstancedEXT;
+ glad_debug_glDrawPixels = glad_debug_impl_glDrawPixels;
glad_debug_glDrawRangeElements = glad_debug_impl_glDrawRangeElements;
glad_debug_glDrawRangeElementsBaseVertex = glad_debug_impl_glDrawRangeElementsBaseVertex;
glad_debug_glDrawTransformFeedback = glad_debug_impl_glDrawTransformFeedback;
glad_debug_glDrawTransformFeedbackInstanced = glad_debug_impl_glDrawTransformFeedbackInstanced;
glad_debug_glDrawTransformFeedbackStream = glad_debug_impl_glDrawTransformFeedbackStream;
glad_debug_glDrawTransformFeedbackStreamInstanced = glad_debug_impl_glDrawTransformFeedbackStreamInstanced;
+ glad_debug_glEdgeFlag = glad_debug_impl_glEdgeFlag;
+ glad_debug_glEdgeFlagPointer = glad_debug_impl_glEdgeFlagPointer;
+ glad_debug_glEdgeFlagv = glad_debug_impl_glEdgeFlagv;
glad_debug_glEnable = glad_debug_impl_glEnable;
+ glad_debug_glEnableClientState = glad_debug_impl_glEnableClientState;
glad_debug_glEnableVertexArrayAttrib = glad_debug_impl_glEnableVertexArrayAttrib;
glad_debug_glEnableVertexAttribArray = glad_debug_impl_glEnableVertexAttribArray;
glad_debug_glEnableVertexAttribArrayARB = glad_debug_impl_glEnableVertexAttribArrayARB;
glad_debug_glEnablei = glad_debug_impl_glEnablei;
+ glad_debug_glEnd = glad_debug_impl_glEnd;
glad_debug_glEndConditionalRender = glad_debug_impl_glEndConditionalRender;
+ glad_debug_glEndList = glad_debug_impl_glEndList;
glad_debug_glEndQuery = glad_debug_impl_glEndQuery;
glad_debug_glEndQueryARB = glad_debug_impl_glEndQueryARB;
glad_debug_glEndQueryIndexed = glad_debug_impl_glEndQueryIndexed;
glad_debug_glEndTransformFeedback = glad_debug_impl_glEndTransformFeedback;
- glad_debug_glEvalCoord1xOES = glad_debug_impl_glEvalCoord1xOES;
- glad_debug_glEvalCoord1xvOES = glad_debug_impl_glEvalCoord1xvOES;
- glad_debug_glEvalCoord2xOES = glad_debug_impl_glEvalCoord2xOES;
- glad_debug_glEvalCoord2xvOES = glad_debug_impl_glEvalCoord2xvOES;
+ glad_debug_glEvalCoord1d = glad_debug_impl_glEvalCoord1d;
+ glad_debug_glEvalCoord1dv = glad_debug_impl_glEvalCoord1dv;
+ glad_debug_glEvalCoord1f = glad_debug_impl_glEvalCoord1f;
+ glad_debug_glEvalCoord1fv = glad_debug_impl_glEvalCoord1fv;
+ glad_debug_glEvalCoord2d = glad_debug_impl_glEvalCoord2d;
+ glad_debug_glEvalCoord2dv = glad_debug_impl_glEvalCoord2dv;
+ glad_debug_glEvalCoord2f = glad_debug_impl_glEvalCoord2f;
+ glad_debug_glEvalCoord2fv = glad_debug_impl_glEvalCoord2fv;
+ glad_debug_glEvalMesh1 = glad_debug_impl_glEvalMesh1;
+ glad_debug_glEvalMesh2 = glad_debug_impl_glEvalMesh2;
+ glad_debug_glEvalPoint1 = glad_debug_impl_glEvalPoint1;
+ glad_debug_glEvalPoint2 = glad_debug_impl_glEvalPoint2;
glad_debug_glEvaluateDepthValuesARB = glad_debug_impl_glEvaluateDepthValuesARB;
- glad_debug_glFeedbackBufferxOES = glad_debug_impl_glFeedbackBufferxOES;
+ glad_debug_glFeedbackBuffer = glad_debug_impl_glFeedbackBuffer;
glad_debug_glFenceSync = glad_debug_impl_glFenceSync;
glad_debug_glFinish = glad_debug_impl_glFinish;
glad_debug_glFlush = glad_debug_impl_glFlush;
glad_debug_glFlushMappedBufferRange = glad_debug_impl_glFlushMappedBufferRange;
glad_debug_glFlushMappedNamedBufferRange = glad_debug_impl_glFlushMappedNamedBufferRange;
+ glad_debug_glFogCoordPointer = glad_debug_impl_glFogCoordPointer;
glad_debug_glFogCoordPointerEXT = glad_debug_impl_glFogCoordPointerEXT;
+ glad_debug_glFogCoordd = glad_debug_impl_glFogCoordd;
glad_debug_glFogCoorddEXT = glad_debug_impl_glFogCoorddEXT;
+ glad_debug_glFogCoorddv = glad_debug_impl_glFogCoorddv;
glad_debug_glFogCoorddvEXT = glad_debug_impl_glFogCoorddvEXT;
+ glad_debug_glFogCoordf = glad_debug_impl_glFogCoordf;
glad_debug_glFogCoordfEXT = glad_debug_impl_glFogCoordfEXT;
+ glad_debug_glFogCoordfv = glad_debug_impl_glFogCoordfv;
glad_debug_glFogCoordfvEXT = glad_debug_impl_glFogCoordfvEXT;
- glad_debug_glFogxOES = glad_debug_impl_glFogxOES;
- glad_debug_glFogxvOES = glad_debug_impl_glFogxvOES;
+ glad_debug_glFogf = glad_debug_impl_glFogf;
+ glad_debug_glFogfv = glad_debug_impl_glFogfv;
+ glad_debug_glFogi = glad_debug_impl_glFogi;
+ glad_debug_glFogiv = glad_debug_impl_glFogiv;
glad_debug_glFramebufferParameteri = glad_debug_impl_glFramebufferParameteri;
glad_debug_glFramebufferRenderbuffer = glad_debug_impl_glFramebufferRenderbuffer;
glad_debug_glFramebufferRenderbufferEXT = glad_debug_impl_glFramebufferRenderbufferEXT;
@@ -10341,11 +12890,12 @@ void gladInstallGLDebug(void) {
glad_debug_glFramebufferTextureLayer = glad_debug_impl_glFramebufferTextureLayer;
glad_debug_glFramebufferTextureLayerARB = glad_debug_impl_glFramebufferTextureLayerARB;
glad_debug_glFrontFace = glad_debug_impl_glFrontFace;
- glad_debug_glFrustumxOES = glad_debug_impl_glFrustumxOES;
+ glad_debug_glFrustum = glad_debug_impl_glFrustum;
glad_debug_glGenBuffers = glad_debug_impl_glGenBuffers;
glad_debug_glGenBuffersARB = glad_debug_impl_glGenBuffersARB;
glad_debug_glGenFramebuffers = glad_debug_impl_glGenFramebuffers;
glad_debug_glGenFramebuffersEXT = glad_debug_impl_glGenFramebuffersEXT;
+ glad_debug_glGenLists = glad_debug_impl_glGenLists;
glad_debug_glGenProgramPipelines = glad_debug_impl_glGenProgramPipelines;
glad_debug_glGenProgramsARB = glad_debug_impl_glGenProgramsARB;
glad_debug_glGenQueries = glad_debug_impl_glGenQueries;
@@ -10384,18 +12934,16 @@ void gladInstallGLDebug(void) {
glad_debug_glGetBufferPointervARB = glad_debug_impl_glGetBufferPointervARB;
glad_debug_glGetBufferSubData = glad_debug_impl_glGetBufferSubData;
glad_debug_glGetBufferSubDataARB = glad_debug_impl_glGetBufferSubDataARB;
- glad_debug_glGetClipPlanexOES = glad_debug_impl_glGetClipPlanexOES;
+ glad_debug_glGetClipPlane = glad_debug_impl_glGetClipPlane;
glad_debug_glGetCompressedTexImage = glad_debug_impl_glGetCompressedTexImage;
glad_debug_glGetCompressedTexImageARB = glad_debug_impl_glGetCompressedTexImageARB;
glad_debug_glGetCompressedTextureImage = glad_debug_impl_glGetCompressedTextureImage;
glad_debug_glGetCompressedTextureSubImage = glad_debug_impl_glGetCompressedTextureSubImage;
- glad_debug_glGetConvolutionParameterxvOES = glad_debug_impl_glGetConvolutionParameterxvOES;
glad_debug_glGetDebugMessageLog = glad_debug_impl_glGetDebugMessageLog;
glad_debug_glGetDebugMessageLogARB = glad_debug_impl_glGetDebugMessageLogARB;
glad_debug_glGetDoublei_v = glad_debug_impl_glGetDoublei_v;
glad_debug_glGetDoublev = glad_debug_impl_glGetDoublev;
glad_debug_glGetError = glad_debug_impl_glGetError;
- glad_debug_glGetFixedvOES = glad_debug_impl_glGetFixedvOES;
glad_debug_glGetFloati_v = glad_debug_impl_glGetFloati_v;
glad_debug_glGetFloatv = glad_debug_impl_glGetFloatv;
glad_debug_glGetFragDataIndex = glad_debug_impl_glGetFragDataIndex;
@@ -10404,7 +12952,6 @@ void gladInstallGLDebug(void) {
glad_debug_glGetFramebufferAttachmentParameterivEXT = glad_debug_impl_glGetFramebufferAttachmentParameterivEXT;
glad_debug_glGetFramebufferParameteriv = glad_debug_impl_glGetFramebufferParameteriv;
glad_debug_glGetHandleARB = glad_debug_impl_glGetHandleARB;
- glad_debug_glGetHistogramParameterxvOES = glad_debug_impl_glGetHistogramParameterxvOES;
glad_debug_glGetInfoLogARB = glad_debug_impl_glGetInfoLogARB;
glad_debug_glGetInteger64i_v = glad_debug_impl_glGetInteger64i_v;
glad_debug_glGetInteger64v = glad_debug_impl_glGetInteger64v;
@@ -10412,9 +12959,13 @@ void gladInstallGLDebug(void) {
glad_debug_glGetIntegerv = glad_debug_impl_glGetIntegerv;
glad_debug_glGetInternalformati64v = glad_debug_impl_glGetInternalformati64v;
glad_debug_glGetInternalformativ = glad_debug_impl_glGetInternalformativ;
- glad_debug_glGetLightxOES = glad_debug_impl_glGetLightxOES;
- glad_debug_glGetMapxvOES = glad_debug_impl_glGetMapxvOES;
- glad_debug_glGetMaterialxOES = glad_debug_impl_glGetMaterialxOES;
+ glad_debug_glGetLightfv = glad_debug_impl_glGetLightfv;
+ glad_debug_glGetLightiv = glad_debug_impl_glGetLightiv;
+ glad_debug_glGetMapdv = glad_debug_impl_glGetMapdv;
+ glad_debug_glGetMapfv = glad_debug_impl_glGetMapfv;
+ glad_debug_glGetMapiv = glad_debug_impl_glGetMapiv;
+ glad_debug_glGetMaterialfv = glad_debug_impl_glGetMaterialfv;
+ glad_debug_glGetMaterialiv = glad_debug_impl_glGetMaterialiv;
glad_debug_glGetMultisamplefv = glad_debug_impl_glGetMultisamplefv;
glad_debug_glGetNamedBufferParameteri64v = glad_debug_impl_glGetNamedBufferParameteri64v;
glad_debug_glGetNamedBufferParameteriv = glad_debug_impl_glGetNamedBufferParameteriv;
@@ -10429,8 +12980,11 @@ void gladInstallGLDebug(void) {
glad_debug_glGetObjectParameterfvARB = glad_debug_impl_glGetObjectParameterfvARB;
glad_debug_glGetObjectParameterivARB = glad_debug_impl_glGetObjectParameterivARB;
glad_debug_glGetObjectPtrLabel = glad_debug_impl_glGetObjectPtrLabel;
- glad_debug_glGetPixelMapxv = glad_debug_impl_glGetPixelMapxv;
+ glad_debug_glGetPixelMapfv = glad_debug_impl_glGetPixelMapfv;
+ glad_debug_glGetPixelMapuiv = glad_debug_impl_glGetPixelMapuiv;
+ glad_debug_glGetPixelMapusv = glad_debug_impl_glGetPixelMapusv;
glad_debug_glGetPointerv = glad_debug_impl_glGetPointerv;
+ glad_debug_glGetPolygonStipple = glad_debug_impl_glGetPolygonStipple;
glad_debug_glGetProgramBinary = glad_debug_impl_glGetProgramBinary;
glad_debug_glGetProgramEnvParameterdvARB = glad_debug_impl_glGetProgramEnvParameterdvARB;
glad_debug_glGetProgramEnvParameterfvARB = glad_debug_impl_glGetProgramEnvParameterfvARB;
@@ -10478,17 +13032,18 @@ void gladInstallGLDebug(void) {
glad_debug_glGetSubroutineIndex = glad_debug_impl_glGetSubroutineIndex;
glad_debug_glGetSubroutineUniformLocation = glad_debug_impl_glGetSubroutineUniformLocation;
glad_debug_glGetSynciv = glad_debug_impl_glGetSynciv;
- glad_debug_glGetTexEnvxvOES = glad_debug_impl_glGetTexEnvxvOES;
- glad_debug_glGetTexGenxvOES = glad_debug_impl_glGetTexGenxvOES;
+ glad_debug_glGetTexEnvfv = glad_debug_impl_glGetTexEnvfv;
+ glad_debug_glGetTexEnviv = glad_debug_impl_glGetTexEnviv;
+ glad_debug_glGetTexGendv = glad_debug_impl_glGetTexGendv;
+ glad_debug_glGetTexGenfv = glad_debug_impl_glGetTexGenfv;
+ glad_debug_glGetTexGeniv = glad_debug_impl_glGetTexGeniv;
glad_debug_glGetTexImage = glad_debug_impl_glGetTexImage;
glad_debug_glGetTexLevelParameterfv = glad_debug_impl_glGetTexLevelParameterfv;
glad_debug_glGetTexLevelParameteriv = glad_debug_impl_glGetTexLevelParameteriv;
- glad_debug_glGetTexLevelParameterxvOES = glad_debug_impl_glGetTexLevelParameterxvOES;
glad_debug_glGetTexParameterIiv = glad_debug_impl_glGetTexParameterIiv;
glad_debug_glGetTexParameterIuiv = glad_debug_impl_glGetTexParameterIuiv;
glad_debug_glGetTexParameterfv = glad_debug_impl_glGetTexParameterfv;
glad_debug_glGetTexParameteriv = glad_debug_impl_glGetTexParameteriv;
- glad_debug_glGetTexParameterxvOES = glad_debug_impl_glGetTexParameterxvOES;
glad_debug_glGetTextureImage = glad_debug_impl_glGetTextureImage;
glad_debug_glGetTextureLevelParameterfv = glad_debug_impl_glGetTextureLevelParameterfv;
glad_debug_glGetTextureLevelParameteriv = glad_debug_impl_glGetTextureLevelParameteriv;
@@ -10531,8 +13086,20 @@ void gladInstallGLDebug(void) {
glad_debug_glGetnUniformi64vARB = glad_debug_impl_glGetnUniformi64vARB;
glad_debug_glGetnUniformui64vARB = glad_debug_impl_glGetnUniformui64vARB;
glad_debug_glHint = glad_debug_impl_glHint;
- glad_debug_glIndexxOES = glad_debug_impl_glIndexxOES;
- glad_debug_glIndexxvOES = glad_debug_impl_glIndexxvOES;
+ glad_debug_glIndexMask = glad_debug_impl_glIndexMask;
+ glad_debug_glIndexPointer = glad_debug_impl_glIndexPointer;
+ glad_debug_glIndexd = glad_debug_impl_glIndexd;
+ glad_debug_glIndexdv = glad_debug_impl_glIndexdv;
+ glad_debug_glIndexf = glad_debug_impl_glIndexf;
+ glad_debug_glIndexfv = glad_debug_impl_glIndexfv;
+ glad_debug_glIndexi = glad_debug_impl_glIndexi;
+ glad_debug_glIndexiv = glad_debug_impl_glIndexiv;
+ glad_debug_glIndexs = glad_debug_impl_glIndexs;
+ glad_debug_glIndexsv = glad_debug_impl_glIndexsv;
+ glad_debug_glIndexub = glad_debug_impl_glIndexub;
+ glad_debug_glIndexubv = glad_debug_impl_glIndexubv;
+ glad_debug_glInitNames = glad_debug_impl_glInitNames;
+ glad_debug_glInterleavedArrays = glad_debug_impl_glInterleavedArrays;
glad_debug_glInvalidateBufferData = glad_debug_impl_glInvalidateBufferData;
glad_debug_glInvalidateBufferSubData = glad_debug_impl_glInvalidateBufferSubData;
glad_debug_glInvalidateFramebuffer = glad_debug_impl_glInvalidateFramebuffer;
@@ -10547,6 +13114,7 @@ void gladInstallGLDebug(void) {
glad_debug_glIsEnabledi = glad_debug_impl_glIsEnabledi;
glad_debug_glIsFramebuffer = glad_debug_impl_glIsFramebuffer;
glad_debug_glIsFramebufferEXT = glad_debug_impl_glIsFramebufferEXT;
+ glad_debug_glIsList = glad_debug_impl_glIsList;
glad_debug_glIsNamedStringARB = glad_debug_impl_glIsNamedStringARB;
glad_debug_glIsProgram = glad_debug_impl_glIsProgram;
glad_debug_glIsProgramARB = glad_debug_impl_glIsProgramARB;
@@ -10561,83 +13129,132 @@ void gladInstallGLDebug(void) {
glad_debug_glIsTexture = glad_debug_impl_glIsTexture;
glad_debug_glIsTransformFeedback = glad_debug_impl_glIsTransformFeedback;
glad_debug_glIsVertexArray = glad_debug_impl_glIsVertexArray;
- glad_debug_glLightModelxOES = glad_debug_impl_glLightModelxOES;
- glad_debug_glLightModelxvOES = glad_debug_impl_glLightModelxvOES;
- glad_debug_glLightxOES = glad_debug_impl_glLightxOES;
- glad_debug_glLightxvOES = glad_debug_impl_glLightxvOES;
+ glad_debug_glLightModelf = glad_debug_impl_glLightModelf;
+ glad_debug_glLightModelfv = glad_debug_impl_glLightModelfv;
+ glad_debug_glLightModeli = glad_debug_impl_glLightModeli;
+ glad_debug_glLightModeliv = glad_debug_impl_glLightModeliv;
+ glad_debug_glLightf = glad_debug_impl_glLightf;
+ glad_debug_glLightfv = glad_debug_impl_glLightfv;
+ glad_debug_glLighti = glad_debug_impl_glLighti;
+ glad_debug_glLightiv = glad_debug_impl_glLightiv;
+ glad_debug_glLineStipple = glad_debug_impl_glLineStipple;
glad_debug_glLineWidth = glad_debug_impl_glLineWidth;
- glad_debug_glLineWidthxOES = glad_debug_impl_glLineWidthxOES;
glad_debug_glLinkProgram = glad_debug_impl_glLinkProgram;
glad_debug_glLinkProgramARB = glad_debug_impl_glLinkProgramARB;
- glad_debug_glLoadMatrixxOES = glad_debug_impl_glLoadMatrixxOES;
+ glad_debug_glListBase = glad_debug_impl_glListBase;
+ glad_debug_glLoadIdentity = glad_debug_impl_glLoadIdentity;
+ glad_debug_glLoadMatrixd = glad_debug_impl_glLoadMatrixd;
+ glad_debug_glLoadMatrixf = glad_debug_impl_glLoadMatrixf;
+ glad_debug_glLoadName = glad_debug_impl_glLoadName;
+ glad_debug_glLoadTransposeMatrixd = glad_debug_impl_glLoadTransposeMatrixd;
glad_debug_glLoadTransposeMatrixdARB = glad_debug_impl_glLoadTransposeMatrixdARB;
+ glad_debug_glLoadTransposeMatrixf = glad_debug_impl_glLoadTransposeMatrixf;
glad_debug_glLoadTransposeMatrixfARB = glad_debug_impl_glLoadTransposeMatrixfARB;
- glad_debug_glLoadTransposeMatrixxOES = glad_debug_impl_glLoadTransposeMatrixxOES;
glad_debug_glLogicOp = glad_debug_impl_glLogicOp;
- glad_debug_glMap1xOES = glad_debug_impl_glMap1xOES;
- glad_debug_glMap2xOES = glad_debug_impl_glMap2xOES;
+ glad_debug_glMap1d = glad_debug_impl_glMap1d;
+ glad_debug_glMap1f = glad_debug_impl_glMap1f;
+ glad_debug_glMap2d = glad_debug_impl_glMap2d;
+ glad_debug_glMap2f = glad_debug_impl_glMap2f;
glad_debug_glMapBuffer = glad_debug_impl_glMapBuffer;
glad_debug_glMapBufferARB = glad_debug_impl_glMapBufferARB;
glad_debug_glMapBufferRange = glad_debug_impl_glMapBufferRange;
- glad_debug_glMapGrid1xOES = glad_debug_impl_glMapGrid1xOES;
- glad_debug_glMapGrid2xOES = glad_debug_impl_glMapGrid2xOES;
+ glad_debug_glMapGrid1d = glad_debug_impl_glMapGrid1d;
+ glad_debug_glMapGrid1f = glad_debug_impl_glMapGrid1f;
+ glad_debug_glMapGrid2d = glad_debug_impl_glMapGrid2d;
+ glad_debug_glMapGrid2f = glad_debug_impl_glMapGrid2f;
glad_debug_glMapNamedBuffer = glad_debug_impl_glMapNamedBuffer;
glad_debug_glMapNamedBufferRange = glad_debug_impl_glMapNamedBufferRange;
- glad_debug_glMaterialxOES = glad_debug_impl_glMaterialxOES;
- glad_debug_glMaterialxvOES = glad_debug_impl_glMaterialxvOES;
+ glad_debug_glMaterialf = glad_debug_impl_glMaterialf;
+ glad_debug_glMaterialfv = glad_debug_impl_glMaterialfv;
+ glad_debug_glMateriali = glad_debug_impl_glMateriali;
+ glad_debug_glMaterialiv = glad_debug_impl_glMaterialiv;
+ glad_debug_glMatrixMode = glad_debug_impl_glMatrixMode;
glad_debug_glMemoryBarrier = glad_debug_impl_glMemoryBarrier;
- glad_debug_glMemoryBarrierByRegion = glad_debug_impl_glMemoryBarrierByRegion;
glad_debug_glMinSampleShading = glad_debug_impl_glMinSampleShading;
glad_debug_glMinSampleShadingARB = glad_debug_impl_glMinSampleShadingARB;
- glad_debug_glMultMatrixxOES = glad_debug_impl_glMultMatrixxOES;
+ glad_debug_glMultMatrixd = glad_debug_impl_glMultMatrixd;
+ glad_debug_glMultMatrixf = glad_debug_impl_glMultMatrixf;
+ glad_debug_glMultTransposeMatrixd = glad_debug_impl_glMultTransposeMatrixd;
glad_debug_glMultTransposeMatrixdARB = glad_debug_impl_glMultTransposeMatrixdARB;
+ glad_debug_glMultTransposeMatrixf = glad_debug_impl_glMultTransposeMatrixf;
glad_debug_glMultTransposeMatrixfARB = glad_debug_impl_glMultTransposeMatrixfARB;
- glad_debug_glMultTransposeMatrixxOES = glad_debug_impl_glMultTransposeMatrixxOES;
glad_debug_glMultiDrawArrays = glad_debug_impl_glMultiDrawArrays;
glad_debug_glMultiDrawArraysIndirect = glad_debug_impl_glMultiDrawArraysIndirect;
glad_debug_glMultiDrawElements = glad_debug_impl_glMultiDrawElements;
glad_debug_glMultiDrawElementsBaseVertex = glad_debug_impl_glMultiDrawElementsBaseVertex;
glad_debug_glMultiDrawElementsIndirect = glad_debug_impl_glMultiDrawElementsIndirect;
+ glad_debug_glMultiTexCoord1d = glad_debug_impl_glMultiTexCoord1d;
glad_debug_glMultiTexCoord1dARB = glad_debug_impl_glMultiTexCoord1dARB;
+ glad_debug_glMultiTexCoord1dv = glad_debug_impl_glMultiTexCoord1dv;
glad_debug_glMultiTexCoord1dvARB = glad_debug_impl_glMultiTexCoord1dvARB;
+ glad_debug_glMultiTexCoord1f = glad_debug_impl_glMultiTexCoord1f;
glad_debug_glMultiTexCoord1fARB = glad_debug_impl_glMultiTexCoord1fARB;
+ glad_debug_glMultiTexCoord1fv = glad_debug_impl_glMultiTexCoord1fv;
glad_debug_glMultiTexCoord1fvARB = glad_debug_impl_glMultiTexCoord1fvARB;
+ glad_debug_glMultiTexCoord1i = glad_debug_impl_glMultiTexCoord1i;
glad_debug_glMultiTexCoord1iARB = glad_debug_impl_glMultiTexCoord1iARB;
+ glad_debug_glMultiTexCoord1iv = glad_debug_impl_glMultiTexCoord1iv;
glad_debug_glMultiTexCoord1ivARB = glad_debug_impl_glMultiTexCoord1ivARB;
+ glad_debug_glMultiTexCoord1s = glad_debug_impl_glMultiTexCoord1s;
glad_debug_glMultiTexCoord1sARB = glad_debug_impl_glMultiTexCoord1sARB;
+ glad_debug_glMultiTexCoord1sv = glad_debug_impl_glMultiTexCoord1sv;
glad_debug_glMultiTexCoord1svARB = glad_debug_impl_glMultiTexCoord1svARB;
- glad_debug_glMultiTexCoord1xOES = glad_debug_impl_glMultiTexCoord1xOES;
- glad_debug_glMultiTexCoord1xvOES = glad_debug_impl_glMultiTexCoord1xvOES;
+ glad_debug_glMultiTexCoord2d = glad_debug_impl_glMultiTexCoord2d;
glad_debug_glMultiTexCoord2dARB = glad_debug_impl_glMultiTexCoord2dARB;
+ glad_debug_glMultiTexCoord2dv = glad_debug_impl_glMultiTexCoord2dv;
glad_debug_glMultiTexCoord2dvARB = glad_debug_impl_glMultiTexCoord2dvARB;
+ glad_debug_glMultiTexCoord2f = glad_debug_impl_glMultiTexCoord2f;
glad_debug_glMultiTexCoord2fARB = glad_debug_impl_glMultiTexCoord2fARB;
+ glad_debug_glMultiTexCoord2fv = glad_debug_impl_glMultiTexCoord2fv;
glad_debug_glMultiTexCoord2fvARB = glad_debug_impl_glMultiTexCoord2fvARB;
+ glad_debug_glMultiTexCoord2i = glad_debug_impl_glMultiTexCoord2i;
glad_debug_glMultiTexCoord2iARB = glad_debug_impl_glMultiTexCoord2iARB;
+ glad_debug_glMultiTexCoord2iv = glad_debug_impl_glMultiTexCoord2iv;
glad_debug_glMultiTexCoord2ivARB = glad_debug_impl_glMultiTexCoord2ivARB;
+ glad_debug_glMultiTexCoord2s = glad_debug_impl_glMultiTexCoord2s;
glad_debug_glMultiTexCoord2sARB = glad_debug_impl_glMultiTexCoord2sARB;
+ glad_debug_glMultiTexCoord2sv = glad_debug_impl_glMultiTexCoord2sv;
glad_debug_glMultiTexCoord2svARB = glad_debug_impl_glMultiTexCoord2svARB;
- glad_debug_glMultiTexCoord2xOES = glad_debug_impl_glMultiTexCoord2xOES;
- glad_debug_glMultiTexCoord2xvOES = glad_debug_impl_glMultiTexCoord2xvOES;
+ glad_debug_glMultiTexCoord3d = glad_debug_impl_glMultiTexCoord3d;
glad_debug_glMultiTexCoord3dARB = glad_debug_impl_glMultiTexCoord3dARB;
+ glad_debug_glMultiTexCoord3dv = glad_debug_impl_glMultiTexCoord3dv;
glad_debug_glMultiTexCoord3dvARB = glad_debug_impl_glMultiTexCoord3dvARB;
+ glad_debug_glMultiTexCoord3f = glad_debug_impl_glMultiTexCoord3f;
glad_debug_glMultiTexCoord3fARB = glad_debug_impl_glMultiTexCoord3fARB;
+ glad_debug_glMultiTexCoord3fv = glad_debug_impl_glMultiTexCoord3fv;
glad_debug_glMultiTexCoord3fvARB = glad_debug_impl_glMultiTexCoord3fvARB;
+ glad_debug_glMultiTexCoord3i = glad_debug_impl_glMultiTexCoord3i;
glad_debug_glMultiTexCoord3iARB = glad_debug_impl_glMultiTexCoord3iARB;
+ glad_debug_glMultiTexCoord3iv = glad_debug_impl_glMultiTexCoord3iv;
glad_debug_glMultiTexCoord3ivARB = glad_debug_impl_glMultiTexCoord3ivARB;
+ glad_debug_glMultiTexCoord3s = glad_debug_impl_glMultiTexCoord3s;
glad_debug_glMultiTexCoord3sARB = glad_debug_impl_glMultiTexCoord3sARB;
+ glad_debug_glMultiTexCoord3sv = glad_debug_impl_glMultiTexCoord3sv;
glad_debug_glMultiTexCoord3svARB = glad_debug_impl_glMultiTexCoord3svARB;
- glad_debug_glMultiTexCoord3xOES = glad_debug_impl_glMultiTexCoord3xOES;
- glad_debug_glMultiTexCoord3xvOES = glad_debug_impl_glMultiTexCoord3xvOES;
+ glad_debug_glMultiTexCoord4d = glad_debug_impl_glMultiTexCoord4d;
glad_debug_glMultiTexCoord4dARB = glad_debug_impl_glMultiTexCoord4dARB;
+ glad_debug_glMultiTexCoord4dv = glad_debug_impl_glMultiTexCoord4dv;
glad_debug_glMultiTexCoord4dvARB = glad_debug_impl_glMultiTexCoord4dvARB;
+ glad_debug_glMultiTexCoord4f = glad_debug_impl_glMultiTexCoord4f;
glad_debug_glMultiTexCoord4fARB = glad_debug_impl_glMultiTexCoord4fARB;
+ glad_debug_glMultiTexCoord4fv = glad_debug_impl_glMultiTexCoord4fv;
glad_debug_glMultiTexCoord4fvARB = glad_debug_impl_glMultiTexCoord4fvARB;
+ glad_debug_glMultiTexCoord4i = glad_debug_impl_glMultiTexCoord4i;
glad_debug_glMultiTexCoord4iARB = glad_debug_impl_glMultiTexCoord4iARB;
+ glad_debug_glMultiTexCoord4iv = glad_debug_impl_glMultiTexCoord4iv;
glad_debug_glMultiTexCoord4ivARB = glad_debug_impl_glMultiTexCoord4ivARB;
+ glad_debug_glMultiTexCoord4s = glad_debug_impl_glMultiTexCoord4s;
glad_debug_glMultiTexCoord4sARB = glad_debug_impl_glMultiTexCoord4sARB;
+ glad_debug_glMultiTexCoord4sv = glad_debug_impl_glMultiTexCoord4sv;
glad_debug_glMultiTexCoord4svARB = glad_debug_impl_glMultiTexCoord4svARB;
- glad_debug_glMultiTexCoord4xOES = glad_debug_impl_glMultiTexCoord4xOES;
- glad_debug_glMultiTexCoord4xvOES = glad_debug_impl_glMultiTexCoord4xvOES;
+ glad_debug_glMultiTexCoordP1ui = glad_debug_impl_glMultiTexCoordP1ui;
+ glad_debug_glMultiTexCoordP1uiv = glad_debug_impl_glMultiTexCoordP1uiv;
+ glad_debug_glMultiTexCoordP2ui = glad_debug_impl_glMultiTexCoordP2ui;
+ glad_debug_glMultiTexCoordP2uiv = glad_debug_impl_glMultiTexCoordP2uiv;
+ glad_debug_glMultiTexCoordP3ui = glad_debug_impl_glMultiTexCoordP3ui;
+ glad_debug_glMultiTexCoordP3uiv = glad_debug_impl_glMultiTexCoordP3uiv;
+ glad_debug_glMultiTexCoordP4ui = glad_debug_impl_glMultiTexCoordP4ui;
+ glad_debug_glMultiTexCoordP4uiv = glad_debug_impl_glMultiTexCoordP4uiv;
glad_debug_glNamedBufferData = glad_debug_impl_glNamedBufferData;
glad_debug_glNamedBufferStorage = glad_debug_impl_glNamedBufferStorage;
glad_debug_glNamedBufferSubData = glad_debug_impl_glNamedBufferSubData;
@@ -10652,35 +13269,51 @@ void gladInstallGLDebug(void) {
glad_debug_glNamedRenderbufferStorage = glad_debug_impl_glNamedRenderbufferStorage;
glad_debug_glNamedRenderbufferStorageMultisample = glad_debug_impl_glNamedRenderbufferStorageMultisample;
glad_debug_glNamedStringARB = glad_debug_impl_glNamedStringARB;
- glad_debug_glNormal3xOES = glad_debug_impl_glNormal3xOES;
- glad_debug_glNormal3xvOES = glad_debug_impl_glNormal3xvOES;
+ glad_debug_glNewList = glad_debug_impl_glNewList;
+ glad_debug_glNormal3b = glad_debug_impl_glNormal3b;
+ glad_debug_glNormal3bv = glad_debug_impl_glNormal3bv;
+ glad_debug_glNormal3d = glad_debug_impl_glNormal3d;
+ glad_debug_glNormal3dv = glad_debug_impl_glNormal3dv;
+ glad_debug_glNormal3f = glad_debug_impl_glNormal3f;
+ glad_debug_glNormal3fv = glad_debug_impl_glNormal3fv;
+ glad_debug_glNormal3i = glad_debug_impl_glNormal3i;
+ glad_debug_glNormal3iv = glad_debug_impl_glNormal3iv;
+ glad_debug_glNormal3s = glad_debug_impl_glNormal3s;
+ glad_debug_glNormal3sv = glad_debug_impl_glNormal3sv;
+ glad_debug_glNormalP3ui = glad_debug_impl_glNormalP3ui;
+ glad_debug_glNormalP3uiv = glad_debug_impl_glNormalP3uiv;
+ glad_debug_glNormalPointer = glad_debug_impl_glNormalPointer;
glad_debug_glObjectLabel = glad_debug_impl_glObjectLabel;
glad_debug_glObjectPtrLabel = glad_debug_impl_glObjectPtrLabel;
- glad_debug_glOrthoxOES = glad_debug_impl_glOrthoxOES;
- glad_debug_glPassThroughxOES = glad_debug_impl_glPassThroughxOES;
+ glad_debug_glOrtho = glad_debug_impl_glOrtho;
+ glad_debug_glPassThrough = glad_debug_impl_glPassThrough;
glad_debug_glPatchParameterfv = glad_debug_impl_glPatchParameterfv;
glad_debug_glPatchParameteri = glad_debug_impl_glPatchParameteri;
glad_debug_glPauseTransformFeedback = glad_debug_impl_glPauseTransformFeedback;
- glad_debug_glPixelMapx = glad_debug_impl_glPixelMapx;
+ glad_debug_glPixelMapfv = glad_debug_impl_glPixelMapfv;
+ glad_debug_glPixelMapuiv = glad_debug_impl_glPixelMapuiv;
+ glad_debug_glPixelMapusv = glad_debug_impl_glPixelMapusv;
glad_debug_glPixelStoref = glad_debug_impl_glPixelStoref;
glad_debug_glPixelStorei = glad_debug_impl_glPixelStorei;
- glad_debug_glPixelStorex = glad_debug_impl_glPixelStorex;
- glad_debug_glPixelTransferxOES = glad_debug_impl_glPixelTransferxOES;
- glad_debug_glPixelZoomxOES = glad_debug_impl_glPixelZoomxOES;
+ glad_debug_glPixelTransferf = glad_debug_impl_glPixelTransferf;
+ glad_debug_glPixelTransferi = glad_debug_impl_glPixelTransferi;
+ glad_debug_glPixelZoom = glad_debug_impl_glPixelZoom;
glad_debug_glPointParameterf = glad_debug_impl_glPointParameterf;
glad_debug_glPointParameterfv = glad_debug_impl_glPointParameterfv;
glad_debug_glPointParameteri = glad_debug_impl_glPointParameteri;
glad_debug_glPointParameteriv = glad_debug_impl_glPointParameteriv;
- glad_debug_glPointParameterxvOES = glad_debug_impl_glPointParameterxvOES;
glad_debug_glPointSize = glad_debug_impl_glPointSize;
- glad_debug_glPointSizexOES = glad_debug_impl_glPointSizexOES;
glad_debug_glPolygonMode = glad_debug_impl_glPolygonMode;
glad_debug_glPolygonOffset = glad_debug_impl_glPolygonOffset;
- glad_debug_glPolygonOffsetxOES = glad_debug_impl_glPolygonOffsetxOES;
+ glad_debug_glPolygonStipple = glad_debug_impl_glPolygonStipple;
+ glad_debug_glPopAttrib = glad_debug_impl_glPopAttrib;
+ glad_debug_glPopClientAttrib = glad_debug_impl_glPopClientAttrib;
glad_debug_glPopDebugGroup = glad_debug_impl_glPopDebugGroup;
+ glad_debug_glPopMatrix = glad_debug_impl_glPopMatrix;
+ glad_debug_glPopName = glad_debug_impl_glPopName;
glad_debug_glPrimitiveBoundingBoxARB = glad_debug_impl_glPrimitiveBoundingBoxARB;
glad_debug_glPrimitiveRestartIndex = glad_debug_impl_glPrimitiveRestartIndex;
- glad_debug_glPrioritizeTexturesxOES = glad_debug_impl_glPrioritizeTexturesxOES;
+ glad_debug_glPrioritizeTextures = glad_debug_impl_glPrioritizeTextures;
glad_debug_glProgramBinary = glad_debug_impl_glProgramBinary;
glad_debug_glProgramEnvParameter4dARB = glad_debug_impl_glProgramEnvParameter4dARB;
glad_debug_glProgramEnvParameter4dvARB = glad_debug_impl_glProgramEnvParameter4dvARB;
@@ -10760,25 +13393,55 @@ void gladInstallGLDebug(void) {
glad_debug_glProgramUniformMatrix4x3dv = glad_debug_impl_glProgramUniformMatrix4x3dv;
glad_debug_glProgramUniformMatrix4x3fv = glad_debug_impl_glProgramUniformMatrix4x3fv;
glad_debug_glProvokingVertex = glad_debug_impl_glProvokingVertex;
+ glad_debug_glPushAttrib = glad_debug_impl_glPushAttrib;
+ glad_debug_glPushClientAttrib = glad_debug_impl_glPushClientAttrib;
glad_debug_glPushDebugGroup = glad_debug_impl_glPushDebugGroup;
+ glad_debug_glPushMatrix = glad_debug_impl_glPushMatrix;
+ glad_debug_glPushName = glad_debug_impl_glPushName;
glad_debug_glQueryCounter = glad_debug_impl_glQueryCounter;
- glad_debug_glRasterPos2xOES = glad_debug_impl_glRasterPos2xOES;
- glad_debug_glRasterPos2xvOES = glad_debug_impl_glRasterPos2xvOES;
- glad_debug_glRasterPos3xOES = glad_debug_impl_glRasterPos3xOES;
- glad_debug_glRasterPos3xvOES = glad_debug_impl_glRasterPos3xvOES;
- glad_debug_glRasterPos4xOES = glad_debug_impl_glRasterPos4xOES;
- glad_debug_glRasterPos4xvOES = glad_debug_impl_glRasterPos4xvOES;
+ glad_debug_glRasterPos2d = glad_debug_impl_glRasterPos2d;
+ glad_debug_glRasterPos2dv = glad_debug_impl_glRasterPos2dv;
+ glad_debug_glRasterPos2f = glad_debug_impl_glRasterPos2f;
+ glad_debug_glRasterPos2fv = glad_debug_impl_glRasterPos2fv;
+ glad_debug_glRasterPos2i = glad_debug_impl_glRasterPos2i;
+ glad_debug_glRasterPos2iv = glad_debug_impl_glRasterPos2iv;
+ glad_debug_glRasterPos2s = glad_debug_impl_glRasterPos2s;
+ glad_debug_glRasterPos2sv = glad_debug_impl_glRasterPos2sv;
+ glad_debug_glRasterPos3d = glad_debug_impl_glRasterPos3d;
+ glad_debug_glRasterPos3dv = glad_debug_impl_glRasterPos3dv;
+ glad_debug_glRasterPos3f = glad_debug_impl_glRasterPos3f;
+ glad_debug_glRasterPos3fv = glad_debug_impl_glRasterPos3fv;
+ glad_debug_glRasterPos3i = glad_debug_impl_glRasterPos3i;
+ glad_debug_glRasterPos3iv = glad_debug_impl_glRasterPos3iv;
+ glad_debug_glRasterPos3s = glad_debug_impl_glRasterPos3s;
+ glad_debug_glRasterPos3sv = glad_debug_impl_glRasterPos3sv;
+ glad_debug_glRasterPos4d = glad_debug_impl_glRasterPos4d;
+ glad_debug_glRasterPos4dv = glad_debug_impl_glRasterPos4dv;
+ glad_debug_glRasterPos4f = glad_debug_impl_glRasterPos4f;
+ glad_debug_glRasterPos4fv = glad_debug_impl_glRasterPos4fv;
+ glad_debug_glRasterPos4i = glad_debug_impl_glRasterPos4i;
+ glad_debug_glRasterPos4iv = glad_debug_impl_glRasterPos4iv;
+ glad_debug_glRasterPos4s = glad_debug_impl_glRasterPos4s;
+ glad_debug_glRasterPos4sv = glad_debug_impl_glRasterPos4sv;
glad_debug_glReadBuffer = glad_debug_impl_glReadBuffer;
glad_debug_glReadPixels = glad_debug_impl_glReadPixels;
- glad_debug_glRectxOES = glad_debug_impl_glRectxOES;
- glad_debug_glRectxvOES = glad_debug_impl_glRectxvOES;
+ glad_debug_glRectd = glad_debug_impl_glRectd;
+ glad_debug_glRectdv = glad_debug_impl_glRectdv;
+ glad_debug_glRectf = glad_debug_impl_glRectf;
+ glad_debug_glRectfv = glad_debug_impl_glRectfv;
+ glad_debug_glRecti = glad_debug_impl_glRecti;
+ glad_debug_glRectiv = glad_debug_impl_glRectiv;
+ glad_debug_glRects = glad_debug_impl_glRects;
+ glad_debug_glRectsv = glad_debug_impl_glRectsv;
glad_debug_glReleaseShaderCompiler = glad_debug_impl_glReleaseShaderCompiler;
+ glad_debug_glRenderMode = glad_debug_impl_glRenderMode;
glad_debug_glRenderbufferStorage = glad_debug_impl_glRenderbufferStorage;
glad_debug_glRenderbufferStorageEXT = glad_debug_impl_glRenderbufferStorageEXT;
glad_debug_glRenderbufferStorageMultisample = glad_debug_impl_glRenderbufferStorageMultisample;
glad_debug_glRenderbufferStorageMultisampleEXT = glad_debug_impl_glRenderbufferStorageMultisampleEXT;
glad_debug_glResumeTransformFeedback = glad_debug_impl_glResumeTransformFeedback;
- glad_debug_glRotatexOES = glad_debug_impl_glRotatexOES;
+ glad_debug_glRotated = glad_debug_impl_glRotated;
+ glad_debug_glRotatef = glad_debug_impl_glRotatef;
glad_debug_glSampleCoverage = glad_debug_impl_glSampleCoverage;
glad_debug_glSampleCoverageARB = glad_debug_impl_glSampleCoverageARB;
glad_debug_glSampleMaski = glad_debug_impl_glSampleMaski;
@@ -10788,11 +13451,33 @@ void gladInstallGLDebug(void) {
glad_debug_glSamplerParameterfv = glad_debug_impl_glSamplerParameterfv;
glad_debug_glSamplerParameteri = glad_debug_impl_glSamplerParameteri;
glad_debug_glSamplerParameteriv = glad_debug_impl_glSamplerParameteriv;
- glad_debug_glScalexOES = glad_debug_impl_glScalexOES;
+ glad_debug_glScaled = glad_debug_impl_glScaled;
+ glad_debug_glScalef = glad_debug_impl_glScalef;
glad_debug_glScissor = glad_debug_impl_glScissor;
glad_debug_glScissorArrayv = glad_debug_impl_glScissorArrayv;
glad_debug_glScissorIndexed = glad_debug_impl_glScissorIndexed;
glad_debug_glScissorIndexedv = glad_debug_impl_glScissorIndexedv;
+ glad_debug_glSecondaryColor3b = glad_debug_impl_glSecondaryColor3b;
+ glad_debug_glSecondaryColor3bv = glad_debug_impl_glSecondaryColor3bv;
+ glad_debug_glSecondaryColor3d = glad_debug_impl_glSecondaryColor3d;
+ glad_debug_glSecondaryColor3dv = glad_debug_impl_glSecondaryColor3dv;
+ glad_debug_glSecondaryColor3f = glad_debug_impl_glSecondaryColor3f;
+ glad_debug_glSecondaryColor3fv = glad_debug_impl_glSecondaryColor3fv;
+ glad_debug_glSecondaryColor3i = glad_debug_impl_glSecondaryColor3i;
+ glad_debug_glSecondaryColor3iv = glad_debug_impl_glSecondaryColor3iv;
+ glad_debug_glSecondaryColor3s = glad_debug_impl_glSecondaryColor3s;
+ glad_debug_glSecondaryColor3sv = glad_debug_impl_glSecondaryColor3sv;
+ glad_debug_glSecondaryColor3ub = glad_debug_impl_glSecondaryColor3ub;
+ glad_debug_glSecondaryColor3ubv = glad_debug_impl_glSecondaryColor3ubv;
+ glad_debug_glSecondaryColor3ui = glad_debug_impl_glSecondaryColor3ui;
+ glad_debug_glSecondaryColor3uiv = glad_debug_impl_glSecondaryColor3uiv;
+ glad_debug_glSecondaryColor3us = glad_debug_impl_glSecondaryColor3us;
+ glad_debug_glSecondaryColor3usv = glad_debug_impl_glSecondaryColor3usv;
+ glad_debug_glSecondaryColorP3ui = glad_debug_impl_glSecondaryColorP3ui;
+ glad_debug_glSecondaryColorP3uiv = glad_debug_impl_glSecondaryColorP3uiv;
+ glad_debug_glSecondaryColorPointer = glad_debug_impl_glSecondaryColorPointer;
+ glad_debug_glSelectBuffer = glad_debug_impl_glSelectBuffer;
+ glad_debug_glShadeModel = glad_debug_impl_glShadeModel;
glad_debug_glShaderBinary = glad_debug_impl_glShaderBinary;
glad_debug_glShaderSource = glad_debug_impl_glShaderSource;
glad_debug_glShaderSourceARB = glad_debug_impl_glShaderSourceARB;
@@ -10806,18 +13491,57 @@ void gladInstallGLDebug(void) {
glad_debug_glStencilOpSeparate = glad_debug_impl_glStencilOpSeparate;
glad_debug_glTexBuffer = glad_debug_impl_glTexBuffer;
glad_debug_glTexBufferRange = glad_debug_impl_glTexBufferRange;
- glad_debug_glTexCoord1xOES = glad_debug_impl_glTexCoord1xOES;
- glad_debug_glTexCoord1xvOES = glad_debug_impl_glTexCoord1xvOES;
- glad_debug_glTexCoord2xOES = glad_debug_impl_glTexCoord2xOES;
- glad_debug_glTexCoord2xvOES = glad_debug_impl_glTexCoord2xvOES;
- glad_debug_glTexCoord3xOES = glad_debug_impl_glTexCoord3xOES;
- glad_debug_glTexCoord3xvOES = glad_debug_impl_glTexCoord3xvOES;
- glad_debug_glTexCoord4xOES = glad_debug_impl_glTexCoord4xOES;
- glad_debug_glTexCoord4xvOES = glad_debug_impl_glTexCoord4xvOES;
- glad_debug_glTexEnvxOES = glad_debug_impl_glTexEnvxOES;
- glad_debug_glTexEnvxvOES = glad_debug_impl_glTexEnvxvOES;
- glad_debug_glTexGenxOES = glad_debug_impl_glTexGenxOES;
- glad_debug_glTexGenxvOES = glad_debug_impl_glTexGenxvOES;
+ glad_debug_glTexCoord1d = glad_debug_impl_glTexCoord1d;
+ glad_debug_glTexCoord1dv = glad_debug_impl_glTexCoord1dv;
+ glad_debug_glTexCoord1f = glad_debug_impl_glTexCoord1f;
+ glad_debug_glTexCoord1fv = glad_debug_impl_glTexCoord1fv;
+ glad_debug_glTexCoord1i = glad_debug_impl_glTexCoord1i;
+ glad_debug_glTexCoord1iv = glad_debug_impl_glTexCoord1iv;
+ glad_debug_glTexCoord1s = glad_debug_impl_glTexCoord1s;
+ glad_debug_glTexCoord1sv = glad_debug_impl_glTexCoord1sv;
+ glad_debug_glTexCoord2d = glad_debug_impl_glTexCoord2d;
+ glad_debug_glTexCoord2dv = glad_debug_impl_glTexCoord2dv;
+ glad_debug_glTexCoord2f = glad_debug_impl_glTexCoord2f;
+ glad_debug_glTexCoord2fv = glad_debug_impl_glTexCoord2fv;
+ glad_debug_glTexCoord2i = glad_debug_impl_glTexCoord2i;
+ glad_debug_glTexCoord2iv = glad_debug_impl_glTexCoord2iv;
+ glad_debug_glTexCoord2s = glad_debug_impl_glTexCoord2s;
+ glad_debug_glTexCoord2sv = glad_debug_impl_glTexCoord2sv;
+ glad_debug_glTexCoord3d = glad_debug_impl_glTexCoord3d;
+ glad_debug_glTexCoord3dv = glad_debug_impl_glTexCoord3dv;
+ glad_debug_glTexCoord3f = glad_debug_impl_glTexCoord3f;
+ glad_debug_glTexCoord3fv = glad_debug_impl_glTexCoord3fv;
+ glad_debug_glTexCoord3i = glad_debug_impl_glTexCoord3i;
+ glad_debug_glTexCoord3iv = glad_debug_impl_glTexCoord3iv;
+ glad_debug_glTexCoord3s = glad_debug_impl_glTexCoord3s;
+ glad_debug_glTexCoord3sv = glad_debug_impl_glTexCoord3sv;
+ glad_debug_glTexCoord4d = glad_debug_impl_glTexCoord4d;
+ glad_debug_glTexCoord4dv = glad_debug_impl_glTexCoord4dv;
+ glad_debug_glTexCoord4f = glad_debug_impl_glTexCoord4f;
+ glad_debug_glTexCoord4fv = glad_debug_impl_glTexCoord4fv;
+ glad_debug_glTexCoord4i = glad_debug_impl_glTexCoord4i;
+ glad_debug_glTexCoord4iv = glad_debug_impl_glTexCoord4iv;
+ glad_debug_glTexCoord4s = glad_debug_impl_glTexCoord4s;
+ glad_debug_glTexCoord4sv = glad_debug_impl_glTexCoord4sv;
+ glad_debug_glTexCoordP1ui = glad_debug_impl_glTexCoordP1ui;
+ glad_debug_glTexCoordP1uiv = glad_debug_impl_glTexCoordP1uiv;
+ glad_debug_glTexCoordP2ui = glad_debug_impl_glTexCoordP2ui;
+ glad_debug_glTexCoordP2uiv = glad_debug_impl_glTexCoordP2uiv;
+ glad_debug_glTexCoordP3ui = glad_debug_impl_glTexCoordP3ui;
+ glad_debug_glTexCoordP3uiv = glad_debug_impl_glTexCoordP3uiv;
+ glad_debug_glTexCoordP4ui = glad_debug_impl_glTexCoordP4ui;
+ glad_debug_glTexCoordP4uiv = glad_debug_impl_glTexCoordP4uiv;
+ glad_debug_glTexCoordPointer = glad_debug_impl_glTexCoordPointer;
+ glad_debug_glTexEnvf = glad_debug_impl_glTexEnvf;
+ glad_debug_glTexEnvfv = glad_debug_impl_glTexEnvfv;
+ glad_debug_glTexEnvi = glad_debug_impl_glTexEnvi;
+ glad_debug_glTexEnviv = glad_debug_impl_glTexEnviv;
+ glad_debug_glTexGend = glad_debug_impl_glTexGend;
+ glad_debug_glTexGendv = glad_debug_impl_glTexGendv;
+ glad_debug_glTexGenf = glad_debug_impl_glTexGenf;
+ glad_debug_glTexGenfv = glad_debug_impl_glTexGenfv;
+ glad_debug_glTexGeni = glad_debug_impl_glTexGeni;
+ glad_debug_glTexGeniv = glad_debug_impl_glTexGeniv;
glad_debug_glTexImage1D = glad_debug_impl_glTexImage1D;
glad_debug_glTexImage2D = glad_debug_impl_glTexImage2D;
glad_debug_glTexImage2DMultisample = glad_debug_impl_glTexImage2DMultisample;
@@ -10829,8 +13553,6 @@ void gladInstallGLDebug(void) {
glad_debug_glTexParameterfv = glad_debug_impl_glTexParameterfv;
glad_debug_glTexParameteri = glad_debug_impl_glTexParameteri;
glad_debug_glTexParameteriv = glad_debug_impl_glTexParameteriv;
- glad_debug_glTexParameterxOES = glad_debug_impl_glTexParameterxOES;
- glad_debug_glTexParameterxvOES = glad_debug_impl_glTexParameterxvOES;
glad_debug_glTexStorage1D = glad_debug_impl_glTexStorage1D;
glad_debug_glTexStorage2D = glad_debug_impl_glTexStorage2D;
glad_debug_glTexStorage2DMultisample = glad_debug_impl_glTexStorage2DMultisample;
@@ -10859,7 +13581,8 @@ void gladInstallGLDebug(void) {
glad_debug_glTransformFeedbackBufferBase = glad_debug_impl_glTransformFeedbackBufferBase;
glad_debug_glTransformFeedbackBufferRange = glad_debug_impl_glTransformFeedbackBufferRange;
glad_debug_glTransformFeedbackVaryings = glad_debug_impl_glTransformFeedbackVaryings;
- glad_debug_glTranslatexOES = glad_debug_impl_glTranslatexOES;
+ glad_debug_glTranslated = glad_debug_impl_glTranslated;
+ glad_debug_glTranslatef = glad_debug_impl_glTranslatef;
glad_debug_glUniform1d = glad_debug_impl_glUniform1d;
glad_debug_glUniform1dv = glad_debug_impl_glUniform1dv;
glad_debug_glUniform1f = glad_debug_impl_glUniform1f;
@@ -10956,12 +13679,30 @@ void gladInstallGLDebug(void) {
glad_debug_glValidateProgram = glad_debug_impl_glValidateProgram;
glad_debug_glValidateProgramARB = glad_debug_impl_glValidateProgramARB;
glad_debug_glValidateProgramPipeline = glad_debug_impl_glValidateProgramPipeline;
- glad_debug_glVertex2xOES = glad_debug_impl_glVertex2xOES;
- glad_debug_glVertex2xvOES = glad_debug_impl_glVertex2xvOES;
- glad_debug_glVertex3xOES = glad_debug_impl_glVertex3xOES;
- glad_debug_glVertex3xvOES = glad_debug_impl_glVertex3xvOES;
- glad_debug_glVertex4xOES = glad_debug_impl_glVertex4xOES;
- glad_debug_glVertex4xvOES = glad_debug_impl_glVertex4xvOES;
+ glad_debug_glVertex2d = glad_debug_impl_glVertex2d;
+ glad_debug_glVertex2dv = glad_debug_impl_glVertex2dv;
+ glad_debug_glVertex2f = glad_debug_impl_glVertex2f;
+ glad_debug_glVertex2fv = glad_debug_impl_glVertex2fv;
+ glad_debug_glVertex2i = glad_debug_impl_glVertex2i;
+ glad_debug_glVertex2iv = glad_debug_impl_glVertex2iv;
+ glad_debug_glVertex2s = glad_debug_impl_glVertex2s;
+ glad_debug_glVertex2sv = glad_debug_impl_glVertex2sv;
+ glad_debug_glVertex3d = glad_debug_impl_glVertex3d;
+ glad_debug_glVertex3dv = glad_debug_impl_glVertex3dv;
+ glad_debug_glVertex3f = glad_debug_impl_glVertex3f;
+ glad_debug_glVertex3fv = glad_debug_impl_glVertex3fv;
+ glad_debug_glVertex3i = glad_debug_impl_glVertex3i;
+ glad_debug_glVertex3iv = glad_debug_impl_glVertex3iv;
+ glad_debug_glVertex3s = glad_debug_impl_glVertex3s;
+ glad_debug_glVertex3sv = glad_debug_impl_glVertex3sv;
+ glad_debug_glVertex4d = glad_debug_impl_glVertex4d;
+ glad_debug_glVertex4dv = glad_debug_impl_glVertex4dv;
+ glad_debug_glVertex4f = glad_debug_impl_glVertex4f;
+ glad_debug_glVertex4fv = glad_debug_impl_glVertex4fv;
+ glad_debug_glVertex4i = glad_debug_impl_glVertex4i;
+ glad_debug_glVertex4iv = glad_debug_impl_glVertex4iv;
+ glad_debug_glVertex4s = glad_debug_impl_glVertex4s;
+ glad_debug_glVertex4sv = glad_debug_impl_glVertex4sv;
glad_debug_glVertexArrayAttribBinding = glad_debug_impl_glVertexArrayAttribBinding;
glad_debug_glVertexArrayAttribFormat = glad_debug_impl_glVertexArrayAttribFormat;
glad_debug_glVertexArrayAttribIFormat = glad_debug_impl_glVertexArrayAttribIFormat;
@@ -11089,21 +13830,47 @@ void gladInstallGLDebug(void) {
glad_debug_glVertexAttribPointer = glad_debug_impl_glVertexAttribPointer;
glad_debug_glVertexAttribPointerARB = glad_debug_impl_glVertexAttribPointerARB;
glad_debug_glVertexBindingDivisor = glad_debug_impl_glVertexBindingDivisor;
+ glad_debug_glVertexP2ui = glad_debug_impl_glVertexP2ui;
+ glad_debug_glVertexP2uiv = glad_debug_impl_glVertexP2uiv;
+ glad_debug_glVertexP3ui = glad_debug_impl_glVertexP3ui;
+ glad_debug_glVertexP3uiv = glad_debug_impl_glVertexP3uiv;
+ glad_debug_glVertexP4ui = glad_debug_impl_glVertexP4ui;
+ glad_debug_glVertexP4uiv = glad_debug_impl_glVertexP4uiv;
+ glad_debug_glVertexPointer = glad_debug_impl_glVertexPointer;
glad_debug_glViewport = glad_debug_impl_glViewport;
glad_debug_glViewportArrayv = glad_debug_impl_glViewportArrayv;
glad_debug_glViewportIndexedf = glad_debug_impl_glViewportIndexedf;
glad_debug_glViewportIndexedfv = glad_debug_impl_glViewportIndexedfv;
glad_debug_glWaitSync = glad_debug_impl_glWaitSync;
+ glad_debug_glWindowPos2d = glad_debug_impl_glWindowPos2d;
+ glad_debug_glWindowPos2dv = glad_debug_impl_glWindowPos2dv;
+ glad_debug_glWindowPos2f = glad_debug_impl_glWindowPos2f;
+ glad_debug_glWindowPos2fv = glad_debug_impl_glWindowPos2fv;
+ glad_debug_glWindowPos2i = glad_debug_impl_glWindowPos2i;
+ glad_debug_glWindowPos2iv = glad_debug_impl_glWindowPos2iv;
+ glad_debug_glWindowPos2s = glad_debug_impl_glWindowPos2s;
+ glad_debug_glWindowPos2sv = glad_debug_impl_glWindowPos2sv;
+ glad_debug_glWindowPos3d = glad_debug_impl_glWindowPos3d;
+ glad_debug_glWindowPos3dv = glad_debug_impl_glWindowPos3dv;
+ glad_debug_glWindowPos3f = glad_debug_impl_glWindowPos3f;
+ glad_debug_glWindowPos3fv = glad_debug_impl_glWindowPos3fv;
+ glad_debug_glWindowPos3i = glad_debug_impl_glWindowPos3i;
+ glad_debug_glWindowPos3iv = glad_debug_impl_glWindowPos3iv;
+ glad_debug_glWindowPos3s = glad_debug_impl_glWindowPos3s;
+ glad_debug_glWindowPos3sv = glad_debug_impl_glWindowPos3sv;
}
void gladUninstallGLDebug(void) {
- glad_debug_glAccumxOES = glad_glAccumxOES;
+ glad_debug_glAccum = glad_glAccum;
glad_debug_glActiveShaderProgram = glad_glActiveShaderProgram;
glad_debug_glActiveTexture = glad_glActiveTexture;
glad_debug_glActiveTextureARB = glad_glActiveTextureARB;
- glad_debug_glAlphaFuncxOES = glad_glAlphaFuncxOES;
+ glad_debug_glAlphaFunc = glad_glAlphaFunc;
+ glad_debug_glAreTexturesResident = glad_glAreTexturesResident;
+ glad_debug_glArrayElement = glad_glArrayElement;
glad_debug_glAttachObjectARB = glad_glAttachObjectARB;
glad_debug_glAttachShader = glad_glAttachShader;
+ glad_debug_glBegin = glad_glBegin;
glad_debug_glBeginConditionalRender = glad_glBeginConditionalRender;
glad_debug_glBeginQuery = glad_glBeginQuery;
glad_debug_glBeginQueryARB = glad_glBeginQueryARB;
@@ -11136,9 +13903,9 @@ void gladUninstallGLDebug(void) {
glad_debug_glBindVertexArray = glad_glBindVertexArray;
glad_debug_glBindVertexBuffer = glad_glBindVertexBuffer;
glad_debug_glBindVertexBuffers = glad_glBindVertexBuffers;
- glad_debug_glBitmapxOES = glad_glBitmapxOES;
+ glad_debug_glBitmap = glad_glBitmap;
+ glad_debug_glBlendBarrierKHR = glad_glBlendBarrierKHR;
glad_debug_glBlendColor = glad_glBlendColor;
- glad_debug_glBlendColorxOES = glad_glBlendColorxOES;
glad_debug_glBlendEquation = glad_glBlendEquation;
glad_debug_glBlendEquationSeparate = glad_glBlendEquationSeparate;
glad_debug_glBlendEquationSeparatei = glad_glBlendEquationSeparatei;
@@ -11159,13 +13926,15 @@ void gladUninstallGLDebug(void) {
glad_debug_glBufferStorage = glad_glBufferStorage;
glad_debug_glBufferSubData = glad_glBufferSubData;
glad_debug_glBufferSubDataARB = glad_glBufferSubDataARB;
+ glad_debug_glCallList = glad_glCallList;
+ glad_debug_glCallLists = glad_glCallLists;
glad_debug_glCheckFramebufferStatus = glad_glCheckFramebufferStatus;
glad_debug_glCheckFramebufferStatusEXT = glad_glCheckFramebufferStatusEXT;
glad_debug_glCheckNamedFramebufferStatus = glad_glCheckNamedFramebufferStatus;
glad_debug_glClampColor = glad_glClampColor;
glad_debug_glClampColorARB = glad_glClampColorARB;
glad_debug_glClear = glad_glClear;
- glad_debug_glClearAccumxOES = glad_glClearAccumxOES;
+ glad_debug_glClearAccum = glad_glClearAccum;
glad_debug_glClearBufferData = glad_glClearBufferData;
glad_debug_glClearBufferSubData = glad_glClearBufferSubData;
glad_debug_glClearBufferfi = glad_glClearBufferfi;
@@ -11173,10 +13942,9 @@ void gladUninstallGLDebug(void) {
glad_debug_glClearBufferiv = glad_glClearBufferiv;
glad_debug_glClearBufferuiv = glad_glClearBufferuiv;
glad_debug_glClearColor = glad_glClearColor;
- glad_debug_glClearColorxOES = glad_glClearColorxOES;
glad_debug_glClearDepth = glad_glClearDepth;
glad_debug_glClearDepthf = glad_glClearDepthf;
- glad_debug_glClearDepthxOES = glad_glClearDepthxOES;
+ glad_debug_glClearIndex = glad_glClearIndex;
glad_debug_glClearNamedBufferData = glad_glClearNamedBufferData;
glad_debug_glClearNamedBufferSubData = glad_glClearNamedBufferSubData;
glad_debug_glClearNamedFramebufferfi = glad_glClearNamedFramebufferfi;
@@ -11186,15 +13954,50 @@ void gladUninstallGLDebug(void) {
glad_debug_glClearStencil = glad_glClearStencil;
glad_debug_glClearTexImage = glad_glClearTexImage;
glad_debug_glClearTexSubImage = glad_glClearTexSubImage;
+ glad_debug_glClientActiveTexture = glad_glClientActiveTexture;
glad_debug_glClientActiveTextureARB = glad_glClientActiveTextureARB;
glad_debug_glClientWaitSync = glad_glClientWaitSync;
- glad_debug_glClipPlanexOES = glad_glClipPlanexOES;
- glad_debug_glColor3xOES = glad_glColor3xOES;
- glad_debug_glColor3xvOES = glad_glColor3xvOES;
- glad_debug_glColor4xOES = glad_glColor4xOES;
- glad_debug_glColor4xvOES = glad_glColor4xvOES;
+ glad_debug_glClipPlane = glad_glClipPlane;
+ glad_debug_glColor3b = glad_glColor3b;
+ glad_debug_glColor3bv = glad_glColor3bv;
+ glad_debug_glColor3d = glad_glColor3d;
+ glad_debug_glColor3dv = glad_glColor3dv;
+ glad_debug_glColor3f = glad_glColor3f;
+ glad_debug_glColor3fv = glad_glColor3fv;
+ glad_debug_glColor3i = glad_glColor3i;
+ glad_debug_glColor3iv = glad_glColor3iv;
+ glad_debug_glColor3s = glad_glColor3s;
+ glad_debug_glColor3sv = glad_glColor3sv;
+ glad_debug_glColor3ub = glad_glColor3ub;
+ glad_debug_glColor3ubv = glad_glColor3ubv;
+ glad_debug_glColor3ui = glad_glColor3ui;
+ glad_debug_glColor3uiv = glad_glColor3uiv;
+ glad_debug_glColor3us = glad_glColor3us;
+ glad_debug_glColor3usv = glad_glColor3usv;
+ glad_debug_glColor4b = glad_glColor4b;
+ glad_debug_glColor4bv = glad_glColor4bv;
+ glad_debug_glColor4d = glad_glColor4d;
+ glad_debug_glColor4dv = glad_glColor4dv;
+ glad_debug_glColor4f = glad_glColor4f;
+ glad_debug_glColor4fv = glad_glColor4fv;
+ glad_debug_glColor4i = glad_glColor4i;
+ glad_debug_glColor4iv = glad_glColor4iv;
+ glad_debug_glColor4s = glad_glColor4s;
+ glad_debug_glColor4sv = glad_glColor4sv;
+ glad_debug_glColor4ub = glad_glColor4ub;
+ glad_debug_glColor4ubv = glad_glColor4ubv;
+ glad_debug_glColor4ui = glad_glColor4ui;
+ glad_debug_glColor4uiv = glad_glColor4uiv;
+ glad_debug_glColor4us = glad_glColor4us;
+ glad_debug_glColor4usv = glad_glColor4usv;
glad_debug_glColorMask = glad_glColorMask;
glad_debug_glColorMaski = glad_glColorMaski;
+ glad_debug_glColorMaterial = glad_glColorMaterial;
+ glad_debug_glColorP3ui = glad_glColorP3ui;
+ glad_debug_glColorP3uiv = glad_glColorP3uiv;
+ glad_debug_glColorP4ui = glad_glColorP4ui;
+ glad_debug_glColorP4uiv = glad_glColorP4uiv;
+ glad_debug_glColorPointer = glad_glColorPointer;
glad_debug_glCompileShader = glad_glCompileShader;
glad_debug_glCompileShaderARB = glad_glCompileShaderARB;
glad_debug_glCompileShaderIncludeARB = glad_glCompileShaderIncludeARB;
@@ -11213,11 +14016,10 @@ void gladUninstallGLDebug(void) {
glad_debug_glCompressedTextureSubImage1D = glad_glCompressedTextureSubImage1D;
glad_debug_glCompressedTextureSubImage2D = glad_glCompressedTextureSubImage2D;
glad_debug_glCompressedTextureSubImage3D = glad_glCompressedTextureSubImage3D;
- glad_debug_glConvolutionParameterxOES = glad_glConvolutionParameterxOES;
- glad_debug_glConvolutionParameterxvOES = glad_glConvolutionParameterxvOES;
glad_debug_glCopyBufferSubData = glad_glCopyBufferSubData;
glad_debug_glCopyImageSubData = glad_glCopyImageSubData;
glad_debug_glCopyNamedBufferSubData = glad_glCopyNamedBufferSubData;
+ glad_debug_glCopyPixels = glad_glCopyPixels;
glad_debug_glCopyTexImage1D = glad_glCopyTexImage1D;
glad_debug_glCopyTexImage2D = glad_glCopyTexImage2D;
glad_debug_glCopyTexSubImage1D = glad_glCopyTexSubImage1D;
@@ -11251,6 +14053,7 @@ void gladUninstallGLDebug(void) {
glad_debug_glDeleteBuffersARB = glad_glDeleteBuffersARB;
glad_debug_glDeleteFramebuffers = glad_glDeleteFramebuffers;
glad_debug_glDeleteFramebuffersEXT = glad_glDeleteFramebuffersEXT;
+ glad_debug_glDeleteLists = glad_glDeleteLists;
glad_debug_glDeleteNamedStringARB = glad_glDeleteNamedStringARB;
glad_debug_glDeleteObjectARB = glad_glDeleteObjectARB;
glad_debug_glDeleteProgram = glad_glDeleteProgram;
@@ -11272,10 +14075,10 @@ void gladUninstallGLDebug(void) {
glad_debug_glDepthRangeArrayv = glad_glDepthRangeArrayv;
glad_debug_glDepthRangeIndexed = glad_glDepthRangeIndexed;
glad_debug_glDepthRangef = glad_glDepthRangef;
- glad_debug_glDepthRangexOES = glad_glDepthRangexOES;
glad_debug_glDetachObjectARB = glad_glDetachObjectARB;
glad_debug_glDetachShader = glad_glDetachShader;
glad_debug_glDisable = glad_glDisable;
+ glad_debug_glDisableClientState = glad_glDisableClientState;
glad_debug_glDisableVertexArrayAttrib = glad_glDisableVertexArrayAttrib;
glad_debug_glDisableVertexAttribArray = glad_glDisableVertexAttribArray;
glad_debug_glDisableVertexAttribArrayARB = glad_glDisableVertexAttribArrayARB;
@@ -11301,40 +14104,62 @@ void gladUninstallGLDebug(void) {
glad_debug_glDrawElementsInstancedBaseVertex = glad_glDrawElementsInstancedBaseVertex;
glad_debug_glDrawElementsInstancedBaseVertexBaseInstance = glad_glDrawElementsInstancedBaseVertexBaseInstance;
glad_debug_glDrawElementsInstancedEXT = glad_glDrawElementsInstancedEXT;
+ glad_debug_glDrawPixels = glad_glDrawPixels;
glad_debug_glDrawRangeElements = glad_glDrawRangeElements;
glad_debug_glDrawRangeElementsBaseVertex = glad_glDrawRangeElementsBaseVertex;
glad_debug_glDrawTransformFeedback = glad_glDrawTransformFeedback;
glad_debug_glDrawTransformFeedbackInstanced = glad_glDrawTransformFeedbackInstanced;
glad_debug_glDrawTransformFeedbackStream = glad_glDrawTransformFeedbackStream;
glad_debug_glDrawTransformFeedbackStreamInstanced = glad_glDrawTransformFeedbackStreamInstanced;
+ glad_debug_glEdgeFlag = glad_glEdgeFlag;
+ glad_debug_glEdgeFlagPointer = glad_glEdgeFlagPointer;
+ glad_debug_glEdgeFlagv = glad_glEdgeFlagv;
glad_debug_glEnable = glad_glEnable;
+ glad_debug_glEnableClientState = glad_glEnableClientState;
glad_debug_glEnableVertexArrayAttrib = glad_glEnableVertexArrayAttrib;
glad_debug_glEnableVertexAttribArray = glad_glEnableVertexAttribArray;
glad_debug_glEnableVertexAttribArrayARB = glad_glEnableVertexAttribArrayARB;
glad_debug_glEnablei = glad_glEnablei;
+ glad_debug_glEnd = glad_glEnd;
glad_debug_glEndConditionalRender = glad_glEndConditionalRender;
+ glad_debug_glEndList = glad_glEndList;
glad_debug_glEndQuery = glad_glEndQuery;
glad_debug_glEndQueryARB = glad_glEndQueryARB;
glad_debug_glEndQueryIndexed = glad_glEndQueryIndexed;
glad_debug_glEndTransformFeedback = glad_glEndTransformFeedback;
- glad_debug_glEvalCoord1xOES = glad_glEvalCoord1xOES;
- glad_debug_glEvalCoord1xvOES = glad_glEvalCoord1xvOES;
- glad_debug_glEvalCoord2xOES = glad_glEvalCoord2xOES;
- glad_debug_glEvalCoord2xvOES = glad_glEvalCoord2xvOES;
+ glad_debug_glEvalCoord1d = glad_glEvalCoord1d;
+ glad_debug_glEvalCoord1dv = glad_glEvalCoord1dv;
+ glad_debug_glEvalCoord1f = glad_glEvalCoord1f;
+ glad_debug_glEvalCoord1fv = glad_glEvalCoord1fv;
+ glad_debug_glEvalCoord2d = glad_glEvalCoord2d;
+ glad_debug_glEvalCoord2dv = glad_glEvalCoord2dv;
+ glad_debug_glEvalCoord2f = glad_glEvalCoord2f;
+ glad_debug_glEvalCoord2fv = glad_glEvalCoord2fv;
+ glad_debug_glEvalMesh1 = glad_glEvalMesh1;
+ glad_debug_glEvalMesh2 = glad_glEvalMesh2;
+ glad_debug_glEvalPoint1 = glad_glEvalPoint1;
+ glad_debug_glEvalPoint2 = glad_glEvalPoint2;
glad_debug_glEvaluateDepthValuesARB = glad_glEvaluateDepthValuesARB;
- glad_debug_glFeedbackBufferxOES = glad_glFeedbackBufferxOES;
+ glad_debug_glFeedbackBuffer = glad_glFeedbackBuffer;
glad_debug_glFenceSync = glad_glFenceSync;
glad_debug_glFinish = glad_glFinish;
glad_debug_glFlush = glad_glFlush;
glad_debug_glFlushMappedBufferRange = glad_glFlushMappedBufferRange;
glad_debug_glFlushMappedNamedBufferRange = glad_glFlushMappedNamedBufferRange;
+ glad_debug_glFogCoordPointer = glad_glFogCoordPointer;
glad_debug_glFogCoordPointerEXT = glad_glFogCoordPointerEXT;
+ glad_debug_glFogCoordd = glad_glFogCoordd;
glad_debug_glFogCoorddEXT = glad_glFogCoorddEXT;
+ glad_debug_glFogCoorddv = glad_glFogCoorddv;
glad_debug_glFogCoorddvEXT = glad_glFogCoorddvEXT;
+ glad_debug_glFogCoordf = glad_glFogCoordf;
glad_debug_glFogCoordfEXT = glad_glFogCoordfEXT;
+ glad_debug_glFogCoordfv = glad_glFogCoordfv;
glad_debug_glFogCoordfvEXT = glad_glFogCoordfvEXT;
- glad_debug_glFogxOES = glad_glFogxOES;
- glad_debug_glFogxvOES = glad_glFogxvOES;
+ glad_debug_glFogf = glad_glFogf;
+ glad_debug_glFogfv = glad_glFogfv;
+ glad_debug_glFogi = glad_glFogi;
+ glad_debug_glFogiv = glad_glFogiv;
glad_debug_glFramebufferParameteri = glad_glFramebufferParameteri;
glad_debug_glFramebufferRenderbuffer = glad_glFramebufferRenderbuffer;
glad_debug_glFramebufferRenderbufferEXT = glad_glFramebufferRenderbufferEXT;
@@ -11351,11 +14176,12 @@ void gladUninstallGLDebug(void) {
glad_debug_glFramebufferTextureLayer = glad_glFramebufferTextureLayer;
glad_debug_glFramebufferTextureLayerARB = glad_glFramebufferTextureLayerARB;
glad_debug_glFrontFace = glad_glFrontFace;
- glad_debug_glFrustumxOES = glad_glFrustumxOES;
+ glad_debug_glFrustum = glad_glFrustum;
glad_debug_glGenBuffers = glad_glGenBuffers;
glad_debug_glGenBuffersARB = glad_glGenBuffersARB;
glad_debug_glGenFramebuffers = glad_glGenFramebuffers;
glad_debug_glGenFramebuffersEXT = glad_glGenFramebuffersEXT;
+ glad_debug_glGenLists = glad_glGenLists;
glad_debug_glGenProgramPipelines = glad_glGenProgramPipelines;
glad_debug_glGenProgramsARB = glad_glGenProgramsARB;
glad_debug_glGenQueries = glad_glGenQueries;
@@ -11394,18 +14220,16 @@ void gladUninstallGLDebug(void) {
glad_debug_glGetBufferPointervARB = glad_glGetBufferPointervARB;
glad_debug_glGetBufferSubData = glad_glGetBufferSubData;
glad_debug_glGetBufferSubDataARB = glad_glGetBufferSubDataARB;
- glad_debug_glGetClipPlanexOES = glad_glGetClipPlanexOES;
+ glad_debug_glGetClipPlane = glad_glGetClipPlane;
glad_debug_glGetCompressedTexImage = glad_glGetCompressedTexImage;
glad_debug_glGetCompressedTexImageARB = glad_glGetCompressedTexImageARB;
glad_debug_glGetCompressedTextureImage = glad_glGetCompressedTextureImage;
glad_debug_glGetCompressedTextureSubImage = glad_glGetCompressedTextureSubImage;
- glad_debug_glGetConvolutionParameterxvOES = glad_glGetConvolutionParameterxvOES;
glad_debug_glGetDebugMessageLog = glad_glGetDebugMessageLog;
glad_debug_glGetDebugMessageLogARB = glad_glGetDebugMessageLogARB;
glad_debug_glGetDoublei_v = glad_glGetDoublei_v;
glad_debug_glGetDoublev = glad_glGetDoublev;
glad_debug_glGetError = glad_glGetError;
- glad_debug_glGetFixedvOES = glad_glGetFixedvOES;
glad_debug_glGetFloati_v = glad_glGetFloati_v;
glad_debug_glGetFloatv = glad_glGetFloatv;
glad_debug_glGetFragDataIndex = glad_glGetFragDataIndex;
@@ -11414,7 +14238,6 @@ void gladUninstallGLDebug(void) {
glad_debug_glGetFramebufferAttachmentParameterivEXT = glad_glGetFramebufferAttachmentParameterivEXT;
glad_debug_glGetFramebufferParameteriv = glad_glGetFramebufferParameteriv;
glad_debug_glGetHandleARB = glad_glGetHandleARB;
- glad_debug_glGetHistogramParameterxvOES = glad_glGetHistogramParameterxvOES;
glad_debug_glGetInfoLogARB = glad_glGetInfoLogARB;
glad_debug_glGetInteger64i_v = glad_glGetInteger64i_v;
glad_debug_glGetInteger64v = glad_glGetInteger64v;
@@ -11422,9 +14245,13 @@ void gladUninstallGLDebug(void) {
glad_debug_glGetIntegerv = glad_glGetIntegerv;
glad_debug_glGetInternalformati64v = glad_glGetInternalformati64v;
glad_debug_glGetInternalformativ = glad_glGetInternalformativ;
- glad_debug_glGetLightxOES = glad_glGetLightxOES;
- glad_debug_glGetMapxvOES = glad_glGetMapxvOES;
- glad_debug_glGetMaterialxOES = glad_glGetMaterialxOES;
+ glad_debug_glGetLightfv = glad_glGetLightfv;
+ glad_debug_glGetLightiv = glad_glGetLightiv;
+ glad_debug_glGetMapdv = glad_glGetMapdv;
+ glad_debug_glGetMapfv = glad_glGetMapfv;
+ glad_debug_glGetMapiv = glad_glGetMapiv;
+ glad_debug_glGetMaterialfv = glad_glGetMaterialfv;
+ glad_debug_glGetMaterialiv = glad_glGetMaterialiv;
glad_debug_glGetMultisamplefv = glad_glGetMultisamplefv;
glad_debug_glGetNamedBufferParameteri64v = glad_glGetNamedBufferParameteri64v;
glad_debug_glGetNamedBufferParameteriv = glad_glGetNamedBufferParameteriv;
@@ -11439,8 +14266,11 @@ void gladUninstallGLDebug(void) {
glad_debug_glGetObjectParameterfvARB = glad_glGetObjectParameterfvARB;
glad_debug_glGetObjectParameterivARB = glad_glGetObjectParameterivARB;
glad_debug_glGetObjectPtrLabel = glad_glGetObjectPtrLabel;
- glad_debug_glGetPixelMapxv = glad_glGetPixelMapxv;
+ glad_debug_glGetPixelMapfv = glad_glGetPixelMapfv;
+ glad_debug_glGetPixelMapuiv = glad_glGetPixelMapuiv;
+ glad_debug_glGetPixelMapusv = glad_glGetPixelMapusv;
glad_debug_glGetPointerv = glad_glGetPointerv;
+ glad_debug_glGetPolygonStipple = glad_glGetPolygonStipple;
glad_debug_glGetProgramBinary = glad_glGetProgramBinary;
glad_debug_glGetProgramEnvParameterdvARB = glad_glGetProgramEnvParameterdvARB;
glad_debug_glGetProgramEnvParameterfvARB = glad_glGetProgramEnvParameterfvARB;
@@ -11488,17 +14318,18 @@ void gladUninstallGLDebug(void) {
glad_debug_glGetSubroutineIndex = glad_glGetSubroutineIndex;
glad_debug_glGetSubroutineUniformLocation = glad_glGetSubroutineUniformLocation;
glad_debug_glGetSynciv = glad_glGetSynciv;
- glad_debug_glGetTexEnvxvOES = glad_glGetTexEnvxvOES;
- glad_debug_glGetTexGenxvOES = glad_glGetTexGenxvOES;
+ glad_debug_glGetTexEnvfv = glad_glGetTexEnvfv;
+ glad_debug_glGetTexEnviv = glad_glGetTexEnviv;
+ glad_debug_glGetTexGendv = glad_glGetTexGendv;
+ glad_debug_glGetTexGenfv = glad_glGetTexGenfv;
+ glad_debug_glGetTexGeniv = glad_glGetTexGeniv;
glad_debug_glGetTexImage = glad_glGetTexImage;
glad_debug_glGetTexLevelParameterfv = glad_glGetTexLevelParameterfv;
glad_debug_glGetTexLevelParameteriv = glad_glGetTexLevelParameteriv;
- glad_debug_glGetTexLevelParameterxvOES = glad_glGetTexLevelParameterxvOES;
glad_debug_glGetTexParameterIiv = glad_glGetTexParameterIiv;
glad_debug_glGetTexParameterIuiv = glad_glGetTexParameterIuiv;
glad_debug_glGetTexParameterfv = glad_glGetTexParameterfv;
glad_debug_glGetTexParameteriv = glad_glGetTexParameteriv;
- glad_debug_glGetTexParameterxvOES = glad_glGetTexParameterxvOES;
glad_debug_glGetTextureImage = glad_glGetTextureImage;
glad_debug_glGetTextureLevelParameterfv = glad_glGetTextureLevelParameterfv;
glad_debug_glGetTextureLevelParameteriv = glad_glGetTextureLevelParameteriv;
@@ -11541,8 +14372,20 @@ void gladUninstallGLDebug(void) {
glad_debug_glGetnUniformi64vARB = glad_glGetnUniformi64vARB;
glad_debug_glGetnUniformui64vARB = glad_glGetnUniformui64vARB;
glad_debug_glHint = glad_glHint;
- glad_debug_glIndexxOES = glad_glIndexxOES;
- glad_debug_glIndexxvOES = glad_glIndexxvOES;
+ glad_debug_glIndexMask = glad_glIndexMask;
+ glad_debug_glIndexPointer = glad_glIndexPointer;
+ glad_debug_glIndexd = glad_glIndexd;
+ glad_debug_glIndexdv = glad_glIndexdv;
+ glad_debug_glIndexf = glad_glIndexf;
+ glad_debug_glIndexfv = glad_glIndexfv;
+ glad_debug_glIndexi = glad_glIndexi;
+ glad_debug_glIndexiv = glad_glIndexiv;
+ glad_debug_glIndexs = glad_glIndexs;
+ glad_debug_glIndexsv = glad_glIndexsv;
+ glad_debug_glIndexub = glad_glIndexub;
+ glad_debug_glIndexubv = glad_glIndexubv;
+ glad_debug_glInitNames = glad_glInitNames;
+ glad_debug_glInterleavedArrays = glad_glInterleavedArrays;
glad_debug_glInvalidateBufferData = glad_glInvalidateBufferData;
glad_debug_glInvalidateBufferSubData = glad_glInvalidateBufferSubData;
glad_debug_glInvalidateFramebuffer = glad_glInvalidateFramebuffer;
@@ -11557,6 +14400,7 @@ void gladUninstallGLDebug(void) {
glad_debug_glIsEnabledi = glad_glIsEnabledi;
glad_debug_glIsFramebuffer = glad_glIsFramebuffer;
glad_debug_glIsFramebufferEXT = glad_glIsFramebufferEXT;
+ glad_debug_glIsList = glad_glIsList;
glad_debug_glIsNamedStringARB = glad_glIsNamedStringARB;
glad_debug_glIsProgram = glad_glIsProgram;
glad_debug_glIsProgramARB = glad_glIsProgramARB;
@@ -11571,83 +14415,132 @@ void gladUninstallGLDebug(void) {
glad_debug_glIsTexture = glad_glIsTexture;
glad_debug_glIsTransformFeedback = glad_glIsTransformFeedback;
glad_debug_glIsVertexArray = glad_glIsVertexArray;
- glad_debug_glLightModelxOES = glad_glLightModelxOES;
- glad_debug_glLightModelxvOES = glad_glLightModelxvOES;
- glad_debug_glLightxOES = glad_glLightxOES;
- glad_debug_glLightxvOES = glad_glLightxvOES;
+ glad_debug_glLightModelf = glad_glLightModelf;
+ glad_debug_glLightModelfv = glad_glLightModelfv;
+ glad_debug_glLightModeli = glad_glLightModeli;
+ glad_debug_glLightModeliv = glad_glLightModeliv;
+ glad_debug_glLightf = glad_glLightf;
+ glad_debug_glLightfv = glad_glLightfv;
+ glad_debug_glLighti = glad_glLighti;
+ glad_debug_glLightiv = glad_glLightiv;
+ glad_debug_glLineStipple = glad_glLineStipple;
glad_debug_glLineWidth = glad_glLineWidth;
- glad_debug_glLineWidthxOES = glad_glLineWidthxOES;
glad_debug_glLinkProgram = glad_glLinkProgram;
glad_debug_glLinkProgramARB = glad_glLinkProgramARB;
- glad_debug_glLoadMatrixxOES = glad_glLoadMatrixxOES;
+ glad_debug_glListBase = glad_glListBase;
+ glad_debug_glLoadIdentity = glad_glLoadIdentity;
+ glad_debug_glLoadMatrixd = glad_glLoadMatrixd;
+ glad_debug_glLoadMatrixf = glad_glLoadMatrixf;
+ glad_debug_glLoadName = glad_glLoadName;
+ glad_debug_glLoadTransposeMatrixd = glad_glLoadTransposeMatrixd;
glad_debug_glLoadTransposeMatrixdARB = glad_glLoadTransposeMatrixdARB;
+ glad_debug_glLoadTransposeMatrixf = glad_glLoadTransposeMatrixf;
glad_debug_glLoadTransposeMatrixfARB = glad_glLoadTransposeMatrixfARB;
- glad_debug_glLoadTransposeMatrixxOES = glad_glLoadTransposeMatrixxOES;
glad_debug_glLogicOp = glad_glLogicOp;
- glad_debug_glMap1xOES = glad_glMap1xOES;
- glad_debug_glMap2xOES = glad_glMap2xOES;
+ glad_debug_glMap1d = glad_glMap1d;
+ glad_debug_glMap1f = glad_glMap1f;
+ glad_debug_glMap2d = glad_glMap2d;
+ glad_debug_glMap2f = glad_glMap2f;
glad_debug_glMapBuffer = glad_glMapBuffer;
glad_debug_glMapBufferARB = glad_glMapBufferARB;
glad_debug_glMapBufferRange = glad_glMapBufferRange;
- glad_debug_glMapGrid1xOES = glad_glMapGrid1xOES;
- glad_debug_glMapGrid2xOES = glad_glMapGrid2xOES;
+ glad_debug_glMapGrid1d = glad_glMapGrid1d;
+ glad_debug_glMapGrid1f = glad_glMapGrid1f;
+ glad_debug_glMapGrid2d = glad_glMapGrid2d;
+ glad_debug_glMapGrid2f = glad_glMapGrid2f;
glad_debug_glMapNamedBuffer = glad_glMapNamedBuffer;
glad_debug_glMapNamedBufferRange = glad_glMapNamedBufferRange;
- glad_debug_glMaterialxOES = glad_glMaterialxOES;
- glad_debug_glMaterialxvOES = glad_glMaterialxvOES;
+ glad_debug_glMaterialf = glad_glMaterialf;
+ glad_debug_glMaterialfv = glad_glMaterialfv;
+ glad_debug_glMateriali = glad_glMateriali;
+ glad_debug_glMaterialiv = glad_glMaterialiv;
+ glad_debug_glMatrixMode = glad_glMatrixMode;
glad_debug_glMemoryBarrier = glad_glMemoryBarrier;
- glad_debug_glMemoryBarrierByRegion = glad_glMemoryBarrierByRegion;
glad_debug_glMinSampleShading = glad_glMinSampleShading;
glad_debug_glMinSampleShadingARB = glad_glMinSampleShadingARB;
- glad_debug_glMultMatrixxOES = glad_glMultMatrixxOES;
+ glad_debug_glMultMatrixd = glad_glMultMatrixd;
+ glad_debug_glMultMatrixf = glad_glMultMatrixf;
+ glad_debug_glMultTransposeMatrixd = glad_glMultTransposeMatrixd;
glad_debug_glMultTransposeMatrixdARB = glad_glMultTransposeMatrixdARB;
+ glad_debug_glMultTransposeMatrixf = glad_glMultTransposeMatrixf;
glad_debug_glMultTransposeMatrixfARB = glad_glMultTransposeMatrixfARB;
- glad_debug_glMultTransposeMatrixxOES = glad_glMultTransposeMatrixxOES;
glad_debug_glMultiDrawArrays = glad_glMultiDrawArrays;
glad_debug_glMultiDrawArraysIndirect = glad_glMultiDrawArraysIndirect;
glad_debug_glMultiDrawElements = glad_glMultiDrawElements;
glad_debug_glMultiDrawElementsBaseVertex = glad_glMultiDrawElementsBaseVertex;
glad_debug_glMultiDrawElementsIndirect = glad_glMultiDrawElementsIndirect;
+ glad_debug_glMultiTexCoord1d = glad_glMultiTexCoord1d;
glad_debug_glMultiTexCoord1dARB = glad_glMultiTexCoord1dARB;
+ glad_debug_glMultiTexCoord1dv = glad_glMultiTexCoord1dv;
glad_debug_glMultiTexCoord1dvARB = glad_glMultiTexCoord1dvARB;
+ glad_debug_glMultiTexCoord1f = glad_glMultiTexCoord1f;
glad_debug_glMultiTexCoord1fARB = glad_glMultiTexCoord1fARB;
+ glad_debug_glMultiTexCoord1fv = glad_glMultiTexCoord1fv;
glad_debug_glMultiTexCoord1fvARB = glad_glMultiTexCoord1fvARB;
+ glad_debug_glMultiTexCoord1i = glad_glMultiTexCoord1i;
glad_debug_glMultiTexCoord1iARB = glad_glMultiTexCoord1iARB;
+ glad_debug_glMultiTexCoord1iv = glad_glMultiTexCoord1iv;
glad_debug_glMultiTexCoord1ivARB = glad_glMultiTexCoord1ivARB;
+ glad_debug_glMultiTexCoord1s = glad_glMultiTexCoord1s;
glad_debug_glMultiTexCoord1sARB = glad_glMultiTexCoord1sARB;
+ glad_debug_glMultiTexCoord1sv = glad_glMultiTexCoord1sv;
glad_debug_glMultiTexCoord1svARB = glad_glMultiTexCoord1svARB;
- glad_debug_glMultiTexCoord1xOES = glad_glMultiTexCoord1xOES;
- glad_debug_glMultiTexCoord1xvOES = glad_glMultiTexCoord1xvOES;
+ glad_debug_glMultiTexCoord2d = glad_glMultiTexCoord2d;
glad_debug_glMultiTexCoord2dARB = glad_glMultiTexCoord2dARB;
+ glad_debug_glMultiTexCoord2dv = glad_glMultiTexCoord2dv;
glad_debug_glMultiTexCoord2dvARB = glad_glMultiTexCoord2dvARB;
+ glad_debug_glMultiTexCoord2f = glad_glMultiTexCoord2f;
glad_debug_glMultiTexCoord2fARB = glad_glMultiTexCoord2fARB;
+ glad_debug_glMultiTexCoord2fv = glad_glMultiTexCoord2fv;
glad_debug_glMultiTexCoord2fvARB = glad_glMultiTexCoord2fvARB;
+ glad_debug_glMultiTexCoord2i = glad_glMultiTexCoord2i;
glad_debug_glMultiTexCoord2iARB = glad_glMultiTexCoord2iARB;
+ glad_debug_glMultiTexCoord2iv = glad_glMultiTexCoord2iv;
glad_debug_glMultiTexCoord2ivARB = glad_glMultiTexCoord2ivARB;
+ glad_debug_glMultiTexCoord2s = glad_glMultiTexCoord2s;
glad_debug_glMultiTexCoord2sARB = glad_glMultiTexCoord2sARB;
+ glad_debug_glMultiTexCoord2sv = glad_glMultiTexCoord2sv;
glad_debug_glMultiTexCoord2svARB = glad_glMultiTexCoord2svARB;
- glad_debug_glMultiTexCoord2xOES = glad_glMultiTexCoord2xOES;
- glad_debug_glMultiTexCoord2xvOES = glad_glMultiTexCoord2xvOES;
+ glad_debug_glMultiTexCoord3d = glad_glMultiTexCoord3d;
glad_debug_glMultiTexCoord3dARB = glad_glMultiTexCoord3dARB;
+ glad_debug_glMultiTexCoord3dv = glad_glMultiTexCoord3dv;
glad_debug_glMultiTexCoord3dvARB = glad_glMultiTexCoord3dvARB;
+ glad_debug_glMultiTexCoord3f = glad_glMultiTexCoord3f;
glad_debug_glMultiTexCoord3fARB = glad_glMultiTexCoord3fARB;
+ glad_debug_glMultiTexCoord3fv = glad_glMultiTexCoord3fv;
glad_debug_glMultiTexCoord3fvARB = glad_glMultiTexCoord3fvARB;
+ glad_debug_glMultiTexCoord3i = glad_glMultiTexCoord3i;
glad_debug_glMultiTexCoord3iARB = glad_glMultiTexCoord3iARB;
+ glad_debug_glMultiTexCoord3iv = glad_glMultiTexCoord3iv;
glad_debug_glMultiTexCoord3ivARB = glad_glMultiTexCoord3ivARB;
+ glad_debug_glMultiTexCoord3s = glad_glMultiTexCoord3s;
glad_debug_glMultiTexCoord3sARB = glad_glMultiTexCoord3sARB;
+ glad_debug_glMultiTexCoord3sv = glad_glMultiTexCoord3sv;
glad_debug_glMultiTexCoord3svARB = glad_glMultiTexCoord3svARB;
- glad_debug_glMultiTexCoord3xOES = glad_glMultiTexCoord3xOES;
- glad_debug_glMultiTexCoord3xvOES = glad_glMultiTexCoord3xvOES;
+ glad_debug_glMultiTexCoord4d = glad_glMultiTexCoord4d;
glad_debug_glMultiTexCoord4dARB = glad_glMultiTexCoord4dARB;
+ glad_debug_glMultiTexCoord4dv = glad_glMultiTexCoord4dv;
glad_debug_glMultiTexCoord4dvARB = glad_glMultiTexCoord4dvARB;
+ glad_debug_glMultiTexCoord4f = glad_glMultiTexCoord4f;
glad_debug_glMultiTexCoord4fARB = glad_glMultiTexCoord4fARB;
+ glad_debug_glMultiTexCoord4fv = glad_glMultiTexCoord4fv;
glad_debug_glMultiTexCoord4fvARB = glad_glMultiTexCoord4fvARB;
+ glad_debug_glMultiTexCoord4i = glad_glMultiTexCoord4i;
glad_debug_glMultiTexCoord4iARB = glad_glMultiTexCoord4iARB;
+ glad_debug_glMultiTexCoord4iv = glad_glMultiTexCoord4iv;
glad_debug_glMultiTexCoord4ivARB = glad_glMultiTexCoord4ivARB;
+ glad_debug_glMultiTexCoord4s = glad_glMultiTexCoord4s;
glad_debug_glMultiTexCoord4sARB = glad_glMultiTexCoord4sARB;
+ glad_debug_glMultiTexCoord4sv = glad_glMultiTexCoord4sv;
glad_debug_glMultiTexCoord4svARB = glad_glMultiTexCoord4svARB;
- glad_debug_glMultiTexCoord4xOES = glad_glMultiTexCoord4xOES;
- glad_debug_glMultiTexCoord4xvOES = glad_glMultiTexCoord4xvOES;
+ glad_debug_glMultiTexCoordP1ui = glad_glMultiTexCoordP1ui;
+ glad_debug_glMultiTexCoordP1uiv = glad_glMultiTexCoordP1uiv;
+ glad_debug_glMultiTexCoordP2ui = glad_glMultiTexCoordP2ui;
+ glad_debug_glMultiTexCoordP2uiv = glad_glMultiTexCoordP2uiv;
+ glad_debug_glMultiTexCoordP3ui = glad_glMultiTexCoordP3ui;
+ glad_debug_glMultiTexCoordP3uiv = glad_glMultiTexCoordP3uiv;
+ glad_debug_glMultiTexCoordP4ui = glad_glMultiTexCoordP4ui;
+ glad_debug_glMultiTexCoordP4uiv = glad_glMultiTexCoordP4uiv;
glad_debug_glNamedBufferData = glad_glNamedBufferData;
glad_debug_glNamedBufferStorage = glad_glNamedBufferStorage;
glad_debug_glNamedBufferSubData = glad_glNamedBufferSubData;
@@ -11662,35 +14555,51 @@ void gladUninstallGLDebug(void) {
glad_debug_glNamedRenderbufferStorage = glad_glNamedRenderbufferStorage;
glad_debug_glNamedRenderbufferStorageMultisample = glad_glNamedRenderbufferStorageMultisample;
glad_debug_glNamedStringARB = glad_glNamedStringARB;
- glad_debug_glNormal3xOES = glad_glNormal3xOES;
- glad_debug_glNormal3xvOES = glad_glNormal3xvOES;
+ glad_debug_glNewList = glad_glNewList;
+ glad_debug_glNormal3b = glad_glNormal3b;
+ glad_debug_glNormal3bv = glad_glNormal3bv;
+ glad_debug_glNormal3d = glad_glNormal3d;
+ glad_debug_glNormal3dv = glad_glNormal3dv;
+ glad_debug_glNormal3f = glad_glNormal3f;
+ glad_debug_glNormal3fv = glad_glNormal3fv;
+ glad_debug_glNormal3i = glad_glNormal3i;
+ glad_debug_glNormal3iv = glad_glNormal3iv;
+ glad_debug_glNormal3s = glad_glNormal3s;
+ glad_debug_glNormal3sv = glad_glNormal3sv;
+ glad_debug_glNormalP3ui = glad_glNormalP3ui;
+ glad_debug_glNormalP3uiv = glad_glNormalP3uiv;
+ glad_debug_glNormalPointer = glad_glNormalPointer;
glad_debug_glObjectLabel = glad_glObjectLabel;
glad_debug_glObjectPtrLabel = glad_glObjectPtrLabel;
- glad_debug_glOrthoxOES = glad_glOrthoxOES;
- glad_debug_glPassThroughxOES = glad_glPassThroughxOES;
+ glad_debug_glOrtho = glad_glOrtho;
+ glad_debug_glPassThrough = glad_glPassThrough;
glad_debug_glPatchParameterfv = glad_glPatchParameterfv;
glad_debug_glPatchParameteri = glad_glPatchParameteri;
glad_debug_glPauseTransformFeedback = glad_glPauseTransformFeedback;
- glad_debug_glPixelMapx = glad_glPixelMapx;
+ glad_debug_glPixelMapfv = glad_glPixelMapfv;
+ glad_debug_glPixelMapuiv = glad_glPixelMapuiv;
+ glad_debug_glPixelMapusv = glad_glPixelMapusv;
glad_debug_glPixelStoref = glad_glPixelStoref;
glad_debug_glPixelStorei = glad_glPixelStorei;
- glad_debug_glPixelStorex = glad_glPixelStorex;
- glad_debug_glPixelTransferxOES = glad_glPixelTransferxOES;
- glad_debug_glPixelZoomxOES = glad_glPixelZoomxOES;
+ glad_debug_glPixelTransferf = glad_glPixelTransferf;
+ glad_debug_glPixelTransferi = glad_glPixelTransferi;
+ glad_debug_glPixelZoom = glad_glPixelZoom;
glad_debug_glPointParameterf = glad_glPointParameterf;
glad_debug_glPointParameterfv = glad_glPointParameterfv;
glad_debug_glPointParameteri = glad_glPointParameteri;
glad_debug_glPointParameteriv = glad_glPointParameteriv;
- glad_debug_glPointParameterxvOES = glad_glPointParameterxvOES;
glad_debug_glPointSize = glad_glPointSize;
- glad_debug_glPointSizexOES = glad_glPointSizexOES;
glad_debug_glPolygonMode = glad_glPolygonMode;
glad_debug_glPolygonOffset = glad_glPolygonOffset;
- glad_debug_glPolygonOffsetxOES = glad_glPolygonOffsetxOES;
+ glad_debug_glPolygonStipple = glad_glPolygonStipple;
+ glad_debug_glPopAttrib = glad_glPopAttrib;
+ glad_debug_glPopClientAttrib = glad_glPopClientAttrib;
glad_debug_glPopDebugGroup = glad_glPopDebugGroup;
+ glad_debug_glPopMatrix = glad_glPopMatrix;
+ glad_debug_glPopName = glad_glPopName;
glad_debug_glPrimitiveBoundingBoxARB = glad_glPrimitiveBoundingBoxARB;
glad_debug_glPrimitiveRestartIndex = glad_glPrimitiveRestartIndex;
- glad_debug_glPrioritizeTexturesxOES = glad_glPrioritizeTexturesxOES;
+ glad_debug_glPrioritizeTextures = glad_glPrioritizeTextures;
glad_debug_glProgramBinary = glad_glProgramBinary;
glad_debug_glProgramEnvParameter4dARB = glad_glProgramEnvParameter4dARB;
glad_debug_glProgramEnvParameter4dvARB = glad_glProgramEnvParameter4dvARB;
@@ -11770,25 +14679,55 @@ void gladUninstallGLDebug(void) {
glad_debug_glProgramUniformMatrix4x3dv = glad_glProgramUniformMatrix4x3dv;
glad_debug_glProgramUniformMatrix4x3fv = glad_glProgramUniformMatrix4x3fv;
glad_debug_glProvokingVertex = glad_glProvokingVertex;
+ glad_debug_glPushAttrib = glad_glPushAttrib;
+ glad_debug_glPushClientAttrib = glad_glPushClientAttrib;
glad_debug_glPushDebugGroup = glad_glPushDebugGroup;
+ glad_debug_glPushMatrix = glad_glPushMatrix;
+ glad_debug_glPushName = glad_glPushName;
glad_debug_glQueryCounter = glad_glQueryCounter;
- glad_debug_glRasterPos2xOES = glad_glRasterPos2xOES;
- glad_debug_glRasterPos2xvOES = glad_glRasterPos2xvOES;
- glad_debug_glRasterPos3xOES = glad_glRasterPos3xOES;
- glad_debug_glRasterPos3xvOES = glad_glRasterPos3xvOES;
- glad_debug_glRasterPos4xOES = glad_glRasterPos4xOES;
- glad_debug_glRasterPos4xvOES = glad_glRasterPos4xvOES;
+ glad_debug_glRasterPos2d = glad_glRasterPos2d;
+ glad_debug_glRasterPos2dv = glad_glRasterPos2dv;
+ glad_debug_glRasterPos2f = glad_glRasterPos2f;
+ glad_debug_glRasterPos2fv = glad_glRasterPos2fv;
+ glad_debug_glRasterPos2i = glad_glRasterPos2i;
+ glad_debug_glRasterPos2iv = glad_glRasterPos2iv;
+ glad_debug_glRasterPos2s = glad_glRasterPos2s;
+ glad_debug_glRasterPos2sv = glad_glRasterPos2sv;
+ glad_debug_glRasterPos3d = glad_glRasterPos3d;
+ glad_debug_glRasterPos3dv = glad_glRasterPos3dv;
+ glad_debug_glRasterPos3f = glad_glRasterPos3f;
+ glad_debug_glRasterPos3fv = glad_glRasterPos3fv;
+ glad_debug_glRasterPos3i = glad_glRasterPos3i;
+ glad_debug_glRasterPos3iv = glad_glRasterPos3iv;
+ glad_debug_glRasterPos3s = glad_glRasterPos3s;
+ glad_debug_glRasterPos3sv = glad_glRasterPos3sv;
+ glad_debug_glRasterPos4d = glad_glRasterPos4d;
+ glad_debug_glRasterPos4dv = glad_glRasterPos4dv;
+ glad_debug_glRasterPos4f = glad_glRasterPos4f;
+ glad_debug_glRasterPos4fv = glad_glRasterPos4fv;
+ glad_debug_glRasterPos4i = glad_glRasterPos4i;
+ glad_debug_glRasterPos4iv = glad_glRasterPos4iv;
+ glad_debug_glRasterPos4s = glad_glRasterPos4s;
+ glad_debug_glRasterPos4sv = glad_glRasterPos4sv;
glad_debug_glReadBuffer = glad_glReadBuffer;
glad_debug_glReadPixels = glad_glReadPixels;
- glad_debug_glRectxOES = glad_glRectxOES;
- glad_debug_glRectxvOES = glad_glRectxvOES;
+ glad_debug_glRectd = glad_glRectd;
+ glad_debug_glRectdv = glad_glRectdv;
+ glad_debug_glRectf = glad_glRectf;
+ glad_debug_glRectfv = glad_glRectfv;
+ glad_debug_glRecti = glad_glRecti;
+ glad_debug_glRectiv = glad_glRectiv;
+ glad_debug_glRects = glad_glRects;
+ glad_debug_glRectsv = glad_glRectsv;
glad_debug_glReleaseShaderCompiler = glad_glReleaseShaderCompiler;
+ glad_debug_glRenderMode = glad_glRenderMode;
glad_debug_glRenderbufferStorage = glad_glRenderbufferStorage;
glad_debug_glRenderbufferStorageEXT = glad_glRenderbufferStorageEXT;
glad_debug_glRenderbufferStorageMultisample = glad_glRenderbufferStorageMultisample;
glad_debug_glRenderbufferStorageMultisampleEXT = glad_glRenderbufferStorageMultisampleEXT;
glad_debug_glResumeTransformFeedback = glad_glResumeTransformFeedback;
- glad_debug_glRotatexOES = glad_glRotatexOES;
+ glad_debug_glRotated = glad_glRotated;
+ glad_debug_glRotatef = glad_glRotatef;
glad_debug_glSampleCoverage = glad_glSampleCoverage;
glad_debug_glSampleCoverageARB = glad_glSampleCoverageARB;
glad_debug_glSampleMaski = glad_glSampleMaski;
@@ -11798,11 +14737,33 @@ void gladUninstallGLDebug(void) {
glad_debug_glSamplerParameterfv = glad_glSamplerParameterfv;
glad_debug_glSamplerParameteri = glad_glSamplerParameteri;
glad_debug_glSamplerParameteriv = glad_glSamplerParameteriv;
- glad_debug_glScalexOES = glad_glScalexOES;
+ glad_debug_glScaled = glad_glScaled;
+ glad_debug_glScalef = glad_glScalef;
glad_debug_glScissor = glad_glScissor;
glad_debug_glScissorArrayv = glad_glScissorArrayv;
glad_debug_glScissorIndexed = glad_glScissorIndexed;
glad_debug_glScissorIndexedv = glad_glScissorIndexedv;
+ glad_debug_glSecondaryColor3b = glad_glSecondaryColor3b;
+ glad_debug_glSecondaryColor3bv = glad_glSecondaryColor3bv;
+ glad_debug_glSecondaryColor3d = glad_glSecondaryColor3d;
+ glad_debug_glSecondaryColor3dv = glad_glSecondaryColor3dv;
+ glad_debug_glSecondaryColor3f = glad_glSecondaryColor3f;
+ glad_debug_glSecondaryColor3fv = glad_glSecondaryColor3fv;
+ glad_debug_glSecondaryColor3i = glad_glSecondaryColor3i;
+ glad_debug_glSecondaryColor3iv = glad_glSecondaryColor3iv;
+ glad_debug_glSecondaryColor3s = glad_glSecondaryColor3s;
+ glad_debug_glSecondaryColor3sv = glad_glSecondaryColor3sv;
+ glad_debug_glSecondaryColor3ub = glad_glSecondaryColor3ub;
+ glad_debug_glSecondaryColor3ubv = glad_glSecondaryColor3ubv;
+ glad_debug_glSecondaryColor3ui = glad_glSecondaryColor3ui;
+ glad_debug_glSecondaryColor3uiv = glad_glSecondaryColor3uiv;
+ glad_debug_glSecondaryColor3us = glad_glSecondaryColor3us;
+ glad_debug_glSecondaryColor3usv = glad_glSecondaryColor3usv;
+ glad_debug_glSecondaryColorP3ui = glad_glSecondaryColorP3ui;
+ glad_debug_glSecondaryColorP3uiv = glad_glSecondaryColorP3uiv;
+ glad_debug_glSecondaryColorPointer = glad_glSecondaryColorPointer;
+ glad_debug_glSelectBuffer = glad_glSelectBuffer;
+ glad_debug_glShadeModel = glad_glShadeModel;
glad_debug_glShaderBinary = glad_glShaderBinary;
glad_debug_glShaderSource = glad_glShaderSource;
glad_debug_glShaderSourceARB = glad_glShaderSourceARB;
@@ -11816,18 +14777,57 @@ void gladUninstallGLDebug(void) {
glad_debug_glStencilOpSeparate = glad_glStencilOpSeparate;
glad_debug_glTexBuffer = glad_glTexBuffer;
glad_debug_glTexBufferRange = glad_glTexBufferRange;
- glad_debug_glTexCoord1xOES = glad_glTexCoord1xOES;
- glad_debug_glTexCoord1xvOES = glad_glTexCoord1xvOES;
- glad_debug_glTexCoord2xOES = glad_glTexCoord2xOES;
- glad_debug_glTexCoord2xvOES = glad_glTexCoord2xvOES;
- glad_debug_glTexCoord3xOES = glad_glTexCoord3xOES;
- glad_debug_glTexCoord3xvOES = glad_glTexCoord3xvOES;
- glad_debug_glTexCoord4xOES = glad_glTexCoord4xOES;
- glad_debug_glTexCoord4xvOES = glad_glTexCoord4xvOES;
- glad_debug_glTexEnvxOES = glad_glTexEnvxOES;
- glad_debug_glTexEnvxvOES = glad_glTexEnvxvOES;
- glad_debug_glTexGenxOES = glad_glTexGenxOES;
- glad_debug_glTexGenxvOES = glad_glTexGenxvOES;
+ glad_debug_glTexCoord1d = glad_glTexCoord1d;
+ glad_debug_glTexCoord1dv = glad_glTexCoord1dv;
+ glad_debug_glTexCoord1f = glad_glTexCoord1f;
+ glad_debug_glTexCoord1fv = glad_glTexCoord1fv;
+ glad_debug_glTexCoord1i = glad_glTexCoord1i;
+ glad_debug_glTexCoord1iv = glad_glTexCoord1iv;
+ glad_debug_glTexCoord1s = glad_glTexCoord1s;
+ glad_debug_glTexCoord1sv = glad_glTexCoord1sv;
+ glad_debug_glTexCoord2d = glad_glTexCoord2d;
+ glad_debug_glTexCoord2dv = glad_glTexCoord2dv;
+ glad_debug_glTexCoord2f = glad_glTexCoord2f;
+ glad_debug_glTexCoord2fv = glad_glTexCoord2fv;
+ glad_debug_glTexCoord2i = glad_glTexCoord2i;
+ glad_debug_glTexCoord2iv = glad_glTexCoord2iv;
+ glad_debug_glTexCoord2s = glad_glTexCoord2s;
+ glad_debug_glTexCoord2sv = glad_glTexCoord2sv;
+ glad_debug_glTexCoord3d = glad_glTexCoord3d;
+ glad_debug_glTexCoord3dv = glad_glTexCoord3dv;
+ glad_debug_glTexCoord3f = glad_glTexCoord3f;
+ glad_debug_glTexCoord3fv = glad_glTexCoord3fv;
+ glad_debug_glTexCoord3i = glad_glTexCoord3i;
+ glad_debug_glTexCoord3iv = glad_glTexCoord3iv;
+ glad_debug_glTexCoord3s = glad_glTexCoord3s;
+ glad_debug_glTexCoord3sv = glad_glTexCoord3sv;
+ glad_debug_glTexCoord4d = glad_glTexCoord4d;
+ glad_debug_glTexCoord4dv = glad_glTexCoord4dv;
+ glad_debug_glTexCoord4f = glad_glTexCoord4f;
+ glad_debug_glTexCoord4fv = glad_glTexCoord4fv;
+ glad_debug_glTexCoord4i = glad_glTexCoord4i;
+ glad_debug_glTexCoord4iv = glad_glTexCoord4iv;
+ glad_debug_glTexCoord4s = glad_glTexCoord4s;
+ glad_debug_glTexCoord4sv = glad_glTexCoord4sv;
+ glad_debug_glTexCoordP1ui = glad_glTexCoordP1ui;
+ glad_debug_glTexCoordP1uiv = glad_glTexCoordP1uiv;
+ glad_debug_glTexCoordP2ui = glad_glTexCoordP2ui;
+ glad_debug_glTexCoordP2uiv = glad_glTexCoordP2uiv;
+ glad_debug_glTexCoordP3ui = glad_glTexCoordP3ui;
+ glad_debug_glTexCoordP3uiv = glad_glTexCoordP3uiv;
+ glad_debug_glTexCoordP4ui = glad_glTexCoordP4ui;
+ glad_debug_glTexCoordP4uiv = glad_glTexCoordP4uiv;
+ glad_debug_glTexCoordPointer = glad_glTexCoordPointer;
+ glad_debug_glTexEnvf = glad_glTexEnvf;
+ glad_debug_glTexEnvfv = glad_glTexEnvfv;
+ glad_debug_glTexEnvi = glad_glTexEnvi;
+ glad_debug_glTexEnviv = glad_glTexEnviv;
+ glad_debug_glTexGend = glad_glTexGend;
+ glad_debug_glTexGendv = glad_glTexGendv;
+ glad_debug_glTexGenf = glad_glTexGenf;
+ glad_debug_glTexGenfv = glad_glTexGenfv;
+ glad_debug_glTexGeni = glad_glTexGeni;
+ glad_debug_glTexGeniv = glad_glTexGeniv;
glad_debug_glTexImage1D = glad_glTexImage1D;
glad_debug_glTexImage2D = glad_glTexImage2D;
glad_debug_glTexImage2DMultisample = glad_glTexImage2DMultisample;
@@ -11839,8 +14839,6 @@ void gladUninstallGLDebug(void) {
glad_debug_glTexParameterfv = glad_glTexParameterfv;
glad_debug_glTexParameteri = glad_glTexParameteri;
glad_debug_glTexParameteriv = glad_glTexParameteriv;
- glad_debug_glTexParameterxOES = glad_glTexParameterxOES;
- glad_debug_glTexParameterxvOES = glad_glTexParameterxvOES;
glad_debug_glTexStorage1D = glad_glTexStorage1D;
glad_debug_glTexStorage2D = glad_glTexStorage2D;
glad_debug_glTexStorage2DMultisample = glad_glTexStorage2DMultisample;
@@ -11869,7 +14867,8 @@ void gladUninstallGLDebug(void) {
glad_debug_glTransformFeedbackBufferBase = glad_glTransformFeedbackBufferBase;
glad_debug_glTransformFeedbackBufferRange = glad_glTransformFeedbackBufferRange;
glad_debug_glTransformFeedbackVaryings = glad_glTransformFeedbackVaryings;
- glad_debug_glTranslatexOES = glad_glTranslatexOES;
+ glad_debug_glTranslated = glad_glTranslated;
+ glad_debug_glTranslatef = glad_glTranslatef;
glad_debug_glUniform1d = glad_glUniform1d;
glad_debug_glUniform1dv = glad_glUniform1dv;
glad_debug_glUniform1f = glad_glUniform1f;
@@ -11966,12 +14965,30 @@ void gladUninstallGLDebug(void) {
glad_debug_glValidateProgram = glad_glValidateProgram;
glad_debug_glValidateProgramARB = glad_glValidateProgramARB;
glad_debug_glValidateProgramPipeline = glad_glValidateProgramPipeline;
- glad_debug_glVertex2xOES = glad_glVertex2xOES;
- glad_debug_glVertex2xvOES = glad_glVertex2xvOES;
- glad_debug_glVertex3xOES = glad_glVertex3xOES;
- glad_debug_glVertex3xvOES = glad_glVertex3xvOES;
- glad_debug_glVertex4xOES = glad_glVertex4xOES;
- glad_debug_glVertex4xvOES = glad_glVertex4xvOES;
+ glad_debug_glVertex2d = glad_glVertex2d;
+ glad_debug_glVertex2dv = glad_glVertex2dv;
+ glad_debug_glVertex2f = glad_glVertex2f;
+ glad_debug_glVertex2fv = glad_glVertex2fv;
+ glad_debug_glVertex2i = glad_glVertex2i;
+ glad_debug_glVertex2iv = glad_glVertex2iv;
+ glad_debug_glVertex2s = glad_glVertex2s;
+ glad_debug_glVertex2sv = glad_glVertex2sv;
+ glad_debug_glVertex3d = glad_glVertex3d;
+ glad_debug_glVertex3dv = glad_glVertex3dv;
+ glad_debug_glVertex3f = glad_glVertex3f;
+ glad_debug_glVertex3fv = glad_glVertex3fv;
+ glad_debug_glVertex3i = glad_glVertex3i;
+ glad_debug_glVertex3iv = glad_glVertex3iv;
+ glad_debug_glVertex3s = glad_glVertex3s;
+ glad_debug_glVertex3sv = glad_glVertex3sv;
+ glad_debug_glVertex4d = glad_glVertex4d;
+ glad_debug_glVertex4dv = glad_glVertex4dv;
+ glad_debug_glVertex4f = glad_glVertex4f;
+ glad_debug_glVertex4fv = glad_glVertex4fv;
+ glad_debug_glVertex4i = glad_glVertex4i;
+ glad_debug_glVertex4iv = glad_glVertex4iv;
+ glad_debug_glVertex4s = glad_glVertex4s;
+ glad_debug_glVertex4sv = glad_glVertex4sv;
glad_debug_glVertexArrayAttribBinding = glad_glVertexArrayAttribBinding;
glad_debug_glVertexArrayAttribFormat = glad_glVertexArrayAttribFormat;
glad_debug_glVertexArrayAttribIFormat = glad_glVertexArrayAttribIFormat;
@@ -12099,11 +15116,34 @@ void gladUninstallGLDebug(void) {
glad_debug_glVertexAttribPointer = glad_glVertexAttribPointer;
glad_debug_glVertexAttribPointerARB = glad_glVertexAttribPointerARB;
glad_debug_glVertexBindingDivisor = glad_glVertexBindingDivisor;
+ glad_debug_glVertexP2ui = glad_glVertexP2ui;
+ glad_debug_glVertexP2uiv = glad_glVertexP2uiv;
+ glad_debug_glVertexP3ui = glad_glVertexP3ui;
+ glad_debug_glVertexP3uiv = glad_glVertexP3uiv;
+ glad_debug_glVertexP4ui = glad_glVertexP4ui;
+ glad_debug_glVertexP4uiv = glad_glVertexP4uiv;
+ glad_debug_glVertexPointer = glad_glVertexPointer;
glad_debug_glViewport = glad_glViewport;
glad_debug_glViewportArrayv = glad_glViewportArrayv;
glad_debug_glViewportIndexedf = glad_glViewportIndexedf;
glad_debug_glViewportIndexedfv = glad_glViewportIndexedfv;
glad_debug_glWaitSync = glad_glWaitSync;
+ glad_debug_glWindowPos2d = glad_glWindowPos2d;
+ glad_debug_glWindowPos2dv = glad_glWindowPos2dv;
+ glad_debug_glWindowPos2f = glad_glWindowPos2f;
+ glad_debug_glWindowPos2fv = glad_glWindowPos2fv;
+ glad_debug_glWindowPos2i = glad_glWindowPos2i;
+ glad_debug_glWindowPos2iv = glad_glWindowPos2iv;
+ glad_debug_glWindowPos2s = glad_glWindowPos2s;
+ glad_debug_glWindowPos2sv = glad_glWindowPos2sv;
+ glad_debug_glWindowPos3d = glad_glWindowPos3d;
+ glad_debug_glWindowPos3dv = glad_glWindowPos3dv;
+ glad_debug_glWindowPos3f = glad_glWindowPos3f;
+ glad_debug_glWindowPos3fv = glad_glWindowPos3fv;
+ glad_debug_glWindowPos3i = glad_glWindowPos3i;
+ glad_debug_glWindowPos3iv = glad_glWindowPos3iv;
+ glad_debug_glWindowPos3s = glad_glWindowPos3s;
+ glad_debug_glWindowPos3sv = glad_glWindowPos3sv;
}
diff --git a/Source/Renderer/meson.build b/Source/Renderer/meson.build
index f1539fd3d0..4a695aaebe 100644
--- a/Source/Renderer/meson.build
+++ b/Source/Renderer/meson.build
@@ -8,5 +8,6 @@ sources += files(
'raylib/rtextures.c',
'raylib/rlutils.c',
'GLCheck.cpp',
+'GraphicalPrimitive.cpp',
'Draw.cpp',
)
diff --git a/Source/Renderer/raylib/rlconfig.h b/Source/Renderer/raylib/rlconfig.h
index 9585ea0e49..bb5f9ff61d 100644
--- a/Source/Renderer/raylib/rlconfig.h
+++ b/Source/Renderer/raylib/rlconfig.h
@@ -104,8 +104,9 @@
//#define RL_DEFAULT_BATCH_BUFFER_ELEMENTS 4096 // Default internal render batch elements limits
#define RL_DEFAULT_BATCH_BUFFERS 1 // Default number of batch buffers (multi-buffering)
-#define RL_DEFAULT_BATCH_DRAWCALLS 256 // Default number of batch draw calls (by state changes: mode, texture)
+#define RL_DEFAULT_BATCH_DRAWCALLS 1024 // Default number of batch draw calls (by state changes: mode, texture)
#define RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS 16 // Maximum number of textures units that can be activated on batch drawing (SetShaderValueTexture())
+#define RL_DEFAULT_DRAWCALL_UNIFORMS 32 // Maximum number of uniform locations in one draw call.
#define RL_MAX_MATRIX_STACK_SIZE 32 // Maximum size of internal Matrix stack
diff --git a/Source/Renderer/raylib/rlgl.c b/Source/Renderer/raylib/rlgl.c
index b5527d9323..b83096a366 100644
--- a/Source/Renderer/raylib/rlgl.c
+++ b/Source/Renderer/raylib/rlgl.c
@@ -4,217 +4,237 @@
#include "rlgl.h"
/***********************************************************************************
-*
-* RLGL IMPLEMENTATION
-*
-************************************************************************************/
+ *
+ * RLGL IMPLEMENTATION
+
+ *
+ * LICENSE: zlib/libpng
+ *
+ * Copyright (c) 2014-2024 Ramon Santamaria (@raysan5)
+ *
+ * This software is provided "as-is", without any express or implied warranty. In no event
+ * will the authors be held liable for any damages arising from the use of this software.
+ *
+ * Permission is granted to anyone to use this software for any purpose, including commercial
+ * applications, and to alter it and redistribute it freely, subject to the following restrictions:
+ *
+ * 1. The origin of this software must not be misrepresented; you must not claim that you
+ * wrote the original software. If you use this software in a product, an acknowledgment
+ * in the product documentation would be appreciated but is not required.
+ *
+ * 2. Altered source versions must be plainly marked as such, and must not be misrepresented
+ * as being the original software.
+ *
+ * 3. This notice may not be removed or altered from any source distribution.
+ *
+ ************************************************************************************/
// Expose OpenGL functions from glad in raylib
#if defined(BUILD_LIBTYPE_SHARED)
- #define GLAD_API_CALL_EXPORT
- #define GLAD_API_CALL_EXPORT_BUILD
+#define GLAD_API_CALL_EXPORT
+#define GLAD_API_CALL_EXPORT_BUILD
#endif
#if defined(GRAPHICS_API_OPENGL_11)
- #if defined(__APPLE__)
- #include // OpenGL 1.1 library for OSX
- #include // OpenGL extensions library
- #else
- // APIENTRY for OpenGL function pointer declarations is required
- #if !defined(APIENTRY)
- #if defined(_WIN32)
- #define APIENTRY __stdcall
- #else
- #define APIENTRY
- #endif
- #endif
- // WINGDIAPI definition. Some Windows OpenGL headers need it
- #if !defined(WINGDIAPI) && defined(_WIN32)
- #define WINGDIAPI __declspec(dllimport)
- #endif
-
- #include // OpenGL 1.1 library
- #endif
+#if defined(__APPLE__)
+#include // OpenGL 1.1 library for OSX
+#include // OpenGL extensions library
+#else
+// APIENTRY for OpenGL function pointer declarations is required
+#if !defined(APIENTRY)
+#if defined(_WIN32)
+#define APIENTRY __stdcall
+#else
+#define APIENTRY
+#endif
+#endif
+// WINGDIAPI definition. Some Windows OpenGL headers need it
+#if !defined(WINGDIAPI) && defined(_WIN32)
+#define WINGDIAPI __declspec(dllimport)
+#endif
+
+#include // OpenGL 1.1 library
+#endif
#endif
#if defined(GRAPHICS_API_OPENGL_33)
- #define GLAD_MALLOC RL_MALLOC
- #define GLAD_FREE RL_FREE
+#define GLAD_MALLOC RL_MALLOC
+#define GLAD_FREE RL_FREE
- #define GLAD_GL_IMPLEMENTATION
- #include "glad/gl.h" // GLAD extensions loading library, includes OpenGL headers
+#define GLAD_GL_IMPLEMENTATION
+#include "glad/gl.h" // GLAD extensions loading library, includes OpenGL headers
#endif
#if defined(GRAPHICS_API_OPENGL_ES3)
- #include // OpenGL ES 3.0 library
- #define GL_GLEXT_PROTOTYPES
- #include // OpenGL ES 2.0 extensions library
+#include // OpenGL ES 3.0 library
+#define GL_GLEXT_PROTOTYPES
+#include // OpenGL ES 2.0 extensions library
#elif defined(GRAPHICS_API_OPENGL_ES2)
- // NOTE: OpenGL ES 2.0 can be enabled on Desktop platforms,
- // in that case, functions are loaded from a custom glad for OpenGL ES 2.0
- #if defined(PLATFORM_DESKTOP_GLFW) || defined(PLATFORM_DESKTOP_SDL)
- #define GLAD_GLES2_IMPLEMENTATION
- #include "external/glad_gles2.h"
- #else
- #define GL_GLEXT_PROTOTYPES
- //#include // EGL library -> not required, platform layer
- #include // OpenGL ES 2.0 library
- #include // OpenGL ES 2.0 extensions library
- #endif
-
- // It seems OpenGL ES 2.0 instancing entry points are not defined on Raspberry Pi
- // provided headers (despite being defined in official Khronos GLES2 headers)
- #if defined(PLATFORM_DRM)
- typedef void (GL_APIENTRYP PFNGLDRAWARRAYSINSTANCEDEXTPROC) (GLenum mode, GLint start, GLsizei count, GLsizei primcount);
- typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDEXTPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount);
- typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBDIVISOREXTPROC) (GLuint index, GLuint divisor);
- #endif
-#endif
-
-#include // Required for: malloc(), free()
-#include // Required for: strcmp(), strlen() [Used in rlglInit(), on extensions loading]
-#include // Required for: sqrtf(), sinf(), cosf(), floor(), log()
+// NOTE: OpenGL ES 2.0 can be enabled on Desktop platforms,
+// in that case, functions are loaded from a custom glad for OpenGL ES 2.0
+#if defined(PLATFORM_DESKTOP_GLFW) || defined(PLATFORM_DESKTOP_SDL)
+#define GLAD_GLES2_IMPLEMENTATION
+#include "external/glad_gles2.h"
+#else
+#define GL_GLEXT_PROTOTYPES
+// #include // EGL library -> not required, platform layer
+#include // OpenGL ES 2.0 library
+#include // OpenGL ES 2.0 extensions library
+#endif
+
+// It seems OpenGL ES 2.0 instancing entry points are not defined on Raspberry Pi
+// provided headers (despite being defined in official Khronos GLES2 headers)
+#if defined(PLATFORM_DRM)
+typedef void(GL_APIENTRYP PFNGLDRAWARRAYSINSTANCEDEXTPROC)(GLenum mode, GLint start, GLsizei count, GLsizei primcount);
+typedef void(GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDEXTPROC)(GLenum mode, GLsizei count, GLenum type, const void* indices, GLsizei primcount);
+typedef void(GL_APIENTRYP PFNGLVERTEXATTRIBDIVISOREXTPROC)(GLuint index, GLuint divisor);
+#endif
+#endif
+
+#include // Required for: malloc(), free()
+#include // Required for: strcmp(), strlen() [Used in rlglInit(), on extensions loading]
+#include // Required for: sqrtf(), sinf(), cosf(), floor(), log()
//----------------------------------------------------------------------------------
// Defines and Macros
//----------------------------------------------------------------------------------
#ifndef PI
- #define PI 3.14159265358979323846f
+#define PI 3.14159265358979323846f
#endif
#ifndef DEG2RAD
- #define DEG2RAD (PI/180.0f)
+#define DEG2RAD (PI / 180.0f)
#endif
#ifndef RAD2DEG
- #define RAD2DEG (180.0f/PI)
+#define RAD2DEG (180.0f / PI)
#endif
#ifndef GL_SHADING_LANGUAGE_VERSION
- #define GL_SHADING_LANGUAGE_VERSION 0x8B8C
+#define GL_SHADING_LANGUAGE_VERSION 0x8B8C
#endif
#ifndef GL_COMPRESSED_RGB_S3TC_DXT1_EXT
- #define GL_COMPRESSED_RGB_S3TC_DXT1_EXT 0x83F0
+#define GL_COMPRESSED_RGB_S3TC_DXT1_EXT 0x83F0
#endif
#ifndef GL_COMPRESSED_RGBA_S3TC_DXT1_EXT
- #define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT 0x83F1
+#define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT 0x83F1
#endif
#ifndef GL_COMPRESSED_RGBA_S3TC_DXT3_EXT
- #define GL_COMPRESSED_RGBA_S3TC_DXT3_EXT 0x83F2
+#define GL_COMPRESSED_RGBA_S3TC_DXT3_EXT 0x83F2
#endif
#ifndef GL_COMPRESSED_RGBA_S3TC_DXT5_EXT
- #define GL_COMPRESSED_RGBA_S3TC_DXT5_EXT 0x83F3
+#define GL_COMPRESSED_RGBA_S3TC_DXT5_EXT 0x83F3
#endif
#ifndef GL_ETC1_RGB8_OES
- #define GL_ETC1_RGB8_OES 0x8D64
+#define GL_ETC1_RGB8_OES 0x8D64
#endif
#ifndef GL_COMPRESSED_RGB8_ETC2
- #define GL_COMPRESSED_RGB8_ETC2 0x9274
+#define GL_COMPRESSED_RGB8_ETC2 0x9274
#endif
#ifndef GL_COMPRESSED_RGBA8_ETC2_EAC
- #define GL_COMPRESSED_RGBA8_ETC2_EAC 0x9278
+#define GL_COMPRESSED_RGBA8_ETC2_EAC 0x9278
#endif
#ifndef GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG
- #define GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG 0x8C00
+#define GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG 0x8C00
#endif
#ifndef GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG
- #define GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG 0x8C02
+#define GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG 0x8C02
#endif
#ifndef GL_COMPRESSED_RGBA_ASTC_4x4_KHR
- #define GL_COMPRESSED_RGBA_ASTC_4x4_KHR 0x93b0
+#define GL_COMPRESSED_RGBA_ASTC_4x4_KHR 0x93b0
#endif
#ifndef GL_COMPRESSED_RGBA_ASTC_8x8_KHR
- #define GL_COMPRESSED_RGBA_ASTC_8x8_KHR 0x93b7
+#define GL_COMPRESSED_RGBA_ASTC_8x8_KHR 0x93b7
#endif
#ifndef GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT
- #define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF
+#define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF
#endif
#ifndef GL_TEXTURE_MAX_ANISOTROPY_EXT
- #define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE
+#define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE
#endif
#ifndef GL_PROGRAM_POINT_SIZE
- #define GL_PROGRAM_POINT_SIZE 0x8642
+#define GL_PROGRAM_POINT_SIZE 0x8642
#endif
#ifndef GL_LINE_WIDTH
- #define GL_LINE_WIDTH 0x0B21
+#define GL_LINE_WIDTH 0x0B21
#endif
#if defined(GRAPHICS_API_OPENGL_11)
- #define GL_UNSIGNED_SHORT_5_6_5 0x8363
- #define GL_UNSIGNED_SHORT_5_5_5_1 0x8034
- #define GL_UNSIGNED_SHORT_4_4_4_4 0x8033
+#define GL_UNSIGNED_SHORT_5_6_5 0x8363
+#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034
+#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033
#endif
#if defined(GRAPHICS_API_OPENGL_21)
- #define GL_LUMINANCE 0x1909
- #define GL_LUMINANCE_ALPHA 0x190A
+#define GL_LUMINANCE 0x1909
+#define GL_LUMINANCE_ALPHA 0x190A
#endif
#if defined(GRAPHICS_API_OPENGL_ES2)
- #define glClearDepth glClearDepthf
- #if !defined(GRAPHICS_API_OPENGL_ES3)
- #define GL_READ_FRAMEBUFFER GL_FRAMEBUFFER
- #define GL_DRAW_FRAMEBUFFER GL_FRAMEBUFFER
- #endif
+#define glClearDepth glClearDepthf
+#if !defined(GRAPHICS_API_OPENGL_ES3)
+#define GL_READ_FRAMEBUFFER GL_FRAMEBUFFER
+#define GL_DRAW_FRAMEBUFFER GL_FRAMEBUFFER
+#endif
#endif
// Default shader vertex attribute names to set location points
#ifndef RL_DEFAULT_SHADER_ATTRIB_NAME_POSITION
- #define RL_DEFAULT_SHADER_ATTRIB_NAME_POSITION "vertexPosition" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_POSITION
+#define RL_DEFAULT_SHADER_ATTRIB_NAME_POSITION "vertexPosition" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_POSITION
#endif
#ifndef RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD
- #define RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD "vertexTexCoord" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD
+#define RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD "vertexTexCoord" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD
#endif
#ifndef RL_DEFAULT_SHADER_ATTRIB_NAME_NORMAL
- #define RL_DEFAULT_SHADER_ATTRIB_NAME_NORMAL "vertexNormal" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_NORMAL
+#define RL_DEFAULT_SHADER_ATTRIB_NAME_NORMAL "vertexNormal" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_NORMAL
#endif
#ifndef RL_DEFAULT_SHADER_ATTRIB_NAME_COLOR
- #define RL_DEFAULT_SHADER_ATTRIB_NAME_COLOR "vertexColor" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_COLOR
+#define RL_DEFAULT_SHADER_ATTRIB_NAME_COLOR "vertexColor" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_COLOR
#endif
#ifndef RL_DEFAULT_SHADER_ATTRIB_NAME_TANGENT
- #define RL_DEFAULT_SHADER_ATTRIB_NAME_TANGENT "vertexTangent" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_TANGENT
+#define RL_DEFAULT_SHADER_ATTRIB_NAME_TANGENT "vertexTangent" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_TANGENT
#endif
#ifndef RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD2
- #define RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD2 "vertexTexCoord2" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD2
+#define RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD2 "vertexTexCoord2" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD2
#endif
#ifndef RL_DEFAULT_SHADER_ATTRIB_NAME_BONEIDS
- #define RL_DEFAULT_SHADER_ATTRIB_NAME_BONEIDS "vertexBoneIds" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_BONEIDS
+#define RL_DEFAULT_SHADER_ATTRIB_NAME_BONEIDS "vertexBoneIds" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_BONEIDS
#endif
#ifndef RL_DEFAULT_SHADER_ATTRIB_NAME_BONEWEIGHTS
- #define RL_DEFAULT_SHADER_ATTRIB_NAME_BONEWEIGHTS "vertexBoneWeights" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_BONEWEIGHTS
+#define RL_DEFAULT_SHADER_ATTRIB_NAME_BONEWEIGHTS "vertexBoneWeights" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_NAME_BONEWEIGHTS
#endif
#ifndef RL_DEFAULT_SHADER_UNIFORM_NAME_MVP
- #define RL_DEFAULT_SHADER_UNIFORM_NAME_MVP "mvp" // model-view-projection matrix
+#define RL_DEFAULT_SHADER_UNIFORM_NAME_MVP "mvp" // model-view-projection matrix
#endif
#ifndef RL_DEFAULT_SHADER_UNIFORM_NAME_VIEW
- #define RL_DEFAULT_SHADER_UNIFORM_NAME_VIEW "matView" // view matrix
+#define RL_DEFAULT_SHADER_UNIFORM_NAME_VIEW "matView" // view matrix
#endif
#ifndef RL_DEFAULT_SHADER_UNIFORM_NAME_PROJECTION
- #define RL_DEFAULT_SHADER_UNIFORM_NAME_PROJECTION "matProjection" // projection matrix
+#define RL_DEFAULT_SHADER_UNIFORM_NAME_PROJECTION "matProjection" // projection matrix
#endif
#ifndef RL_DEFAULT_SHADER_UNIFORM_NAME_MODEL
- #define RL_DEFAULT_SHADER_UNIFORM_NAME_MODEL "matModel" // model matrix
+#define RL_DEFAULT_SHADER_UNIFORM_NAME_MODEL "matModel" // model matrix
#endif
#ifndef RL_DEFAULT_SHADER_UNIFORM_NAME_NORMAL
- #define RL_DEFAULT_SHADER_UNIFORM_NAME_NORMAL "matNormal" // normal matrix (transpose(inverse(matModelView))
+#define RL_DEFAULT_SHADER_UNIFORM_NAME_NORMAL "matNormal" // normal matrix (transpose(inverse(matModelView))
#endif
#ifndef RL_DEFAULT_SHADER_UNIFORM_NAME_COLOR
- #define RL_DEFAULT_SHADER_UNIFORM_NAME_COLOR "colDiffuse" // color diffuse (base tint color, multiplied by texture color)
+#define RL_DEFAULT_SHADER_UNIFORM_NAME_COLOR "colDiffuse" // color diffuse (base tint color, multiplied by texture color)
#endif
#ifndef RL_DEFAULT_SHADER_UNIFORM_NAME_BONE_MATRICES
- #define RL_DEFAULT_SHADER_UNIFORM_NAME_BONE_MATRICES "boneMatrices" // bone matrices
+#define RL_DEFAULT_SHADER_UNIFORM_NAME_BONE_MATRICES "boneMatrices" // bone matrices
#endif
#ifndef RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE0
- #define RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE0 "texture0" // texture0 (texture slot active 0)
+#define RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE0 "texture0" // texture0 (texture slot active 0)
#endif
#ifndef RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE1
- #define RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE1 "texture1" // texture1 (texture slot active 1)
+#define RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE1 "texture1" // texture1 (texture slot active 1)
#endif
#ifndef RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE2
- #define RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE2 "texture2" // texture2 (texture slot active 2)
+#define RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE2 "texture2" // texture2 (texture slot active 2)
#endif
//----------------------------------------------------------------------------------
@@ -222,82 +242,83 @@
//----------------------------------------------------------------------------------
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
typedef struct rlglData {
- rlRenderBatch *currentBatch; // Current render batch
- rlRenderBatch defaultBatch; // Default internal render batch
-
- struct {
- int vertexCounter; // Current active render batch vertex counter (generic, used for all batches)
- float texcoordx, texcoordy; // Current active texture coordinate (added on glVertex*())
- float normalx, normaly, normalz; // Current active normal (added on glVertex*())
- unsigned char colorr, colorg, colorb, colora; // Current active color (added on glVertex*())
-
- int currentMatrixMode; // Current matrix mode
- RLMatrix *currentMatrix; // Current matrix pointer
- RLMatrix modelview; // Default modelview matrix
- RLMatrix projection; // Default projection matrix
- RLMatrix transform; // Transform matrix to be used with rlTranslate, rlRotate, rlScale
- bool transformRequired; // Require transform matrix application to current draw-call vertex (if required)
- RLMatrix stack[RL_MAX_MATRIX_STACK_SIZE];// RLMatrix stack for push/pop
- int stackCounter; // RLMatrix stack counter
-
- unsigned int defaultTextureId; // Default texture used on shapes/poly drawing (required by shader)
- unsigned int activeTextureId[RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS]; // Active texture ids to be enabled on batch drawing (0 active by default)
- unsigned int defaultVShaderId; // Default vertex shader id (used by default shader program)
- unsigned int defaultFShaderId; // Default fragment shader id (used by default shader program)
- unsigned int defaultShaderId; // Default shader program id, supports vertex color and diffuse texture
- int *defaultShaderLocs; // Default shader locations pointer to be used on rendering
- unsigned int currentShaderId; // Current shader id to be used on rendering (by default, defaultShaderId)
- int *currentShaderLocs; // Current shader locations pointer to be used on rendering (by default, defaultShaderLocs)
-
- bool stereoRender; // Stereo rendering flag
- RLMatrix projectionStereo[2]; // VR stereo rendering eyes projection matrices
- RLMatrix viewOffsetStereo[2]; // VR stereo rendering eyes view offset matrices
-
- // Blending variables
- int currentBlendMode; // Blending mode active
- int glBlendSrcFactor; // Blending source factor
- int glBlendDstFactor; // Blending destination factor
- int glBlendEquation; // Blending equation
- int glBlendSrcFactorRGB; // Blending source RGB factor
- int glBlendDestFactorRGB; // Blending destination RGB factor
- int glBlendSrcFactorAlpha; // Blending source alpha factor
- int glBlendDestFactorAlpha; // Blending destination alpha factor
- int glBlendEquationRGB; // Blending equation for RGB
- int glBlendEquationAlpha; // Blending equation for alpha
- bool glCustomBlendModeModified; // Custom blending factor and equation modification status
-
- int framebufferWidth; // Current framebuffer width
- int framebufferHeight; // Current framebuffer height
-
- } State; // Renderer state
- struct {
- bool vao; // VAO support (OpenGL ES2 could not support VAO extension) (GL_ARB_vertex_array_object)
- bool instancing; // Instancing supported (GL_ANGLE_instanced_arrays, GL_EXT_draw_instanced + GL_EXT_instanced_arrays)
- bool texNPOT; // NPOT textures full support (GL_ARB_texture_non_power_of_two, GL_OES_texture_npot)
- bool texDepth; // Depth textures supported (GL_ARB_depth_texture, GL_OES_depth_texture)
- bool texDepthWebGL; // Depth textures supported WebGL specific (GL_WEBGL_depth_texture)
- bool texFloat32; // float textures support (32 bit per channel) (GL_OES_texture_float)
- bool texFloat16; // half float textures support (16 bit per channel) (GL_OES_texture_half_float)
- bool texCompDXT; // DDS texture compression support (GL_EXT_texture_compression_s3tc, GL_WEBGL_compressed_texture_s3tc, GL_WEBKIT_WEBGL_compressed_texture_s3tc)
- bool texCompETC1; // ETC1 texture compression support (GL_OES_compressed_ETC1_RGB8_texture, GL_WEBGL_compressed_texture_etc1)
- bool texCompETC2; // ETC2/EAC texture compression support (GL_ARB_ES3_compatibility)
- bool texCompPVRT; // PVR texture compression support (GL_IMG_texture_compression_pvrtc)
- bool texCompASTC; // ASTC texture compression support (GL_KHR_texture_compression_astc_hdr, GL_KHR_texture_compression_astc_ldr)
- bool texMirrorClamp; // Clamp mirror wrap mode supported (GL_EXT_texture_mirror_clamp)
- bool texAnisoFilter; // Anisotropic texture filtering support (GL_EXT_texture_filter_anisotropic)
- bool computeShader; // Compute shaders support (GL_ARB_compute_shader)
- bool ssbo; // Shader storage buffer object support (GL_ARB_shader_storage_buffer_object)
- bool debug_output;
-
- float maxAnisotropyLevel; // Maximum anisotropy level supported (minimum is 2.0f)
- int maxDepthBits; // Maximum bits for depth component
-
- } ExtSupported; // Extensions supported flags
+ rlRenderBatch* currentBatch; // Current render batch
+ rlRenderBatch defaultBatch; // Default internal render batch
+
+ struct {
+ int vertexCounter; // Current active render batch vertex counter (generic, used for all batches)
+ float texcoordx, texcoordy; // Current active texture coordinate (added on glVertex*())
+ float normalx, normaly, normalz; // Current active normal (added on glVertex*())
+ unsigned char colorr, colorg, colorb, colora; // Current active color (added on glVertex*())
+
+ int currentMatrixMode; // Current matrix mode
+ RLMatrix* currentMatrix; // Current matrix pointer
+ RLMatrix modelview; // Default modelview matrix
+ RLMatrix projection; // Default projection matrix
+ RLMatrix transform; // Transform matrix to be used with rlTranslate, rlRotate, rlScale
+ bool transformRequired; // Require transform matrix application to current draw-call vertex (if required)
+ RLMatrix stack[RL_MAX_MATRIX_STACK_SIZE]; // RLMatrix stack for push/pop
+ int stackCounter; // RLMatrix stack counter
+
+ unsigned int defaultTextureId; // Default texture used on shapes/poly drawing (required by shader)
+ unsigned int activeTextureId[RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS]; // Active texture ids to be enabled on batch drawing (0 active by default)
+ unsigned int defaultVShaderId; // Default vertex shader id (used by default shader program)
+ unsigned int defaultFShaderId; // Default fragment shader id (used by default shader program)
+ unsigned int defaultShaderId; // Default shader program id, supports vertex color and diffuse texture
+ int* defaultShaderLocs; // Default shader locations pointer to be used on rendering
+ unsigned int currentShaderId; // Current shader id to be used on rendering (by default, defaultShaderId)
+ int* currentShaderLocs; // Current shader locations pointer to be used on rendering (by default, defaultShaderLocs)
+ bool stereoRender; // Stereo rendering flag
+ RLMatrix projectionStereo[2]; // VR stereo rendering eyes projection matrices
+ RLMatrix viewOffsetStereo[2]; // VR stereo rendering eyes view offset matrices
+
+ // Blending variables
+ int currentBlendMode; // Blending mode active
+ int glBlendSrcFactor; // Blending source factor
+ int glBlendDstFactor; // Blending destination factor
+ int glBlendEquation; // Blending equation
+ int glBlendSrcFactorRGB; // Blending source RGB factor
+ int glBlendDestFactorRGB; // Blending destination RGB factor
+ int glBlendSrcFactorAlpha; // Blending source alpha factor
+ int glBlendDestFactorAlpha; // Blending destination alpha factor
+ int glBlendEquationRGB; // Blending equation for RGB
+ int glBlendEquationAlpha; // Blending equation for alpha
+ bool glCustomBlendModeModified; // Custom blending factor and equation modification status
+
+ int framebufferWidth; // Current framebuffer width
+ int framebufferHeight; // Current framebuffer height
+
+ } State; // Renderer state
+ struct {
+ bool vao; // VAO support (OpenGL ES2 could not support VAO extension) (GL_ARB_vertex_array_object)
+ bool instancing; // Instancing supported (GL_ANGLE_instanced_arrays, GL_EXT_draw_instanced + GL_EXT_instanced_arrays)
+ bool texNPOT; // NPOT textures full support (GL_ARB_texture_non_power_of_two, GL_OES_texture_npot)
+ bool texDepth; // Depth textures supported (GL_ARB_depth_texture, GL_OES_depth_texture)
+ bool texDepthWebGL; // Depth textures supported WebGL specific (GL_WEBGL_depth_texture)
+ bool texFloat32; // float textures support (32 bit per channel) (GL_OES_texture_float)
+ bool texFloat16; // half float textures support (16 bit per channel) (GL_OES_texture_half_float)
+ bool texCompDXT; // DDS texture compression support (GL_EXT_texture_compression_s3tc, GL_WEBGL_compressed_texture_s3tc, GL_WEBKIT_WEBGL_compressed_texture_s3tc)
+ bool texCompETC1; // ETC1 texture compression support (GL_OES_compressed_ETC1_RGB8_texture, GL_WEBGL_compressed_texture_etc1)
+ bool texCompETC2; // ETC2/EAC texture compression support (GL_ARB_ES3_compatibility)
+ bool texCompPVRT; // PVR texture compression support (GL_IMG_texture_compression_pvrtc)
+ bool texCompASTC; // ASTC texture compression support (GL_KHR_texture_compression_astc_hdr, GL_KHR_texture_compression_astc_ldr)
+ bool texMirrorClamp; // Clamp mirror wrap mode supported (GL_EXT_texture_mirror_clamp)
+ bool texAnisoFilter; // Anisotropic texture filtering support (GL_EXT_texture_filter_anisotropic)
+ bool computeShader; // Compute shaders support (GL_ARB_compute_shader)
+ bool ssbo; // Shader storage buffer object support (GL_ARB_shader_storage_buffer_object)
+ bool advanced_blend_equations;
+ bool advanced_blend_equations_coherent;
+ bool debug_output;
+
+ float maxAnisotropyLevel; // Maximum anisotropy level supported (minimum is 2.0f)
+ int maxDepthBits; // Maximum bits for depth component
+
+ } ExtSupported; // Extensions supported flags
} rlglData;
-typedef void *(*rlglLoadProc)(const char *name); // OpenGL extension functions loader signature (same as GLADloadproc)
+typedef void* (*rlglLoadProc)(const char* name); // OpenGL extension functions loader signature (same as GLADloadproc)
-#endif // GRAPHICS_API_OPENGL_33 || GRAPHICS_API_OPENGL_ES2
+#endif // GRAPHICS_API_OPENGL_33 || GRAPHICS_API_OPENGL_ES2
//----------------------------------------------------------------------------------
// Global Variables Definition
@@ -306,8 +327,8 @@ static double rlCullDistanceNear = RL_CULL_DISTANCE_NEAR;
static double rlCullDistanceFar = RL_CULL_DISTANCE_FAR;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
-static rlglData RLGL = { 0 };
-#endif // GRAPHICS_API_OPENGL_33 || GRAPHICS_API_OPENGL_ES2
+static rlglData RLGL = {0};
+#endif // GRAPHICS_API_OPENGL_33 || GRAPHICS_API_OPENGL_ES2
#if defined(GRAPHICS_API_OPENGL_ES2) && !defined(GRAPHICS_API_OPENGL_ES3)
// NOTE: VAO functionality is exposed through extensions (OES)
@@ -325,25 +346,25 @@ static PFNGLVERTEXATTRIBDIVISOREXTPROC glVertexAttribDivisor = NULL;
// Module specific Functions Declaration
//----------------------------------------------------------------------------------
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
-static void rlLoadShaderDefault(void); // Load default shader
-static void rlUnloadShaderDefault(void); // Unload default shader
+static void rlLoadShaderDefault(void); // Load default shader
+static void rlUnloadShaderDefault(void); // Unload default shader
#if defined(RLGL_SHOW_GL_DETAILS_INFO)
-static const char *rlGetCompressedFormatName(int format); // Get compressed format official GL identifier name
-#endif // RLGL_SHOW_GL_DETAILS_INFO
-#endif // GRAPHICS_API_OPENGL_33 || GRAPHICS_API_OPENGL_ES2
+static const char* rlGetCompressedFormatName(int format); // Get compressed format official GL identifier name
+#endif // RLGL_SHOW_GL_DETAILS_INFO
+#endif // GRAPHICS_API_OPENGL_33 || GRAPHICS_API_OPENGL_ES2
-static int rlGetPixelDataSize(int width, int height, int format); // Get pixel data size in bytes (image or texture)
+static int rlGetPixelDataSize(int width, int height, int format); // Get pixel data size in bytes (image or texture)
// Auxiliar matrix math functions
typedef struct rl_float16 {
- float v[16];
+ float v[16];
} rl_float16;
-static rl_float16 rlMatrixToFloatV(RLMatrix mat); // Get float array of matrix data
-#define rlMatrixToFloat(mat) (rlMatrixToFloatV(mat).v) // Get float vector for Matrix
-static RLMatrix rlMatrixIdentity(void); // Get identity matrix
-static RLMatrix rlMatrixMultiply(RLMatrix left, RLMatrix right); // Multiply two matrices
-static RLMatrix rlMatrixTranspose(RLMatrix mat); // Transposes provided matrix
-static RLMatrix rlMatrixInvert(RLMatrix mat); // Invert provided matrix
+static rl_float16 rlMatrixToFloatV(RLMatrix mat); // Get float array of matrix data
+#define rlMatrixToFloat(mat) (rlMatrixToFloatV(mat).v) // Get float vector for Matrix
+static RLMatrix rlMatrixIdentity(void); // Get identity matrix
+static RLMatrix rlMatrixMultiply(RLMatrix left, RLMatrix right); // Multiply two matrices
+static RLMatrix rlMatrixTranspose(RLMatrix mat); // Transposes provided matrix
+static RLMatrix rlMatrixInvert(RLMatrix mat); // Invert provided matrix
//----------------------------------------------------------------------------------
// Module Functions Definition - RLMatrix operations
@@ -352,25 +373,28 @@ static RLMatrix rlMatrixInvert(RLMatrix mat); // Invert provid
#if defined(GRAPHICS_API_OPENGL_11)
// Fallback to OpenGL 1.1 function calls
//---------------------------------------
-void rlMatrixMode(int mode)
-{
- switch (mode)
- {
- case RL_PROJECTION: glMatrixMode(GL_PROJECTION); break;
- case RL_MODELVIEW: glMatrixMode(GL_MODELVIEW); break;
- case RL_TEXTURE: glMatrixMode(GL_TEXTURE); break;
- default: break;
- }
+void rlMatrixMode(int mode) {
+ switch (mode) {
+ case RL_PROJECTION:
+ glMatrixMode(GL_PROJECTION);
+ break;
+ case RL_MODELVIEW:
+ glMatrixMode(GL_MODELVIEW);
+ break;
+ case RL_TEXTURE:
+ glMatrixMode(GL_TEXTURE);
+ break;
+ default:
+ break;
+ }
}
-void rlFrustum(double left, double right, double bottom, double top, double znear, double zfar)
-{
- glFrustum(left, right, bottom, top, znear, zfar);
+void rlFrustum(double left, double right, double bottom, double top, double znear, double zfar) {
+ glFrustum(left, right, bottom, top, znear, zfar);
}
-void rlOrtho(double left, double right, double bottom, double top, double znear, double zfar)
-{
- glOrtho(left, right, bottom, top, znear, zfar);
+void rlOrtho(double left, double right, double bottom, double top, double znear, double zfar) {
+ glOrtho(left, right, bottom, top, znear, zfar);
}
void rlPushMatrix(void) { glPushMatrix(); }
@@ -379,230 +403,213 @@ void rlLoadIdentity(void) { glLoadIdentity(); }
void rlTranslatef(float x, float y, float z) { glTranslatef(x, y, z); }
void rlRotatef(float angle, float x, float y, float z) { glRotatef(angle, x, y, z); }
void rlScalef(float x, float y, float z) { glScalef(x, y, z); }
-void rlMultMatrixf(const float *matf) { glMultMatrixf(matf); }
+void rlMultMatrixf(const float* matf) { glMultMatrixf(matf); }
#endif
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
// Choose the current matrix to be transformed
-void rlMatrixMode(int mode)
-{
- if (mode == RL_PROJECTION) RLGL.State.currentMatrix = &RLGL.State.projection;
- else if (mode == RL_MODELVIEW) RLGL.State.currentMatrix = &RLGL.State.modelview;
- //else if (mode == RL_TEXTURE) // Not supported
+void rlMatrixMode(int mode) {
+ if (mode == RL_PROJECTION)
+ RLGL.State.currentMatrix = &RLGL.State.projection;
+ else if (mode == RL_MODELVIEW)
+ RLGL.State.currentMatrix = &RLGL.State.modelview;
+ // else if (mode == RL_TEXTURE) // Not supported
- RLGL.State.currentMatrixMode = mode;
+ RLGL.State.currentMatrixMode = mode;
}
// Push the current matrix into RLGL.State.stack
-void rlPushMatrix(void)
-{
- if (RLGL.State.stackCounter >= RL_MAX_MATRIX_STACK_SIZE) TRACELOG(RL_LOG_ERROR, "RLGL: RLMatrix stack overflow (RL_MAX_MATRIX_STACK_SIZE)");
+void rlPushMatrix(void) {
+ if (RLGL.State.stackCounter >= RL_MAX_MATRIX_STACK_SIZE)
+ TRACELOG(RL_LOG_ERROR, "RLGL: RLMatrix stack overflow (RL_MAX_MATRIX_STACK_SIZE)");
- if (RLGL.State.currentMatrixMode == RL_MODELVIEW)
- {
- RLGL.State.transformRequired = true;
- RLGL.State.currentMatrix = &RLGL.State.transform;
- }
+ if (RLGL.State.currentMatrixMode == RL_MODELVIEW) {
+ RLGL.State.transformRequired = true;
+ RLGL.State.currentMatrix = &RLGL.State.transform;
+ }
- RLGL.State.stack[RLGL.State.stackCounter] = *RLGL.State.currentMatrix;
- RLGL.State.stackCounter++;
+ RLGL.State.stack[RLGL.State.stackCounter] = *RLGL.State.currentMatrix;
+ RLGL.State.stackCounter++;
}
// Pop lattest inserted matrix from RLGL.State.stack
-void rlPopMatrix(void)
-{
- if (RLGL.State.stackCounter > 0)
- {
- RLMatrix mat = RLGL.State.stack[RLGL.State.stackCounter - 1];
- *RLGL.State.currentMatrix = mat;
- RLGL.State.stackCounter--;
- }
-
- if ((RLGL.State.stackCounter == 0) && (RLGL.State.currentMatrixMode == RL_MODELVIEW))
- {
- RLGL.State.currentMatrix = &RLGL.State.modelview;
- RLGL.State.transformRequired = false;
- }
+void rlPopMatrix(void) {
+ if (RLGL.State.stackCounter > 0) {
+ RLMatrix mat = RLGL.State.stack[RLGL.State.stackCounter - 1];
+ *RLGL.State.currentMatrix = mat;
+ RLGL.State.stackCounter--;
+ }
+
+ if ((RLGL.State.stackCounter == 0) && (RLGL.State.currentMatrixMode == RL_MODELVIEW)) {
+ RLGL.State.currentMatrix = &RLGL.State.modelview;
+ RLGL.State.transformRequired = false;
+ }
}
// Reset current matrix to identity matrix
-void rlLoadIdentity(void)
-{
- *RLGL.State.currentMatrix = rlMatrixIdentity();
+void rlLoadIdentity(void) {
+ *RLGL.State.currentMatrix = rlMatrixIdentity();
}
// Multiply the current matrix by a translation matrix
-void rlTranslatef(float x, float y, float z)
-{
- RLMatrix matTranslation = {
- 1.0f, 0.0f, 0.0f, x,
- 0.0f, 1.0f, 0.0f, y,
- 0.0f, 0.0f, 1.0f, z,
- 0.0f, 0.0f, 0.0f, 1.0f
- };
+void rlTranslatef(float x, float y, float z) {
+ RLMatrix matTranslation = {
+ 1.0f, 0.0f, 0.0f, x,
+ 0.0f, 1.0f, 0.0f, y,
+ 0.0f, 0.0f, 1.0f, z,
+ 0.0f, 0.0f, 0.0f, 1.0f};
- // NOTE: We transpose matrix with multiplication order
- *RLGL.State.currentMatrix = rlMatrixMultiply(matTranslation, *RLGL.State.currentMatrix);
+ // NOTE: We transpose matrix with multiplication order
+ *RLGL.State.currentMatrix = rlMatrixMultiply(matTranslation, *RLGL.State.currentMatrix);
}
// Multiply the current matrix by a rotation matrix
// NOTE: The provided angle must be in degrees
-void rlRotatef(float angle, float x, float y, float z)
-{
- RLMatrix matRotation = rlMatrixIdentity();
-
- // Axis vector (x, y, z) normalization
- float lengthSquared = x*x + y*y + z*z;
- if ((lengthSquared != 1.0f) && (lengthSquared != 0.0f))
- {
- float inverseLength = 1.0f/sqrtf(lengthSquared);
- x *= inverseLength;
- y *= inverseLength;
- z *= inverseLength;
- }
-
- // Rotation matrix generation
- float sinres = sinf(DEG2RAD*angle);
- float cosres = cosf(DEG2RAD*angle);
- float t = 1.0f - cosres;
-
- matRotation.m0 = x*x*t + cosres;
- matRotation.m1 = y*x*t + z*sinres;
- matRotation.m2 = z*x*t - y*sinres;
- matRotation.m3 = 0.0f;
-
- matRotation.m4 = x*y*t - z*sinres;
- matRotation.m5 = y*y*t + cosres;
- matRotation.m6 = z*y*t + x*sinres;
- matRotation.m7 = 0.0f;
-
- matRotation.m8 = x*z*t + y*sinres;
- matRotation.m9 = y*z*t - x*sinres;
- matRotation.m10 = z*z*t + cosres;
- matRotation.m11 = 0.0f;
-
- matRotation.m12 = 0.0f;
- matRotation.m13 = 0.0f;
- matRotation.m14 = 0.0f;
- matRotation.m15 = 1.0f;
-
- // NOTE: We transpose matrix with multiplication order
- *RLGL.State.currentMatrix = rlMatrixMultiply(matRotation, *RLGL.State.currentMatrix);
+void rlRotatef(float angle, float x, float y, float z) {
+ RLMatrix matRotation = rlMatrixIdentity();
+
+ // Axis vector (x, y, z) normalization
+ float lengthSquared = x * x + y * y + z * z;
+ if ((lengthSquared != 1.0f) && (lengthSquared != 0.0f)) {
+ float inverseLength = 1.0f / sqrtf(lengthSquared);
+ x *= inverseLength;
+ y *= inverseLength;
+ z *= inverseLength;
+ }
+
+ // Rotation matrix generation
+ float sinres = sinf(DEG2RAD * angle);
+ float cosres = cosf(DEG2RAD * angle);
+ float t = 1.0f - cosres;
+
+ matRotation.m0 = x * x * t + cosres;
+ matRotation.m1 = y * x * t + z * sinres;
+ matRotation.m2 = z * x * t - y * sinres;
+ matRotation.m3 = 0.0f;
+
+ matRotation.m4 = x * y * t - z * sinres;
+ matRotation.m5 = y * y * t + cosres;
+ matRotation.m6 = z * y * t + x * sinres;
+ matRotation.m7 = 0.0f;
+
+ matRotation.m8 = x * z * t + y * sinres;
+ matRotation.m9 = y * z * t - x * sinres;
+ matRotation.m10 = z * z * t + cosres;
+ matRotation.m11 = 0.0f;
+
+ matRotation.m12 = 0.0f;
+ matRotation.m13 = 0.0f;
+ matRotation.m14 = 0.0f;
+ matRotation.m15 = 1.0f;
+
+ // NOTE: We transpose matrix with multiplication order
+ *RLGL.State.currentMatrix = rlMatrixMultiply(matRotation, *RLGL.State.currentMatrix);
}
// Multiply the current matrix by a scaling matrix
-void rlScalef(float x, float y, float z)
-{
- RLMatrix matScale = {
- x, 0.0f, 0.0f, 0.0f,
- 0.0f, y, 0.0f, 0.0f,
- 0.0f, 0.0f, z, 0.0f,
- 0.0f, 0.0f, 0.0f, 1.0f
- };
+void rlScalef(float x, float y, float z) {
+ RLMatrix matScale = {
+ x, 0.0f, 0.0f, 0.0f,
+ 0.0f, y, 0.0f, 0.0f,
+ 0.0f, 0.0f, z, 0.0f,
+ 0.0f, 0.0f, 0.0f, 1.0f};
- // NOTE: We transpose matrix with multiplication order
- *RLGL.State.currentMatrix = rlMatrixMultiply(matScale, *RLGL.State.currentMatrix);
+ // NOTE: We transpose matrix with multiplication order
+ *RLGL.State.currentMatrix = rlMatrixMultiply(matScale, *RLGL.State.currentMatrix);
}
// Multiply the current matrix by another matrix
-void rlMultMatrixf(const float *matf)
-{
- // RLMatrix creation from array
- RLMatrix mat = { matf[0], matf[4], matf[8], matf[12],
- matf[1], matf[5], matf[9], matf[13],
- matf[2], matf[6], matf[10], matf[14],
- matf[3], matf[7], matf[11], matf[15] };
+void rlMultMatrixf(const float* matf) {
+ // RLMatrix creation from array
+ RLMatrix mat = {matf[0], matf[4], matf[8], matf[12],
+ matf[1], matf[5], matf[9], matf[13],
+ matf[2], matf[6], matf[10], matf[14],
+ matf[3], matf[7], matf[11], matf[15]};
- *RLGL.State.currentMatrix = rlMatrixMultiply(mat, *RLGL.State.currentMatrix);
+ *RLGL.State.currentMatrix = rlMatrixMultiply(mat, *RLGL.State.currentMatrix);
}
// Multiply the current matrix by a perspective matrix generated by parameters
-void rlFrustum(double left, double right, double bottom, double top, double znear, double zfar)
-{
- RLMatrix matFrustum = { 0 };
+void rlFrustum(double left, double right, double bottom, double top, double znear, double zfar) {
+ RLMatrix matFrustum = {0};
- float rl = (float)(right - left);
- float tb = (float)(top - bottom);
- float fn = (float)(zfar - znear);
+ float rl = (float)(right - left);
+ float tb = (float)(top - bottom);
+ float fn = (float)(zfar - znear);
- matFrustum.m0 = ((float) znear*2.0f)/rl;
- matFrustum.m1 = 0.0f;
- matFrustum.m2 = 0.0f;
- matFrustum.m3 = 0.0f;
+ matFrustum.m0 = ((float)znear * 2.0f) / rl;
+ matFrustum.m1 = 0.0f;
+ matFrustum.m2 = 0.0f;
+ matFrustum.m3 = 0.0f;
- matFrustum.m4 = 0.0f;
- matFrustum.m5 = ((float) znear*2.0f)/tb;
- matFrustum.m6 = 0.0f;
- matFrustum.m7 = 0.0f;
+ matFrustum.m4 = 0.0f;
+ matFrustum.m5 = ((float)znear * 2.0f) / tb;
+ matFrustum.m6 = 0.0f;
+ matFrustum.m7 = 0.0f;
- matFrustum.m8 = ((float)right + (float)left)/rl;
- matFrustum.m9 = ((float)top + (float)bottom)/tb;
- matFrustum.m10 = -((float)zfar + (float)znear)/fn;
- matFrustum.m11 = -1.0f;
+ matFrustum.m8 = ((float)right + (float)left) / rl;
+ matFrustum.m9 = ((float)top + (float)bottom) / tb;
+ matFrustum.m10 = -((float)zfar + (float)znear) / fn;
+ matFrustum.m11 = -1.0f;
- matFrustum.m12 = 0.0f;
- matFrustum.m13 = 0.0f;
- matFrustum.m14 = -((float)zfar*(float)znear*2.0f)/fn;
- matFrustum.m15 = 0.0f;
+ matFrustum.m12 = 0.0f;
+ matFrustum.m13 = 0.0f;
+ matFrustum.m14 = -((float)zfar * (float)znear * 2.0f) / fn;
+ matFrustum.m15 = 0.0f;
- *RLGL.State.currentMatrix = rlMatrixMultiply(*RLGL.State.currentMatrix, matFrustum);
+ *RLGL.State.currentMatrix = rlMatrixMultiply(*RLGL.State.currentMatrix, matFrustum);
}
// Multiply the current matrix by an orthographic matrix generated by parameters
-void rlOrtho(double left, double right, double bottom, double top, double znear, double zfar)
-{
- // NOTE: If left-right and top-botton values are equal it could create a division by zero,
- // response to it is platform/compiler dependant
- RLMatrix matOrtho = { 0 };
-
- float rl = (float)(right - left);
- float tb = (float)(top - bottom);
- float fn = (float)(zfar - znear);
-
- matOrtho.m0 = 2.0f/rl;
- matOrtho.m1 = 0.0f;
- matOrtho.m2 = 0.0f;
- matOrtho.m3 = 0.0f;
- matOrtho.m4 = 0.0f;
- matOrtho.m5 = 2.0f/tb;
- matOrtho.m6 = 0.0f;
- matOrtho.m7 = 0.0f;
- matOrtho.m8 = 0.0f;
- matOrtho.m9 = 0.0f;
- matOrtho.m10 = -2.0f/fn;
- matOrtho.m11 = 0.0f;
- matOrtho.m12 = -((float)left + (float)right)/rl;
- matOrtho.m13 = -((float)top + (float)bottom)/tb;
- matOrtho.m14 = -((float)zfar + (float)znear)/fn;
- matOrtho.m15 = 1.0f;
-
- *RLGL.State.currentMatrix = rlMatrixMultiply(*RLGL.State.currentMatrix, matOrtho);
+void rlOrtho(double left, double right, double bottom, double top, double znear, double zfar) {
+ // NOTE: If left-right and top-botton values are equal it could create a division by zero,
+ // response to it is platform/compiler dependant
+ RLMatrix matOrtho = {0};
+
+ float rl = (float)(right - left);
+ float tb = (float)(top - bottom);
+ float fn = (float)(zfar - znear);
+
+ matOrtho.m0 = 2.0f / rl;
+ matOrtho.m1 = 0.0f;
+ matOrtho.m2 = 0.0f;
+ matOrtho.m3 = 0.0f;
+ matOrtho.m4 = 0.0f;
+ matOrtho.m5 = 2.0f / tb;
+ matOrtho.m6 = 0.0f;
+ matOrtho.m7 = 0.0f;
+ matOrtho.m8 = 0.0f;
+ matOrtho.m9 = 0.0f;
+ matOrtho.m10 = -2.0f / fn;
+ matOrtho.m11 = 0.0f;
+ matOrtho.m12 = -((float)left + (float)right) / rl;
+ matOrtho.m13 = -((float)top + (float)bottom) / tb;
+ matOrtho.m14 = -((float)zfar + (float)znear) / fn;
+ matOrtho.m15 = 1.0f;
+
+ *RLGL.State.currentMatrix = rlMatrixMultiply(*RLGL.State.currentMatrix, matOrtho);
}
#endif
// Set the viewport area (transformation from normalized device coordinates to window coordinates)
// NOTE: We store current viewport dimensions
-void rlViewport(int x, int y, int width, int height)
-{
- glViewport(x, y, width, height);
+void rlViewport(int x, int y, int width, int height) {
+ glViewport(x, y, width, height);
}
// Set clip planes distances
-void rlSetClipPlanes(double nearPlane, double farPlane)
-{
- rlCullDistanceNear = nearPlane;
- rlCullDistanceFar = farPlane;
+void rlSetClipPlanes(double nearPlane, double farPlane) {
+ rlCullDistanceNear = nearPlane;
+ rlCullDistanceFar = farPlane;
}
// Get cull plane distance near
-double rlGetCullDistanceNear(void)
-{
- return rlCullDistanceNear;
+double rlGetCullDistanceNear(void) {
+ return rlCullDistanceNear;
}
// Get cull plane distance far
-double rlGetCullDistanceFar(void)
-{
- return rlCullDistanceFar;
+double rlGetCullDistanceFar(void) {
+ return rlCullDistanceFar;
}
//----------------------------------------------------------------------------------
@@ -611,15 +618,20 @@ double rlGetCullDistanceFar(void)
#if defined(GRAPHICS_API_OPENGL_11)
// Fallback to OpenGL 1.1 function calls
//---------------------------------------
-void rlBegin(int mode)
-{
- switch (mode)
- {
- case RL_LINES: glBegin(GL_LINES); break;
- case RL_TRIANGLES: glBegin(GL_TRIANGLES); break;
- case RL_QUADS: glBegin(GL_QUADS); break;
- default: break;
- }
+void rlBegin(int mode) {
+ switch (mode) {
+ case RL_LINES:
+ glBegin(GL_LINES);
+ break;
+ case RL_TRIANGLES:
+ glBegin(GL_TRIANGLES);
+ break;
+ case RL_QUADS:
+ glBegin(GL_QUADS);
+ break;
+ default:
+ break;
+ }
}
void rlEnd(void) { glEnd(); }
@@ -634,181 +646,163 @@ void rlColor4f(float x, float y, float z, float w) { glColor4f(x, y, z, w); }
#endif
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
// Initialize drawing mode (how to organize vertex)
-void rlBegin(int mode)
-{
- // Draw mode can be RL_LINES, RL_TRIANGLES and RL_QUADS
- // NOTE: In all three cases, vertex are accumulated over default internal vertex buffer
- if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode != mode)
- {
- if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount > 0)
- {
- // Make sure current RLGL.currentBatch->draws[i].vertexCount is aligned a multiple of 4,
- // that way, following QUADS drawing will keep aligned with index processing
- // It implies adding some extra alignment vertex at the end of the draw,
- // those vertex are not processed but they are considered as an additional offset
- // for the next set of vertex to be drawn
- if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_LINES) RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment = ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount < 4)? RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount : RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount%4);
- else if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_TRIANGLES) RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment = ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount < 4)? 1 : (4 - (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount%4)));
- else RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment = 0;
-
- if (!rlCheckRenderBatchLimit(RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment))
- {
- RLGL.State.vertexCounter += RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment;
- RLGL.currentBatch->drawCounter++;
- }
- }
-
- if (RLGL.currentBatch->drawCounter >= RL_DEFAULT_BATCH_DRAWCALLS) rlDrawRenderBatch(RLGL.currentBatch);
-
- RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode = mode;
- RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount = 0;
- RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].textureId = RLGL.State.defaultTextureId;
- }
+void rlBegin(int mode) {
+ // Draw mode can be RL_LINES, RL_TRIANGLES and RL_QUADS
+ // NOTE: In all three cases, vertex are accumulated over default internal vertex buffer
+ if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode != mode) {
+ if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount > 0) {
+ // Make sure current RLGL.currentBatch->draws[i].vertexCount is aligned a multiple of 4,
+ // that way, following QUADS drawing will keep aligned with index processing
+ // It implies adding some extra alignment vertex at the end of the draw,
+ // those vertex are not processed but they are considered as an additional offset
+ // for the next set of vertex to be drawn
+ if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_LINES)
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment = ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount < 4) ? RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount : RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount % 4);
+ else if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_TRIANGLES)
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment = ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount < 4) ? 1 : (4 - (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount % 4)));
+ else
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment = 0;
+
+ if (!rlCheckRenderBatchLimit(RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment)) {
+ RLGL.State.vertexCounter += RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment;
+ RLGL.currentBatch->drawCounter++;
+ }
+ }
+
+ if (RLGL.currentBatch->drawCounter >= RL_DEFAULT_BATCH_DRAWCALLS)
+ rlDrawRenderBatch(RLGL.currentBatch);
+
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode = mode;
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount = 0;
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].textureId = RLGL.State.defaultTextureId;
+ }
}
// Finish vertex providing
-void rlEnd(void)
-{
- // NOTE: Depth increment is dependant on rlOrtho(): z-near and z-far values,
- // as well as depth buffer bit-depth (16bit or 24bit or 32bit)
- // Correct increment formula would be: depthInc = (zfar - znear)/pow(2, bits)
- RLGL.currentBatch->currentDepth += (1.0f/200000.0f);
+void rlEnd(void) {
+ // NOTE: Depth increment is dependant on rlOrtho(): z-near and z-far values,
+ // as well as depth buffer bit-depth (16bit or 24bit or 32bit)
+ // Correct increment formula would be: depthInc = (zfar - znear)/pow(2, bits)
+ RLGL.currentBatch->currentDepth += (1.0f / 200000.0f);
}
// Define one vertex (position)
// NOTE: Vertex position data is the basic information required for drawing
-void rlVertex3f(float x, float y, float z)
-{
- float tx = x;
- float ty = y;
- float tz = z;
-
- // Transform provided vector if required
- if (RLGL.State.transformRequired)
- {
- tx = RLGL.State.transform.m0*x + RLGL.State.transform.m4*y + RLGL.State.transform.m8*z + RLGL.State.transform.m12;
- ty = RLGL.State.transform.m1*x + RLGL.State.transform.m5*y + RLGL.State.transform.m9*z + RLGL.State.transform.m13;
- tz = RLGL.State.transform.m2*x + RLGL.State.transform.m6*y + RLGL.State.transform.m10*z + RLGL.State.transform.m14;
- }
-
- // WARNING: We can't break primitives when launching a new batch
- // RL_LINES comes in pairs, RL_TRIANGLES come in groups of 3 vertices and RL_QUADS come in groups of 4 vertices
- // We must check current draw.mode when a new vertex is required and finish the batch only if the draw.mode draw.vertexCount is %2, %3 or %4
- if (RLGL.State.vertexCounter > (RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].elementCount*4 - 4))
- {
- if ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_LINES) &&
- (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount%2 == 0))
- {
- // Reached the maximum number of vertices for RL_LINES drawing
- // Launch a draw call but keep current state for next vertices comming
- // NOTE: We add +1 vertex to the check for security
- rlCheckRenderBatchLimit(2 + 1);
- }
- else if ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_TRIANGLES) &&
- (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount%3 == 0))
- {
- rlCheckRenderBatchLimit(3 + 1);
- }
- else if ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_QUADS) &&
- (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount%4 == 0))
- {
- rlCheckRenderBatchLimit(4 + 1);
- }
- }
-
- // Add vertices
- RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].vertices[3*RLGL.State.vertexCounter] = tx;
- RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].vertices[3*RLGL.State.vertexCounter + 1] = ty;
- RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].vertices[3*RLGL.State.vertexCounter + 2] = tz;
-
- // Add current texcoord
- RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].texcoords[2*RLGL.State.vertexCounter] = RLGL.State.texcoordx;
- RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].texcoords[2*RLGL.State.vertexCounter + 1] = RLGL.State.texcoordy;
-
- // Add current normal
- RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].normals[3*RLGL.State.vertexCounter] = RLGL.State.normalx;
- RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].normals[3*RLGL.State.vertexCounter + 1] = RLGL.State.normaly;
- RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].normals[3*RLGL.State.vertexCounter + 2] = RLGL.State.normalz;
-
- // Add current color
- RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].colors[4*RLGL.State.vertexCounter] = RLGL.State.colorr;
- RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].colors[4*RLGL.State.vertexCounter + 1] = RLGL.State.colorg;
- RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].colors[4*RLGL.State.vertexCounter + 2] = RLGL.State.colorb;
- RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].colors[4*RLGL.State.vertexCounter + 3] = RLGL.State.colora;
-
- RLGL.State.vertexCounter++;
- RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount++;
+void rlVertex3f(float x, float y, float z) {
+ float tx = x;
+ float ty = y;
+ float tz = z;
+
+ // Transform provided vector if required
+ if (RLGL.State.transformRequired) {
+ tx = RLGL.State.transform.m0 * x + RLGL.State.transform.m4 * y + RLGL.State.transform.m8 * z + RLGL.State.transform.m12;
+ ty = RLGL.State.transform.m1 * x + RLGL.State.transform.m5 * y + RLGL.State.transform.m9 * z + RLGL.State.transform.m13;
+ tz = RLGL.State.transform.m2 * x + RLGL.State.transform.m6 * y + RLGL.State.transform.m10 * z + RLGL.State.transform.m14;
+ }
+
+ // WARNING: We can't break primitives when launching a new batch
+ // RL_LINES comes in pairs, RL_TRIANGLES come in groups of 3 vertices and RL_QUADS come in groups of 4 vertices
+ // We must check current draw.mode when a new vertex is required and finish the batch only if the draw.mode draw.vertexCount is %2, %3 or %4
+ if (RLGL.State.vertexCounter > (RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].elementCount * 4 - 4)) {
+ if ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_LINES) &&
+ (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount % 2 == 0)) {
+ // Reached the maximum number of vertices for RL_LINES drawing
+ // Launch a draw call but keep current state for next vertices comming
+ // NOTE: We add +1 vertex to the check for security
+ rlCheckRenderBatchLimit(2 + 1);
+ } else if ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_TRIANGLES) &&
+ (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount % 3 == 0)) {
+ rlCheckRenderBatchLimit(3 + 1);
+ } else if ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_QUADS) &&
+ (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount % 4 == 0)) {
+ rlCheckRenderBatchLimit(4 + 1);
+ }
+ }
+
+ // Add vertices
+ RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].vertices[3 * RLGL.State.vertexCounter] = tx;
+ RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].vertices[3 * RLGL.State.vertexCounter + 1] = ty;
+ RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].vertices[3 * RLGL.State.vertexCounter + 2] = tz;
+
+ // Add current texcoord
+ RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].texcoords[2 * RLGL.State.vertexCounter] = RLGL.State.texcoordx;
+ RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].texcoords[2 * RLGL.State.vertexCounter + 1] = RLGL.State.texcoordy;
+
+ // Add current normal
+ RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].normals[3 * RLGL.State.vertexCounter] = RLGL.State.normalx;
+ RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].normals[3 * RLGL.State.vertexCounter + 1] = RLGL.State.normaly;
+ RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].normals[3 * RLGL.State.vertexCounter + 2] = RLGL.State.normalz;
+
+ // Add current color
+ RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].colors[4 * RLGL.State.vertexCounter] = RLGL.State.colorr;
+ RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].colors[4 * RLGL.State.vertexCounter + 1] = RLGL.State.colorg;
+ RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].colors[4 * RLGL.State.vertexCounter + 2] = RLGL.State.colorb;
+ RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].colors[4 * RLGL.State.vertexCounter + 3] = RLGL.State.colora;
+
+ RLGL.State.vertexCounter++;
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount++;
}
void rlZDepth(float z) {
- RLGL.currentBatch->currentZ = z;
+ RLGL.currentBatch->currentZ = z;
}
// Define one vertex (position)
-void rlVertex2f(float x, float y)
-{
- rlVertex3f(x, y, RLGL.currentBatch->currentDepth - RLGL.currentBatch->currentZ);
+void rlVertex2f(float x, float y) {
+ rlVertex3f(x, y, RLGL.currentBatch->currentDepth - RLGL.currentBatch->currentZ);
}
// Define one vertex (position)
-void rlVertex2i(int x, int y)
-{
- rlVertex3f((float)x, (float)y, RLGL.currentBatch->currentDepth - RLGL.currentBatch->currentZ);
+void rlVertex2i(int x, int y) {
+ rlVertex3f((float)x, (float)y, RLGL.currentBatch->currentDepth - RLGL.currentBatch->currentZ);
}
// Define one vertex (texture coordinate)
// NOTE: Texture coordinates are limited to QUADS only
-void rlTexCoord2f(float x, float y)
-{
- RLGL.State.texcoordx = x;
- RLGL.State.texcoordy = y;
+void rlTexCoord2f(float x, float y) {
+ RLGL.State.texcoordx = x;
+ RLGL.State.texcoordy = y;
}
// Define one vertex (normal)
// NOTE: Normals limited to TRIANGLES only?
-void rlNormal3f(float x, float y, float z)
-{
- float normalx = x;
- float normaly = y;
- float normalz = z;
- if (RLGL.State.transformRequired)
- {
- normalx = RLGL.State.transform.m0*x + RLGL.State.transform.m4*y + RLGL.State.transform.m8*z;
- normaly = RLGL.State.transform.m1*x + RLGL.State.transform.m5*y + RLGL.State.transform.m9*z;
- normalz = RLGL.State.transform.m2*x + RLGL.State.transform.m6*y + RLGL.State.transform.m10*z;
- }
- float length = sqrtf(normalx*normalx + normaly*normaly + normalz*normalz);
- if (length != 0.0f)
- {
- float ilength = 1.0f/length;
- normalx *= ilength;
- normaly *= ilength;
- normalz *= ilength;
- }
- RLGL.State.normalx = normalx;
- RLGL.State.normaly = normaly;
- RLGL.State.normalz = normalz;
+void rlNormal3f(float x, float y, float z) {
+ float normalx = x;
+ float normaly = y;
+ float normalz = z;
+ if (RLGL.State.transformRequired) {
+ normalx = RLGL.State.transform.m0 * x + RLGL.State.transform.m4 * y + RLGL.State.transform.m8 * z;
+ normaly = RLGL.State.transform.m1 * x + RLGL.State.transform.m5 * y + RLGL.State.transform.m9 * z;
+ normalz = RLGL.State.transform.m2 * x + RLGL.State.transform.m6 * y + RLGL.State.transform.m10 * z;
+ }
+ float length = sqrtf(normalx * normalx + normaly * normaly + normalz * normalz);
+ if (length != 0.0f) {
+ float ilength = 1.0f / length;
+ normalx *= ilength;
+ normaly *= ilength;
+ normalz *= ilength;
+ }
+ RLGL.State.normalx = normalx;
+ RLGL.State.normaly = normaly;
+ RLGL.State.normalz = normalz;
}
// Define one vertex (color)
-void rlColor4ub(unsigned char x, unsigned char y, unsigned char z, unsigned char w)
-{
- RLGL.State.colorr = x;
- RLGL.State.colorg = y;
- RLGL.State.colorb = z;
- RLGL.State.colora = w;
+void rlColor4ub(unsigned char x, unsigned char y, unsigned char z, unsigned char w) {
+ RLGL.State.colorr = x;
+ RLGL.State.colorg = y;
+ RLGL.State.colorb = z;
+ RLGL.State.colora = w;
}
// Define one vertex (color)
-void rlColor4f(float r, float g, float b, float a)
-{
- rlColor4ub((unsigned char)(r*255), (unsigned char)(g*255), (unsigned char)(b*255), (unsigned char)(a*255));
+void rlColor4f(float r, float g, float b, float a) {
+ rlColor4ub((unsigned char)(r * 255), (unsigned char)(g * 255), (unsigned char)(b * 255), (unsigned char)(a * 255));
}
// Define one vertex (color)
-void rlColor3f(float x, float y, float z)
-{
- rlColor4ub((unsigned char)(x*255), (unsigned char)(y*255), (unsigned char)(z*255), 255);
+void rlColor3f(float x, float y, float z) {
+ rlColor4ub((unsigned char)(x * 255), (unsigned char)(y * 255), (unsigned char)(z * 255), 255);
}
#endif
@@ -818,293 +812,277 @@ void rlColor3f(float x, float y, float z)
//--------------------------------------------------------------------------------------
// Set current texture to use
-void rlSetTexture(unsigned int id)
-{
- if (id == 0)
- {
+void rlSetTexture(unsigned int id) {
+ if (id == 0) {
#if defined(GRAPHICS_API_OPENGL_11)
- rlDisableTexture();
+ rlDisableTexture();
#else
- // NOTE: If quads batch limit is reached, we force a draw call and next batch starts
- if (RLGL.State.vertexCounter >=
- RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].elementCount*4)
- {
- rlDrawRenderBatch(RLGL.currentBatch);
- }
-#endif
- }
- else
- {
+ // NOTE: If quads batch limit is reached, we force a draw call and next batch starts
+ if (RLGL.State.vertexCounter >=
+ RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].elementCount * 4) {
+ rlDrawRenderBatch(RLGL.currentBatch);
+ }
+#endif
+ } else {
#if defined(GRAPHICS_API_OPENGL_11)
- rlEnableTexture(id);
+ rlEnableTexture(id);
#else
- if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].textureId != id)
- {
- if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount > 0)
- {
- // Make sure current RLGL.currentBatch->draws[i].vertexCount is aligned a multiple of 4,
- // that way, following QUADS drawing will keep aligned with index processing
- // It implies adding some extra alignment vertex at the end of the draw,
- // those vertex are not processed but they are considered as an additional offset
- // for the next set of vertex to be drawn
- if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_LINES) RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment = ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount < 4)? RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount : RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount%4);
- else if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_TRIANGLES) RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment = ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount < 4)? 1 : (4 - (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount%4)));
- else RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment = 0;
+ if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].textureId != id) {
+ if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount > 0) {
+ // Make sure current RLGL.currentBatch->draws[i].vertexCount is aligned a multiple of 4,
+ // that way, following QUADS drawing will keep aligned with index processing
+ // It implies adding some extra alignment vertex at the end of the draw,
+ // those vertex are not processed but they are considered as an additional offset
+ // for the next set of vertex to be drawn
+ if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_LINES)
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment = ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount < 4) ? RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount : RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount % 4);
+ else if (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode == RL_TRIANGLES)
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment = ((RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount < 4) ? 1 : (4 - (RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount % 4)));
+ else
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment = 0;
- if (!rlCheckRenderBatchLimit(RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment))
- {
- RLGL.State.vertexCounter += RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment;
+ if (!rlCheckRenderBatchLimit(RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment)) {
+ RLGL.State.vertexCounter += RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexAlignment;
- RLGL.currentBatch->drawCounter++;
- }
- }
+ RLGL.currentBatch->drawCounter++;
+ }
+ }
- if (RLGL.currentBatch->drawCounter >= RL_DEFAULT_BATCH_DRAWCALLS) rlDrawRenderBatch(RLGL.currentBatch);
+ if (RLGL.currentBatch->drawCounter >= RL_DEFAULT_BATCH_DRAWCALLS)
+ rlDrawRenderBatch(RLGL.currentBatch);
- RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].textureId = id;
- RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount = 0;
- }
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].textureId = id;
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].vertexCount = 0;
+ }
#endif
- }
+ }
}
// Select and active a texture slot
-void rlActiveTextureSlot(int slot)
-{
+void rlActiveTextureSlot(int slot) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glActiveTexture(GL_TEXTURE0 + slot);
+ glActiveTexture(GL_TEXTURE0 + slot);
#endif
}
// Enable texture
-void rlEnableTexture(unsigned int id)
-{
+void rlEnableTexture(unsigned int id) {
#if defined(GRAPHICS_API_OPENGL_11)
- glEnable(GL_TEXTURE_2D);
+ glEnable(GL_TEXTURE_2D);
#endif
- glBindTexture(GL_TEXTURE_2D, id);
+ glBindTexture(GL_TEXTURE_2D, id);
}
// Disable texture
-void rlDisableTexture(void)
-{
+void rlDisableTexture(void) {
#if defined(GRAPHICS_API_OPENGL_11)
- glDisable(GL_TEXTURE_2D);
+ glDisable(GL_TEXTURE_2D);
#endif
- glBindTexture(GL_TEXTURE_2D, 0);
+ glBindTexture(GL_TEXTURE_2D, 0);
}
// Enable texture cubemap
-void rlEnableTextureCubemap(unsigned int id)
-{
+void rlEnableTextureCubemap(unsigned int id) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glBindTexture(GL_TEXTURE_CUBE_MAP, id);
+ glBindTexture(GL_TEXTURE_CUBE_MAP, id);
#endif
}
// Disable texture cubemap
-void rlDisableTextureCubemap(void)
-{
+void rlDisableTextureCubemap(void) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glBindTexture(GL_TEXTURE_CUBE_MAP, 0);
+ glBindTexture(GL_TEXTURE_CUBE_MAP, 0);
#endif
}
// Set texture parameters (wrap mode/filter mode)
-void rlTextureParameters(unsigned int id, int param, int value)
-{
- glBindTexture(GL_TEXTURE_2D, id);
+void rlTextureParameters(unsigned int id, int param, int value) {
+ glBindTexture(GL_TEXTURE_2D, id);
#if !defined(GRAPHICS_API_OPENGL_11)
- // Reset anisotropy filter, in case it was set
- glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAX_ANISOTROPY_EXT, 1.0f);
+ // Reset anisotropy filter, in case it was set
+ glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAX_ANISOTROPY_EXT, 1.0f);
#endif
- switch (param)
- {
- case RL_TEXTURE_WRAP_S:
- case RL_TEXTURE_WRAP_T:
- {
- if (value == RL_TEXTURE_WRAP_MIRROR_CLAMP)
- {
+ switch (param) {
+ case RL_TEXTURE_WRAP_S:
+ case RL_TEXTURE_WRAP_T: {
+ if (value == RL_TEXTURE_WRAP_MIRROR_CLAMP) {
#if !defined(GRAPHICS_API_OPENGL_11)
- if (RLGL.ExtSupported.texMirrorClamp) glTexParameteri(GL_TEXTURE_2D, param, value);
- else TRACELOG(RL_LOG_WARNING, "GL: Clamp mirror wrap mode not supported (GL_MIRROR_CLAMP_EXT)");
-#endif
- }
- else glTexParameteri(GL_TEXTURE_2D, param, value);
-
- } break;
- case RL_TEXTURE_MAG_FILTER:
- case RL_TEXTURE_MIN_FILTER: glTexParameteri(GL_TEXTURE_2D, param, value); break;
- case RL_TEXTURE_FILTER_ANISOTROPIC:
- {
+ if (RLGL.ExtSupported.texMirrorClamp)
+ glTexParameteri(GL_TEXTURE_2D, param, value);
+ else
+ TRACELOG(RL_LOG_WARNING, "GL: Clamp mirror wrap mode not supported (GL_MIRROR_CLAMP_EXT)");
+#endif
+ } else
+ glTexParameteri(GL_TEXTURE_2D, param, value);
+
+ } break;
+ case RL_TEXTURE_MAG_FILTER:
+ case RL_TEXTURE_MIN_FILTER:
+ glTexParameteri(GL_TEXTURE_2D, param, value);
+ break;
+ case RL_TEXTURE_FILTER_ANISOTROPIC: {
#if !defined(GRAPHICS_API_OPENGL_11)
- if (value <= RLGL.ExtSupported.maxAnisotropyLevel) glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAX_ANISOTROPY_EXT, (float)value);
- else if (RLGL.ExtSupported.maxAnisotropyLevel > 0.0f)
- {
- TRACELOG(RL_LOG_WARNING, "GL: Maximum anisotropic filter level supported is %iX", id, (int)RLGL.ExtSupported.maxAnisotropyLevel);
- glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAX_ANISOTROPY_EXT, (float)value);
- }
- else TRACELOG(RL_LOG_WARNING, "GL: Anisotropic filtering not supported");
-#endif
- } break;
+ if (value <= RLGL.ExtSupported.maxAnisotropyLevel)
+ glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAX_ANISOTROPY_EXT, (float)value);
+ else if (RLGL.ExtSupported.maxAnisotropyLevel > 0.0f) {
+ TRACELOG(RL_LOG_WARNING, "GL: Maximum anisotropic filter level supported is %iX", id, (int)RLGL.ExtSupported.maxAnisotropyLevel);
+ glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAX_ANISOTROPY_EXT, (float)value);
+ } else
+ TRACELOG(RL_LOG_WARNING, "GL: Anisotropic filtering not supported");
+#endif
+ } break;
#if defined(GRAPHICS_API_OPENGL_33)
- case RL_TEXTURE_MIPMAP_BIAS_RATIO: glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_LOD_BIAS, value/100.0f);
+ case RL_TEXTURE_MIPMAP_BIAS_RATIO:
+ glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_LOD_BIAS, value / 100.0f);
#endif
- default: break;
- }
+ default:
+ break;
+ }
- glBindTexture(GL_TEXTURE_2D, 0);
+ glBindTexture(GL_TEXTURE_2D, 0);
}
// Set cubemap parameters (wrap mode/filter mode)
-void rlCubemapParameters(unsigned int id, int param, int value)
-{
+void rlCubemapParameters(unsigned int id, int param, int value) {
#if !defined(GRAPHICS_API_OPENGL_11)
- glBindTexture(GL_TEXTURE_CUBE_MAP, id);
-
- // Reset anisotropy filter, in case it was set
- glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MAX_ANISOTROPY_EXT, 1.0f);
-
- switch (param)
- {
- case RL_TEXTURE_WRAP_S:
- case RL_TEXTURE_WRAP_T:
- {
- if (value == RL_TEXTURE_WRAP_MIRROR_CLAMP)
- {
- if (RLGL.ExtSupported.texMirrorClamp) glTexParameteri(GL_TEXTURE_CUBE_MAP, param, value);
- else TRACELOG(RL_LOG_WARNING, "GL: Clamp mirror wrap mode not supported (GL_MIRROR_CLAMP_EXT)");
- }
- else glTexParameteri(GL_TEXTURE_CUBE_MAP, param, value);
-
- } break;
- case RL_TEXTURE_MAG_FILTER:
- case RL_TEXTURE_MIN_FILTER: glTexParameteri(GL_TEXTURE_CUBE_MAP, param, value); break;
- case RL_TEXTURE_FILTER_ANISOTROPIC:
- {
- if (value <= RLGL.ExtSupported.maxAnisotropyLevel) glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MAX_ANISOTROPY_EXT, (float)value);
- else if (RLGL.ExtSupported.maxAnisotropyLevel > 0.0f)
- {
- TRACELOG(RL_LOG_WARNING, "GL: Maximum anisotropic filter level supported is %iX", id, (int)RLGL.ExtSupported.maxAnisotropyLevel);
- glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MAX_ANISOTROPY_EXT, (float)value);
- }
- else TRACELOG(RL_LOG_WARNING, "GL: Anisotropic filtering not supported");
- } break;
+ glBindTexture(GL_TEXTURE_CUBE_MAP, id);
+
+ // Reset anisotropy filter, in case it was set
+ glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MAX_ANISOTROPY_EXT, 1.0f);
+
+ switch (param) {
+ case RL_TEXTURE_WRAP_S:
+ case RL_TEXTURE_WRAP_T: {
+ if (value == RL_TEXTURE_WRAP_MIRROR_CLAMP) {
+ if (RLGL.ExtSupported.texMirrorClamp)
+ glTexParameteri(GL_TEXTURE_CUBE_MAP, param, value);
+ else
+ TRACELOG(RL_LOG_WARNING, "GL: Clamp mirror wrap mode not supported (GL_MIRROR_CLAMP_EXT)");
+ } else
+ glTexParameteri(GL_TEXTURE_CUBE_MAP, param, value);
+
+ } break;
+ case RL_TEXTURE_MAG_FILTER:
+ case RL_TEXTURE_MIN_FILTER:
+ glTexParameteri(GL_TEXTURE_CUBE_MAP, param, value);
+ break;
+ case RL_TEXTURE_FILTER_ANISOTROPIC: {
+ if (value <= RLGL.ExtSupported.maxAnisotropyLevel)
+ glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MAX_ANISOTROPY_EXT, (float)value);
+ else if (RLGL.ExtSupported.maxAnisotropyLevel > 0.0f) {
+ TRACELOG(RL_LOG_WARNING, "GL: Maximum anisotropic filter level supported is %iX", id, (int)RLGL.ExtSupported.maxAnisotropyLevel);
+ glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MAX_ANISOTROPY_EXT, (float)value);
+ } else
+ TRACELOG(RL_LOG_WARNING, "GL: Anisotropic filtering not supported");
+ } break;
#if defined(GRAPHICS_API_OPENGL_33)
- case RL_TEXTURE_MIPMAP_BIAS_RATIO: glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_LOD_BIAS, value/100.0f);
+ case RL_TEXTURE_MIPMAP_BIAS_RATIO:
+ glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_LOD_BIAS, value / 100.0f);
#endif
- default: break;
- }
+ default:
+ break;
+ }
- glBindTexture(GL_TEXTURE_CUBE_MAP, 0);
+ glBindTexture(GL_TEXTURE_CUBE_MAP, 0);
#endif
}
// Enable shader program
-void rlEnableShader(unsigned int id)
-{
+void rlEnableShader(unsigned int id) {
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2))
- glUseProgram(id);
+ glUseProgram(id);
#endif
}
// Disable shader program
-void rlDisableShader(void)
-{
+void rlDisableShader(void) {
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2))
- glUseProgram(0);
+ glUseProgram(0);
#endif
}
// Enable rendering to texture (fbo)
-void rlEnableFramebuffer(unsigned int id)
-{
+void rlEnableFramebuffer(unsigned int id) {
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)) && defined(RLGL_RENDER_TEXTURES_HINT)
- glBindFramebuffer(GL_FRAMEBUFFER, id);
+ glBindFramebuffer(GL_FRAMEBUFFER, id);
#endif
}
// return the active render texture (fbo)
-unsigned int rlGetActiveFramebuffer(void)
-{
- GLint fboId = 0;
+unsigned int rlGetActiveFramebuffer(void) {
+ GLint fboId = 0;
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES3)) && defined(RLGL_RENDER_TEXTURES_HINT)
- glGetIntegerv(GL_DRAW_FRAMEBUFFER_BINDING, &fboId);
+ glGetIntegerv(GL_DRAW_FRAMEBUFFER_BINDING, &fboId);
#endif
- return fboId;
+ return fboId;
}
// Disable rendering to texture
-void rlDisableFramebuffer(void)
-{
+void rlDisableFramebuffer(void) {
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)) && defined(RLGL_RENDER_TEXTURES_HINT)
- glBindFramebuffer(GL_FRAMEBUFFER, 0);
+ glBindFramebuffer(GL_FRAMEBUFFER, 0);
#endif
}
// Blit active framebuffer to main framebuffer
-void rlBlitFramebuffer(int srcX, int srcY, int srcWidth, int srcHeight, int dstX, int dstY, int dstWidth, int dstHeight, int bufferMask)
-{
+void rlBlitFramebuffer(int srcX, int srcY, int srcWidth, int srcHeight, int dstX, int dstY, int dstWidth, int dstHeight, int bufferMask) {
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES3)) && defined(RLGL_RENDER_TEXTURES_HINT)
- glBlitFramebuffer(srcX, srcY, srcWidth, srcHeight, dstX, dstY, dstWidth, dstHeight, bufferMask, GL_NEAREST);
+ glBlitFramebuffer(srcX, srcY, srcWidth, srcHeight, dstX, dstY, dstWidth, dstHeight, bufferMask, GL_NEAREST);
#endif
}
// Bind framebuffer object (fbo)
-void rlBindFramebuffer(unsigned int target, unsigned int framebuffer)
-{
+void rlBindFramebuffer(unsigned int target, unsigned int framebuffer) {
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)) && defined(RLGL_RENDER_TEXTURES_HINT)
- glBindFramebuffer(target, framebuffer);
+ glBindFramebuffer(target, framebuffer);
#endif
}
// Activate multiple draw color buffers
// NOTE: One color buffer is always active by default
-void rlActiveDrawBuffers(int count)
-{
+void rlActiveDrawBuffers(int count) {
#if ((defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES3)) && defined(RLGL_RENDER_TEXTURES_HINT))
- // NOTE: Maximum number of draw buffers supported is implementation dependant,
- // it can be queried with glGet*() but it must be at least 8
- //GLint maxDrawBuffers = 0;
- //glGetIntegerv(GL_MAX_DRAW_BUFFERS, &maxDrawBuffers);
-
- if (count > 0)
- {
- if (count > 8) TRACELOG(LOG_WARNING, "GL: Max color buffers limited to 8");
- else
- {
- unsigned int buffers[8] = {
+ // NOTE: Maximum number of draw buffers supported is implementation dependant,
+ // it can be queried with glGet*() but it must be at least 8
+ // GLint maxDrawBuffers = 0;
+ // glGetIntegerv(GL_MAX_DRAW_BUFFERS, &maxDrawBuffers);
+
+ if (count > 0) {
+ if (count > 8)
+ TRACELOG(LOG_WARNING, "GL: Max color buffers limited to 8");
+ else {
+ unsigned int buffers[8] = {
#if defined(GRAPHICS_API_OPENGL_ES3)
- GL_COLOR_ATTACHMENT0_EXT,
- GL_COLOR_ATTACHMENT1_EXT,
- GL_COLOR_ATTACHMENT2_EXT,
- GL_COLOR_ATTACHMENT3_EXT,
- GL_COLOR_ATTACHMENT4_EXT,
- GL_COLOR_ATTACHMENT5_EXT,
- GL_COLOR_ATTACHMENT6_EXT,
- GL_COLOR_ATTACHMENT7_EXT,
+ GL_COLOR_ATTACHMENT0_EXT,
+ GL_COLOR_ATTACHMENT1_EXT,
+ GL_COLOR_ATTACHMENT2_EXT,
+ GL_COLOR_ATTACHMENT3_EXT,
+ GL_COLOR_ATTACHMENT4_EXT,
+ GL_COLOR_ATTACHMENT5_EXT,
+ GL_COLOR_ATTACHMENT6_EXT,
+ GL_COLOR_ATTACHMENT7_EXT,
#else
- GL_COLOR_ATTACHMENT0,
- GL_COLOR_ATTACHMENT1,
- GL_COLOR_ATTACHMENT2,
- GL_COLOR_ATTACHMENT3,
- GL_COLOR_ATTACHMENT4,
- GL_COLOR_ATTACHMENT5,
- GL_COLOR_ATTACHMENT6,
- GL_COLOR_ATTACHMENT7,
+ GL_COLOR_ATTACHMENT0,
+ GL_COLOR_ATTACHMENT1,
+ GL_COLOR_ATTACHMENT2,
+ GL_COLOR_ATTACHMENT3,
+ GL_COLOR_ATTACHMENT4,
+ GL_COLOR_ATTACHMENT5,
+ GL_COLOR_ATTACHMENT6,
+ GL_COLOR_ATTACHMENT7,
#endif
- };
+ };
#if defined(GRAPHICS_API_OPENGL_ES3)
- glDrawBuffersEXT(count, buffers);
+ glDrawBuffersEXT(count, buffers);
#else
- glDrawBuffers(count, buffers);
+ glDrawBuffers(count, buffers);
#endif
- }
- }
- else TRACELOG(LOG_WARNING, "GL: One color buffer active by default");
+ }
+ } else
+ TRACELOG(LOG_WARNING, "GL: One color buffer active by default");
#endif
}
@@ -1118,6 +1096,17 @@ void rlEnableColorBlend(void) { glEnable(GL_BLEND); }
// Disable color blending
void rlDisableColorBlend(void) { glDisable(GL_BLEND); }
+void rlEnableAdvancedColorBlend(void) {
+ if (RLGL.ExtSupported.advanced_blend_equations_coherent) {
+ glEnable(GL_BLEND_ADVANCED_COHERENT_KHR);
+ }
+}
+
+void rlDisableAdvancedColorBlend(void) {
+ if (RLGL.ExtSupported.advanced_blend_equations_coherent) {
+ glDisable(GL_BLEND_ADVANCED_COHERENT_KHR);
+ }
+}
// Enable depth test
void rlEnableDepthTest(void) { glEnable(GL_DEPTH_TEST); }
@@ -1140,14 +1129,17 @@ void rlDisableBackfaceCulling(void) { glDisable(GL_CULL_FACE); }
void rlColorMask(bool r, bool g, bool b, bool a) { glColorMask(r, g, b, a); }
// Set face culling mode
-void rlSetCullFace(int mode)
-{
- switch (mode)
- {
- case RL_CULL_FACE_BACK: glCullFace(GL_BACK); break;
- case RL_CULL_FACE_FRONT: glCullFace(GL_FRONT); break;
- default: break;
- }
+void rlSetCullFace(int mode) {
+ switch (mode) {
+ case RL_CULL_FACE_BACK:
+ glCullFace(GL_BACK);
+ break;
+ case RL_CULL_FACE_FRONT:
+ glCullFace(GL_FRONT);
+ break;
+ default:
+ break;
+ }
}
// Enable scissor test
@@ -1160,30 +1152,27 @@ void rlDisableScissorTest(void) { glDisable(GL_SCISSOR_TEST); }
void rlScissor(int x, int y, int width, int height) { glScissor(x, y, width, height); }
// Enable wire mode
-void rlEnableWireMode(void)
-{
+void rlEnableWireMode(void) {
#if defined(GRAPHICS_API_OPENGL_11) || defined(GRAPHICS_API_OPENGL_33)
- // NOTE: glPolygonMode() not available on OpenGL ES
- glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
+ // NOTE: glPolygonMode() not available on OpenGL ES
+ glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
#endif
}
// Enable point mode
-void rlEnablePointMode(void)
-{
+void rlEnablePointMode(void) {
#if defined(GRAPHICS_API_OPENGL_11) || defined(GRAPHICS_API_OPENGL_33)
- // NOTE: glPolygonMode() not available on OpenGL ES
- glPolygonMode(GL_FRONT_AND_BACK, GL_POINT);
- glEnable(GL_PROGRAM_POINT_SIZE);
+ // NOTE: glPolygonMode() not available on OpenGL ES
+ glPolygonMode(GL_FRONT_AND_BACK, GL_POINT);
+ glEnable(GL_PROGRAM_POINT_SIZE);
#endif
}
// Disable wire mode
-void rlDisableWireMode(void)
-{
+void rlDisableWireMode(void) {
#if defined(GRAPHICS_API_OPENGL_11) || defined(GRAPHICS_API_OPENGL_33)
- // NOTE: glPolygonMode() not available on OpenGL ES
- glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
+ // NOTE: glPolygonMode() not available on OpenGL ES
+ glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
#endif
}
@@ -1191,233 +1180,328 @@ void rlDisableWireMode(void)
void rlSetLineWidth(float width) { glLineWidth(width); }
// Get the line drawing width
-float rlGetLineWidth(void)
-{
- float width = 0;
- glGetFloatv(GL_LINE_WIDTH, &width);
- return width;
+float rlGetLineWidth(void) {
+ float width = 0;
+ glGetFloatv(GL_LINE_WIDTH, &width);
+ return width;
}
// Enable line aliasing
-void rlEnableSmoothLines(void)
-{
+void rlEnableSmoothLines(void) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_11)
- glEnable(GL_LINE_SMOOTH);
+ glEnable(GL_LINE_SMOOTH);
#endif
}
// Disable line aliasing
-void rlDisableSmoothLines(void)
-{
+void rlDisableSmoothLines(void) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_11)
- glDisable(GL_LINE_SMOOTH);
+ glDisable(GL_LINE_SMOOTH);
#endif
}
// Enable stereo rendering
-void rlEnableStereoRender(void)
-{
+void rlEnableStereoRender(void) {
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2))
- RLGL.State.stereoRender = true;
+ RLGL.State.stereoRender = true;
#endif
}
// Disable stereo rendering
-void rlDisableStereoRender(void)
-{
+void rlDisableStereoRender(void) {
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2))
- RLGL.State.stereoRender = false;
+ RLGL.State.stereoRender = false;
#endif
}
// Check if stereo render is enabled
-bool rlIsStereoRenderEnabled(void)
-{
+bool rlIsStereoRenderEnabled(void) {
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2))
- return RLGL.State.stereoRender;
+ return RLGL.State.stereoRender;
#else
- return false;
+ return false;
#endif
}
// Clear color buffer with color
-void rlClearColor(unsigned char r, unsigned char g, unsigned char b, unsigned char a)
-{
- // Color values clamp to 0.0f(0) and 1.0f(255)
- float cr = (float)r/255;
- float cg = (float)g/255;
- float cb = (float)b/255;
- float ca = (float)a/255;
+void rlClearColor(unsigned char r, unsigned char g, unsigned char b, unsigned char a) {
+ // Color values clamp to 0.0f(0) and 1.0f(255)
+ float cr = (float)r / 255;
+ float cg = (float)g / 255;
+ float cb = (float)b / 255;
+ float ca = (float)a / 255;
- glClearColor(cr, cg, cb, ca);
+ glClearColor(cr, cg, cb, ca);
}
// Clear used screen buffers (color and depth)
-void rlClearScreenBuffers(void)
-{
- glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); // Clear used buffers: Color and Depth (Depth is used for 3D)
- //glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT | GL_STENCIL_BUFFER_BIT); // Stencil buffer not used...
+void rlClearScreenBuffers(void) {
+ glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); // Clear used buffers: Color and Depth (Depth is used for 3D)
+ // glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT | GL_STENCIL_BUFFER_BIT); // Stencil buffer not used...
}
// Check and log OpenGL error codes
-void rlCheckErrors(void)
-{
+void rlCheckErrors(void) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- int check = 1;
- while (check)
- {
- const GLenum err = glGetError();
- switch (err)
- {
- case GL_NO_ERROR: check = 0; break;
- case 0x0500: TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_INVALID_ENUM"); break;
- case 0x0501: TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_INVALID_VALUE"); break;
- case 0x0502: TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_INVALID_OPERATION"); break;
- case 0x0503: TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_STACK_OVERFLOW"); break;
- case 0x0504: TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_STACK_UNDERFLOW"); break;
- case 0x0505: TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_OUT_OF_MEMORY"); break;
- case 0x0506: TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_INVALID_FRAMEBUFFER_OPERATION"); break;
- default: TRACELOG(RL_LOG_WARNING, "GL: Error detected: Unknown error code: %x", err); break;
- }
- }
+ int check = 1;
+ while (check) {
+ const GLenum err = glGetError();
+ switch (err) {
+ case GL_NO_ERROR:
+ check = 0;
+ break;
+ case 0x0500:
+ TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_INVALID_ENUM");
+ break;
+ case 0x0501:
+ TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_INVALID_VALUE");
+ break;
+ case 0x0502:
+ TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_INVALID_OPERATION");
+ break;
+ case 0x0503:
+ TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_STACK_OVERFLOW");
+ break;
+ case 0x0504:
+ TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_STACK_UNDERFLOW");
+ break;
+ case 0x0505:
+ TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_OUT_OF_MEMORY");
+ break;
+ case 0x0506:
+ TRACELOG(RL_LOG_WARNING, "GL: Error detected: GL_INVALID_FRAMEBUFFER_OPERATION");
+ break;
+ default:
+ TRACELOG(RL_LOG_WARNING, "GL: Error detected: Unknown error code: %x", err);
+ break;
+ }
+ }
#endif
}
// Set blend mode
-void rlSetBlendMode(int mode)
-{
+void rlSetBlendMode(int mode) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- if ((RLGL.State.currentBlendMode != mode) || ((mode == RL_BLEND_CUSTOM || mode == RL_BLEND_CUSTOM_SEPARATE) && RLGL.State.glCustomBlendModeModified))
- {
- rlDrawRenderBatch(RLGL.currentBatch);
-
- switch (mode)
- {
- case RL_BLEND_ALPHA: glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); glBlendEquation(GL_FUNC_ADD); break;
- case RL_BLEND_ADDITIVE: glBlendFunc(GL_SRC_ALPHA, GL_ONE); glBlendEquation(GL_FUNC_ADD); break;
- case RL_BLEND_MULTIPLIED: glBlendFunc(GL_DST_COLOR, GL_ONE_MINUS_SRC_ALPHA); glBlendEquation(GL_FUNC_ADD); break;
- case RL_BLEND_ADD_COLORS: glBlendFunc(GL_ONE, GL_ONE); glBlendEquation(GL_FUNC_ADD); break;
- case RL_BLEND_SUBTRACT_COLORS: glBlendFunc(GL_ONE, GL_ONE); glBlendEquation(GL_FUNC_SUBTRACT); break;
- case RL_BLEND_ALPHA_PREMULTIPLY: glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA); glBlendEquation(GL_FUNC_ADD); break;
- case RL_BLEND_CUSTOM:
- {
- // NOTE: Using GL blend src/dst factors and GL equation configured with rlSetBlendFactors()
- glBlendFunc(RLGL.State.glBlendSrcFactor, RLGL.State.glBlendDstFactor); glBlendEquation(RLGL.State.glBlendEquation);
-
- } break;
- case RL_BLEND_CUSTOM_SEPARATE:
- {
- // NOTE: Using GL blend src/dst factors and GL equation configured with rlSetBlendFactorsSeparate()
- glBlendFuncSeparate(RLGL.State.glBlendSrcFactorRGB, RLGL.State.glBlendDestFactorRGB, RLGL.State.glBlendSrcFactorAlpha, RLGL.State.glBlendDestFactorAlpha);
- glBlendEquationSeparate(RLGL.State.glBlendEquationRGB, RLGL.State.glBlendEquationAlpha);
-
- } break;
- default: break;
- }
-
- RLGL.State.currentBlendMode = mode;
- RLGL.State.glCustomBlendModeModified = false;
- }
+ if ((RLGL.State.currentBlendMode != mode) || ((mode == RL_BLEND_CUSTOM || mode == RL_BLEND_CUSTOM_SEPARATE) && RLGL.State.glCustomBlendModeModified)) {
+ rlDrawRenderBatch(RLGL.currentBatch);
+ TRACELOG(LOG_DEBUG, "blendmode: %d", mode);
+ switch (mode) {
+ case RL_BLEND_ALPHA:
+ glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
+ glBlendEquation(GL_FUNC_ADD);
+ break;
+ case RL_BLEND_BURN:
+ if(RLGL.ExtSupported.advanced_blend_equations){
+ glBlendEquation(GL_COLORBURN_KHR);
+ } else {
+ rlSetBlendMode(RL_BLEND_ALPHA);
+ }
+ break;
+ case RL_BLEND_DODGE:
+ if (RLGL.ExtSupported.advanced_blend_equations) {
+ glBlendEquation(GL_COLORDODGE_KHR);
+ } else {
+ rlSetBlendMode(RL_BLEND_ALPHA);
+ }
+ break;
+ case RL_BLEND_HSL_COLOR:
+ if (RLGL.ExtSupported.advanced_blend_equations) {
+ glBlendEquation(GL_HSL_COLOR_KHR);
+ } else {
+ rlSetBlendMode(RL_BLEND_ALPHA);
+ }
+ break;
+ case RL_BLEND_HSL_SATURATION:
+ if(RLGL.ExtSupported.advanced_blend_equations) {
+ glBlendEquation(GL_HSL_SATURATION_KHR);
+ } else {
+ rlSetBlendMode(RL_BLEND_ALPHA);
+ }
+ break;
+ case RL_BLEND_HSL_LUMINOSITY:
+ if (RLGL.ExtSupported.advanced_blend_equations) {
+ glBlendEquation(GL_HSL_LUMINOSITY_KHR);
+ } else {
+ rlSetBlendMode(RL_BLEND_ALPHA);
+ }
+ break;
+ case RL_BLEND_SCREEN:
+ glBlendFuncSeparate(GL_ONE, GL_ONE_MINUS_SRC_COLOR, GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
+ glBlendEquation(GL_FUNC_ADD);
+ break;
+ case RL_BLEND_ADDITIVE:
+ glBlendFunc(GL_SRC_ALPHA, GL_ONE);
+ glBlendEquation(GL_FUNC_ADD);
+ break;
+ case RL_BLEND_MULTIPLIED:
+ glBlendFunc(GL_DST_COLOR, GL_ONE_MINUS_SRC_ALPHA);
+ glBlendEquation(GL_FUNC_ADD);
+ break;
+ case RL_BLEND_ADD_COLORS:
+ glBlendFunc(GL_ONE, GL_ONE);
+ glBlendEquation(GL_FUNC_ADD);
+ break;
+ case RL_BLEND_SUBTRACT_COLORS:
+ glBlendFunc(GL_ONE, GL_ONE);
+ glBlendEquation(GL_FUNC_SUBTRACT);
+ break;
+ case RL_BLEND_ALPHA_PREMULTIPLY:
+ glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
+ glBlendEquation(GL_FUNC_ADD);
+ break;
+ case RL_BLEND_CUSTOM: {
+ // NOTE: Using GL blend src/dst factors and GL equation configured with rlSetBlendFactors()
+ glBlendFunc(RLGL.State.glBlendSrcFactor, RLGL.State.glBlendDstFactor);
+ glBlendEquation(RLGL.State.glBlendEquation);
+
+ } break;
+ case RL_BLEND_CUSTOM_SEPARATE: {
+ // NOTE: Using GL blend src/dst factors and GL equation configured with rlSetBlendFactorsSeparate()
+ glBlendFuncSeparate(RLGL.State.glBlendSrcFactorRGB, RLGL.State.glBlendDestFactorRGB, RLGL.State.glBlendSrcFactorAlpha, RLGL.State.glBlendDestFactorAlpha);
+ glBlendEquationSeparate(RLGL.State.glBlendEquationRGB, RLGL.State.glBlendEquationAlpha);
+
+ } break;
+ default:
+ break;
+ }
+
+ RLGL.State.currentBlendMode = mode;
+ RLGL.State.glCustomBlendModeModified = false;
+ }
#endif
}
// Set blending mode factor and equation
-void rlSetBlendFactors(int glSrcFactor, int glDstFactor, int glEquation)
-{
+void rlSetBlendFactors(int glSrcFactor, int glDstFactor, int glEquation) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- if ((RLGL.State.glBlendSrcFactor != glSrcFactor) ||
- (RLGL.State.glBlendDstFactor != glDstFactor) ||
- (RLGL.State.glBlendEquation != glEquation))
- {
- RLGL.State.glBlendSrcFactor = glSrcFactor;
- RLGL.State.glBlendDstFactor = glDstFactor;
- RLGL.State.glBlendEquation = glEquation;
+ if ((RLGL.State.glBlendSrcFactor != glSrcFactor) ||
+ (RLGL.State.glBlendDstFactor != glDstFactor) ||
+ (RLGL.State.glBlendEquation != glEquation)) {
+ RLGL.State.glBlendSrcFactor = glSrcFactor;
+ RLGL.State.glBlendDstFactor = glDstFactor;
+ RLGL.State.glBlendEquation = glEquation;
- RLGL.State.glCustomBlendModeModified = true;
- }
+ RLGL.State.glCustomBlendModeModified = true;
+ }
#endif
}
// Set blending mode factor and equation separately for RGB and alpha
-void rlSetBlendFactorsSeparate(int glSrcRGB, int glDstRGB, int glSrcAlpha, int glDstAlpha, int glEqRGB, int glEqAlpha)
-{
+void rlSetBlendFactorsSeparate(int glSrcRGB, int glDstRGB, int glSrcAlpha, int glDstAlpha, int glEqRGB, int glEqAlpha) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- if ((RLGL.State.glBlendSrcFactorRGB != glSrcRGB) ||
- (RLGL.State.glBlendDestFactorRGB != glDstRGB) ||
- (RLGL.State.glBlendSrcFactorAlpha != glSrcAlpha) ||
- (RLGL.State.glBlendDestFactorAlpha != glDstAlpha) ||
- (RLGL.State.glBlendEquationRGB != glEqRGB) ||
- (RLGL.State.glBlendEquationAlpha != glEqAlpha))
- {
- RLGL.State.glBlendSrcFactorRGB = glSrcRGB;
- RLGL.State.glBlendDestFactorRGB = glDstRGB;
- RLGL.State.glBlendSrcFactorAlpha = glSrcAlpha;
- RLGL.State.glBlendDestFactorAlpha = glDstAlpha;
- RLGL.State.glBlendEquationRGB = glEqRGB;
- RLGL.State.glBlendEquationAlpha = glEqAlpha;
+ if ((RLGL.State.glBlendSrcFactorRGB != glSrcRGB) ||
+ (RLGL.State.glBlendDestFactorRGB != glDstRGB) ||
+ (RLGL.State.glBlendSrcFactorAlpha != glSrcAlpha) ||
+ (RLGL.State.glBlendDestFactorAlpha != glDstAlpha) ||
+ (RLGL.State.glBlendEquationRGB != glEqRGB) ||
+ (RLGL.State.glBlendEquationAlpha != glEqAlpha)) {
+ RLGL.State.glBlendSrcFactorRGB = glSrcRGB;
+ RLGL.State.glBlendDestFactorRGB = glDstRGB;
+ RLGL.State.glBlendSrcFactorAlpha = glSrcAlpha;
+ RLGL.State.glBlendDestFactorAlpha = glDstAlpha;
+ RLGL.State.glBlendEquationRGB = glEqRGB;
+ RLGL.State.glBlendEquationAlpha = glEqAlpha;
- RLGL.State.glCustomBlendModeModified = true;
- }
+ RLGL.State.glCustomBlendModeModified = true;
+ }
#endif
}
//----------------------------------------------------------------------------------
// Module Functions Definition - OpenGL Debug
//----------------------------------------------------------------------------------
-#if defined(RLGL_ENABLE_OPENGL_DEBUG_CONTEXT) && defined(GRAPHICS_API_OPENGL_43)
-static void GLAPIENTRY rlDebugMessageCallback(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *message, const void *userParam)
-{
- // Ignore non-significant error/warning codes (NVidia drivers)
- // NOTE: Here there are the details with a sample output:
- // - #131169 - Framebuffer detailed info: The driver allocated storage for renderbuffer 2. (severity: low)
- // - #131185 - Buffer detailed info: Buffer object 1 (bound to GL_ELEMENT_ARRAY_BUFFER_ARB, usage hint is GL_ENUM_88e4)
- // will use VIDEO memory as the source for buffer object operations. (severity: low)
- // - #131218 - Program/shader state performance warning: Vertex shader in program 7 is being recompiled based on GL state. (severity: medium)
- // - #131204 - Texture state usage warning: The texture object (0) bound to texture image unit 0 does not have
- // a defined base level and cannot be used for texture mapping. (severity: low)
- if ((id == 131169) || (id == 131185) || (id == 131218) || (id == 131204)) return;
-
- const char *msgSource = NULL;
- switch (source)
- {
- case GL_DEBUG_SOURCE_API: msgSource = "API"; break;
- case GL_DEBUG_SOURCE_WINDOW_SYSTEM: msgSource = "WINDOW_SYSTEM"; break;
- case GL_DEBUG_SOURCE_SHADER_COMPILER: msgSource = "SHADER_COMPILER"; break;
- case GL_DEBUG_SOURCE_THIRD_PARTY: msgSource = "THIRD_PARTY"; break;
- case GL_DEBUG_SOURCE_APPLICATION: msgSource = "APPLICATION"; break;
- case GL_DEBUG_SOURCE_OTHER: msgSource = "OTHER"; break;
- default: break;
- }
-
- const char *msgType = NULL;
- switch (type)
- {
- case GL_DEBUG_TYPE_ERROR: msgType = "ERROR"; break;
- case GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR: msgType = "DEPRECATED_BEHAVIOR"; break;
- case GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR: msgType = "UNDEFINED_BEHAVIOR"; break;
- case GL_DEBUG_TYPE_PORTABILITY: msgType = "PORTABILITY"; break;
- case GL_DEBUG_TYPE_PERFORMANCE: msgType = "PERFORMANCE"; break;
- case GL_DEBUG_TYPE_MARKER: msgType = "MARKER"; break;
- case GL_DEBUG_TYPE_PUSH_GROUP: msgType = "PUSH_GROUP"; break;
- case GL_DEBUG_TYPE_POP_GROUP: msgType = "POP_GROUP"; break;
- case GL_DEBUG_TYPE_OTHER: msgType = "OTHER"; break;
- default: break;
- }
-
- const char *msgSeverity = "DEFAULT";
- switch (severity)
- {
- case GL_DEBUG_SEVERITY_LOW: msgSeverity = "LOW"; break;
- case GL_DEBUG_SEVERITY_MEDIUM: msgSeverity = "MEDIUM"; break;
- case GL_DEBUG_SEVERITY_HIGH: msgSeverity = "HIGH"; break;
- case GL_DEBUG_SEVERITY_NOTIFICATION: msgSeverity = "NOTIFICATION"; break;
- default: break;
- }
-
- TRACELOG(LOG_WARNING, "GL: OpenGL debug message: %s", message);
- TRACELOG(LOG_WARNING, " > Type: %s", msgType);
- TRACELOG(LOG_WARNING, " > Source = %s", msgSource);
- TRACELOG(LOG_WARNING, " > Severity = %s", msgSeverity);
+#if defined(RLGL_ENABLE_OPENGL_DEBUG_CONTEXT)
+static void GLAPIENTRY rlDebugMessageCallback(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar* message, const void* userParam) {
+ // Ignore non-significant error/warning codes (NVidia drivers)
+ // NOTE: Here there are the details with a sample output:
+ // - #131169 - Framebuffer detailed info: The driver allocated storage for renderbuffer 2. (severity: low)
+ // - #131185 - Buffer detailed info: Buffer object 1 (bound to GL_ELEMENT_ARRAY_BUFFER_ARB, usage hint is GL_ENUM_88e4)
+ // will use VIDEO memory as the source for buffer object operations. (severity: low)
+ // - #131218 - Program/shader state performance warning: Vertex shader in program 7 is being recompiled based on GL state. (severity: medium)
+ // - #131204 - Texture state usage warning: The texture object (0) bound to texture image unit 0 does not have
+ // a defined base level and cannot be used for texture mapping. (severity: low)
+ if ((id == 131169) || (id == 131185) || (id == 131218) || (id == 131204))
+ return;
+
+ const char* msgSource = NULL;
+ switch (source) {
+ case GL_DEBUG_SOURCE_API:
+ msgSource = "API";
+ break;
+ case GL_DEBUG_SOURCE_WINDOW_SYSTEM:
+ msgSource = "WINDOW_SYSTEM";
+ break;
+ case GL_DEBUG_SOURCE_SHADER_COMPILER:
+ msgSource = "SHADER_COMPILER";
+ break;
+ case GL_DEBUG_SOURCE_THIRD_PARTY:
+ msgSource = "THIRD_PARTY";
+ break;
+ case GL_DEBUG_SOURCE_APPLICATION:
+ msgSource = "APPLICATION";
+ break;
+ case GL_DEBUG_SOURCE_OTHER:
+ msgSource = "OTHER";
+ break;
+ default:
+ break;
+ }
+
+ const char* msgType = NULL;
+ switch (type) {
+ case GL_DEBUG_TYPE_ERROR:
+ msgType = "ERROR";
+ break;
+ case GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR:
+ msgType = "DEPRECATED_BEHAVIOR";
+ break;
+ case GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR:
+ msgType = "UNDEFINED_BEHAVIOR";
+ break;
+ case GL_DEBUG_TYPE_PORTABILITY:
+ msgType = "PORTABILITY";
+ break;
+ case GL_DEBUG_TYPE_PERFORMANCE:
+ msgType = "PERFORMANCE";
+ break;
+ case GL_DEBUG_TYPE_MARKER:
+ msgType = "MARKER";
+ break;
+ case GL_DEBUG_TYPE_PUSH_GROUP:
+ msgType = "PUSH_GROUP";
+ break;
+ case GL_DEBUG_TYPE_POP_GROUP:
+ msgType = "POP_GROUP";
+ break;
+ case GL_DEBUG_TYPE_OTHER:
+ msgType = "OTHER";
+ break;
+ default:
+ break;
+ }
+
+ const char* msgSeverity = "DEFAULT";
+ switch (severity) {
+ case GL_DEBUG_SEVERITY_LOW:
+ msgSeverity = "LOW";
+ break;
+ case GL_DEBUG_SEVERITY_MEDIUM:
+ msgSeverity = "MEDIUM";
+ break;
+ case GL_DEBUG_SEVERITY_HIGH:
+ msgSeverity = "HIGH";
+ break;
+ case GL_DEBUG_SEVERITY_NOTIFICATION:
+ msgSeverity = "NOTIFICATION";
+ break;
+ default:
+ break;
+ }
+
+ TRACELOG(LOG_WARNING, "GL: OpenGL debug message: %s", message);
+ TRACELOG(LOG_WARNING, " > Type: %s", msgType);
+ TRACELOG(LOG_WARNING, " > Source = %s", msgSource);
+ TRACELOG(LOG_WARNING, " > Severity = %s", msgSeverity);
}
#endif
@@ -1426,1820 +1510,2009 @@ static void GLAPIENTRY rlDebugMessageCallback(GLenum source, GLenum type, GLuint
//----------------------------------------------------------------------------------
// Initialize rlgl: OpenGL extensions, default buffers/shaders/textures, OpenGL states
-void rlglInit(int width, int height)
-{
- // Enable OpenGL debug context if required
-#if defined(RLGL_ENABLE_OPENGL_DEBUG_CONTEXT) && defined(GRAPHICS_API_OPENGL_43)
- if ((glDebugMessageCallback != NULL) && (glDebugMessageControl != NULL))
- {
- glDebugMessageCallback(rlDebugMessageCallback, 0);
- // glDebugMessageControl(GL_DEBUG_SOURCE_API, GL_DEBUG_TYPE_ERROR, GL_DEBUG_SEVERITY_HIGH, 0, 0, GL_TRUE);
-
- // Debug context options:
- // - GL_DEBUG_OUTPUT - Faster version but not useful for breakpoints
- // - GL_DEBUG_OUTPUT_SYNCHRONUS - Callback is in sync with errors, so a breakpoint can be placed on the callback in order to get a stacktrace for the GL error
- glEnable(GL_DEBUG_OUTPUT);
- glEnable(GL_DEBUG_OUTPUT_SYNCHRONOUS);
- }
+void rlglInit(int width, int height) {
+ // Enable OpenGL debug context if required
+#if defined(RLGL_ENABLE_OPENGL_DEBUG_CONTEXT)
+ if (RLGL.ExtSupported.debug_output && (glDebugMessageCallback != NULL) && (glDebugMessageControl != NULL)) {
+ glDebugMessageCallback(rlDebugMessageCallback, 0);
+ // glDebugMessageControl(GL_DEBUG_SOURCE_API, GL_DEBUG_TYPE_ERROR, GL_DEBUG_SEVERITY_HIGH, 0, 0, GL_TRUE);
+
+ // Debug context options:
+ // - GL_DEBUG_OUTPUT - Faster version but not useful for breakpoints
+ // - GL_DEBUG_OUTPUT_SYNCHRONUS - Callback is in sync with errors, so a breakpoint can be placed on the callback in order to get a stacktrace for the GL error
+ glEnable(GL_DEBUG_OUTPUT);
+ glEnable(GL_DEBUG_OUTPUT_SYNCHRONOUS);
+ }
#endif
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- // Init default white texture
- unsigned char pixels[4] = { 255, 255, 255, 255 }; // 1 pixel RGBA (4 bytes)
- RLGL.State.defaultTextureId = rlLoadTexture(pixels, 1, 1, RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8, 1);
-
- if (RLGL.State.defaultTextureId != 0) TRACELOG(RL_LOG_INFO, "TEXTURE: [ID %i] Default texture loaded successfully", RLGL.State.defaultTextureId);
- else TRACELOG(RL_LOG_WARNING, "TEXTURE: Failed to load default texture");
-
- // Init default Shader (customized for GL 3.3 and ES2)
- // Loaded: RLGL.State.defaultShaderId + RLGL.State.defaultShaderLocs
- rlLoadShaderDefault();
- RLGL.State.currentShaderId = RLGL.State.defaultShaderId;
- RLGL.State.currentShaderLocs = RLGL.State.defaultShaderLocs;
-
- // Init default vertex arrays buffers
- // Simulate that the default shader has the location RL_SHADER_LOC_VERTEX_NORMAL to bind the normal buffer for the default render batch
- RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_NORMAL] = RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL;
- RLGL.defaultBatch = rlLoadRenderBatch(RL_DEFAULT_BATCH_BUFFERS, RL_DEFAULT_BATCH_BUFFER_ELEMENTS);
- RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_NORMAL] = -1;
- RLGL.currentBatch = &RLGL.defaultBatch;
-
- // Init stack matrices (emulating OpenGL 1.1)
- for (int i = 0; i < RL_MAX_MATRIX_STACK_SIZE; i++) RLGL.State.stack[i] = rlMatrixIdentity();
-
- // Init internal matrices
- RLGL.State.transform = rlMatrixIdentity();
- RLGL.State.projection = rlMatrixIdentity();
- RLGL.State.modelview = rlMatrixIdentity();
- RLGL.State.currentMatrix = &RLGL.State.modelview;
-#endif // GRAPHICS_API_OPENGL_33 || GRAPHICS_API_OPENGL_ES2
-
- // Initialize OpenGL default states
- //----------------------------------------------------------
- // Init state: Depth test
- glDepthFunc(GL_LEQUAL); // Type of depth testing to apply
- glDisable(GL_DEPTH_TEST); // Disable depth testing for 2D (only used for 3D)
-
- // Init state: Blending mode
- glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); // Color blending function (how colors are mixed)
- glEnable(GL_BLEND); // Enable color blending (required to work with transparencies)
-
- // Init state: Culling
- // NOTE: All shapes/models triangles are drawn CCW
- glCullFace(GL_BACK); // Cull the back face (default)
- glFrontFace(GL_CCW); // Front face are defined counter clockwise (default)
- glEnable(GL_CULL_FACE); // Enable backface culling
-
- // Init state: Cubemap seamless
+ // Init default white texture
+ unsigned char pixels[4] = {255, 255, 255, 255}; // 1 pixel RGBA (4 bytes)
+ RLGL.State.defaultTextureId = rlLoadTexture(pixels, 1, 1, RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8, 1);
+
+ if (RLGL.State.defaultTextureId != 0)
+ TRACELOG(RL_LOG_INFO, "TEXTURE: [ID %i] Default texture loaded successfully", RLGL.State.defaultTextureId);
+ else
+ TRACELOG(RL_LOG_WARNING, "TEXTURE: Failed to load default texture");
+
+ // Init default Shader (customized for GL 3.3 and ES2)
+ // Loaded: RLGL.State.defaultShaderId + RLGL.State.defaultShaderLocs
+ rlLoadShaderDefault();
+ RLGL.State.currentShaderId = RLGL.State.defaultShaderId;
+ RLGL.State.currentShaderLocs = RLGL.State.defaultShaderLocs;
+
+ // Init default vertex arrays buffers
+ // Simulate that the default shader has the location RL_SHADER_LOC_VERTEX_NORMAL to bind the normal buffer for the default render batch
+ RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_NORMAL] = RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL;
+ RLGL.defaultBatch = rlLoadRenderBatch(RL_DEFAULT_BATCH_BUFFERS, RL_DEFAULT_BATCH_BUFFER_ELEMENTS);
+ RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_NORMAL] = -1;
+ RLGL.currentBatch = &RLGL.defaultBatch;
+
+ // Init stack matrices (emulating OpenGL 1.1)
+ for (int i = 0; i < RL_MAX_MATRIX_STACK_SIZE; i++)
+ RLGL.State.stack[i] = rlMatrixIdentity();
+
+ // Init internal matrices
+ RLGL.State.transform = rlMatrixIdentity();
+ RLGL.State.projection = rlMatrixIdentity();
+ RLGL.State.modelview = rlMatrixIdentity();
+ RLGL.State.currentMatrix = &RLGL.State.modelview;
+#endif // GRAPHICS_API_OPENGL_33 || GRAPHICS_API_OPENGL_ES2
+
+ // Initialize OpenGL default states
+ //----------------------------------------------------------
+ // Init state: Depth test
+ glDepthFunc(GL_LEQUAL); // Type of depth testing to apply
+ glDisable(GL_DEPTH_TEST); // Disable depth testing for 2D (only used for 3D)
+
+ // Init state: Blending mode
+ glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); // Color blending function (how colors are mixed)
+ glEnable(GL_BLEND); // Enable color blending (required to work with transparencies)
+
+ // Init state: Culling
+ // NOTE: All shapes/models triangles are drawn CCW
+ glCullFace(GL_BACK); // Cull the back face (default)
+ glFrontFace(GL_CCW); // Front face are defined counter clockwise (default)
+ glEnable(GL_CULL_FACE); // Enable backface culling
+
+ // Init state: Cubemap seamless
#if defined(GRAPHICS_API_OPENGL_33)
- glEnable(GL_TEXTURE_CUBE_MAP_SEAMLESS); // Seamless cubemaps (not supported on OpenGL ES 2.0)
+ glEnable(GL_TEXTURE_CUBE_MAP_SEAMLESS); // Seamless cubemaps (not supported on OpenGL ES 2.0)
#endif
#if defined(GRAPHICS_API_OPENGL_11)
- // Init state: Color hints (deprecated in OpenGL 3.0+)
- glHint(GL_PERSPECTIVE_CORRECTION_HINT, GL_NICEST); // Improve quality of color and texture coordinate interpolation
- glShadeModel(GL_SMOOTH); // Smooth shading between vertex (vertex colors interpolation)
+ // Init state: Color hints (deprecated in OpenGL 3.0+)
+ glHint(GL_PERSPECTIVE_CORRECTION_HINT, GL_NICEST); // Improve quality of color and texture coordinate interpolation
+ glShadeModel(GL_SMOOTH); // Smooth shading between vertex (vertex colors interpolation)
#endif
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- // Store screen size into global variables
- RLGL.State.framebufferWidth = width;
- RLGL.State.framebufferHeight = height;
+ // Store screen size into global variables
+ RLGL.State.framebufferWidth = width;
+ RLGL.State.framebufferHeight = height;
- TRACELOG(RL_LOG_INFO, "RLGL: Default OpenGL state initialized successfully");
- //----------------------------------------------------------
+ TRACELOG(RL_LOG_INFO, "RLGL: Default OpenGL state initialized successfully");
+ //----------------------------------------------------------
#endif
- // Init state: Color/Depth buffers clear
- glClearColor(0.0f, 0.0f, 0.0f, 1.0f); // Set clear color (black)
- glClearDepth(1.0f); // Set clear depth value (default)
- glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); // Clear color and depth buffers (depth buffer required for 3D)
+ // Init state: Color/Depth buffers clear
+ glClearColor(0.0f, 0.0f, 0.0f, 1.0f); // Set clear color (black)
+ glClearDepth(1.0f); // Set clear depth value (default)
+ glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); // Clear color and depth buffers (depth buffer required for 3D)
}
// Vertex Buffer Object deinitialization (memory free)
-void rlglClose(void)
-{
+void rlglClose(void) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- rlUnloadRenderBatch(RLGL.defaultBatch);
+ rlUnloadRenderBatch(RLGL.defaultBatch);
- rlUnloadShaderDefault(); // Unload default shader
+ rlUnloadShaderDefault(); // Unload default shader
- glDeleteTextures(1, &RLGL.State.defaultTextureId); // Unload default texture
- TRACELOG(RL_LOG_INFO, "TEXTURE: [ID %i] Default texture unloaded successfully", RLGL.State.defaultTextureId);
+ glDeleteTextures(1, &RLGL.State.defaultTextureId); // Unload default texture
+ TRACELOG(RL_LOG_INFO, "TEXTURE: [ID %i] Default texture unloaded successfully", RLGL.State.defaultTextureId);
#endif
}
// Load OpenGL extensions
// NOTE: External loader function must be provided
-void rlLoadExtensions(void *loader)
-{
-#if defined(GRAPHICS_API_OPENGL_33) // Also defined for GRAPHICS_API_OPENGL_21
- // NOTE: glad is generated and contains only required OpenGL 3.3 Core extensions (and lower versions)
- if (gladLoadGL((GLADloadfunc)loader) == 0) TRACELOG(RL_LOG_WARNING, "GLAD: Cannot load OpenGL extensions");
- else TRACELOG(RL_LOG_INFO, "GLAD: OpenGL extensions loaded successfully");
-
- // Get number of supported extensions
- GLint numExt = 0;
- glGetIntegerv(GL_NUM_EXTENSIONS, &numExt);
- TRACELOG(RL_LOG_INFO, "GL: Supported extensions count: %i", numExt);
+void rlLoadExtensions(void* loader) {
+#if defined(GRAPHICS_API_OPENGL_33) // Also defined for GRAPHICS_API_OPENGL_21
+ // NOTE: glad is generated and contains only required OpenGL 3.3 Core extensions (and lower versions)
+ if (gladLoadGL((GLADloadfunc)loader) == 0)
+ TRACELOG(RL_LOG_WARNING, "GLAD: Cannot load OpenGL extensions");
+ else
+ TRACELOG(RL_LOG_INFO, "GLAD: OpenGL extensions loaded successfully");
+
+ // Get number of supported extensions
+ GLint numExt = 0;
+ glGetIntegerv(GL_NUM_EXTENSIONS, &numExt);
+ TRACELOG(RL_LOG_INFO, "GL: Supported extensions count: %i", numExt);
#if defined(RLGL_SHOW_GL_DETAILS_INFO)
- // Get supported extensions list
- // WARNING: glGetStringi() not available on OpenGL 2.1
- TRACELOG(RL_LOG_INFO, "GL: OpenGL extensions:");
- for (int i = 0; i < numExt; i++) TRACELOG(RL_LOG_INFO, " %s", glGetStringi(GL_EXTENSIONS, i));
+ // Get supported extensions list
+ // WARNING: glGetStringi() not available on OpenGL 2.1
+ TRACELOG(RL_LOG_INFO, "GL: OpenGL extensions:");
+ for (int i = 0; i < numExt; i++)
+ TRACELOG(RL_LOG_INFO, " %s", glGetStringi(GL_EXTENSIONS, i));
#endif
#if defined(GRAPHICS_API_OPENGL_21)
- // Register supported extensions flags
- // Optional OpenGL 2.1 extensions
- RLGL.ExtSupported.vao = GLAD_GL_ARB_vertex_array_object;
- RLGL.ExtSupported.instancing = (GLAD_GL_EXT_draw_instanced && GLAD_GL_ARB_instanced_arrays);
- RLGL.ExtSupported.texNPOT = GLAD_GL_ARB_texture_non_power_of_two;
- RLGL.ExtSupported.texFloat32 = GLAD_GL_ARB_texture_float;
- RLGL.ExtSupported.texFloat16 = GLAD_GL_ARB_texture_float;
- RLGL.ExtSupported.texDepth = GLAD_GL_ARB_depth_texture;
- RLGL.ExtSupported.maxDepthBits = 32;
- RLGL.ExtSupported.texAnisoFilter = GLAD_GL_EXT_texture_filter_anisotropic;
- RLGL.ExtSupported.texMirrorClamp = GLAD_GL_EXT_texture_mirror_clamp;
+ // Register supported extensions flags
+ // Optional OpenGL 2.1 extensions
+ RLGL.ExtSupported.vao = GLAD_GL_ARB_vertex_array_object;
+ RLGL.ExtSupported.instancing = (GLAD_GL_EXT_draw_instanced && GLAD_GL_ARB_instanced_arrays);
+ RLGL.ExtSupported.texNPOT = GLAD_GL_ARB_texture_non_power_of_two;
+ RLGL.ExtSupported.texFloat32 = GLAD_GL_ARB_texture_float;
+ RLGL.ExtSupported.texFloat16 = GLAD_GL_ARB_texture_float;
+ RLGL.ExtSupported.texDepth = GLAD_GL_ARB_depth_texture;
+ RLGL.ExtSupported.maxDepthBits = 32;
+ RLGL.ExtSupported.texAnisoFilter = GLAD_GL_EXT_texture_filter_anisotropic;
+ RLGL.ExtSupported.texMirrorClamp = GLAD_GL_EXT_texture_mirror_clamp;
#else
- // Register supported extensions flags
- // OpenGL 3.3 extensions supported by default (core)
- RLGL.ExtSupported.vao = true;
- RLGL.ExtSupported.instancing = true;
- RLGL.ExtSupported.texNPOT = true;
- RLGL.ExtSupported.texFloat32 = true;
- RLGL.ExtSupported.texFloat16 = true;
- RLGL.ExtSupported.texDepth = true;
- RLGL.ExtSupported.maxDepthBits = 32;
- RLGL.ExtSupported.texAnisoFilter = true;
- RLGL.ExtSupported.texMirrorClamp = true;
-#endif
-
- // Optional OpenGL 3.3 extensions
- RLGL.ExtSupported.texCompASTC = GLAD_GL_KHR_texture_compression_astc_hdr && GLAD_GL_KHR_texture_compression_astc_ldr;
- RLGL.ExtSupported.texCompDXT = GLAD_GL_EXT_texture_compression_s3tc; // Texture compression: DXT
- RLGL.ExtSupported.texCompETC2 = GLAD_GL_ARB_ES3_compatibility; // Texture compression: ETC2/EAC
- RLGL.ExtSupported.debug_output = GLAD_GL_ARB_debug_output;
- #if defined(GRAPHICS_API_OPENGL_43)
- RLGL.ExtSupported.computeShader = GLAD_GL_ARB_compute_shader;
- RLGL.ExtSupported.ssbo = GLAD_GL_ARB_shader_storage_buffer_object;
- #endif
-
-#endif // GRAPHICS_API_OPENGL_33
+ // Register supported extensions flags
+ // OpenGL 3.3 extensions supported by default (core)
+ RLGL.ExtSupported.vao = true;
+ RLGL.ExtSupported.instancing = true;
+ RLGL.ExtSupported.texNPOT = true;
+ RLGL.ExtSupported.texFloat32 = true;
+ RLGL.ExtSupported.texFloat16 = true;
+ RLGL.ExtSupported.texDepth = true;
+ RLGL.ExtSupported.maxDepthBits = 32;
+ RLGL.ExtSupported.texAnisoFilter = true;
+ RLGL.ExtSupported.texMirrorClamp = true;
+#endif
+
+ // Optional OpenGL 3.3 extensions
+ RLGL.ExtSupported.texCompASTC = GLAD_GL_KHR_texture_compression_astc_hdr && GLAD_GL_KHR_texture_compression_astc_ldr;
+ RLGL.ExtSupported.texCompDXT = GLAD_GL_EXT_texture_compression_s3tc; // Texture compression: DXT
+ RLGL.ExtSupported.texCompETC2 = GLAD_GL_ARB_ES3_compatibility; // Texture compression: ETC2/EAC
+ RLGL.ExtSupported.debug_output = GLAD_GL_KHR_debug;
+ RLGL.ExtSupported.advanced_blend_equations = GLAD_GL_KHR_blend_equation_advanced;
+ RLGL.ExtSupported.advanced_blend_equations_coherent = GLAD_GL_KHR_blend_equation_advanced_coherent;
+#if defined(GRAPHICS_API_OPENGL_43)
+ RLGL.ExtSupported.computeShader = GLAD_GL_ARB_compute_shader;
+ RLGL.ExtSupported.ssbo = GLAD_GL_ARB_shader_storage_buffer_object;
+#endif
+
+#endif // GRAPHICS_API_OPENGL_33
#if defined(GRAPHICS_API_OPENGL_ES3)
- // Register supported extensions flags
- // OpenGL ES 3.0 extensions supported by default (or it should be)
- RLGL.ExtSupported.vao = true;
- RLGL.ExtSupported.instancing = true;
- RLGL.ExtSupported.texNPOT = true;
- RLGL.ExtSupported.texFloat32 = true;
- RLGL.ExtSupported.texFloat16 = true;
- RLGL.ExtSupported.texDepth = true;
- RLGL.ExtSupported.texDepthWebGL = true;
- RLGL.ExtSupported.maxDepthBits = 24;
- RLGL.ExtSupported.texAnisoFilter = true;
- RLGL.ExtSupported.texMirrorClamp = true;
- // TODO: Check for additional OpenGL ES 3.0 supported extensions:
- //RLGL.ExtSupported.texCompDXT = true;
- //RLGL.ExtSupported.texCompETC1 = true;
- //RLGL.ExtSupported.texCompETC2 = true;
- //RLGL.ExtSupported.texCompPVRT = true;
- //RLGL.ExtSupported.texCompASTC = true;
- //RLGL.ExtSupported.maxAnisotropyLevel = true;
- //RLGL.ExtSupported.computeShader = true;
- //RLGL.ExtSupported.ssbo = true;
+ // Register supported extensions flags
+ // OpenGL ES 3.0 extensions supported by default (or it should be)
+ RLGL.ExtSupported.vao = true;
+ RLGL.ExtSupported.instancing = true;
+ RLGL.ExtSupported.texNPOT = true;
+ RLGL.ExtSupported.texFloat32 = true;
+ RLGL.ExtSupported.texFloat16 = true;
+ RLGL.ExtSupported.texDepth = true;
+ RLGL.ExtSupported.texDepthWebGL = true;
+ RLGL.ExtSupported.maxDepthBits = 24;
+ RLGL.ExtSupported.texAnisoFilter = true;
+ RLGL.ExtSupported.texMirrorClamp = true;
+ // TODO: Check for additional OpenGL ES 3.0 supported extensions:
+ // RLGL.ExtSupported.texCompDXT = true;
+ // RLGL.ExtSupported.texCompETC1 = true;
+ // RLGL.ExtSupported.texCompETC2 = true;
+ // RLGL.ExtSupported.texCompPVRT = true;
+ // RLGL.ExtSupported.texCompASTC = true;
+ // RLGL.ExtSupported.maxAnisotropyLevel = true;
+ // RLGL.ExtSupported.computeShader = true;
+ // RLGL.ExtSupported.ssbo = true;
#elif defined(GRAPHICS_API_OPENGL_ES2)
- #if defined(PLATFORM_DESKTOP_GLFW) || defined(PLATFORM_DESKTOP_SDL)
- // TODO: Support GLAD loader for OpenGL ES 3.0
- if (gladLoadGLES2((GLADloadfunc)loader) == 0) TRACELOG(RL_LOG_WARNING, "GLAD: Cannot load OpenGL ES2.0 functions");
- else TRACELOG(RL_LOG_INFO, "GLAD: OpenGL ES 2.0 loaded successfully");
- #endif
-
- // Get supported extensions list
- GLint numExt = 0;
- const char **extList = RL_MALLOC(512*sizeof(const char *)); // Allocate 512 strings pointers (2 KB)
- const char *extensions = (const char *)glGetString(GL_EXTENSIONS); // One big const string
-
- // NOTE: We have to duplicate string because glGetString() returns a const string
- int size = strlen(extensions) + 1; // Get extensions string size in bytes
- char *extensionsDup = (char *)RL_CALLOC(size, sizeof(char));
- strcpy(extensionsDup, extensions);
- extList[numExt] = extensionsDup;
-
- for (int i = 0; i < size; i++)
- {
- if (extensionsDup[i] == ' ')
- {
- extensionsDup[i] = '\0';
- numExt++;
- extList[numExt] = &extensionsDup[i + 1];
- }
- }
-
- TRACELOG(RL_LOG_INFO, "GL: Supported extensions count: %i", numExt);
+#if defined(PLATFORM_DESKTOP_GLFW) || defined(PLATFORM_DESKTOP_SDL)
+ // TODO: Support GLAD loader for OpenGL ES 3.0
+ if (gladLoadGLES2((GLADloadfunc)loader) == 0)
+ TRACELOG(RL_LOG_WARNING, "GLAD: Cannot load OpenGL ES2.0 functions");
+ else
+ TRACELOG(RL_LOG_INFO, "GLAD: OpenGL ES 2.0 loaded successfully");
+#endif
+
+ // Get supported extensions list
+ GLint numExt = 0;
+ const char** extList = RL_MALLOC(512 * sizeof(const char*)); // Allocate 512 strings pointers (2 KB)
+ const char* extensions = (const char*)glGetString(GL_EXTENSIONS); // One big const string
+
+ // NOTE: We have to duplicate string because glGetString() returns a const string
+ int size = strlen(extensions) + 1; // Get extensions string size in bytes
+ char* extensionsDup = (char*)RL_CALLOC(size, sizeof(char));
+ strcpy(extensionsDup, extensions);
+ extList[numExt] = extensionsDup;
+
+ for (int i = 0; i < size; i++) {
+ if (extensionsDup[i] == ' ') {
+ extensionsDup[i] = '\0';
+ numExt++;
+ extList[numExt] = &extensionsDup[i + 1];
+ }
+ }
+
+ TRACELOG(RL_LOG_INFO, "GL: Supported extensions count: %i", numExt);
#if defined(RLGL_SHOW_GL_DETAILS_INFO)
- TRACELOG(RL_LOG_INFO, "GL: OpenGL extensions:");
- for (int i = 0; i < numExt; i++) TRACELOG(RL_LOG_INFO, " %s", extList[i]);
-#endif
-
- // Check required extensions
- for (int i = 0; i < numExt; i++)
- {
- // Check VAO support
- // NOTE: Only check on OpenGL ES, OpenGL 3.3 has VAO support as core feature
- if (strcmp(extList[i], (const char *)"GL_OES_vertex_array_object") == 0)
- {
- // The extension is supported by our hardware and driver, try to get related functions pointers
- // NOTE: emscripten does not support VAOs natively, it uses emulation and it reduces overall performance...
- glGenVertexArrays = (PFNGLGENVERTEXARRAYSOESPROC)((rlglLoadProc)loader)("glGenVertexArraysOES");
- glBindVertexArray = (PFNGLBINDVERTEXARRAYOESPROC)((rlglLoadProc)loader)("glBindVertexArrayOES");
- glDeleteVertexArrays = (PFNGLDELETEVERTEXARRAYSOESPROC)((rlglLoadProc)loader)("glDeleteVertexArraysOES");
- //glIsVertexArray = (PFNGLISVERTEXARRAYOESPROC)loader("glIsVertexArrayOES"); // NOTE: Fails in WebGL, omitted
-
- if ((glGenVertexArrays != NULL) && (glBindVertexArray != NULL) && (glDeleteVertexArrays != NULL)) RLGL.ExtSupported.vao = true;
- }
-
- // Check instanced rendering support
- if (strstr(extList[i], (const char*)"instanced_arrays") != NULL) // Broad check for instanced_arrays
- {
- // Specific check
- if (strcmp(extList[i], (const char *)"GL_ANGLE_instanced_arrays") == 0) // ANGLE
- {
- glDrawArraysInstanced = (PFNGLDRAWARRAYSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawArraysInstancedANGLE");
- glDrawElementsInstanced = (PFNGLDRAWELEMENTSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawElementsInstancedANGLE");
- glVertexAttribDivisor = (PFNGLVERTEXATTRIBDIVISOREXTPROC)((rlglLoadProc)loader)("glVertexAttribDivisorANGLE");
- }
- else if (strcmp(extList[i], (const char *)"GL_EXT_instanced_arrays") == 0) // EXT
- {
- glDrawArraysInstanced = (PFNGLDRAWARRAYSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawArraysInstancedEXT");
- glDrawElementsInstanced = (PFNGLDRAWELEMENTSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawElementsInstancedEXT");
- glVertexAttribDivisor = (PFNGLVERTEXATTRIBDIVISOREXTPROC)((rlglLoadProc)loader)("glVertexAttribDivisorEXT");
- }
- else if (strcmp(extList[i], (const char *)"GL_NV_instanced_arrays") == 0) // NVIDIA GLES
- {
- glDrawArraysInstanced = (PFNGLDRAWARRAYSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawArraysInstancedNV");
- glDrawElementsInstanced = (PFNGLDRAWELEMENTSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawElementsInstancedNV");
- glVertexAttribDivisor = (PFNGLVERTEXATTRIBDIVISOREXTPROC)((rlglLoadProc)loader)("glVertexAttribDivisorNV");
- }
-
- // The feature will only be marked as supported if the elements from GL_XXX_instanced_arrays are present
- if ((glDrawArraysInstanced != NULL) && (glDrawElementsInstanced != NULL) && (glVertexAttribDivisor != NULL)) RLGL.ExtSupported.instancing = true;
- }
- else if (strstr(extList[i], (const char *)"draw_instanced") != NULL)
- {
- // GL_ANGLE_draw_instanced doesn't exist
- if (strcmp(extList[i], (const char *)"GL_EXT_draw_instanced") == 0)
- {
- glDrawArraysInstanced = (PFNGLDRAWARRAYSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawArraysInstancedEXT");
- glDrawElementsInstanced = (PFNGLDRAWELEMENTSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawElementsInstancedEXT");
- }
- else if (strcmp(extList[i], (const char*)"GL_NV_draw_instanced") == 0)
- {
- glDrawArraysInstanced = (PFNGLDRAWARRAYSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawArraysInstancedNV");
- glDrawElementsInstanced = (PFNGLDRAWELEMENTSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawElementsInstancedNV");
- }
-
- // But the functions will at least be loaded if only GL_XX_EXT_draw_instanced exist
- if ((glDrawArraysInstanced != NULL) && (glDrawElementsInstanced != NULL) && (glVertexAttribDivisor != NULL)) RLGL.ExtSupported.instancing = true;
- }
-
- // Check NPOT textures support
- // NOTE: Only check on OpenGL ES, OpenGL 3.3 has NPOT textures full support as core feature
- if (strcmp(extList[i], (const char *)"GL_OES_texture_npot") == 0) RLGL.ExtSupported.texNPOT = true;
-
- // Check texture float support
- if (strcmp(extList[i], (const char *)"GL_OES_texture_float") == 0) RLGL.ExtSupported.texFloat32 = true;
- if (strcmp(extList[i], (const char *)"GL_OES_texture_half_float") == 0) RLGL.ExtSupported.texFloat16 = true;
-
- // Check depth texture support
- if (strcmp(extList[i], (const char *)"GL_OES_depth_texture") == 0) RLGL.ExtSupported.texDepth = true;
- if (strcmp(extList[i], (const char *)"GL_WEBGL_depth_texture") == 0) RLGL.ExtSupported.texDepthWebGL = true; // WebGL requires unsized internal format
- if (RLGL.ExtSupported.texDepthWebGL) RLGL.ExtSupported.texDepth = true;
-
- if (strcmp(extList[i], (const char *)"GL_OES_depth24") == 0) RLGL.ExtSupported.maxDepthBits = 24; // Not available on WebGL
- if (strcmp(extList[i], (const char *)"GL_OES_depth32") == 0) RLGL.ExtSupported.maxDepthBits = 32; // Not available on WebGL
-
- // Check texture compression support: DXT
- if ((strcmp(extList[i], (const char *)"GL_EXT_texture_compression_s3tc") == 0) ||
- (strcmp(extList[i], (const char *)"GL_WEBGL_compressed_texture_s3tc") == 0) ||
- (strcmp(extList[i], (const char *)"GL_WEBKIT_WEBGL_compressed_texture_s3tc") == 0)) RLGL.ExtSupported.texCompDXT = true;
-
- // Check texture compression support: ETC1
- if ((strcmp(extList[i], (const char *)"GL_OES_compressed_ETC1_RGB8_texture") == 0) ||
- (strcmp(extList[i], (const char *)"GL_WEBGL_compressed_texture_etc1") == 0)) RLGL.ExtSupported.texCompETC1 = true;
-
- // Check texture compression support: ETC2/EAC
- if (strcmp(extList[i], (const char *)"GL_ARB_ES3_compatibility") == 0) RLGL.ExtSupported.texCompETC2 = true;
-
- // Check texture compression support: PVR
- if (strcmp(extList[i], (const char *)"GL_IMG_texture_compression_pvrtc") == 0) RLGL.ExtSupported.texCompPVRT = true;
-
- // Check texture compression support: ASTC
- if (strcmp(extList[i], (const char *)"GL_KHR_texture_compression_astc_hdr") == 0) RLGL.ExtSupported.texCompASTC = true;
-
- // Check anisotropic texture filter support
- if (strcmp(extList[i], (const char *)"GL_EXT_texture_filter_anisotropic") == 0) RLGL.ExtSupported.texAnisoFilter = true;
-
- // Check clamp mirror wrap mode support
- if (strcmp(extList[i], (const char *)"GL_EXT_texture_mirror_clamp") == 0) RLGL.ExtSupported.texMirrorClamp = true;
- }
-
- // Free extensions pointers
- RL_FREE(extList);
- RL_FREE(extensionsDup); // Duplicated string must be deallocated
-#endif // GRAPHICS_API_OPENGL_ES2
-
- // Check OpenGL information and capabilities
- //------------------------------------------------------------------------------
- // Show current OpenGL and GLSL version
- TRACELOG(RL_LOG_INFO, "GL: OpenGL device information:");
- TRACELOG(RL_LOG_INFO, " > Vendor: %s", glGetString(GL_VENDOR));
- TRACELOG(RL_LOG_INFO, " > Renderer: %s", glGetString(GL_RENDERER));
- TRACELOG(RL_LOG_INFO, " > Version: %s", glGetString(GL_VERSION));
- TRACELOG(RL_LOG_INFO, " > GLSL: %s", glGetString(GL_SHADING_LANGUAGE_VERSION));
+ TRACELOG(RL_LOG_INFO, "GL: OpenGL extensions:");
+ for (int i = 0; i < numExt; i++)
+ TRACELOG(RL_LOG_INFO, " %s", extList[i]);
+#endif
+
+ // Check required extensions
+ for (int i = 0; i < numExt; i++) {
+ // Check VAO support
+ // NOTE: Only check on OpenGL ES, OpenGL 3.3 has VAO support as core feature
+ if (strcmp(extList[i], (const char*)"GL_OES_vertex_array_object") == 0) {
+ // The extension is supported by our hardware and driver, try to get related functions pointers
+ // NOTE: emscripten does not support VAOs natively, it uses emulation and it reduces overall performance...
+ glGenVertexArrays = (PFNGLGENVERTEXARRAYSOESPROC)((rlglLoadProc)loader)("glGenVertexArraysOES");
+ glBindVertexArray = (PFNGLBINDVERTEXARRAYOESPROC)((rlglLoadProc)loader)("glBindVertexArrayOES");
+ glDeleteVertexArrays = (PFNGLDELETEVERTEXARRAYSOESPROC)((rlglLoadProc)loader)("glDeleteVertexArraysOES");
+ // glIsVertexArray = (PFNGLISVERTEXARRAYOESPROC)loader("glIsVertexArrayOES"); // NOTE: Fails in WebGL, omitted
+
+ if ((glGenVertexArrays != NULL) && (glBindVertexArray != NULL) && (glDeleteVertexArrays != NULL))
+ RLGL.ExtSupported.vao = true;
+ }
+
+ // Check instanced rendering support
+ if (strstr(extList[i], (const char*)"instanced_arrays") != NULL) // Broad check for instanced_arrays
+ {
+ // Specific check
+ if (strcmp(extList[i], (const char*)"GL_ANGLE_instanced_arrays") == 0) // ANGLE
+ {
+ glDrawArraysInstanced = (PFNGLDRAWARRAYSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawArraysInstancedANGLE");
+ glDrawElementsInstanced = (PFNGLDRAWELEMENTSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawElementsInstancedANGLE");
+ glVertexAttribDivisor = (PFNGLVERTEXATTRIBDIVISOREXTPROC)((rlglLoadProc)loader)("glVertexAttribDivisorANGLE");
+ } else if (strcmp(extList[i], (const char*)"GL_EXT_instanced_arrays") == 0) // EXT
+ {
+ glDrawArraysInstanced = (PFNGLDRAWARRAYSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawArraysInstancedEXT");
+ glDrawElementsInstanced = (PFNGLDRAWELEMENTSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawElementsInstancedEXT");
+ glVertexAttribDivisor = (PFNGLVERTEXATTRIBDIVISOREXTPROC)((rlglLoadProc)loader)("glVertexAttribDivisorEXT");
+ } else if (strcmp(extList[i], (const char*)"GL_NV_instanced_arrays") == 0) // NVIDIA GLES
+ {
+ glDrawArraysInstanced = (PFNGLDRAWARRAYSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawArraysInstancedNV");
+ glDrawElementsInstanced = (PFNGLDRAWELEMENTSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawElementsInstancedNV");
+ glVertexAttribDivisor = (PFNGLVERTEXATTRIBDIVISOREXTPROC)((rlglLoadProc)loader)("glVertexAttribDivisorNV");
+ }
+
+ // The feature will only be marked as supported if the elements from GL_XXX_instanced_arrays are present
+ if ((glDrawArraysInstanced != NULL) && (glDrawElementsInstanced != NULL) && (glVertexAttribDivisor != NULL))
+ RLGL.ExtSupported.instancing = true;
+ } else if (strstr(extList[i], (const char*)"draw_instanced") != NULL) {
+ // GL_ANGLE_draw_instanced doesn't exist
+ if (strcmp(extList[i], (const char*)"GL_EXT_draw_instanced") == 0) {
+ glDrawArraysInstanced = (PFNGLDRAWARRAYSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawArraysInstancedEXT");
+ glDrawElementsInstanced = (PFNGLDRAWELEMENTSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawElementsInstancedEXT");
+ } else if (strcmp(extList[i], (const char*)"GL_NV_draw_instanced") == 0) {
+ glDrawArraysInstanced = (PFNGLDRAWARRAYSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawArraysInstancedNV");
+ glDrawElementsInstanced = (PFNGLDRAWELEMENTSINSTANCEDEXTPROC)((rlglLoadProc)loader)("glDrawElementsInstancedNV");
+ }
+
+ // But the functions will at least be loaded if only GL_XX_EXT_draw_instanced exist
+ if ((glDrawArraysInstanced != NULL) && (glDrawElementsInstanced != NULL) && (glVertexAttribDivisor != NULL))
+ RLGL.ExtSupported.instancing = true;
+ }
+
+ // Check NPOT textures support
+ // NOTE: Only check on OpenGL ES, OpenGL 3.3 has NPOT textures full support as core feature
+ if (strcmp(extList[i], (const char*)"GL_OES_texture_npot") == 0)
+ RLGL.ExtSupported.texNPOT = true;
+
+ // Check texture float support
+ if (strcmp(extList[i], (const char*)"GL_OES_texture_float") == 0)
+ RLGL.ExtSupported.texFloat32 = true;
+ if (strcmp(extList[i], (const char*)"GL_OES_texture_half_float") == 0)
+ RLGL.ExtSupported.texFloat16 = true;
+
+ // Check depth texture support
+ if (strcmp(extList[i], (const char*)"GL_OES_depth_texture") == 0)
+ RLGL.ExtSupported.texDepth = true;
+ if (strcmp(extList[i], (const char*)"GL_WEBGL_depth_texture") == 0)
+ RLGL.ExtSupported.texDepthWebGL = true; // WebGL requires unsized internal format
+ if (RLGL.ExtSupported.texDepthWebGL)
+ RLGL.ExtSupported.texDepth = true;
+
+ if (strcmp(extList[i], (const char*)"GL_OES_depth24") == 0)
+ RLGL.ExtSupported.maxDepthBits = 24; // Not available on WebGL
+ if (strcmp(extList[i], (const char*)"GL_OES_depth32") == 0)
+ RLGL.ExtSupported.maxDepthBits = 32; // Not available on WebGL
+
+ // Check texture compression support: DXT
+ if ((strcmp(extList[i], (const char*)"GL_EXT_texture_compression_s3tc") == 0) ||
+ (strcmp(extList[i], (const char*)"GL_WEBGL_compressed_texture_s3tc") == 0) ||
+ (strcmp(extList[i], (const char*)"GL_WEBKIT_WEBGL_compressed_texture_s3tc") == 0))
+ RLGL.ExtSupported.texCompDXT = true;
+
+ // Check texture compression support: ETC1
+ if ((strcmp(extList[i], (const char*)"GL_OES_compressed_ETC1_RGB8_texture") == 0) ||
+ (strcmp(extList[i], (const char*)"GL_WEBGL_compressed_texture_etc1") == 0))
+ RLGL.ExtSupported.texCompETC1 = true;
+
+ // Check texture compression support: ETC2/EAC
+ if (strcmp(extList[i], (const char*)"GL_ARB_ES3_compatibility") == 0)
+ RLGL.ExtSupported.texCompETC2 = true;
+
+ // Check texture compression support: PVR
+ if (strcmp(extList[i], (const char*)"GL_IMG_texture_compression_pvrtc") == 0)
+ RLGL.ExtSupported.texCompPVRT = true;
+
+ // Check texture compression support: ASTC
+ if (strcmp(extList[i], (const char*)"GL_KHR_texture_compression_astc_hdr") == 0)
+ RLGL.ExtSupported.texCompASTC = true;
+
+ // Check anisotropic texture filter support
+ if (strcmp(extList[i], (const char*)"GL_EXT_texture_filter_anisotropic") == 0)
+ RLGL.ExtSupported.texAnisoFilter = true;
+
+ // Check clamp mirror wrap mode support
+ if (strcmp(extList[i], (const char*)"GL_EXT_texture_mirror_clamp") == 0)
+ RLGL.ExtSupported.texMirrorClamp = true;
+ }
+
+ // Free extensions pointers
+ RL_FREE(extList);
+ RL_FREE(extensionsDup); // Duplicated string must be deallocated
+#endif // GRAPHICS_API_OPENGL_ES2
+
+ // Check OpenGL information and capabilities
+ //------------------------------------------------------------------------------
+ // Show current OpenGL and GLSL version
+ TRACELOG(RL_LOG_INFO, "GL: OpenGL device information:");
+ TRACELOG(RL_LOG_INFO, " > Vendor: %s", glGetString(GL_VENDOR));
+ TRACELOG(RL_LOG_INFO, " > Renderer: %s", glGetString(GL_RENDERER));
+ TRACELOG(RL_LOG_INFO, " > Version: %s", glGetString(GL_VERSION));
+ TRACELOG(RL_LOG_INFO, " > GLSL: %s", glGetString(GL_SHADING_LANGUAGE_VERSION));
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- // NOTE: Anisotropy levels capability is an extension
- #ifndef GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT
- #define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF
- #endif
- glGetFloatv(GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT, &RLGL.ExtSupported.maxAnisotropyLevel);
+// NOTE: Anisotropy levels capability is an extension
+#ifndef GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT
+#define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF
+#endif
+ glGetFloatv(GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT, &RLGL.ExtSupported.maxAnisotropyLevel);
#if defined(RLGL_SHOW_GL_DETAILS_INFO)
- // Show some OpenGL GPU capabilities
- TRACELOG(RL_LOG_INFO, "GL: OpenGL capabilities:");
- GLint capability = 0;
- glGetIntegerv(GL_MAX_TEXTURE_SIZE, &capability);
- TRACELOG(RL_LOG_INFO, " GL_MAX_TEXTURE_SIZE: %i", capability);
- glGetIntegerv(GL_MAX_CUBE_MAP_TEXTURE_SIZE, &capability);
- TRACELOG(RL_LOG_INFO, " GL_MAX_CUBE_MAP_TEXTURE_SIZE: %i", capability);
- glGetIntegerv(GL_MAX_TEXTURE_IMAGE_UNITS, &capability);
- TRACELOG(RL_LOG_INFO, " GL_MAX_TEXTURE_IMAGE_UNITS: %i", capability);
- glGetIntegerv(GL_MAX_VERTEX_ATTRIBS, &capability);
- TRACELOG(RL_LOG_INFO, " GL_MAX_VERTEX_ATTRIBS: %i", capability);
- #if !defined(GRAPHICS_API_OPENGL_ES2)
- glGetIntegerv(GL_MAX_UNIFORM_BLOCK_SIZE, &capability);
- TRACELOG(RL_LOG_INFO, " GL_MAX_UNIFORM_BLOCK_SIZE: %i", capability);
- glGetIntegerv(GL_MAX_DRAW_BUFFERS, &capability);
- TRACELOG(RL_LOG_INFO, " GL_MAX_DRAW_BUFFERS: %i", capability);
- if (RLGL.ExtSupported.texAnisoFilter) TRACELOG(RL_LOG_INFO, " GL_MAX_TEXTURE_MAX_ANISOTROPY: %.0f", RLGL.ExtSupported.maxAnisotropyLevel);
- #endif
- glGetIntegerv(GL_NUM_COMPRESSED_TEXTURE_FORMATS, &capability);
- TRACELOG(RL_LOG_INFO, " GL_NUM_COMPRESSED_TEXTURE_FORMATS: %i", capability);
- GLint *compFormats = (GLint *)RL_CALLOC(capability, sizeof(GLint));
- glGetIntegerv(GL_COMPRESSED_TEXTURE_FORMATS, compFormats);
- for (int i = 0; i < capability; i++) TRACELOG(RL_LOG_INFO, " %s", rlGetCompressedFormatName(compFormats[i]));
- RL_FREE(compFormats);
+ // Show some OpenGL GPU capabilities
+ TRACELOG(RL_LOG_INFO, "GL: OpenGL capabilities:");
+ GLint capability = 0;
+ glGetIntegerv(GL_MAX_TEXTURE_SIZE, &capability);
+ TRACELOG(RL_LOG_INFO, " GL_MAX_TEXTURE_SIZE: %i", capability);
+ glGetIntegerv(GL_MAX_CUBE_MAP_TEXTURE_SIZE, &capability);
+ TRACELOG(RL_LOG_INFO, " GL_MAX_CUBE_MAP_TEXTURE_SIZE: %i", capability);
+ glGetIntegerv(GL_MAX_TEXTURE_IMAGE_UNITS, &capability);
+ TRACELOG(RL_LOG_INFO, " GL_MAX_TEXTURE_IMAGE_UNITS: %i", capability);
+ glGetIntegerv(GL_MAX_VERTEX_ATTRIBS, &capability);
+ TRACELOG(RL_LOG_INFO, " GL_MAX_VERTEX_ATTRIBS: %i", capability);
+ glGetIntegerv(GL_MAX_UNIFORM_LOCATIONS, &capability);
+ TRACELOG(RL_LOG_INFO, " GL_MAX_UNIFORM_LOCATIONS: %i", capability);
+#if !defined(GRAPHICS_API_OPENGL_ES2)
+ glGetIntegerv(GL_MAX_UNIFORM_BLOCK_SIZE, &capability);
+ TRACELOG(RL_LOG_INFO, " GL_MAX_UNIFORM_BLOCK_SIZE: %i", capability);
+ glGetIntegerv(GL_MAX_DRAW_BUFFERS, &capability);
+ TRACELOG(RL_LOG_INFO, " GL_MAX_DRAW_BUFFERS: %i", capability);
+ if (RLGL.ExtSupported.texAnisoFilter)
+ TRACELOG(RL_LOG_INFO, " GL_MAX_TEXTURE_MAX_ANISOTROPY: %.0f", RLGL.ExtSupported.maxAnisotropyLevel);
+#endif
+ glGetIntegerv(GL_NUM_COMPRESSED_TEXTURE_FORMATS, &capability);
+ TRACELOG(RL_LOG_INFO, " GL_NUM_COMPRESSED_TEXTURE_FORMATS: %i", capability);
+ GLint* compFormats = (GLint*)RL_CALLOC(capability, sizeof(GLint));
+ glGetIntegerv(GL_COMPRESSED_TEXTURE_FORMATS, compFormats);
+ for (int i = 0; i < capability; i++)
+ TRACELOG(RL_LOG_INFO, " %s", rlGetCompressedFormatName(compFormats[i]));
+ RL_FREE(compFormats);
#if defined(GRAPHICS_API_OPENGL_43)
- glGetIntegerv(GL_MAX_VERTEX_ATTRIB_BINDINGS, &capability);
- TRACELOG(RL_LOG_INFO, " GL_MAX_VERTEX_ATTRIB_BINDINGS: %i", capability);
- glGetIntegerv(GL_MAX_UNIFORM_LOCATIONS, &capability);
- TRACELOG(RL_LOG_INFO, " GL_MAX_UNIFORM_LOCATIONS: %i", capability);
-#endif // GRAPHICS_API_OPENGL_43
-#else // RLGL_SHOW_GL_DETAILS_INFO
-
- // Show some basic info about GL supported features
- if (RLGL.ExtSupported.vao) TRACELOG(RL_LOG_INFO, "GL: VAO extension detected, VAO functions loaded successfully");
- else TRACELOG(RL_LOG_WARNING, "GL: VAO extension not found, VAO not supported");
- if (RLGL.ExtSupported.texNPOT) TRACELOG(RL_LOG_INFO, "GL: NPOT textures extension detected, full NPOT textures supported");
- else TRACELOG(RL_LOG_WARNING, "GL: NPOT textures extension not found, limited NPOT support (no-mipmaps, no-repeat)");
- if (RLGL.ExtSupported.texCompDXT) TRACELOG(RL_LOG_INFO, "GL: DXT compressed textures supported");
- if (RLGL.ExtSupported.texCompETC1) TRACELOG(RL_LOG_INFO, "GL: ETC1 compressed textures supported");
- if (RLGL.ExtSupported.texCompETC2) TRACELOG(RL_LOG_INFO, "GL: ETC2/EAC compressed textures supported");
- if (RLGL.ExtSupported.texCompPVRT) TRACELOG(RL_LOG_INFO, "GL: PVRT compressed textures supported");
- if (RLGL.ExtSupported.texCompASTC) TRACELOG(RL_LOG_INFO, "GL: ASTC compressed textures supported");
- if (RLGL.ExtSupported.computeShader) TRACELOG(RL_LOG_INFO, "GL: Compute shaders supported");
- if (RLGL.ExtSupported.ssbo) TRACELOG(RL_LOG_INFO, "GL: Shader storage buffer objects supported");
-#endif // RLGL_SHOW_GL_DETAILS_INFO
-
-#endif // GRAPHICS_API_OPENGL_33 || GRAPHICS_API_OPENGL_ES2
+ glGetIntegerv(GL_MAX_VERTEX_ATTRIB_BINDINGS, &capability);
+ TRACELOG(RL_LOG_INFO, " GL_MAX_VERTEX_ATTRIB_BINDINGS: %i", capability);
+ glGetIntegerv(GL_MAX_UNIFORM_LOCATIONS, &capability);
+ TRACELOG(RL_LOG_INFO, " GL_MAX_UNIFORM_LOCATIONS: %i", capability);
+#endif // GRAPHICS_API_OPENGL_43
+#else // RLGL_SHOW_GL_DETAILS_INFO
+
+ // Show some basic info about GL supported features
+ if (RLGL.ExtSupported.vao)
+ TRACELOG(RL_LOG_INFO, "GL: VAO extension detected, VAO functions loaded successfully");
+ else
+ TRACELOG(RL_LOG_WARNING, "GL: VAO extension not found, VAO not supported");
+ if (RLGL.ExtSupported.texNPOT)
+ TRACELOG(RL_LOG_INFO, "GL: NPOT textures extension detected, full NPOT textures supported");
+ else
+ TRACELOG(RL_LOG_WARNING, "GL: NPOT textures extension not found, limited NPOT support (no-mipmaps, no-repeat)");
+ if (RLGL.ExtSupported.texCompDXT)
+ TRACELOG(RL_LOG_INFO, "GL: DXT compressed textures supported");
+ if (RLGL.ExtSupported.texCompETC1)
+ TRACELOG(RL_LOG_INFO, "GL: ETC1 compressed textures supported");
+ if (RLGL.ExtSupported.texCompETC2)
+ TRACELOG(RL_LOG_INFO, "GL: ETC2/EAC compressed textures supported");
+ if (RLGL.ExtSupported.texCompPVRT)
+ TRACELOG(RL_LOG_INFO, "GL: PVRT compressed textures supported");
+ if (RLGL.ExtSupported.texCompASTC)
+ TRACELOG(RL_LOG_INFO, "GL: ASTC compressed textures supported");
+ if (RLGL.ExtSupported.computeShader)
+ TRACELOG(RL_LOG_INFO, "GL: Compute shaders supported");
+ if (RLGL.ExtSupported.ssbo)
+ TRACELOG(RL_LOG_INFO, "GL: Shader storage buffer objects supported");
+#endif // RLGL_SHOW_GL_DETAILS_INFO
+
+#endif // GRAPHICS_API_OPENGL_33 || GRAPHICS_API_OPENGL_ES2
}
// Get current OpenGL version
-int rlGetVersion(void)
-{
- int glVersion = 0;
+int rlGetVersion(void) {
+ int glVersion = 0;
#if defined(GRAPHICS_API_OPENGL_11)
- glVersion = RL_OPENGL_11;
+ glVersion = RL_OPENGL_11;
#endif
#if defined(GRAPHICS_API_OPENGL_21)
- glVersion = RL_OPENGL_21;
+ glVersion = RL_OPENGL_21;
#elif defined(GRAPHICS_API_OPENGL_43)
- glVersion = RL_OPENGL_43;
+ glVersion = RL_OPENGL_43;
#elif defined(GRAPHICS_API_OPENGL_33)
- glVersion = RL_OPENGL_33;
+ glVersion = RL_OPENGL_33;
#endif
#if defined(GRAPHICS_API_OPENGL_ES3)
- glVersion = RL_OPENGL_ES_30;
+ glVersion = RL_OPENGL_ES_30;
#elif defined(GRAPHICS_API_OPENGL_ES2)
- glVersion = RL_OPENGL_ES_20;
+ glVersion = RL_OPENGL_ES_20;
#endif
- return glVersion;
+ return glVersion;
}
// Set current framebuffer width
-void rlSetFramebufferWidth(int width)
-{
+void rlSetFramebufferWidth(int width) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- RLGL.State.framebufferWidth = width;
+ RLGL.State.framebufferWidth = width;
#endif
}
// Set current framebuffer height
-void rlSetFramebufferHeight(int height)
-{
+void rlSetFramebufferHeight(int height) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- RLGL.State.framebufferHeight = height;
+ RLGL.State.framebufferHeight = height;
#endif
}
// Get default framebuffer width
-int rlGetFramebufferWidth(void)
-{
- int width = 0;
+int rlGetFramebufferWidth(void) {
+ int width = 0;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- width = RLGL.State.framebufferWidth;
+ width = RLGL.State.framebufferWidth;
#endif
- return width;
+ return width;
}
// Get default framebuffer height
-int rlGetFramebufferHeight(void)
-{
- int height = 0;
+int rlGetFramebufferHeight(void) {
+ int height = 0;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- height = RLGL.State.framebufferHeight;
+ height = RLGL.State.framebufferHeight;
#endif
- return height;
+ return height;
}
// Get default internal texture (white texture)
// NOTE: Default texture is a 1x1 pixel UNCOMPRESSED_R8G8B8A8
-unsigned int rlGetTextureIdDefault(void)
-{
- unsigned int id = 0;
+unsigned int rlGetTextureIdDefault(void) {
+ unsigned int id = 0;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- id = RLGL.State.defaultTextureId;
+ id = RLGL.State.defaultTextureId;
#endif
- return id;
+ return id;
}
// Get default shader id
-unsigned int rlGetShaderIdDefault(void)
-{
- unsigned int id = 0;
+unsigned int rlGetShaderIdDefault(void) {
+ unsigned int id = 0;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- id = RLGL.State.defaultShaderId;
+ id = RLGL.State.defaultShaderId;
#endif
- return id;
+ return id;
}
// Get default shader locs
-int *rlGetShaderLocsDefault(void)
-{
- int *locs = NULL;
+int* rlGetShaderLocsDefault(void) {
+ int* locs = NULL;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- locs = RLGL.State.defaultShaderLocs;
+ locs = RLGL.State.defaultShaderLocs;
#endif
- return locs;
+ return locs;
}
// Render batch management
//------------------------------------------------------------------------------------------------
// Load render batch
-rlRenderBatch rlLoadRenderBatch(int numBuffers, int bufferElements)
-{
- rlRenderBatch batch = { 0 };
+rlRenderBatch rlLoadRenderBatch(int numBuffers, int bufferElements) {
+ rlRenderBatch batch = {0};
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- // Initialize CPU (RAM) vertex buffers (position, texcoord, color data and indexes)
- //--------------------------------------------------------------------------------------------
- batch.vertexBuffer = (rlVertexBuffer *)RL_MALLOC(numBuffers*sizeof(rlVertexBuffer));
-
- for (int i = 0; i < numBuffers; i++)
- {
- batch.vertexBuffer[i].elementCount = bufferElements;
-
- batch.vertexBuffer[i].vertices = (float *)RL_MALLOC(bufferElements*3*4*sizeof(float)); // 3 float by vertex, 4 vertex by quad
- batch.vertexBuffer[i].texcoords = (float *)RL_MALLOC(bufferElements*2*4*sizeof(float)); // 2 float by texcoord, 4 texcoord by quad
- batch.vertexBuffer[i].normals = (float *)RL_MALLOC(bufferElements*3*4*sizeof(float)); // 3 float by vertex, 4 vertex by quad
- batch.vertexBuffer[i].colors = (unsigned char *)RL_MALLOC(bufferElements*4*4*sizeof(unsigned char)); // 4 float by color, 4 colors by quad
+ // Initialize CPU (RAM) vertex buffers (position, texcoord, color data and indexes)
+ //--------------------------------------------------------------------------------------------
+ batch.vertexBuffer = (rlVertexBuffer*)RL_MALLOC(numBuffers * sizeof(rlVertexBuffer));
+
+ for (int i = 0; i < numBuffers; i++) {
+ batch.vertexBuffer[i].elementCount = bufferElements;
+
+ batch.vertexBuffer[i].vertices = (float*)RL_MALLOC(bufferElements * 3 * 4 * sizeof(float)); // 3 float by vertex, 4 vertex by quad
+ batch.vertexBuffer[i].texcoords = (float*)RL_MALLOC(bufferElements * 2 * 4 * sizeof(float)); // 2 float by texcoord, 4 texcoord by quad
+ batch.vertexBuffer[i].normals = (float*)RL_MALLOC(bufferElements * 3 * 4 * sizeof(float)); // 3 float by vertex, 4 vertex by quad
+ batch.vertexBuffer[i].colors = (unsigned char*)RL_MALLOC(bufferElements * 4 * 4 * sizeof(unsigned char)); // 4 float by color, 4 colors by quad
#if defined(GRAPHICS_API_OPENGL_33)
- batch.vertexBuffer[i].indices = (unsigned int *)RL_MALLOC(bufferElements*6*sizeof(unsigned int)); // 6 int by quad (indices)
+ batch.vertexBuffer[i].indices = (unsigned int*)RL_MALLOC(bufferElements * 6 * sizeof(unsigned int)); // 6 int by quad (indices)
#endif
#if defined(GRAPHICS_API_OPENGL_ES2)
- batch.vertexBuffer[i].indices = (unsigned short *)RL_MALLOC(bufferElements*6*sizeof(unsigned short)); // 6 int by quad (indices)
-#endif
-
- for (int j = 0; j < (3*4*bufferElements); j++) batch.vertexBuffer[i].vertices[j] = 0.0f;
- for (int j = 0; j < (2*4*bufferElements); j++) batch.vertexBuffer[i].texcoords[j] = 0.0f;
- for (int j = 0; j < (3*4*bufferElements); j++) batch.vertexBuffer[i].normals[j] = 0.0f;
- for (int j = 0; j < (4*4*bufferElements); j++) batch.vertexBuffer[i].colors[j] = 0;
-
- int k = 0;
-
- // Indices can be initialized right now
- for (int j = 0; j < (6*bufferElements); j += 6)
- {
- batch.vertexBuffer[i].indices[j] = 4*k;
- batch.vertexBuffer[i].indices[j + 1] = 4*k + 1;
- batch.vertexBuffer[i].indices[j + 2] = 4*k + 2;
- batch.vertexBuffer[i].indices[j + 3] = 4*k;
- batch.vertexBuffer[i].indices[j + 4] = 4*k + 2;
- batch.vertexBuffer[i].indices[j + 5] = 4*k + 3;
-
- k++;
- }
-
- RLGL.State.vertexCounter = 0;
- }
-
- TRACELOG(RL_LOG_INFO, "RLGL: Render batch vertex buffers loaded successfully in RAM (CPU)");
- //--------------------------------------------------------------------------------------------
-
- // Upload to GPU (VRAM) vertex data and initialize VAOs/VBOs
- //--------------------------------------------------------------------------------------------
- for (int i = 0; i < numBuffers; i++)
- {
- if (RLGL.ExtSupported.vao)
- {
- // Initialize Quads VAO
- glGenVertexArrays(1, &batch.vertexBuffer[i].vaoId);
- glBindVertexArray(batch.vertexBuffer[i].vaoId);
- }
-
- // Quads - Vertex buffers binding and attributes enable
- // Vertex position buffer (shader-location = 0)
- glGenBuffers(1, &batch.vertexBuffer[i].vboId[0]);
- glBindBuffer(GL_ARRAY_BUFFER, batch.vertexBuffer[i].vboId[0]);
- glBufferData(GL_ARRAY_BUFFER, bufferElements*3*4*sizeof(float), batch.vertexBuffer[i].vertices, GL_DYNAMIC_DRAW);
- glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_POSITION]);
- glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_POSITION], 3, GL_FLOAT, 0, 0, 0);
-
- // Vertex texcoord buffer (shader-location = 1)
- glGenBuffers(1, &batch.vertexBuffer[i].vboId[1]);
- glBindBuffer(GL_ARRAY_BUFFER, batch.vertexBuffer[i].vboId[1]);
- glBufferData(GL_ARRAY_BUFFER, bufferElements*2*4*sizeof(float), batch.vertexBuffer[i].texcoords, GL_DYNAMIC_DRAW);
- glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_TEXCOORD01]);
- glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_TEXCOORD01], 2, GL_FLOAT, 0, 0, 0);
-
- // Vertex normal buffer (shader-location = 2)
- glGenBuffers(1, &batch.vertexBuffer[i].vboId[2]);
- glBindBuffer(GL_ARRAY_BUFFER, batch.vertexBuffer[i].vboId[2]);
- glBufferData(GL_ARRAY_BUFFER, bufferElements*3*4*sizeof(float), batch.vertexBuffer[i].normals, GL_DYNAMIC_DRAW);
- glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_NORMAL]);
- glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_NORMAL], 3, GL_FLOAT, 0, 0, 0);
-
- // Vertex color buffer (shader-location = 3)
- glGenBuffers(1, &batch.vertexBuffer[i].vboId[3]);
- glBindBuffer(GL_ARRAY_BUFFER, batch.vertexBuffer[i].vboId[3]);
- glBufferData(GL_ARRAY_BUFFER, bufferElements*4*4*sizeof(unsigned char), batch.vertexBuffer[i].colors, GL_DYNAMIC_DRAW);
- glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_COLOR]);
- glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_COLOR], 4, GL_UNSIGNED_BYTE, GL_TRUE, 0, 0);
-
- // Fill index buffer
- glGenBuffers(1, &batch.vertexBuffer[i].vboId[4]);
- glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, batch.vertexBuffer[i].vboId[4]);
+ batch.vertexBuffer[i].indices = (unsigned short*)RL_MALLOC(bufferElements * 6 * sizeof(unsigned short)); // 6 int by quad (indices)
+#endif
+
+ for (int j = 0; j < (3 * 4 * bufferElements); j++)
+ batch.vertexBuffer[i].vertices[j] = 0.0f;
+ for (int j = 0; j < (2 * 4 * bufferElements); j++)
+ batch.vertexBuffer[i].texcoords[j] = 0.0f;
+ for (int j = 0; j < (3 * 4 * bufferElements); j++)
+ batch.vertexBuffer[i].normals[j] = 0.0f;
+ for (int j = 0; j < (4 * 4 * bufferElements); j++)
+ batch.vertexBuffer[i].colors[j] = 0;
+
+ int k = 0;
+
+ // Indices can be initialized right now
+ for (int j = 0; j < (6 * bufferElements); j += 6) {
+ batch.vertexBuffer[i].indices[j] = 4 * k;
+ batch.vertexBuffer[i].indices[j + 1] = 4 * k + 1;
+ batch.vertexBuffer[i].indices[j + 2] = 4 * k + 2;
+ batch.vertexBuffer[i].indices[j + 3] = 4 * k;
+ batch.vertexBuffer[i].indices[j + 4] = 4 * k + 2;
+ batch.vertexBuffer[i].indices[j + 5] = 4 * k + 3;
+
+ k++;
+ }
+
+ RLGL.State.vertexCounter = 0;
+ }
+
+ TRACELOG(RL_LOG_INFO, "RLGL: Render batch vertex buffers loaded successfully in RAM (CPU)");
+ //--------------------------------------------------------------------------------------------
+
+ // Upload to GPU (VRAM) vertex data and initialize VAOs/VBOs
+ //--------------------------------------------------------------------------------------------
+ for (int i = 0; i < numBuffers; i++) {
+ if (RLGL.ExtSupported.vao) {
+ // Initialize Quads VAO
+ glGenVertexArrays(1, &batch.vertexBuffer[i].vaoId);
+ glBindVertexArray(batch.vertexBuffer[i].vaoId);
+ }
+
+ // Quads - Vertex buffers binding and attributes enable
+ // Vertex position buffer (shader-location = 0)
+ glGenBuffers(1, &batch.vertexBuffer[i].vboId[0]);
+ glBindBuffer(GL_ARRAY_BUFFER, batch.vertexBuffer[i].vboId[0]);
+ glBufferData(GL_ARRAY_BUFFER, bufferElements * 3 * 4 * sizeof(float), batch.vertexBuffer[i].vertices, GL_DYNAMIC_DRAW);
+ glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_POSITION]);
+ glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_POSITION], 3, GL_FLOAT, 0, 0, 0);
+
+ // Vertex texcoord buffer (shader-location = 1)
+ glGenBuffers(1, &batch.vertexBuffer[i].vboId[1]);
+ glBindBuffer(GL_ARRAY_BUFFER, batch.vertexBuffer[i].vboId[1]);
+ glBufferData(GL_ARRAY_BUFFER, bufferElements * 2 * 4 * sizeof(float), batch.vertexBuffer[i].texcoords, GL_DYNAMIC_DRAW);
+ glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_TEXCOORD01]);
+ glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_TEXCOORD01], 2, GL_FLOAT, 0, 0, 0);
+
+ // Vertex normal buffer (shader-location = 2)
+ glGenBuffers(1, &batch.vertexBuffer[i].vboId[2]);
+ glBindBuffer(GL_ARRAY_BUFFER, batch.vertexBuffer[i].vboId[2]);
+ glBufferData(GL_ARRAY_BUFFER, bufferElements * 3 * 4 * sizeof(float), batch.vertexBuffer[i].normals, GL_DYNAMIC_DRAW);
+ glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_NORMAL]);
+ glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_NORMAL], 3, GL_FLOAT, 0, 0, 0);
+
+ // Vertex color buffer (shader-location = 3)
+ glGenBuffers(1, &batch.vertexBuffer[i].vboId[3]);
+ glBindBuffer(GL_ARRAY_BUFFER, batch.vertexBuffer[i].vboId[3]);
+ glBufferData(GL_ARRAY_BUFFER, bufferElements * 4 * 4 * sizeof(unsigned char), batch.vertexBuffer[i].colors, GL_DYNAMIC_DRAW);
+ glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_COLOR]);
+ glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_COLOR], 4, GL_UNSIGNED_BYTE, GL_TRUE, 0, 0);
+
+ // Fill index buffer
+ glGenBuffers(1, &batch.vertexBuffer[i].vboId[4]);
+ glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, batch.vertexBuffer[i].vboId[4]);
#if defined(GRAPHICS_API_OPENGL_33)
- glBufferData(GL_ELEMENT_ARRAY_BUFFER, bufferElements*6*sizeof(int), batch.vertexBuffer[i].indices, GL_STATIC_DRAW);
+ glBufferData(GL_ELEMENT_ARRAY_BUFFER, bufferElements * 6 * sizeof(int), batch.vertexBuffer[i].indices, GL_STATIC_DRAW);
#endif
#if defined(GRAPHICS_API_OPENGL_ES2)
- glBufferData(GL_ELEMENT_ARRAY_BUFFER, bufferElements*6*sizeof(short), batch.vertexBuffer[i].indices, GL_STATIC_DRAW);
-#endif
- }
-
- TRACELOG(RL_LOG_INFO, "RLGL: Render batch vertex buffers loaded successfully in VRAM (GPU)");
-
- // Unbind the current VAO
- if (RLGL.ExtSupported.vao) glBindVertexArray(0);
- //--------------------------------------------------------------------------------------------
-
- // Init draw calls tracking system
- //--------------------------------------------------------------------------------------------
- batch.draws = (rlDrawCall *)RL_MALLOC(RL_DEFAULT_BATCH_DRAWCALLS*sizeof(rlDrawCall));
-
- for (int i = 0; i < RL_DEFAULT_BATCH_DRAWCALLS; i++)
- {
- batch.draws[i].mode = RL_QUADS;
- batch.draws[i].vertexCount = 0;
- batch.draws[i].vertexAlignment = 0;
- //batch.draws[i].vaoId = 0;
- //batch.draws[i].shaderId = 0;
- batch.draws[i].textureId = RLGL.State.defaultTextureId;
- //batch.draws[i].RLGL.State.projection = rlMatrixIdentity();
- //batch.draws[i].RLGL.State.modelview = rlMatrixIdentity();
- }
-
- batch.bufferCount = numBuffers; // Record buffer count
- batch.drawCounter = 1; // Reset draws counter
- batch.currentDepth = -1.0f; // Reset depth value
- //--------------------------------------------------------------------------------------------
-#endif
-
- return batch;
+ glBufferData(GL_ELEMENT_ARRAY_BUFFER, bufferElements * 6 * sizeof(short), batch.vertexBuffer[i].indices, GL_STATIC_DRAW);
+#endif
+ }
+
+ TRACELOG(RL_LOG_INFO, "RLGL: Render batch vertex buffers loaded successfully in VRAM (GPU)");
+
+ // Unbind the current VAO
+ if (RLGL.ExtSupported.vao)
+ glBindVertexArray(0);
+ //--------------------------------------------------------------------------------------------
+
+ // Init draw calls tracking system
+ //--------------------------------------------------------------------------------------------
+ batch.draws = (rlDrawCall*)RL_MALLOC(RL_DEFAULT_BATCH_DRAWCALLS * sizeof(rlDrawCall));
+
+ for (int i = 0; i < RL_DEFAULT_BATCH_DRAWCALLS; i++) {
+ batch.draws[i].mode = RL_QUADS;
+ batch.draws[i].vertexCount = 0;
+ batch.draws[i].vertexAlignment = 0;
+ // batch.draws[i].vaoId = 0;
+ batch.draws[i].textureId = RLGL.State.defaultTextureId;
+ batch.draws[i].currentBlendMode = RLGL.State.currentBlendMode;
+ batch.draws[i].BlendSrcFactor = RLGL.State.glBlendSrcFactor;
+ batch.draws[i].BlendDstFactor = RLGL.State.glBlendDstFactor;
+ batch.draws[i].BlendEquation = RLGL.State.glBlendEquation;
+ batch.draws[i].BlendSrcFactorRGB = RLGL.State.glBlendSrcFactorRGB;
+ batch.draws[i].BlendDestFactorRGB = RLGL.State.glBlendDestFactorRGB;
+ batch.draws[i].BlendSrcFactorAlpha = RLGL.State.glBlendSrcFactorAlpha;
+ batch.draws[i].BlendDestFactorAlpha = RLGL.State.glBlendDestFactorAlpha;
+ batch.draws[i].BlendEquationRGB = RLGL.State.glBlendEquationRGB;
+ batch.draws[i].BlendEquationAlpha = RLGL.State.glBlendEquationAlpha;
+ // batch.draws[i].RLGL.State.projection = rlMatrixIdentity();
+ // batch.draws[i].RLGL.State.modelview = rlMatrixIdentity();
+ }
+
+ batch.bufferCount = numBuffers; // Record buffer count
+ batch.drawCounter = 1; // Reset draws counter
+ batch.currentDepth = -1.0f; // Reset depth value
+ //--------------------------------------------------------------------------------------------
+#endif
+
+ return batch;
}
// Unload default internal buffers vertex data from CPU and GPU
-void rlUnloadRenderBatch(rlRenderBatch batch)
-{
+void rlUnloadRenderBatch(rlRenderBatch batch) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- // Unbind everything
- glBindBuffer(GL_ARRAY_BUFFER, 0);
- glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0);
-
- // Unload all vertex buffers data
- for (int i = 0; i < batch.bufferCount; i++)
- {
- // Unbind VAO attribs data
- if (RLGL.ExtSupported.vao)
- {
- glBindVertexArray(batch.vertexBuffer[i].vaoId);
- glDisableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION);
- glDisableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD);
- glDisableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL);
- glDisableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_COLOR);
- glBindVertexArray(0);
- }
-
- // Delete VBOs from GPU (VRAM)
- glDeleteBuffers(1, &batch.vertexBuffer[i].vboId[0]);
- glDeleteBuffers(1, &batch.vertexBuffer[i].vboId[1]);
- glDeleteBuffers(1, &batch.vertexBuffer[i].vboId[2]);
- glDeleteBuffers(1, &batch.vertexBuffer[i].vboId[3]);
- glDeleteBuffers(1, &batch.vertexBuffer[i].vboId[4]);
-
- // Delete VAOs from GPU (VRAM)
- if (RLGL.ExtSupported.vao) glDeleteVertexArrays(1, &batch.vertexBuffer[i].vaoId);
-
- // Free vertex arrays memory from CPU (RAM)
- RL_FREE(batch.vertexBuffer[i].vertices);
- RL_FREE(batch.vertexBuffer[i].texcoords);
- RL_FREE(batch.vertexBuffer[i].normals);
- RL_FREE(batch.vertexBuffer[i].colors);
- RL_FREE(batch.vertexBuffer[i].indices);
- }
-
- // Unload arrays
- RL_FREE(batch.vertexBuffer);
- RL_FREE(batch.draws);
+ // Unbind everything
+ glBindBuffer(GL_ARRAY_BUFFER, 0);
+ glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0);
+
+ // Unload all vertex buffers data
+ for (int i = 0; i < batch.bufferCount; i++) {
+ // Unbind VAO attribs data
+ if (RLGL.ExtSupported.vao) {
+ glBindVertexArray(batch.vertexBuffer[i].vaoId);
+ glDisableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION);
+ glDisableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD);
+ glDisableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL);
+ glDisableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_COLOR);
+ glBindVertexArray(0);
+ }
+
+ // Delete VBOs from GPU (VRAM)
+ glDeleteBuffers(1, &batch.vertexBuffer[i].vboId[0]);
+ glDeleteBuffers(1, &batch.vertexBuffer[i].vboId[1]);
+ glDeleteBuffers(1, &batch.vertexBuffer[i].vboId[2]);
+ glDeleteBuffers(1, &batch.vertexBuffer[i].vboId[3]);
+ glDeleteBuffers(1, &batch.vertexBuffer[i].vboId[4]);
+
+ // Delete VAOs from GPU (VRAM)
+ if (RLGL.ExtSupported.vao)
+ glDeleteVertexArrays(1, &batch.vertexBuffer[i].vaoId);
+
+ // Free vertex arrays memory from CPU (RAM)
+ RL_FREE(batch.vertexBuffer[i].vertices);
+ RL_FREE(batch.vertexBuffer[i].texcoords);
+ RL_FREE(batch.vertexBuffer[i].normals);
+ RL_FREE(batch.vertexBuffer[i].colors);
+ RL_FREE(batch.vertexBuffer[i].indices);
+ }
+
+ // Unload arrays
+ RL_FREE(batch.vertexBuffer);
+ RL_FREE(batch.draws);
#endif
}
// Draw render batch
// NOTE: We require a pointer to reset batch and increase current buffer (multi-buffer)
-void rlDrawRenderBatch(rlRenderBatch *batch)
-{
+void rlDrawRenderBatch(rlRenderBatch* batch) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- // Update batch vertex buffers
- //------------------------------------------------------------------------------------------------------------
- // NOTE: If there is not vertex data, buffers doesn't need to be updated (vertexCount > 0)
- // TODO: If no data changed on the CPU arrays --> No need to re-update GPU arrays (use a change detector flag?)
- if (RLGL.State.vertexCounter > 0)
- {
- // Activate elements VAO
- if (RLGL.ExtSupported.vao) glBindVertexArray(batch->vertexBuffer[batch->currentBuffer].vaoId);
-
- // Vertex positions buffer
- glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[0]);
- glBufferSubData(GL_ARRAY_BUFFER, 0, RLGL.State.vertexCounter*3*sizeof(float), batch->vertexBuffer[batch->currentBuffer].vertices);
- //glBufferData(GL_ARRAY_BUFFER, sizeof(float)*3*4*batch->vertexBuffer[batch->currentBuffer].elementCount, batch->vertexBuffer[batch->currentBuffer].vertices, GL_DYNAMIC_DRAW); // Update all buffer
-
- // Texture coordinates buffer
- glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[1]);
- glBufferSubData(GL_ARRAY_BUFFER, 0, RLGL.State.vertexCounter*2*sizeof(float), batch->vertexBuffer[batch->currentBuffer].texcoords);
- //glBufferData(GL_ARRAY_BUFFER, sizeof(float)*2*4*batch->vertexBuffer[batch->currentBuffer].elementCount, batch->vertexBuffer[batch->currentBuffer].texcoords, GL_DYNAMIC_DRAW); // Update all buffer
-
- // Normals buffer
- glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[2]);
- glBufferSubData(GL_ARRAY_BUFFER, 0, RLGL.State.vertexCounter*3*sizeof(float), batch->vertexBuffer[batch->currentBuffer].normals);
- //glBufferData(GL_ARRAY_BUFFER, sizeof(float)*3*4*batch->vertexBuffer[batch->currentBuffer].elementCount, batch->vertexBuffer[batch->currentBuffer].normals, GL_DYNAMIC_DRAW); // Update all buffer
-
- // Colors buffer
- glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[3]);
- glBufferSubData(GL_ARRAY_BUFFER, 0, RLGL.State.vertexCounter*4*sizeof(unsigned char), batch->vertexBuffer[batch->currentBuffer].colors);
- //glBufferData(GL_ARRAY_BUFFER, sizeof(float)*4*4*batch->vertexBuffer[batch->currentBuffer].elementCount, batch->vertexBuffer[batch->currentBuffer].colors, GL_DYNAMIC_DRAW); // Update all buffer
-
- // NOTE: glMapBuffer() causes sync issue
- // If GPU is working with this buffer, glMapBuffer() will wait(stall) until GPU to finish its job
- // To avoid waiting (idle), you can call first glBufferData() with NULL pointer before glMapBuffer()
- // If you do that, the previous data in PBO will be discarded and glMapBuffer() returns a new
- // allocated pointer immediately even if GPU is still working with the previous data
-
- // Another option: map the buffer object into client's memory
- // Probably this code could be moved somewhere else...
- // batch->vertexBuffer[batch->currentBuffer].vertices = (float *)glMapBuffer(GL_ARRAY_BUFFER, GL_READ_WRITE);
- // if (batch->vertexBuffer[batch->currentBuffer].vertices)
- // {
- // Update vertex data
- // }
- // glUnmapBuffer(GL_ARRAY_BUFFER);
-
- // Unbind the current VAO
- if (RLGL.ExtSupported.vao) glBindVertexArray(0);
- }
- //------------------------------------------------------------------------------------------------------------
-
- // Draw batch vertex buffers (considering VR stereo if required)
- //------------------------------------------------------------------------------------------------------------
- RLMatrix matProjection = RLGL.State.projection;
- RLMatrix matModelView = RLGL.State.modelview;
-
- int eyeCount = 1;
- if (RLGL.State.stereoRender) eyeCount = 2;
-
- for (int eye = 0; eye < eyeCount; eye++)
- {
- if (eyeCount == 2)
- {
- // Setup current eye viewport (half screen width)
- rlViewport(eye*RLGL.State.framebufferWidth/2, 0, RLGL.State.framebufferWidth/2, RLGL.State.framebufferHeight);
-
- // Set current eye view offset to modelview matrix
- rlSetMatrixModelview(rlMatrixMultiply(matModelView, RLGL.State.viewOffsetStereo[eye]));
- // Set current eye projection matrix
- rlSetMatrixProjection(RLGL.State.projectionStereo[eye]);
- }
-
- // Draw buffers
- if (RLGL.State.vertexCounter > 0)
- {
- // Set current shader and upload current MVP matrix
- glUseProgram(RLGL.State.currentShaderId);
-
- // Create modelview-projection matrix and upload to shader
- RLMatrix matMVP = rlMatrixMultiply(RLGL.State.modelview, RLGL.State.projection);
- glUniformMatrix4fv(RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_MVP], 1, false, rlMatrixToFloat(matMVP));
-
- if (RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_PROJECTION] != -1)
- {
- glUniformMatrix4fv(RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_PROJECTION], 1, false, rlMatrixToFloat(RLGL.State.projection));
- }
-
- // WARNING: For the following setup of the view, model, and normal matrices, it is expected that
- // transformations and rendering occur between rlPushMatrix() and rlPopMatrix()
-
- if (RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_VIEW] != -1)
- {
- glUniformMatrix4fv(RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_VIEW], 1, false, rlMatrixToFloat(RLGL.State.modelview));
- }
-
- if (RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_MODEL] != -1)
- {
- glUniformMatrix4fv(RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_MODEL], 1, false, rlMatrixToFloat(RLGL.State.transform));
- }
-
- if (RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_NORMAL] != -1)
- {
- glUniformMatrix4fv(RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_NORMAL], 1, false, rlMatrixToFloat(rlMatrixTranspose(rlMatrixInvert(RLGL.State.transform))));
- }
-
- if (RLGL.ExtSupported.vao) glBindVertexArray(batch->vertexBuffer[batch->currentBuffer].vaoId);
- else
- {
- // Bind vertex attrib: position (shader-location = 0)
- glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[0]);
- glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_POSITION], 3, GL_FLOAT, 0, 0, 0);
- glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_POSITION]);
-
- // Bind vertex attrib: texcoord (shader-location = 1)
- glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[1]);
- glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_TEXCOORD01], 2, GL_FLOAT, 0, 0, 0);
- glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_TEXCOORD01]);
-
- // Bind vertex attrib: normal (shader-location = 2)
- glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[2]);
- glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_NORMAL], 3, GL_FLOAT, 0, 0, 0);
- glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_NORMAL]);
-
- // Bind vertex attrib: color (shader-location = 3)
- glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[3]);
- glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_COLOR], 4, GL_UNSIGNED_BYTE, GL_TRUE, 0, 0);
- glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_COLOR]);
-
- glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[4]);
- }
-
- // Setup some default shader values
- glUniform4f(RLGL.State.currentShaderLocs[RL_SHADER_LOC_COLOR_DIFFUSE], 1.0f, 1.0f, 1.0f, 1.0f);
- glUniform1i(RLGL.State.currentShaderLocs[RL_SHADER_LOC_MAP_DIFFUSE], 0); // Active default sampler2D: texture0
-
- // Activate additional sampler textures
- // Those additional textures will be common for all draw calls of the batch
- for (int i = 0; i < RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS; i++)
- {
- if (RLGL.State.activeTextureId[i] > 0)
- {
- glActiveTexture(GL_TEXTURE0 + 1 + i);
- glBindTexture(GL_TEXTURE_2D, RLGL.State.activeTextureId[i]);
- }
- }
-
- // Activate default sampler2D texture0 (one texture is always active for default batch shader)
- // NOTE: Batch system accumulates calls by texture0 changes, additional textures are enabled for all the draw calls
- glActiveTexture(GL_TEXTURE0);
-
- for (int i = 0, vertexOffset = 0; i < batch->drawCounter; i++)
- {
- // Bind current draw call texture, activated as GL_TEXTURE0 and Bound to sampler2D texture0 by default
- glBindTexture(GL_TEXTURE_2D, batch->draws[i].textureId);
-
- if ((batch->draws[i].mode == RL_LINES) || (batch->draws[i].mode == RL_TRIANGLES)) glDrawArrays(batch->draws[i].mode, vertexOffset, batch->draws[i].vertexCount);
- else
- {
- #if defined(GRAPHICS_API_OPENGL_33)
- // We need to define the number of indices to be processed: elementCount*6
- // NOTE: The final parameter tells the GPU the offset in bytes from the
- // start of the index buffer to the location of the first index to process
- glDrawElements(GL_TRIANGLES, batch->draws[i].vertexCount/4*6, GL_UNSIGNED_INT, (GLvoid *)(vertexOffset/4*6*sizeof(GLuint)));
- #endif
- #if defined(GRAPHICS_API_OPENGL_ES2)
- glDrawElements(GL_TRIANGLES, batch->draws[i].vertexCount/4*6, GL_UNSIGNED_SHORT, (GLvoid *)(vertexOffset/4*6*sizeof(GLushort)));
- #endif
- }
-
- vertexOffset += (batch->draws[i].vertexCount + batch->draws[i].vertexAlignment);
- }
-
- if (!RLGL.ExtSupported.vao)
- {
- glBindBuffer(GL_ARRAY_BUFFER, 0);
- glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0);
- }
-
- glBindTexture(GL_TEXTURE_2D, 0); // Unbind textures
- }
-
- if (RLGL.ExtSupported.vao) glBindVertexArray(0); // Unbind VAO
-
- glUseProgram(0); // Unbind shader program
- }
-
- // Restore viewport to default measures
- if (eyeCount == 2) rlViewport(0, 0, RLGL.State.framebufferWidth, RLGL.State.framebufferHeight);
- //------------------------------------------------------------------------------------------------------------
-
- // Reset batch buffers
- //------------------------------------------------------------------------------------------------------------
- // Reset vertex counter for next frame
- RLGL.State.vertexCounter = 0;
-
-
- // Restore projection/modelview matrices
- RLGL.State.projection = matProjection;
- RLGL.State.modelview = matModelView;
-
- // Reset RLGL.currentBatch->draws array
- for (int i = 0; i < RL_DEFAULT_BATCH_DRAWCALLS; i++)
- {
- batch->draws[i].mode = RL_QUADS;
- batch->draws[i].vertexCount = 0;
- batch->draws[i].textureId = RLGL.State.defaultTextureId;
- }
-
- // Reset draws counter to one draw for the batch
- batch->drawCounter = 1;
- //------------------------------------------------------------------------------------------------------------
-
- // Change to next buffer in the list (in case of multi-buffering)
- batch->currentBuffer++;
- if (batch->currentBuffer >= batch->bufferCount) batch->currentBuffer = 0;
+ TRACELOGD("FLUSH");
+ // Update batch vertex buffers
+ //------------------------------------------------------------------------------------------------------------
+ // NOTE: If there is not vertex data, buffers doesn't need to be updated (vertexCount > 0)
+ // TODO: If no data changed on the CPU arrays --> No need to re-update GPU arrays (use a change detector flag?)
+ if (RLGL.State.vertexCounter > 0) {
+ // Activate elements VAO
+ if (RLGL.ExtSupported.vao)
+ glBindVertexArray(batch->vertexBuffer[batch->currentBuffer].vaoId);
+
+ // Vertex positions buffer
+ glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[0]);
+ glBufferSubData(GL_ARRAY_BUFFER, 0, RLGL.State.vertexCounter * 3 * sizeof(float), batch->vertexBuffer[batch->currentBuffer].vertices);
+ // glBufferData(GL_ARRAY_BUFFER, sizeof(float)*3*4*batch->vertexBuffer[batch->currentBuffer].elementCount, batch->vertexBuffer[batch->currentBuffer].vertices, GL_DYNAMIC_DRAW); // Update all buffer
+
+ // Texture coordinates buffer
+ glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[1]);
+ glBufferSubData(GL_ARRAY_BUFFER, 0, RLGL.State.vertexCounter * 2 * sizeof(float), batch->vertexBuffer[batch->currentBuffer].texcoords);
+ // glBufferData(GL_ARRAY_BUFFER, sizeof(float)*2*4*batch->vertexBuffer[batch->currentBuffer].elementCount, batch->vertexBuffer[batch->currentBuffer].texcoords, GL_DYNAMIC_DRAW); // Update all buffer
+
+ // Normals buffer
+ glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[2]);
+ glBufferSubData(GL_ARRAY_BUFFER, 0, RLGL.State.vertexCounter * 3 * sizeof(float), batch->vertexBuffer[batch->currentBuffer].normals);
+ // glBufferData(GL_ARRAY_BUFFER, sizeof(float)*3*4*batch->vertexBuffer[batch->currentBuffer].elementCount, batch->vertexBuffer[batch->currentBuffer].normals, GL_DYNAMIC_DRAW); // Update all buffer
+
+ // Colors buffer
+ glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[3]);
+ glBufferSubData(GL_ARRAY_BUFFER, 0, RLGL.State.vertexCounter * 4 * sizeof(unsigned char), batch->vertexBuffer[batch->currentBuffer].colors);
+ // glBufferData(GL_ARRAY_BUFFER, sizeof(float)*4*4*batch->vertexBuffer[batch->currentBuffer].elementCount, batch->vertexBuffer[batch->currentBuffer].colors, GL_DYNAMIC_DRAW); // Update all buffer
+
+ // NOTE: glMapBuffer() causes sync issue
+ // If GPU is working with this buffer, glMapBuffer() will wait(stall) until GPU to finish its job
+ // To avoid waiting (idle), you can call first glBufferData() with NULL pointer before glMapBuffer()
+ // If you do that, the previous data in PBO will be discarded and glMapBuffer() returns a new
+ // allocated pointer immediately even if GPU is still working with the previous data
+
+ // Another option: map the buffer object into client's memory
+ // Probably this code could be moved somewhere else...
+ // batch->vertexBuffer[batch->currentBuffer].vertices = (float *)glMapBuffer(GL_ARRAY_BUFFER, GL_READ_WRITE);
+ // if (batch->vertexBuffer[batch->currentBuffer].vertices)
+ // {
+ // Update vertex data
+ // }
+ // glUnmapBuffer(GL_ARRAY_BUFFER);
+
+ // Unbind the current VAO
+ if (RLGL.ExtSupported.vao)
+ glBindVertexArray(0);
+ } else { TRACELOGD("NO DATA!"); }
+ //------------------------------------------------------------------------------------------------------------
+
+ // Draw batch vertex buffers (considering VR stereo if required)
+ //------------------------------------------------------------------------------------------------------------
+ RLMatrix matProjection = RLGL.State.projection;
+ RLMatrix matModelView = RLGL.State.modelview;
+
+ int eyeCount = 1;
+ if (RLGL.State.stereoRender)
+ eyeCount = 2;
+
+ for (int eye = 0; eye < eyeCount; eye++) {
+ if (eyeCount == 2) {
+ // Setup current eye viewport (half screen width)
+ rlViewport(eye * RLGL.State.framebufferWidth / 2, 0, RLGL.State.framebufferWidth / 2, RLGL.State.framebufferHeight);
+
+ // Set current eye view offset to modelview matrix
+ rlSetMatrixModelview(rlMatrixMultiply(matModelView, RLGL.State.viewOffsetStereo[eye]));
+ // Set current eye projection matrix
+ rlSetMatrixProjection(RLGL.State.projectionStereo[eye]);
+ }
+
+ // Draw buffers
+ if (RLGL.State.vertexCounter > 0) {
+ // Set current shader and upload current MVP matrix
+ glUseProgram(RLGL.State.currentShaderId);
+
+ // Create modelview-projection matrix and upload to shader
+ RLMatrix matMVP = rlMatrixMultiply(RLGL.State.modelview, RLGL.State.projection);
+ glUniformMatrix4fv(RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_MVP], 1, false, rlMatrixToFloat(matMVP));
+
+ if (RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_PROJECTION] != -1) {
+ glUniformMatrix4fv(RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_PROJECTION], 1, false, rlMatrixToFloat(RLGL.State.projection));
+ }
+
+ // WARNING: For the following setup of the view, model, and normal matrices, it is expected that
+ // transformations and rendering occur between rlPushMatrix() and rlPopMatrix()
+
+ if (RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_VIEW] != -1) {
+ glUniformMatrix4fv(RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_VIEW], 1, false, rlMatrixToFloat(RLGL.State.modelview));
+ }
+
+ if (RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_MODEL] != -1) {
+ glUniformMatrix4fv(RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_MODEL], 1, false, rlMatrixToFloat(RLGL.State.transform));
+ }
+
+ if (RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_NORMAL] != -1) {
+ glUniformMatrix4fv(RLGL.State.currentShaderLocs[RL_SHADER_LOC_MATRIX_NORMAL], 1, false, rlMatrixToFloat(rlMatrixTranspose(rlMatrixInvert(RLGL.State.transform))));
+ }
+
+ if (RLGL.ExtSupported.vao)
+ glBindVertexArray(batch->vertexBuffer[batch->currentBuffer].vaoId);
+ else {
+ // Bind vertex attrib: position (shader-location = 0)
+ glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[0]);
+ glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_POSITION], 3, GL_FLOAT, 0, 0, 0);
+ glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_POSITION]);
+
+ // Bind vertex attrib: texcoord (shader-location = 1)
+ glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[1]);
+ glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_TEXCOORD01], 2, GL_FLOAT, 0, 0, 0);
+ glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_TEXCOORD01]);
+
+ // Bind vertex attrib: normal (shader-location = 2)
+ glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[2]);
+ glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_NORMAL], 3, GL_FLOAT, 0, 0, 0);
+ glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_NORMAL]);
+
+ // Bind vertex attrib: color (shader-location = 3)
+ glBindBuffer(GL_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[3]);
+ glVertexAttribPointer(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_COLOR], 4, GL_UNSIGNED_BYTE, GL_TRUE, 0, 0);
+ glEnableVertexAttribArray(RLGL.State.currentShaderLocs[RL_SHADER_LOC_VERTEX_COLOR]);
+
+ glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, batch->vertexBuffer[batch->currentBuffer].vboId[4]);
+ }
+
+ // Setup some default shader values
+ glUniform1i(RLGL.State.currentShaderLocs[RL_SHADER_LOC_MAP_DIFFUSE], 0); // Active default sampler2D: texture0
+
+ // Activate additional sampler textures
+ // Those additional textures will be common for all draw calls of the batch
+ for (int i = 0; i < RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS; i++) {
+ if (RLGL.State.activeTextureId[i] > 0) {
+ glActiveTexture(GL_TEXTURE0 + 1 + i);
+ glBindTexture(GL_TEXTURE_2D, RLGL.State.activeTextureId[i]);
+ }
+ }
+
+ // Activate default sampler2D texture0 (one texture is always active for default batch shader)
+ // NOTE: Batch system accumulates calls by texture0 changes, additional textures are enabled for all the draw calls
+ glActiveTexture(GL_TEXTURE0);
+
+ for (int i = 0, vertexOffset = 0; i < batch->drawCounter; i++) {
+ // Bind current draw call texture, activated as GL_TEXTURE0 and Bound to sampler2D texture0 by default
+ glBindTexture(GL_TEXTURE_2D, batch->draws[i].textureId);
+
+ if ((batch->draws[i].mode == RL_LINES) || (batch->draws[i].mode == RL_TRIANGLES))
+ glDrawArrays(batch->draws[i].mode, vertexOffset, batch->draws[i].vertexCount);
+ else {
+#if defined(GRAPHICS_API_OPENGL_33)
+ // We need to define the number of indices to be processed: elementCount*6
+ // NOTE: The final parameter tells the GPU the offset in bytes from the
+ // start of the index buffer to the location of the first index to process
+ glDrawElements(GL_TRIANGLES, batch->draws[i].vertexCount / 4 * 6, GL_UNSIGNED_INT, (GLvoid*)(vertexOffset / 4 * 6 * sizeof(GLuint)));
+#endif
+#if defined(GRAPHICS_API_OPENGL_ES2)
+ glDrawElements(GL_TRIANGLES, batch->draws[i].vertexCount / 4 * 6, GL_UNSIGNED_SHORT, (GLvoid*)(vertexOffset / 4 * 6 * sizeof(GLushort)));
+#endif
+ }
+
+ vertexOffset += (batch->draws[i].vertexCount + batch->draws[i].vertexAlignment);
+ }
+
+ if (!RLGL.ExtSupported.vao) {
+ glBindBuffer(GL_ARRAY_BUFFER, 0);
+ glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0);
+ }
+
+ glBindTexture(GL_TEXTURE_2D, 0); // Unbind textures
+ }
+
+ if (RLGL.ExtSupported.vao)
+ glBindVertexArray(0); // Unbind VAO
+
+ }
+
+ // Restore viewport to default measures
+ if (eyeCount == 2)
+ rlViewport(0, 0, RLGL.State.framebufferWidth, RLGL.State.framebufferHeight);
+ //------------------------------------------------------------------------------------------------------------
+
+ // Reset batch buffers
+ //------------------------------------------------------------------------------------------------------------
+ // Reset vertex counter for next frame
+ RLGL.State.vertexCounter = 0;
+
+ // Restore projection/modelview matrices
+ RLGL.State.projection = matProjection;
+ RLGL.State.modelview = matModelView;
+
+ // Reset RLGL.currentBatch->draws array
+ for (int i = 0; i < RL_DEFAULT_BATCH_DRAWCALLS; i++) {
+ batch->draws[i].mode = RL_QUADS;
+ batch->draws[i].vertexCount = 0;
+ batch->draws[i].textureId = RLGL.State.defaultTextureId;
+ }
+
+ // Reset draws counter to one draw for the batch
+ batch->drawCounter = 1;
+ //------------------------------------------------------------------------------------------------------------
+
+ // Change to next buffer in the list (in case of multi-buffering)
+ batch->currentBuffer++;
+ if (batch->currentBuffer >= batch->bufferCount)
+ batch->currentBuffer = 0;
#endif
}
// Set the active render batch for rlgl
-void rlSetRenderBatchActive(rlRenderBatch *batch)
-{
+void rlSetRenderBatchActive(rlRenderBatch* batch) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- rlDrawRenderBatch(RLGL.currentBatch);
+ rlDrawRenderBatch(RLGL.currentBatch);
- if (batch != NULL) RLGL.currentBatch = batch;
- else RLGL.currentBatch = &RLGL.defaultBatch;
+ if (batch != NULL)
+ RLGL.currentBatch = batch;
+ else
+ RLGL.currentBatch = &RLGL.defaultBatch;
#endif
}
// Update and draw internal render batch
-void rlDrawRenderBatchActive(void)
-{
+void rlDrawRenderBatchActive(void) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- rlDrawRenderBatch(RLGL.currentBatch); // NOTE: Stereo rendering is checked inside
+ rlDrawRenderBatch(RLGL.currentBatch); // NOTE: Stereo rendering is checked inside
#endif
}
// Check internal buffer overflow for a given number of vertex
// and force a rlRenderBatch draw call if required
-bool rlCheckRenderBatchLimit(int vCount)
-{
- bool overflow = false;
+bool rlCheckRenderBatchLimit(int vCount) {
+ bool overflow = false;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- if ((RLGL.State.vertexCounter + vCount) >=
- (RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].elementCount*4))
- {
- overflow = true;
+ if ((RLGL.State.vertexCounter + vCount) >=
+ (RLGL.currentBatch->vertexBuffer[RLGL.currentBatch->currentBuffer].elementCount * 4)) {
+ overflow = true;
- // Store current primitive drawing mode and texture id
- int currentMode = RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode;
- int currentTexture = RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].textureId;
+ // Store current primitive drawing mode and texture id
+ int currentMode = RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode;
+ int currentTexture = RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].textureId;
- rlDrawRenderBatch(RLGL.currentBatch); // NOTE: Stereo rendering is checked inside
+ rlDrawRenderBatch(RLGL.currentBatch); // NOTE: Stereo rendering is checked inside
- // Restore state of last batch so we can continue adding vertices
- RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode = currentMode;
- RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].textureId = currentTexture;
- }
+ // Restore state of last batch so we can continue adding vertices
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].mode = currentMode;
+ RLGL.currentBatch->draws[RLGL.currentBatch->drawCounter - 1].textureId = currentTexture;
+ }
#endif
- return overflow;
+ return overflow;
}
// Textures data management
//-----------------------------------------------------------------------------------------
// Convert image data to OpenGL texture (returns OpenGL valid Id)
-unsigned int rlLoadTexture(const void *data, int width, int height, int format, int mipmapCount)
-{
- unsigned int id = 0;
+unsigned int rlLoadTexture(const void* data, int width, int height, int format, int mipmapCount) {
+ unsigned int id = 0;
- glBindTexture(GL_TEXTURE_2D, 0); // Free any old binding
+ glBindTexture(GL_TEXTURE_2D, 0); // Free any old binding
- // Check texture format support by OpenGL 1.1 (compressed textures not supported)
+ // Check texture format support by OpenGL 1.1 (compressed textures not supported)
#if defined(GRAPHICS_API_OPENGL_11)
- if (format >= RL_PIXELFORMAT_COMPRESSED_DXT1_RGB)
- {
- TRACELOG(RL_LOG_WARNING, "GL: OpenGL 1.1 does not support GPU compressed texture formats");
- return id;
- }
+ if (format >= RL_PIXELFORMAT_COMPRESSED_DXT1_RGB) {
+ TRACELOG(RL_LOG_WARNING, "GL: OpenGL 1.1 does not support GPU compressed texture formats");
+ return id;
+ }
#else
- if ((!RLGL.ExtSupported.texCompDXT) && ((format == RL_PIXELFORMAT_COMPRESSED_DXT1_RGB) || (format == RL_PIXELFORMAT_COMPRESSED_DXT1_RGBA) ||
- (format == RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA) || (format == RL_PIXELFORMAT_COMPRESSED_DXT5_RGBA)))
- {
- TRACELOG(RL_LOG_WARNING, "GL: DXT compressed texture format not supported");
- return id;
- }
+ if ((!RLGL.ExtSupported.texCompDXT) && ((format == RL_PIXELFORMAT_COMPRESSED_DXT1_RGB) || (format == RL_PIXELFORMAT_COMPRESSED_DXT1_RGBA) ||
+ (format == RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA) || (format == RL_PIXELFORMAT_COMPRESSED_DXT5_RGBA))) {
+ TRACELOG(RL_LOG_WARNING, "GL: DXT compressed texture format not supported");
+ return id;
+ }
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- if ((!RLGL.ExtSupported.texCompETC1) && (format == RL_PIXELFORMAT_COMPRESSED_ETC1_RGB))
- {
- TRACELOG(RL_LOG_WARNING, "GL: ETC1 compressed texture format not supported");
- return id;
- }
+ if ((!RLGL.ExtSupported.texCompETC1) && (format == RL_PIXELFORMAT_COMPRESSED_ETC1_RGB)) {
+ TRACELOG(RL_LOG_WARNING, "GL: ETC1 compressed texture format not supported");
+ return id;
+ }
- if ((!RLGL.ExtSupported.texCompETC2) && ((format == RL_PIXELFORMAT_COMPRESSED_ETC2_RGB) || (format == RL_PIXELFORMAT_COMPRESSED_ETC2_EAC_RGBA)))
- {
- TRACELOG(RL_LOG_WARNING, "GL: ETC2 compressed texture format not supported");
- return id;
- }
+ if ((!RLGL.ExtSupported.texCompETC2) && ((format == RL_PIXELFORMAT_COMPRESSED_ETC2_RGB) || (format == RL_PIXELFORMAT_COMPRESSED_ETC2_EAC_RGBA))) {
+ TRACELOG(RL_LOG_WARNING, "GL: ETC2 compressed texture format not supported");
+ return id;
+ }
- if ((!RLGL.ExtSupported.texCompPVRT) && ((format == RL_PIXELFORMAT_COMPRESSED_PVRT_RGB) || (format == RL_PIXELFORMAT_COMPRESSED_PVRT_RGBA)))
- {
- TRACELOG(RL_LOG_WARNING, "GL: PVRT compressed texture format not supported");
- return id;
- }
+ if ((!RLGL.ExtSupported.texCompPVRT) && ((format == RL_PIXELFORMAT_COMPRESSED_PVRT_RGB) || (format == RL_PIXELFORMAT_COMPRESSED_PVRT_RGBA))) {
+ TRACELOG(RL_LOG_WARNING, "GL: PVRT compressed texture format not supported");
+ return id;
+ }
- if ((!RLGL.ExtSupported.texCompASTC) && ((format == RL_PIXELFORMAT_COMPRESSED_ASTC_4x4_RGBA) || (format == RL_PIXELFORMAT_COMPRESSED_ASTC_8x8_RGBA)))
- {
- TRACELOG(RL_LOG_WARNING, "GL: ASTC compressed texture format not supported");
- return id;
- }
+ if ((!RLGL.ExtSupported.texCompASTC) && ((format == RL_PIXELFORMAT_COMPRESSED_ASTC_4x4_RGBA) || (format == RL_PIXELFORMAT_COMPRESSED_ASTC_8x8_RGBA))) {
+ TRACELOG(RL_LOG_WARNING, "GL: ASTC compressed texture format not supported");
+ return id;
+ }
#endif
-#endif // GRAPHICS_API_OPENGL_11
+#endif // GRAPHICS_API_OPENGL_11
- //glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
+ // glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
- glGenTextures(1, &id); // Generate texture id
+ glGenTextures(1, &id); // Generate texture id
- glBindTexture(GL_TEXTURE_2D, id);
+ glBindTexture(GL_TEXTURE_2D, id);
- int mipWidth = width;
- int mipHeight = height;
- int mipOffset = 0; // Mipmap data offset, only used for tracelog
+ int mipWidth = width;
+ int mipHeight = height;
+ int mipOffset = 0; // Mipmap data offset, only used for tracelog
- // NOTE: Added pointer math separately from function to avoid UBSAN complaining
- unsigned char *dataPtr = NULL;
- if (data != NULL) dataPtr = (unsigned char *)data;
+ // NOTE: Added pointer math separately from function to avoid UBSAN complaining
+ unsigned char* dataPtr = NULL;
+ if (data != NULL)
+ dataPtr = (unsigned char*)data;
- // Load the different mipmap levels
- for (int i = 0; i < mipmapCount; i++)
- {
- unsigned int mipSize = rlGetPixelDataSize(mipWidth, mipHeight, format);
+ // Load the different mipmap levels
+ for (int i = 0; i < mipmapCount; i++) {
+ unsigned int mipSize = rlGetPixelDataSize(mipWidth, mipHeight, format);
- unsigned int glInternalFormat, glFormat, glType;
- rlGetGlTextureFormats(format, &glInternalFormat, &glFormat, &glType);
+ unsigned int glInternalFormat, glFormat, glType;
+ rlGetGlTextureFormats(format, &glInternalFormat, &glFormat, &glType);
- TRACELOGD("TEXTURE: Load mipmap level %i (%i x %i), size: %i, offset: %i", i, mipWidth, mipHeight, mipSize, mipOffset);
+ TRACELOGD("TEXTURE: Load mipmap level %i (%i x %i), size: %i, offset: %i", i, mipWidth, mipHeight, mipSize, mipOffset);
- if (glInternalFormat != 0)
- {
- if (format < RL_PIXELFORMAT_COMPRESSED_DXT1_RGB) glTexImage2D(GL_TEXTURE_2D, i, glInternalFormat, mipWidth, mipHeight, 0, glFormat, glType, dataPtr);
+ if (glInternalFormat != 0) {
+ if (format < RL_PIXELFORMAT_COMPRESSED_DXT1_RGB)
+ glTexImage2D(GL_TEXTURE_2D, i, glInternalFormat, mipWidth, mipHeight, 0, glFormat, glType, dataPtr);
#if !defined(GRAPHICS_API_OPENGL_11)
- else glCompressedTexImage2D(GL_TEXTURE_2D, i, glInternalFormat, mipWidth, mipHeight, 0, mipSize, dataPtr);
+ else
+ glCompressedTexImage2D(GL_TEXTURE_2D, i, glInternalFormat, mipWidth, mipHeight, 0, mipSize, dataPtr);
#endif
#if defined(GRAPHICS_API_OPENGL_33)
- if (format == RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE)
- {
- GLint swizzleMask[] = { GL_RED, GL_RED, GL_RED, GL_ONE };
- glTexParameteriv(GL_TEXTURE_2D, GL_TEXTURE_SWIZZLE_RGBA, swizzleMask);
- }
- else if (format == RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA)
- {
+ if (format == RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE) {
+ GLint swizzleMask[] = {GL_RED, GL_RED, GL_RED, GL_ONE};
+ glTexParameteriv(GL_TEXTURE_2D, GL_TEXTURE_SWIZZLE_RGBA, swizzleMask);
+ } else if (format == RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA) {
#if defined(GRAPHICS_API_OPENGL_21)
- GLint swizzleMask[] = { GL_RED, GL_RED, GL_RED, GL_ALPHA };
+ GLint swizzleMask[] = {GL_RED, GL_RED, GL_RED, GL_ALPHA};
#elif defined(GRAPHICS_API_OPENGL_33)
- GLint swizzleMask[] = { GL_RED, GL_RED, GL_RED, GL_GREEN };
+ GLint swizzleMask[] = {GL_RED, GL_RED, GL_RED, GL_GREEN};
#endif
- glTexParameteriv(GL_TEXTURE_2D, GL_TEXTURE_SWIZZLE_RGBA, swizzleMask);
- }
+ glTexParameteriv(GL_TEXTURE_2D, GL_TEXTURE_SWIZZLE_RGBA, swizzleMask);
+ }
#endif
- }
+ }
- mipWidth /= 2;
- mipHeight /= 2;
- mipOffset += mipSize; // Increment offset position to next mipmap
- if (data != NULL) dataPtr += mipSize; // Increment data pointer to next mipmap
+ mipWidth /= 2;
+ mipHeight /= 2;
+ mipOffset += mipSize; // Increment offset position to next mipmap
+ if (data != NULL)
+ dataPtr += mipSize; // Increment data pointer to next mipmap
- // Security check for NPOT textures
- if (mipWidth < 1) mipWidth = 1;
- if (mipHeight < 1) mipHeight = 1;
- }
+ // Security check for NPOT textures
+ if (mipWidth < 1)
+ mipWidth = 1;
+ if (mipHeight < 1)
+ mipHeight = 1;
+ }
- // Texture parameters configuration
- // NOTE: glTexParameteri does NOT affect texture uploading, just the way it's used
+ // Texture parameters configuration
+ // NOTE: glTexParameteri does NOT affect texture uploading, just the way it's used
#if defined(GRAPHICS_API_OPENGL_ES2)
- // NOTE: OpenGL ES 2.0 with no GL_OES_texture_npot support (i.e. WebGL) has limited NPOT support, so CLAMP_TO_EDGE must be used
- if (RLGL.ExtSupported.texNPOT)
- {
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); // Set texture to repeat on x-axis
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT); // Set texture to repeat on y-axis
- }
- else
- {
- // NOTE: If using negative texture coordinates (LoadOBJ()), it does not work!
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); // Set texture to clamp on x-axis
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); // Set texture to clamp on y-axis
- }
+ // NOTE: OpenGL ES 2.0 with no GL_OES_texture_npot support (i.e. WebGL) has limited NPOT support, so CLAMP_TO_EDGE must be used
+ if (RLGL.ExtSupported.texNPOT) {
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); // Set texture to repeat on x-axis
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT); // Set texture to repeat on y-axis
+ } else {
+ // NOTE: If using negative texture coordinates (LoadOBJ()), it does not work!
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); // Set texture to clamp on x-axis
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); // Set texture to clamp on y-axis
+ }
#else
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); // Set texture to repeat on x-axis
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT); // Set texture to repeat on y-axis
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); // Set texture to repeat on x-axis
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT); // Set texture to repeat on y-axis
#endif
- // Magnification and minification filters
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST); // Alternative: GL_LINEAR
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST); // Alternative: GL_LINEAR
+ // Magnification and minification filters
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST); // Alternative: GL_LINEAR
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST); // Alternative: GL_LINEAR
#if defined(GRAPHICS_API_OPENGL_33)
- if (mipmapCount > 1)
- {
- // Activate Trilinear filtering if mipmaps are available
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR);
- }
+ if (mipmapCount > 1) {
+ // Activate Trilinear filtering if mipmaps are available
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR);
+ }
#endif
- // At this point we have the texture loaded in GPU and texture parameters configured
+ // At this point we have the texture loaded in GPU and texture parameters configured
- // NOTE: If mipmaps were not in data, they are not generated automatically
+ // NOTE: If mipmaps were not in data, they are not generated automatically
- // Unbind current texture
- glBindTexture(GL_TEXTURE_2D, 0);
+ // Unbind current texture
+ glBindTexture(GL_TEXTURE_2D, 0);
- if (id > 0) TRACELOG(RL_LOG_INFO, "TEXTURE: [ID %i] Texture loaded successfully (%ix%i | %s | %i mipmaps)", id, width, height, rlGetPixelFormatName(format), mipmapCount);
- else TRACELOG(RL_LOG_WARNING, "TEXTURE: Failed to load texture");
+ if (id > 0)
+ TRACELOG(RL_LOG_INFO, "TEXTURE: [ID %i] Texture loaded successfully (%ix%i | %s | %i mipmaps)", id, width, height, rlGetPixelFormatName(format), mipmapCount);
+ else
+ TRACELOG(RL_LOG_WARNING, "TEXTURE: Failed to load texture");
- return id;
+ return id;
}
// Load depth texture/renderbuffer (to be attached to fbo)
// WARNING: OpenGL ES 2.0 requires GL_OES_depth_texture and WebGL requires WEBGL_depth_texture extensions
-unsigned int rlLoadTextureDepth(int width, int height, bool useRenderBuffer)
-{
- unsigned int id = 0;
+unsigned int rlLoadTextureDepth(int width, int height, bool useRenderBuffer) {
+ unsigned int id = 0;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- // In case depth textures not supported, we force renderbuffer usage
- if (!RLGL.ExtSupported.texDepth) useRenderBuffer = true;
+ // In case depth textures not supported, we force renderbuffer usage
+ if (!RLGL.ExtSupported.texDepth)
+ useRenderBuffer = true;
- // NOTE: We let the implementation to choose the best bit-depth
- // Possible formats: GL_DEPTH_COMPONENT16, GL_DEPTH_COMPONENT24, GL_DEPTH_COMPONENT32 and GL_DEPTH_COMPONENT32F
- unsigned int glInternalFormat = GL_DEPTH_COMPONENT;
+ // NOTE: We let the implementation to choose the best bit-depth
+ // Possible formats: GL_DEPTH_COMPONENT16, GL_DEPTH_COMPONENT24, GL_DEPTH_COMPONENT32 and GL_DEPTH_COMPONENT32F
+ unsigned int glInternalFormat = GL_DEPTH_COMPONENT;
#if (defined(GRAPHICS_API_OPENGL_ES2) || defined(GRAPHICS_API_OPENGL_ES3))
- // WARNING: WebGL platform requires unsized internal format definition (GL_DEPTH_COMPONENT)
- // while other platforms using OpenGL ES 2.0 require/support sized internal formats depending on the GPU capabilities
- if (!RLGL.ExtSupported.texDepthWebGL || useRenderBuffer)
- {
- if (RLGL.ExtSupported.maxDepthBits == 32) glInternalFormat = GL_DEPTH_COMPONENT32_OES;
- else if (RLGL.ExtSupported.maxDepthBits == 24) glInternalFormat = GL_DEPTH_COMPONENT24_OES;
- else glInternalFormat = GL_DEPTH_COMPONENT16;
- }
+ // WARNING: WebGL platform requires unsized internal format definition (GL_DEPTH_COMPONENT)
+ // while other platforms using OpenGL ES 2.0 require/support sized internal formats depending on the GPU capabilities
+ if (!RLGL.ExtSupported.texDepthWebGL || useRenderBuffer) {
+ if (RLGL.ExtSupported.maxDepthBits == 32)
+ glInternalFormat = GL_DEPTH_COMPONENT32_OES;
+ else if (RLGL.ExtSupported.maxDepthBits == 24)
+ glInternalFormat = GL_DEPTH_COMPONENT24_OES;
+ else
+ glInternalFormat = GL_DEPTH_COMPONENT16;
+ }
#endif
- if (!useRenderBuffer && RLGL.ExtSupported.texDepth)
- {
- glGenTextures(1, &id);
- glBindTexture(GL_TEXTURE_2D, id);
- glTexImage2D(GL_TEXTURE_2D, 0, glInternalFormat, width, height, 0, GL_DEPTH_COMPONENT, GL_UNSIGNED_INT, NULL);
+ if (!useRenderBuffer && RLGL.ExtSupported.texDepth) {
+ glGenTextures(1, &id);
+ glBindTexture(GL_TEXTURE_2D, id);
+ glTexImage2D(GL_TEXTURE_2D, 0, glInternalFormat, width, height, 0, GL_DEPTH_COMPONENT, GL_UNSIGNED_INT, NULL);
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
- glBindTexture(GL_TEXTURE_2D, 0);
+ glBindTexture(GL_TEXTURE_2D, 0);
- TRACELOG(RL_LOG_INFO, "TEXTURE: Depth texture loaded successfully");
- }
- else
- {
- // Create the renderbuffer that will serve as the depth attachment for the framebuffer
- // NOTE: A renderbuffer is simpler than a texture and could offer better performance on embedded devices
- glGenRenderbuffers(1, &id);
- glBindRenderbuffer(GL_RENDERBUFFER, id);
- glRenderbufferStorage(GL_RENDERBUFFER, glInternalFormat, width, height);
+ TRACELOG(RL_LOG_INFO, "TEXTURE: Depth texture loaded successfully");
+ } else {
+ // Create the renderbuffer that will serve as the depth attachment for the framebuffer
+ // NOTE: A renderbuffer is simpler than a texture and could offer better performance on embedded devices
+ glGenRenderbuffers(1, &id);
+ glBindRenderbuffer(GL_RENDERBUFFER, id);
+ glRenderbufferStorage(GL_RENDERBUFFER, glInternalFormat, width, height);
- glBindRenderbuffer(GL_RENDERBUFFER, 0);
+ glBindRenderbuffer(GL_RENDERBUFFER, 0);
- TRACELOG(RL_LOG_INFO, "TEXTURE: [ID %i] Depth renderbuffer loaded successfully (%i bits)", id, (RLGL.ExtSupported.maxDepthBits >= 24)? RLGL.ExtSupported.maxDepthBits : 16);
- }
+ TRACELOG(RL_LOG_INFO, "TEXTURE: [ID %i] Depth renderbuffer loaded successfully (%i bits)", id, (RLGL.ExtSupported.maxDepthBits >= 24) ? RLGL.ExtSupported.maxDepthBits : 16);
+ }
#endif
- return id;
+ return id;
}
// Load texture cubemap
// NOTE: Cubemap data is expected to be 6 images in a single data array (one after the other),
// expected the following convention: +X, -X, +Y, -Y, +Z, -Z
-unsigned int rlLoadTextureCubemap(const void *data, int size, int format, int mipmapCount)
-{
- unsigned int id = 0;
+unsigned int rlLoadTextureCubemap(const void* data, int size, int format, int mipmapCount) {
+ unsigned int id = 0;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- int mipSize = size;
-
- // NOTE: Added pointer math separately from function to avoid UBSAN complaining
- unsigned char *dataPtr = NULL;
- if (data != NULL) dataPtr = (unsigned char *)data;
-
- unsigned int dataSize = rlGetPixelDataSize(size, size, format);
-
- glGenTextures(1, &id);
- glBindTexture(GL_TEXTURE_CUBE_MAP, id);
-
- unsigned int glInternalFormat, glFormat, glType;
- rlGetGlTextureFormats(format, &glInternalFormat, &glFormat, &glType);
-
- if (glInternalFormat != 0)
- {
- // Load cubemap faces/mipmaps
- for (int i = 0; i < 6*mipmapCount; i++)
- {
- int mipmapLevel = i/6;
- int face = i%6;
-
- if (data == NULL)
- {
- if (format < RL_PIXELFORMAT_COMPRESSED_DXT1_RGB)
- {
- if ((format == RL_PIXELFORMAT_UNCOMPRESSED_R32) ||
- (format == RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32) ||
- (format == RL_PIXELFORMAT_UNCOMPRESSED_R16) ||
- (format == RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16)) TRACELOG(RL_LOG_WARNING, "TEXTURES: Cubemap requested format not supported");
- else glTexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, mipmapLevel, glInternalFormat, mipSize, mipSize, 0, glFormat, glType, NULL);
- }
- else TRACELOG(RL_LOG_WARNING, "TEXTURES: Empty cubemap creation does not support compressed format");
- }
- else
- {
- if (format < RL_PIXELFORMAT_COMPRESSED_DXT1_RGB) glTexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, mipmapLevel, glInternalFormat, mipSize, mipSize, 0, glFormat, glType, (unsigned char *)dataPtr + face*dataSize);
- else glCompressedTexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, mipmapLevel, glInternalFormat, mipSize, mipSize, 0, dataSize, (unsigned char *)dataPtr + face*dataSize);
- }
+ int mipSize = size;
+
+ // NOTE: Added pointer math separately from function to avoid UBSAN complaining
+ unsigned char* dataPtr = NULL;
+ if (data != NULL)
+ dataPtr = (unsigned char*)data;
+
+ unsigned int dataSize = rlGetPixelDataSize(size, size, format);
+
+ glGenTextures(1, &id);
+ glBindTexture(GL_TEXTURE_CUBE_MAP, id);
+
+ unsigned int glInternalFormat, glFormat, glType;
+ rlGetGlTextureFormats(format, &glInternalFormat, &glFormat, &glType);
+
+ if (glInternalFormat != 0) {
+ // Load cubemap faces/mipmaps
+ for (int i = 0; i < 6 * mipmapCount; i++) {
+ int mipmapLevel = i / 6;
+ int face = i % 6;
+
+ if (data == NULL) {
+ if (format < RL_PIXELFORMAT_COMPRESSED_DXT1_RGB) {
+ if ((format == RL_PIXELFORMAT_UNCOMPRESSED_R32) ||
+ (format == RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32) ||
+ (format == RL_PIXELFORMAT_UNCOMPRESSED_R16) ||
+ (format == RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16))
+ TRACELOG(RL_LOG_WARNING, "TEXTURES: Cubemap requested format not supported");
+ else
+ glTexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, mipmapLevel, glInternalFormat, mipSize, mipSize, 0, glFormat, glType, NULL);
+ } else
+ TRACELOG(RL_LOG_WARNING, "TEXTURES: Empty cubemap creation does not support compressed format");
+ } else {
+ if (format < RL_PIXELFORMAT_COMPRESSED_DXT1_RGB)
+ glTexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, mipmapLevel, glInternalFormat, mipSize, mipSize, 0, glFormat, glType, (unsigned char*)dataPtr + face * dataSize);
+ else
+ glCompressedTexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, mipmapLevel, glInternalFormat, mipSize, mipSize, 0, dataSize, (unsigned char*)dataPtr + face * dataSize);
+ }
#if defined(GRAPHICS_API_OPENGL_33)
- if (format == RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE)
- {
- GLint swizzleMask[] = { GL_RED, GL_RED, GL_RED, GL_ONE };
- glTexParameteriv(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_SWIZZLE_RGBA, swizzleMask);
- }
- else if (format == RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA)
- {
+ if (format == RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE) {
+ GLint swizzleMask[] = {GL_RED, GL_RED, GL_RED, GL_ONE};
+ glTexParameteriv(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_SWIZZLE_RGBA, swizzleMask);
+ } else if (format == RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA) {
#if defined(GRAPHICS_API_OPENGL_21)
- GLint swizzleMask[] = { GL_RED, GL_RED, GL_RED, GL_ALPHA };
+ GLint swizzleMask[] = {GL_RED, GL_RED, GL_RED, GL_ALPHA};
#elif defined(GRAPHICS_API_OPENGL_33)
- GLint swizzleMask[] = { GL_RED, GL_RED, GL_RED, GL_GREEN };
-#endif
- glTexParameteriv(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_SWIZZLE_RGBA, swizzleMask);
- }
-#endif
- if (face == 5)
- {
- mipSize /= 2;
- if (data != NULL) dataPtr += dataSize*6; // Increment data pointer to next mipmap
-
- // Security check for NPOT textures
- if (mipSize < 1) mipSize = 1;
-
- dataSize = rlGetPixelDataSize(mipSize, mipSize, format);
- }
- }
- }
-
- // Set cubemap texture sampling parameters
- if (mipmapCount > 1) glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR);
- else glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
-
- glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
- glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
- glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
+ GLint swizzleMask[] = {GL_RED, GL_RED, GL_RED, GL_GREEN};
+#endif
+ glTexParameteriv(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_SWIZZLE_RGBA, swizzleMask);
+ }
+#endif
+ if (face == 5) {
+ mipSize /= 2;
+ if (data != NULL)
+ dataPtr += dataSize * 6; // Increment data pointer to next mipmap
+
+ // Security check for NPOT textures
+ if (mipSize < 1)
+ mipSize = 1;
+
+ dataSize = rlGetPixelDataSize(mipSize, mipSize, format);
+ }
+ }
+ }
+
+ // Set cubemap texture sampling parameters
+ if (mipmapCount > 1)
+ glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR);
+ else
+ glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
+
+ glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
+ glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
+ glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
#if defined(GRAPHICS_API_OPENGL_33)
- glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_WRAP_R, GL_CLAMP_TO_EDGE); // Flag not supported on OpenGL ES 2.0
+ glTexParameteri(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_WRAP_R, GL_CLAMP_TO_EDGE); // Flag not supported on OpenGL ES 2.0
#endif
- glBindTexture(GL_TEXTURE_CUBE_MAP, 0);
+ glBindTexture(GL_TEXTURE_CUBE_MAP, 0);
#endif
- if (id > 0) TRACELOG(RL_LOG_INFO, "TEXTURE: [ID %i] Cubemap texture loaded successfully (%ix%i)", id, size, size);
- else TRACELOG(RL_LOG_WARNING, "TEXTURE: Failed to load cubemap texture");
+ if (id > 0)
+ TRACELOG(RL_LOG_INFO, "TEXTURE: [ID %i] Cubemap texture loaded successfully (%ix%i)", id, size, size);
+ else
+ TRACELOG(RL_LOG_WARNING, "TEXTURE: Failed to load cubemap texture");
- return id;
+ return id;
}
// Update already loaded texture in GPU with new data
// NOTE: We don't know safely if internal texture format is the expected one...
-void rlUpdateTexture(unsigned int id, int offsetX, int offsetY, int width, int height, int format, const void *data)
-{
- glBindTexture(GL_TEXTURE_2D, id);
+void rlUpdateTexture(unsigned int id, int offsetX, int offsetY, int width, int height, int format, const void* data) {
+ glBindTexture(GL_TEXTURE_2D, id);
- unsigned int glInternalFormat, glFormat, glType;
- rlGetGlTextureFormats(format, &glInternalFormat, &glFormat, &glType);
+ unsigned int glInternalFormat, glFormat, glType;
+ rlGetGlTextureFormats(format, &glInternalFormat, &glFormat, &glType);
- if ((glInternalFormat != 0) && (format < RL_PIXELFORMAT_COMPRESSED_DXT1_RGB))
- {
- glTexSubImage2D(GL_TEXTURE_2D, 0, offsetX, offsetY, width, height, glFormat, glType, data);
- }
- else TRACELOG(RL_LOG_WARNING, "TEXTURE: [ID %i] Failed to update for current texture format (%i)", id, format);
+ if ((glInternalFormat != 0) && (format < RL_PIXELFORMAT_COMPRESSED_DXT1_RGB)) {
+ glTexSubImage2D(GL_TEXTURE_2D, 0, offsetX, offsetY, width, height, glFormat, glType, data);
+ } else
+ TRACELOG(RL_LOG_WARNING, "TEXTURE: [ID %i] Failed to update for current texture format (%i)", id, format);
}
// Get OpenGL internal formats and data type from raylib PixelFormat
-void rlGetGlTextureFormats(int format, unsigned int *glInternalFormat, unsigned int *glFormat, unsigned int *glType)
-{
- *glInternalFormat = 0;
- *glFormat = 0;
- *glType = 0;
-
- switch (format)
- {
- #if defined(GRAPHICS_API_OPENGL_11) || defined(GRAPHICS_API_OPENGL_21) || defined(GRAPHICS_API_OPENGL_ES2)
- // NOTE: on OpenGL ES 2.0 (WebGL), internalFormat must match format and options allowed are: GL_LUMINANCE, GL_RGB, GL_RGBA
- case RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE: *glInternalFormat = GL_LUMINANCE; *glFormat = GL_LUMINANCE; *glType = GL_UNSIGNED_BYTE; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA: *glInternalFormat = GL_LUMINANCE_ALPHA; *glFormat = GL_LUMINANCE_ALPHA; *glType = GL_UNSIGNED_BYTE; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R5G6B5: *glInternalFormat = GL_RGB; *glFormat = GL_RGB; *glType = GL_UNSIGNED_SHORT_5_6_5; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8: *glInternalFormat = GL_RGB; *glFormat = GL_RGB; *glType = GL_UNSIGNED_BYTE; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R5G5B5A1: *glInternalFormat = GL_RGBA; *glFormat = GL_RGBA; *glType = GL_UNSIGNED_SHORT_5_5_5_1; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R4G4B4A4: *glInternalFormat = GL_RGBA; *glFormat = GL_RGBA; *glType = GL_UNSIGNED_SHORT_4_4_4_4; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8: *glInternalFormat = GL_RGBA; *glFormat = GL_RGBA; *glType = GL_UNSIGNED_BYTE; break;
- #if !defined(GRAPHICS_API_OPENGL_11)
- #if defined(GRAPHICS_API_OPENGL_ES3)
- case RL_PIXELFORMAT_UNCOMPRESSED_R32: if (RLGL.ExtSupported.texFloat32) *glInternalFormat = GL_R32F_EXT; *glFormat = GL_RED_EXT; *glType = GL_FLOAT; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32: if (RLGL.ExtSupported.texFloat32) *glInternalFormat = GL_RGB32F_EXT; *glFormat = GL_RGB; *glType = GL_FLOAT; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32: if (RLGL.ExtSupported.texFloat32) *glInternalFormat = GL_RGBA32F_EXT; *glFormat = GL_RGBA; *glType = GL_FLOAT; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R16: if (RLGL.ExtSupported.texFloat16) *glInternalFormat = GL_R16F_EXT; *glFormat = GL_RED_EXT; *glType = GL_HALF_FLOAT; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16: if (RLGL.ExtSupported.texFloat16) *glInternalFormat = GL_RGB16F_EXT; *glFormat = GL_RGB; *glType = GL_HALF_FLOAT; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16: if (RLGL.ExtSupported.texFloat16) *glInternalFormat = GL_RGBA16F_EXT; *glFormat = GL_RGBA; *glType = GL_HALF_FLOAT; break;
- #else
- case RL_PIXELFORMAT_UNCOMPRESSED_R32: if (RLGL.ExtSupported.texFloat32) *glInternalFormat = GL_LUMINANCE; *glFormat = GL_LUMINANCE; *glType = GL_FLOAT; break; // NOTE: Requires extension OES_texture_float
- case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32: if (RLGL.ExtSupported.texFloat32) *glInternalFormat = GL_RGB; *glFormat = GL_RGB; *glType = GL_FLOAT; break; // NOTE: Requires extension OES_texture_float
- case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32: if (RLGL.ExtSupported.texFloat32) *glInternalFormat = GL_RGBA; *glFormat = GL_RGBA; *glType = GL_FLOAT; break; // NOTE: Requires extension OES_texture_float
- #if defined(GRAPHICS_API_OPENGL_21)
- case RL_PIXELFORMAT_UNCOMPRESSED_R16: if (RLGL.ExtSupported.texFloat16) *glInternalFormat = GL_LUMINANCE; *glFormat = GL_LUMINANCE; *glType = GL_HALF_FLOAT_ARB; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16: if (RLGL.ExtSupported.texFloat16) *glInternalFormat = GL_RGB; *glFormat = GL_RGB; *glType = GL_HALF_FLOAT_ARB; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16: if (RLGL.ExtSupported.texFloat16) *glInternalFormat = GL_RGBA; *glFormat = GL_RGBA; *glType = GL_HALF_FLOAT_ARB; break;
- #else // defined(GRAPHICS_API_OPENGL_ES2)
- case RL_PIXELFORMAT_UNCOMPRESSED_R16: if (RLGL.ExtSupported.texFloat16) *glInternalFormat = GL_LUMINANCE; *glFormat = GL_LUMINANCE; *glType = GL_HALF_FLOAT_OES; break; // NOTE: Requires extension OES_texture_half_float
- case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16: if (RLGL.ExtSupported.texFloat16) *glInternalFormat = GL_RGB; *glFormat = GL_RGB; *glType = GL_HALF_FLOAT_OES; break; // NOTE: Requires extension OES_texture_half_float
- case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16: if (RLGL.ExtSupported.texFloat16) *glInternalFormat = GL_RGBA; *glFormat = GL_RGBA; *glType = GL_HALF_FLOAT_OES; break; // NOTE: Requires extension OES_texture_half_float
- #endif
- #endif
- #endif
- #elif defined(GRAPHICS_API_OPENGL_33)
- case RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE: *glInternalFormat = GL_R8; *glFormat = GL_RED; *glType = GL_UNSIGNED_BYTE; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA: *glInternalFormat = GL_RG8; *glFormat = GL_RG; *glType = GL_UNSIGNED_BYTE; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R5G6B5: *glInternalFormat = GL_RGB565; *glFormat = GL_RGB; *glType = GL_UNSIGNED_SHORT_5_6_5; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8: *glInternalFormat = GL_RGB8; *glFormat = GL_RGB; *glType = GL_UNSIGNED_BYTE; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R5G5B5A1: *glInternalFormat = GL_RGB5_A1; *glFormat = GL_RGBA; *glType = GL_UNSIGNED_SHORT_5_5_5_1; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R4G4B4A4: *glInternalFormat = GL_RGBA4; *glFormat = GL_RGBA; *glType = GL_UNSIGNED_SHORT_4_4_4_4; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8: *glInternalFormat = GL_RGBA8; *glFormat = GL_RGBA; *glType = GL_UNSIGNED_BYTE; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R32: if (RLGL.ExtSupported.texFloat32) *glInternalFormat = GL_R32F; *glFormat = GL_RED; *glType = GL_FLOAT; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32: if (RLGL.ExtSupported.texFloat32) *glInternalFormat = GL_RGB32F; *glFormat = GL_RGB; *glType = GL_FLOAT; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32: if (RLGL.ExtSupported.texFloat32) *glInternalFormat = GL_RGBA32F; *glFormat = GL_RGBA; *glType = GL_FLOAT; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R16: if (RLGL.ExtSupported.texFloat16) *glInternalFormat = GL_R16F; *glFormat = GL_RED; *glType = GL_HALF_FLOAT; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16: if (RLGL.ExtSupported.texFloat16) *glInternalFormat = GL_RGB16F; *glFormat = GL_RGB; *glType = GL_HALF_FLOAT; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16: if (RLGL.ExtSupported.texFloat16) *glInternalFormat = GL_RGBA16F; *glFormat = GL_RGBA; *glType = GL_HALF_FLOAT; break;
- #endif
- #if !defined(GRAPHICS_API_OPENGL_11)
- case RL_PIXELFORMAT_COMPRESSED_DXT1_RGB: if (RLGL.ExtSupported.texCompDXT) *glInternalFormat = GL_COMPRESSED_RGB_S3TC_DXT1_EXT; break;
- case RL_PIXELFORMAT_COMPRESSED_DXT1_RGBA: if (RLGL.ExtSupported.texCompDXT) *glInternalFormat = GL_COMPRESSED_RGBA_S3TC_DXT1_EXT; break;
- case RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA: if (RLGL.ExtSupported.texCompDXT) *glInternalFormat = GL_COMPRESSED_RGBA_S3TC_DXT3_EXT; break;
- case RL_PIXELFORMAT_COMPRESSED_DXT5_RGBA: if (RLGL.ExtSupported.texCompDXT) *glInternalFormat = GL_COMPRESSED_RGBA_S3TC_DXT5_EXT; break;
- case RL_PIXELFORMAT_COMPRESSED_ETC1_RGB: if (RLGL.ExtSupported.texCompETC1) *glInternalFormat = GL_ETC1_RGB8_OES; break; // NOTE: Requires OpenGL ES 2.0 or OpenGL 4.3
- case RL_PIXELFORMAT_COMPRESSED_ETC2_RGB: if (RLGL.ExtSupported.texCompETC2) *glInternalFormat = GL_COMPRESSED_RGB8_ETC2; break; // NOTE: Requires OpenGL ES 3.0 or OpenGL 4.3
- case RL_PIXELFORMAT_COMPRESSED_ETC2_EAC_RGBA: if (RLGL.ExtSupported.texCompETC2) *glInternalFormat = GL_COMPRESSED_RGBA8_ETC2_EAC; break; // NOTE: Requires OpenGL ES 3.0 or OpenGL 4.3
- case RL_PIXELFORMAT_COMPRESSED_PVRT_RGB: if (RLGL.ExtSupported.texCompPVRT) *glInternalFormat = GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG; break; // NOTE: Requires PowerVR GPU
- case RL_PIXELFORMAT_COMPRESSED_PVRT_RGBA: if (RLGL.ExtSupported.texCompPVRT) *glInternalFormat = GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG; break; // NOTE: Requires PowerVR GPU
- case RL_PIXELFORMAT_COMPRESSED_ASTC_4x4_RGBA: if (RLGL.ExtSupported.texCompASTC) *glInternalFormat = GL_COMPRESSED_RGBA_ASTC_4x4_KHR; break; // NOTE: Requires OpenGL ES 3.1 or OpenGL 4.3
- case RL_PIXELFORMAT_COMPRESSED_ASTC_8x8_RGBA: if (RLGL.ExtSupported.texCompASTC) *glInternalFormat = GL_COMPRESSED_RGBA_ASTC_8x8_KHR; break; // NOTE: Requires OpenGL ES 3.1 or OpenGL 4.3
- #endif
- default: TRACELOG(RL_LOG_WARNING, "TEXTURE: Current format not supported (%i)", format); break;
- }
+void rlGetGlTextureFormats(int format, unsigned int* glInternalFormat, unsigned int* glFormat, unsigned int* glType) {
+ *glInternalFormat = 0;
+ *glFormat = 0;
+ *glType = 0;
+
+ switch (format) {
+#if defined(GRAPHICS_API_OPENGL_11) || defined(GRAPHICS_API_OPENGL_21) || defined(GRAPHICS_API_OPENGL_ES2)
+ // NOTE: on OpenGL ES 2.0 (WebGL), internalFormat must match format and options allowed are: GL_LUMINANCE, GL_RGB, GL_RGBA
+ case RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE:
+ *glInternalFormat = GL_LUMINANCE;
+ *glFormat = GL_LUMINANCE;
+ *glType = GL_UNSIGNED_BYTE;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA:
+ *glInternalFormat = GL_LUMINANCE_ALPHA;
+ *glFormat = GL_LUMINANCE_ALPHA;
+ *glType = GL_UNSIGNED_BYTE;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R5G6B5:
+ *glInternalFormat = GL_RGB;
+ *glFormat = GL_RGB;
+ *glType = GL_UNSIGNED_SHORT_5_6_5;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8:
+ *glInternalFormat = GL_RGB;
+ *glFormat = GL_RGB;
+ *glType = GL_UNSIGNED_BYTE;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R5G5B5A1:
+ *glInternalFormat = GL_RGBA;
+ *glFormat = GL_RGBA;
+ *glType = GL_UNSIGNED_SHORT_5_5_5_1;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R4G4B4A4:
+ *glInternalFormat = GL_RGBA;
+ *glFormat = GL_RGBA;
+ *glType = GL_UNSIGNED_SHORT_4_4_4_4;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8:
+ *glInternalFormat = GL_RGBA;
+ *glFormat = GL_RGBA;
+ *glType = GL_UNSIGNED_BYTE;
+ break;
+#if !defined(GRAPHICS_API_OPENGL_11)
+#if defined(GRAPHICS_API_OPENGL_ES3)
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32:
+ if (RLGL.ExtSupported.texFloat32)
+ *glInternalFormat = GL_R32F_EXT;
+ *glFormat = GL_RED_EXT;
+ *glType = GL_FLOAT;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32:
+ if (RLGL.ExtSupported.texFloat32)
+ *glInternalFormat = GL_RGB32F_EXT;
+ *glFormat = GL_RGB;
+ *glType = GL_FLOAT;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32:
+ if (RLGL.ExtSupported.texFloat32)
+ *glInternalFormat = GL_RGBA32F_EXT;
+ *glFormat = GL_RGBA;
+ *glType = GL_FLOAT;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16:
+ if (RLGL.ExtSupported.texFloat16)
+ *glInternalFormat = GL_R16F_EXT;
+ *glFormat = GL_RED_EXT;
+ *glType = GL_HALF_FLOAT;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16:
+ if (RLGL.ExtSupported.texFloat16)
+ *glInternalFormat = GL_RGB16F_EXT;
+ *glFormat = GL_RGB;
+ *glType = GL_HALF_FLOAT;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16:
+ if (RLGL.ExtSupported.texFloat16)
+ *glInternalFormat = GL_RGBA16F_EXT;
+ *glFormat = GL_RGBA;
+ *glType = GL_HALF_FLOAT;
+ break;
+#else
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32:
+ if (RLGL.ExtSupported.texFloat32)
+ *glInternalFormat = GL_LUMINANCE;
+ *glFormat = GL_LUMINANCE;
+ *glType = GL_FLOAT;
+ break; // NOTE: Requires extension OES_texture_float
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32:
+ if (RLGL.ExtSupported.texFloat32)
+ *glInternalFormat = GL_RGB;
+ *glFormat = GL_RGB;
+ *glType = GL_FLOAT;
+ break; // NOTE: Requires extension OES_texture_float
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32:
+ if (RLGL.ExtSupported.texFloat32)
+ *glInternalFormat = GL_RGBA;
+ *glFormat = GL_RGBA;
+ *glType = GL_FLOAT;
+ break; // NOTE: Requires extension OES_texture_float
+#if defined(GRAPHICS_API_OPENGL_21)
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16:
+ if (RLGL.ExtSupported.texFloat16)
+ *glInternalFormat = GL_LUMINANCE;
+ *glFormat = GL_LUMINANCE;
+ *glType = GL_HALF_FLOAT_ARB;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16:
+ if (RLGL.ExtSupported.texFloat16)
+ *glInternalFormat = GL_RGB;
+ *glFormat = GL_RGB;
+ *glType = GL_HALF_FLOAT_ARB;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16:
+ if (RLGL.ExtSupported.texFloat16)
+ *glInternalFormat = GL_RGBA;
+ *glFormat = GL_RGBA;
+ *glType = GL_HALF_FLOAT_ARB;
+ break;
+#else // defined(GRAPHICS_API_OPENGL_ES2)
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16:
+ if (RLGL.ExtSupported.texFloat16)
+ *glInternalFormat = GL_LUMINANCE;
+ *glFormat = GL_LUMINANCE;
+ *glType = GL_HALF_FLOAT_OES;
+ break; // NOTE: Requires extension OES_texture_half_float
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16:
+ if (RLGL.ExtSupported.texFloat16)
+ *glInternalFormat = GL_RGB;
+ *glFormat = GL_RGB;
+ *glType = GL_HALF_FLOAT_OES;
+ break; // NOTE: Requires extension OES_texture_half_float
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16:
+ if (RLGL.ExtSupported.texFloat16)
+ *glInternalFormat = GL_RGBA;
+ *glFormat = GL_RGBA;
+ *glType = GL_HALF_FLOAT_OES;
+ break; // NOTE: Requires extension OES_texture_half_float
+#endif
+#endif
+#endif
+#elif defined(GRAPHICS_API_OPENGL_33)
+ case RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE:
+ *glInternalFormat = GL_R8;
+ *glFormat = GL_RED;
+ *glType = GL_UNSIGNED_BYTE;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA:
+ *glInternalFormat = GL_RG8;
+ *glFormat = GL_RG;
+ *glType = GL_UNSIGNED_BYTE;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R5G6B5:
+ *glInternalFormat = GL_RGB565;
+ *glFormat = GL_RGB;
+ *glType = GL_UNSIGNED_SHORT_5_6_5;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8:
+ *glInternalFormat = GL_RGB8;
+ *glFormat = GL_RGB;
+ *glType = GL_UNSIGNED_BYTE;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R5G5B5A1:
+ *glInternalFormat = GL_RGB5_A1;
+ *glFormat = GL_RGBA;
+ *glType = GL_UNSIGNED_SHORT_5_5_5_1;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R4G4B4A4:
+ *glInternalFormat = GL_RGBA4;
+ *glFormat = GL_RGBA;
+ *glType = GL_UNSIGNED_SHORT_4_4_4_4;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8:
+ *glInternalFormat = GL_RGBA8;
+ *glFormat = GL_RGBA;
+ *glType = GL_UNSIGNED_BYTE;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32:
+ if (RLGL.ExtSupported.texFloat32)
+ *glInternalFormat = GL_R32F;
+ *glFormat = GL_RED;
+ *glType = GL_FLOAT;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32:
+ if (RLGL.ExtSupported.texFloat32)
+ *glInternalFormat = GL_RGB32F;
+ *glFormat = GL_RGB;
+ *glType = GL_FLOAT;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32:
+ if (RLGL.ExtSupported.texFloat32)
+ *glInternalFormat = GL_RGBA32F;
+ *glFormat = GL_RGBA;
+ *glType = GL_FLOAT;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16:
+ if (RLGL.ExtSupported.texFloat16)
+ *glInternalFormat = GL_R16F;
+ *glFormat = GL_RED;
+ *glType = GL_HALF_FLOAT;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16:
+ if (RLGL.ExtSupported.texFloat16)
+ *glInternalFormat = GL_RGB16F;
+ *glFormat = GL_RGB;
+ *glType = GL_HALF_FLOAT;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16:
+ if (RLGL.ExtSupported.texFloat16)
+ *glInternalFormat = GL_RGBA16F;
+ *glFormat = GL_RGBA;
+ *glType = GL_HALF_FLOAT;
+ break;
+#endif
+#if !defined(GRAPHICS_API_OPENGL_11)
+ case RL_PIXELFORMAT_COMPRESSED_DXT1_RGB:
+ if (RLGL.ExtSupported.texCompDXT)
+ *glInternalFormat = GL_COMPRESSED_RGB_S3TC_DXT1_EXT;
+ break;
+ case RL_PIXELFORMAT_COMPRESSED_DXT1_RGBA:
+ if (RLGL.ExtSupported.texCompDXT)
+ *glInternalFormat = GL_COMPRESSED_RGBA_S3TC_DXT1_EXT;
+ break;
+ case RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA:
+ if (RLGL.ExtSupported.texCompDXT)
+ *glInternalFormat = GL_COMPRESSED_RGBA_S3TC_DXT3_EXT;
+ break;
+ case RL_PIXELFORMAT_COMPRESSED_DXT5_RGBA:
+ if (RLGL.ExtSupported.texCompDXT)
+ *glInternalFormat = GL_COMPRESSED_RGBA_S3TC_DXT5_EXT;
+ break;
+ case RL_PIXELFORMAT_COMPRESSED_ETC1_RGB:
+ if (RLGL.ExtSupported.texCompETC1)
+ *glInternalFormat = GL_ETC1_RGB8_OES;
+ break; // NOTE: Requires OpenGL ES 2.0 or OpenGL 4.3
+ case RL_PIXELFORMAT_COMPRESSED_ETC2_RGB:
+ if (RLGL.ExtSupported.texCompETC2)
+ *glInternalFormat = GL_COMPRESSED_RGB8_ETC2;
+ break; // NOTE: Requires OpenGL ES 3.0 or OpenGL 4.3
+ case RL_PIXELFORMAT_COMPRESSED_ETC2_EAC_RGBA:
+ if (RLGL.ExtSupported.texCompETC2)
+ *glInternalFormat = GL_COMPRESSED_RGBA8_ETC2_EAC;
+ break; // NOTE: Requires OpenGL ES 3.0 or OpenGL 4.3
+ case RL_PIXELFORMAT_COMPRESSED_PVRT_RGB:
+ if (RLGL.ExtSupported.texCompPVRT)
+ *glInternalFormat = GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG;
+ break; // NOTE: Requires PowerVR GPU
+ case RL_PIXELFORMAT_COMPRESSED_PVRT_RGBA:
+ if (RLGL.ExtSupported.texCompPVRT)
+ *glInternalFormat = GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG;
+ break; // NOTE: Requires PowerVR GPU
+ case RL_PIXELFORMAT_COMPRESSED_ASTC_4x4_RGBA:
+ if (RLGL.ExtSupported.texCompASTC)
+ *glInternalFormat = GL_COMPRESSED_RGBA_ASTC_4x4_KHR;
+ break; // NOTE: Requires OpenGL ES 3.1 or OpenGL 4.3
+ case RL_PIXELFORMAT_COMPRESSED_ASTC_8x8_RGBA:
+ if (RLGL.ExtSupported.texCompASTC)
+ *glInternalFormat = GL_COMPRESSED_RGBA_ASTC_8x8_KHR;
+ break; // NOTE: Requires OpenGL ES 3.1 or OpenGL 4.3
+#endif
+ default:
+ TRACELOG(RL_LOG_WARNING, "TEXTURE: Current format not supported (%i)", format);
+ break;
+ }
}
// Unload texture from GPU memory
-void rlUnloadTexture(unsigned int id)
-{
- glDeleteTextures(1, &id);
+void rlUnloadTexture(unsigned int id) {
+ glDeleteTextures(1, &id);
}
// Generate mipmap data for selected texture
// NOTE: Only supports GPU mipmap generation
-void rlGenTextureMipmaps(unsigned int id, int width, int height, int format, int *mipmaps)
-{
+void rlGenTextureMipmaps(unsigned int id, int width, int height, int format, int* mipmaps) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glBindTexture(GL_TEXTURE_2D, id);
+ glBindTexture(GL_TEXTURE_2D, id);
- // Check if texture is power-of-two (POT)
- bool texIsPOT = false;
+ // Check if texture is power-of-two (POT)
+ bool texIsPOT = false;
- if (((width > 0) && ((width & (width - 1)) == 0)) &&
- ((height > 0) && ((height & (height - 1)) == 0))) texIsPOT = true;
+ if (((width > 0) && ((width & (width - 1)) == 0)) &&
+ ((height > 0) && ((height & (height - 1)) == 0)))
+ texIsPOT = true;
- if ((texIsPOT) || (RLGL.ExtSupported.texNPOT))
- {
- //glHint(GL_GENERATE_MIPMAP_HINT, GL_DONT_CARE); // Hint for mipmaps generation algorithm: GL_FASTEST, GL_NICEST, GL_DONT_CARE
- glGenerateMipmap(GL_TEXTURE_2D); // Generate mipmaps automatically
+ if ((texIsPOT) || (RLGL.ExtSupported.texNPOT)) {
+ // glHint(GL_GENERATE_MIPMAP_HINT, GL_DONT_CARE); // Hint for mipmaps generation algorithm: GL_FASTEST, GL_NICEST, GL_DONT_CARE
+ glGenerateMipmap(GL_TEXTURE_2D); // Generate mipmaps automatically
- #define MIN(a,b) (((a)<(b))? (a):(b))
- #define MAX(a,b) (((a)>(b))? (a):(b))
+#define MIN(a, b) (((a) < (b)) ? (a) : (b))
+#define MAX(a, b) (((a) > (b)) ? (a) : (b))
- *mipmaps = 1 + (int)floor(log(MAX(width, height))/log(2));
- TRACELOG(RL_LOG_INFO, "TEXTURE: [ID %i] Mipmaps generated automatically, total: %i", id, *mipmaps);
- }
- else TRACELOG(RL_LOG_WARNING, "TEXTURE: [ID %i] Failed to generate mipmaps", id);
+ *mipmaps = 1 + (int)floor(log(MAX(width, height)) / log(2));
+ TRACELOG(RL_LOG_INFO, "TEXTURE: [ID %i] Mipmaps generated automatically, total: %i", id, *mipmaps);
+ } else
+ TRACELOG(RL_LOG_WARNING, "TEXTURE: [ID %i] Failed to generate mipmaps", id);
- glBindTexture(GL_TEXTURE_2D, 0);
+ glBindTexture(GL_TEXTURE_2D, 0);
#else
- TRACELOG(RL_LOG_WARNING, "TEXTURE: [ID %i] GPU mipmap generation not supported", id);
+ TRACELOG(RL_LOG_WARNING, "TEXTURE: [ID %i] GPU mipmap generation not supported", id);
#endif
}
// Read texture pixel data
-void *rlReadTexturePixels(unsigned int id, int width, int height, int format)
-{
- void *pixels = NULL;
+void* rlReadTexturePixels(unsigned int id, int width, int height, int format) {
+ void* pixels = NULL;
#if defined(GRAPHICS_API_OPENGL_11) || defined(GRAPHICS_API_OPENGL_33)
- glBindTexture(GL_TEXTURE_2D, id);
+ glBindTexture(GL_TEXTURE_2D, id);
- // NOTE: Using texture id, we can retrieve some texture info (but not on OpenGL ES 2.0)
- // Possible texture info: GL_TEXTURE_RED_SIZE, GL_TEXTURE_GREEN_SIZE, GL_TEXTURE_BLUE_SIZE, GL_TEXTURE_ALPHA_SIZE
- //int width, height, format;
- //glGetTexLevelParameteriv(GL_TEXTURE_2D, 0, GL_TEXTURE_WIDTH, &width);
- //glGetTexLevelParameteriv(GL_TEXTURE_2D, 0, GL_TEXTURE_HEIGHT, &height);
- //glGetTexLevelParameteriv(GL_TEXTURE_2D, 0, GL_TEXTURE_INTERNAL_FORMAT, &format);
+ // NOTE: Using texture id, we can retrieve some texture info (but not on OpenGL ES 2.0)
+ // Possible texture info: GL_TEXTURE_RED_SIZE, GL_TEXTURE_GREEN_SIZE, GL_TEXTURE_BLUE_SIZE, GL_TEXTURE_ALPHA_SIZE
+ // int width, height, format;
+ // glGetTexLevelParameteriv(GL_TEXTURE_2D, 0, GL_TEXTURE_WIDTH, &width);
+ // glGetTexLevelParameteriv(GL_TEXTURE_2D, 0, GL_TEXTURE_HEIGHT, &height);
+ // glGetTexLevelParameteriv(GL_TEXTURE_2D, 0, GL_TEXTURE_INTERNAL_FORMAT, &format);
- // NOTE: Each row written to or read from by OpenGL pixel operations like glGetTexImage are aligned to a 4 byte boundary by default, which may add some padding
- // Use glPixelStorei to modify padding with the GL_[UN]PACK_ALIGNMENT setting
- // GL_PACK_ALIGNMENT affects operations that read from OpenGL memory (glReadPixels, glGetTexImage, etc.)
- // GL_UNPACK_ALIGNMENT affects operations that write to OpenGL memory (glTexImage, etc.)
- glPixelStorei(GL_PACK_ALIGNMENT, 1);
+ // NOTE: Each row written to or read from by OpenGL pixel operations like glGetTexImage are aligned to a 4 byte boundary by default, which may add some padding
+ // Use glPixelStorei to modify padding with the GL_[UN]PACK_ALIGNMENT setting
+ // GL_PACK_ALIGNMENT affects operations that read from OpenGL memory (glReadPixels, glGetTexImage, etc.)
+ // GL_UNPACK_ALIGNMENT affects operations that write to OpenGL memory (glTexImage, etc.)
+ glPixelStorei(GL_PACK_ALIGNMENT, 1);
- unsigned int glInternalFormat, glFormat, glType;
- rlGetGlTextureFormats(format, &glInternalFormat, &glFormat, &glType);
- unsigned int size = rlGetPixelDataSize(width, height, format);
+ unsigned int glInternalFormat, glFormat, glType;
+ rlGetGlTextureFormats(format, &glInternalFormat, &glFormat, &glType);
+ unsigned int size = rlGetPixelDataSize(width, height, format);
- if ((glInternalFormat != 0) && (format < RL_PIXELFORMAT_COMPRESSED_DXT1_RGB))
- {
- pixels = RL_MALLOC(size);
- glGetTexImage(GL_TEXTURE_2D, 0, glFormat, glType, pixels);
- }
- else TRACELOG(RL_LOG_WARNING, "TEXTURE: [ID %i] Data retrieval not suported for pixel format (%i)", id, format);
+ if ((glInternalFormat != 0) && (format < RL_PIXELFORMAT_COMPRESSED_DXT1_RGB)) {
+ pixels = RL_MALLOC(size);
+ glGetTexImage(GL_TEXTURE_2D, 0, glFormat, glType, pixels);
+ } else
+ TRACELOG(RL_LOG_WARNING, "TEXTURE: [ID %i] Data retrieval not suported for pixel format (%i)", id, format);
- glBindTexture(GL_TEXTURE_2D, 0);
+ glBindTexture(GL_TEXTURE_2D, 0);
#endif
#if defined(GRAPHICS_API_OPENGL_ES2)
- // glGetTexImage() is not available on OpenGL ES 2.0
- // Texture width and height are required on OpenGL ES 2.0, there is no way to get it from texture id
- // Two possible Options:
- // 1 - Bind texture to color fbo attachment and glReadPixels()
- // 2 - Create an fbo, activate it, render quad with texture, glReadPixels()
- // We are using Option 1, just need to care for texture format on retrieval
- // NOTE: This behaviour could be conditioned by graphic driver...
- unsigned int fboId = rlLoadFramebuffer();
+ // glGetTexImage() is not available on OpenGL ES 2.0
+ // Texture width and height are required on OpenGL ES 2.0, there is no way to get it from texture id
+ // Two possible Options:
+ // 1 - Bind texture to color fbo attachment and glReadPixels()
+ // 2 - Create an fbo, activate it, render quad with texture, glReadPixels()
+ // We are using Option 1, just need to care for texture format on retrieval
+ // NOTE: This behaviour could be conditioned by graphic driver...
+ unsigned int fboId = rlLoadFramebuffer();
- glBindFramebuffer(GL_FRAMEBUFFER, fboId);
- glBindTexture(GL_TEXTURE_2D, 0);
+ glBindFramebuffer(GL_FRAMEBUFFER, fboId);
+ glBindTexture(GL_TEXTURE_2D, 0);
- // Attach our texture to FBO
- glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, id, 0);
+ // Attach our texture to FBO
+ glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, id, 0);
- // We read data as RGBA because FBO texture is configured as RGBA, despite binding another texture format
- pixels = (unsigned char *)RL_MALLOC(rlGetPixelDataSize(width, height, RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8));
- glReadPixels(0, 0, width, height, GL_RGBA, GL_UNSIGNED_BYTE, pixels);
+ // We read data as RGBA because FBO texture is configured as RGBA, despite binding another texture format
+ pixels = (unsigned char*)RL_MALLOC(rlGetPixelDataSize(width, height, RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8));
+ glReadPixels(0, 0, width, height, GL_RGBA, GL_UNSIGNED_BYTE, pixels);
- glBindFramebuffer(GL_FRAMEBUFFER, 0);
+ glBindFramebuffer(GL_FRAMEBUFFER, 0);
- // Clean up temporal fbo
- rlUnloadFramebuffer(fboId);
+ // Clean up temporal fbo
+ rlUnloadFramebuffer(fboId);
#endif
- return pixels;
+ return pixels;
}
// Read screen pixel data (color buffer)
-unsigned char *rlReadScreenPixels(int width, int height)
-{
- unsigned char *screenData = (unsigned char *)RL_CALLOC(width*height*4, sizeof(unsigned char));
+unsigned char* rlReadScreenPixels(int width, int height) {
+ unsigned char* screenData = (unsigned char*)RL_CALLOC(width * height * 4, sizeof(unsigned char));
- // NOTE 1: glReadPixels returns image flipped vertically -> (0,0) is the bottom left corner of the framebuffer
- // NOTE 2: We are getting alpha channel! Be careful, it can be transparent if not cleared properly!
- glReadPixels(0, 0, width, height, GL_RGBA, GL_UNSIGNED_BYTE, screenData);
+ // NOTE 1: glReadPixels returns image flipped vertically -> (0,0) is the bottom left corner of the framebuffer
+ // NOTE 2: We are getting alpha channel! Be careful, it can be transparent if not cleared properly!
+ glReadPixels(0, 0, width, height, GL_RGBA, GL_UNSIGNED_BYTE, screenData);
- // Flip image vertically!
- unsigned char *imgData = (unsigned char *)RL_MALLOC(width*height*4*sizeof(unsigned char));
+ // Flip image vertically!
+ unsigned char* imgData = (unsigned char*)RL_MALLOC(width * height * 4 * sizeof(unsigned char));
- for (int y = height - 1; y >= 0; y--)
- {
- for (int x = 0; x < (width*4); x++)
- {
- imgData[((height - 1) - y)*width*4 + x] = screenData[(y*width*4) + x]; // Flip line
+ for (int y = height - 1; y >= 0; y--) {
+ for (int x = 0; x < (width * 4); x++) {
+ imgData[((height - 1) - y) * width * 4 + x] = screenData[(y * width * 4) + x]; // Flip line
- // Set alpha component value to 255 (no trasparent image retrieval)
- // NOTE: Alpha value has already been applied to RGB in framebuffer, we don't need it!
- if (((x + 1)%4) == 0) imgData[((height - 1) - y)*width*4 + x] = 255;
- }
- }
+ // Set alpha component value to 255 (no trasparent image retrieval)
+ // NOTE: Alpha value has already been applied to RGB in framebuffer, we don't need it!
+ if (((x + 1) % 4) == 0)
+ imgData[((height - 1) - y) * width * 4 + x] = 255;
+ }
+ }
- RL_FREE(screenData);
+ RL_FREE(screenData);
- return imgData; // NOTE: image data should be freed
+ return imgData; // NOTE: image data should be freed
}
// Framebuffer management (fbo)
//-----------------------------------------------------------------------------------------
// Load a framebuffer to be used for rendering
// NOTE: No textures attached
-unsigned int rlLoadFramebuffer(void)
-{
- unsigned int fboId = 0;
+unsigned int rlLoadFramebuffer(void) {
+ unsigned int fboId = 0;
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)) && defined(RLGL_RENDER_TEXTURES_HINT)
- glGenFramebuffers(1, &fboId); // Create the framebuffer object
- glBindFramebuffer(GL_FRAMEBUFFER, 0); // Unbind any framebuffer
+ glGenFramebuffers(1, &fboId); // Create the framebuffer object
+ glBindFramebuffer(GL_FRAMEBUFFER, 0); // Unbind any framebuffer
#endif
- return fboId;
+ return fboId;
}
// Attach color buffer texture to an fbo (unloads previous attachment)
// NOTE: Attach type: 0-Color, 1-Depth renderbuffer, 2-Depth texture
-void rlFramebufferAttach(unsigned int fboId, unsigned int texId, int attachType, int texType, int mipLevel)
-{
+void rlFramebufferAttach(unsigned int fboId, unsigned int texId, int attachType, int texType, int mipLevel) {
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)) && defined(RLGL_RENDER_TEXTURES_HINT)
- glBindFramebuffer(GL_FRAMEBUFFER, fboId);
-
- switch (attachType)
- {
- case RL_ATTACHMENT_COLOR_CHANNEL0:
- case RL_ATTACHMENT_COLOR_CHANNEL1:
- case RL_ATTACHMENT_COLOR_CHANNEL2:
- case RL_ATTACHMENT_COLOR_CHANNEL3:
- case RL_ATTACHMENT_COLOR_CHANNEL4:
- case RL_ATTACHMENT_COLOR_CHANNEL5:
- case RL_ATTACHMENT_COLOR_CHANNEL6:
- case RL_ATTACHMENT_COLOR_CHANNEL7:
- {
- if (texType == RL_ATTACHMENT_TEXTURE2D) glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0 + attachType, GL_TEXTURE_2D, texId, mipLevel);
- else if (texType == RL_ATTACHMENT_RENDERBUFFER) glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0 + attachType, GL_RENDERBUFFER, texId);
- else if (texType >= RL_ATTACHMENT_CUBEMAP_POSITIVE_X) glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0 + attachType, GL_TEXTURE_CUBE_MAP_POSITIVE_X + texType, texId, mipLevel);
-
- } break;
- case RL_ATTACHMENT_DEPTH:
- {
- if (texType == RL_ATTACHMENT_TEXTURE2D) glFramebufferTexture2D(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_TEXTURE_2D, texId, mipLevel);
- else if (texType == RL_ATTACHMENT_RENDERBUFFER) glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_RENDERBUFFER, texId);
-
- } break;
- case RL_ATTACHMENT_STENCIL:
- {
- if (texType == RL_ATTACHMENT_TEXTURE2D) glFramebufferTexture2D(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT, GL_TEXTURE_2D, texId, mipLevel);
- else if (texType == RL_ATTACHMENT_RENDERBUFFER) glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT, GL_RENDERBUFFER, texId);
-
- } break;
- default: break;
- }
-
- glBindFramebuffer(GL_FRAMEBUFFER, 0);
+ glBindFramebuffer(GL_FRAMEBUFFER, fboId);
+
+ switch (attachType) {
+ case RL_ATTACHMENT_COLOR_CHANNEL0:
+ case RL_ATTACHMENT_COLOR_CHANNEL1:
+ case RL_ATTACHMENT_COLOR_CHANNEL2:
+ case RL_ATTACHMENT_COLOR_CHANNEL3:
+ case RL_ATTACHMENT_COLOR_CHANNEL4:
+ case RL_ATTACHMENT_COLOR_CHANNEL5:
+ case RL_ATTACHMENT_COLOR_CHANNEL6:
+ case RL_ATTACHMENT_COLOR_CHANNEL7: {
+ if (texType == RL_ATTACHMENT_TEXTURE2D)
+ glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0 + attachType, GL_TEXTURE_2D, texId, mipLevel);
+ else if (texType == RL_ATTACHMENT_RENDERBUFFER)
+ glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0 + attachType, GL_RENDERBUFFER, texId);
+ else if (texType >= RL_ATTACHMENT_CUBEMAP_POSITIVE_X)
+ glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0 + attachType, GL_TEXTURE_CUBE_MAP_POSITIVE_X + texType, texId, mipLevel);
+
+ } break;
+ case RL_ATTACHMENT_DEPTH: {
+ if (texType == RL_ATTACHMENT_TEXTURE2D)
+ glFramebufferTexture2D(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_TEXTURE_2D, texId, mipLevel);
+ else if (texType == RL_ATTACHMENT_RENDERBUFFER)
+ glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_RENDERBUFFER, texId);
+
+ } break;
+ case RL_ATTACHMENT_STENCIL: {
+ if (texType == RL_ATTACHMENT_TEXTURE2D)
+ glFramebufferTexture2D(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT, GL_TEXTURE_2D, texId, mipLevel);
+ else if (texType == RL_ATTACHMENT_RENDERBUFFER)
+ glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT, GL_RENDERBUFFER, texId);
+
+ } break;
+ default:
+ break;
+ }
+
+ glBindFramebuffer(GL_FRAMEBUFFER, 0);
#endif
}
// Verify render texture is complete
-bool rlFramebufferComplete(unsigned int id)
-{
- bool result = false;
+bool rlFramebufferComplete(unsigned int id) {
+ bool result = false;
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)) && defined(RLGL_RENDER_TEXTURES_HINT)
- glBindFramebuffer(GL_FRAMEBUFFER, id);
-
- GLenum status = glCheckFramebufferStatus(GL_FRAMEBUFFER);
-
- if (status != GL_FRAMEBUFFER_COMPLETE)
- {
- switch (status)
- {
- case GL_FRAMEBUFFER_UNSUPPORTED: TRACELOG(RL_LOG_WARNING, "FBO: [ID %i] Framebuffer is unsupported", id); break;
- case GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT: TRACELOG(RL_LOG_WARNING, "FBO: [ID %i] Framebuffer has incomplete attachment", id); break;
+ glBindFramebuffer(GL_FRAMEBUFFER, id);
+
+ GLenum status = glCheckFramebufferStatus(GL_FRAMEBUFFER);
+
+ if (status != GL_FRAMEBUFFER_COMPLETE) {
+ switch (status) {
+ case GL_FRAMEBUFFER_UNSUPPORTED:
+ TRACELOG(RL_LOG_WARNING, "FBO: [ID %i] Framebuffer is unsupported", id);
+ break;
+ case GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT:
+ TRACELOG(RL_LOG_WARNING, "FBO: [ID %i] Framebuffer has incomplete attachment", id);
+ break;
#if defined(GRAPHICS_API_OPENGL_ES2)
- case GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS: TRACELOG(RL_LOG_WARNING, "FBO: [ID %i] Framebuffer has incomplete dimensions", id); break;
+ case GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS:
+ TRACELOG(RL_LOG_WARNING, "FBO: [ID %i] Framebuffer has incomplete dimensions", id);
+ break;
#endif
- case GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT: TRACELOG(RL_LOG_WARNING, "FBO: [ID %i] Framebuffer has a missing attachment", id); break;
- default: break;
- }
- }
+ case GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT:
+ TRACELOG(RL_LOG_WARNING, "FBO: [ID %i] Framebuffer has a missing attachment", id);
+ break;
+ default:
+ break;
+ }
+ }
- glBindFramebuffer(GL_FRAMEBUFFER, 0);
+ glBindFramebuffer(GL_FRAMEBUFFER, 0);
- result = (status == GL_FRAMEBUFFER_COMPLETE);
+ result = (status == GL_FRAMEBUFFER_COMPLETE);
#endif
- return result;
+ return result;
}
// Unload framebuffer from GPU memory
// NOTE: All attached textures/cubemaps/renderbuffers are also deleted
-void rlUnloadFramebuffer(unsigned int id)
-{
+void rlUnloadFramebuffer(unsigned int id) {
#if (defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)) && defined(RLGL_RENDER_TEXTURES_HINT)
- // Query depth attachment to automatically delete texture/renderbuffer
- int depthType = 0, depthId = 0;
- glBindFramebuffer(GL_FRAMEBUFFER, id); // Bind framebuffer to query depth texture type
- glGetFramebufferAttachmentParameteriv(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE, &depthType);
+ // Query depth attachment to automatically delete texture/renderbuffer
+ int depthType = 0, depthId = 0;
+ glBindFramebuffer(GL_FRAMEBUFFER, id); // Bind framebuffer to query depth texture type
+ glGetFramebufferAttachmentParameteriv(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE, &depthType);
- // TODO: Review warning retrieving object name in WebGL
- // WARNING: WebGL: INVALID_ENUM: getFramebufferAttachmentParameter: invalid parameter name
- // https://registry.khronos.org/webgl/specs/latest/1.0/
- glGetFramebufferAttachmentParameteriv(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME, &depthId);
+ // TODO: Review warning retrieving object name in WebGL
+ // WARNING: WebGL: INVALID_ENUM: getFramebufferAttachmentParameter: invalid parameter name
+ // https://registry.khronos.org/webgl/specs/latest/1.0/
+ glGetFramebufferAttachmentParameteriv(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME, &depthId);
- unsigned int depthIdU = (unsigned int)depthId;
- if (depthType == GL_RENDERBUFFER) glDeleteRenderbuffers(1, &depthIdU);
- else if (depthType == GL_TEXTURE) glDeleteTextures(1, &depthIdU);
+ unsigned int depthIdU = (unsigned int)depthId;
+ if (depthType == GL_RENDERBUFFER)
+ glDeleteRenderbuffers(1, &depthIdU);
+ else if (depthType == GL_TEXTURE)
+ glDeleteTextures(1, &depthIdU);
- // NOTE: If a texture object is deleted while its image is attached to the *currently bound* framebuffer,
- // the texture image is automatically detached from the currently bound framebuffer
+ // NOTE: If a texture object is deleted while its image is attached to the *currently bound* framebuffer,
+ // the texture image is automatically detached from the currently bound framebuffer
- glBindFramebuffer(GL_FRAMEBUFFER, 0);
- glDeleteFramebuffers(1, &id);
+ glBindFramebuffer(GL_FRAMEBUFFER, 0);
+ glDeleteFramebuffers(1, &id);
- TRACELOG(RL_LOG_INFO, "FBO: [ID %i] Unloaded framebuffer from VRAM (GPU)", id);
+ TRACELOG(RL_LOG_INFO, "FBO: [ID %i] Unloaded framebuffer from VRAM (GPU)", id);
#endif
}
// Vertex data management
//-----------------------------------------------------------------------------------------
// Load a new attributes buffer
-unsigned int rlLoadVertexBuffer(const void *buffer, int size, bool dynamic)
-{
- unsigned int id = 0;
+unsigned int rlLoadVertexBuffer(const void* buffer, int size, bool dynamic) {
+ unsigned int id = 0;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glGenBuffers(1, &id);
- glBindBuffer(GL_ARRAY_BUFFER, id);
- glBufferData(GL_ARRAY_BUFFER, size, buffer, dynamic? GL_DYNAMIC_DRAW : GL_STATIC_DRAW);
+ glGenBuffers(1, &id);
+ glBindBuffer(GL_ARRAY_BUFFER, id);
+ glBufferData(GL_ARRAY_BUFFER, size, buffer, dynamic ? GL_DYNAMIC_DRAW : GL_STATIC_DRAW);
#endif
- return id;
+ return id;
}
// Load a new attributes element buffer
-unsigned int rlLoadVertexBufferElement(const void *buffer, int size, bool dynamic)
-{
- unsigned int id = 0;
+unsigned int rlLoadVertexBufferElement(const void* buffer, int size, bool dynamic) {
+ unsigned int id = 0;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glGenBuffers(1, &id);
- glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, id);
- glBufferData(GL_ELEMENT_ARRAY_BUFFER, size, buffer, dynamic? GL_DYNAMIC_DRAW : GL_STATIC_DRAW);
+ glGenBuffers(1, &id);
+ glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, id);
+ glBufferData(GL_ELEMENT_ARRAY_BUFFER, size, buffer, dynamic ? GL_DYNAMIC_DRAW : GL_STATIC_DRAW);
#endif
- return id;
+ return id;
}
// Enable vertex buffer (VBO)
-void rlEnableVertexBuffer(unsigned int id)
-{
+void rlEnableVertexBuffer(unsigned int id) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glBindBuffer(GL_ARRAY_BUFFER, id);
+ glBindBuffer(GL_ARRAY_BUFFER, id);
#endif
}
// Disable vertex buffer (VBO)
-void rlDisableVertexBuffer(void)
-{
+void rlDisableVertexBuffer(void) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glBindBuffer(GL_ARRAY_BUFFER, 0);
+ glBindBuffer(GL_ARRAY_BUFFER, 0);
#endif
}
// Enable vertex buffer element (VBO element)
-void rlEnableVertexBufferElement(unsigned int id)
-{
+void rlEnableVertexBufferElement(unsigned int id) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, id);
+ glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, id);
#endif
}
// Disable vertex buffer element (VBO element)
-void rlDisableVertexBufferElement(void)
-{
+void rlDisableVertexBufferElement(void) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0);
+ glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0);
#endif
}
// Update vertex buffer with new data
// NOTE: dataSize and offset must be provided in bytes
-void rlUpdateVertexBuffer(unsigned int id, const void *data, int dataSize, int offset)
-{
+void rlUpdateVertexBuffer(unsigned int id, const void* data, int dataSize, int offset) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glBindBuffer(GL_ARRAY_BUFFER, id);
- glBufferSubData(GL_ARRAY_BUFFER, offset, dataSize, data);
+ glBindBuffer(GL_ARRAY_BUFFER, id);
+ glBufferSubData(GL_ARRAY_BUFFER, offset, dataSize, data);
#endif
}
// Update vertex buffer elements with new data
// NOTE: dataSize and offset must be provided in bytes
-void rlUpdateVertexBufferElements(unsigned int id, const void *data, int dataSize, int offset)
-{
+void rlUpdateVertexBufferElements(unsigned int id, const void* data, int dataSize, int offset) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, id);
- glBufferSubData(GL_ELEMENT_ARRAY_BUFFER, offset, dataSize, data);
+ glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, id);
+ glBufferSubData(GL_ELEMENT_ARRAY_BUFFER, offset, dataSize, data);
#endif
}
// Enable vertex array object (VAO)
-bool rlEnableVertexArray(unsigned int vaoId)
-{
- bool result = false;
+bool rlEnableVertexArray(unsigned int vaoId) {
+ bool result = false;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- if (RLGL.ExtSupported.vao)
- {
- glBindVertexArray(vaoId);
- result = true;
- }
+ if (RLGL.ExtSupported.vao) {
+ glBindVertexArray(vaoId);
+ result = true;
+ }
#endif
- return result;
+ return result;
}
// Disable vertex array object (VAO)
-void rlDisableVertexArray(void)
-{
+void rlDisableVertexArray(void) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- if (RLGL.ExtSupported.vao) glBindVertexArray(0);
+ if (RLGL.ExtSupported.vao)
+ glBindVertexArray(0);
#endif
}
// Enable vertex attribute index
-void rlEnableVertexAttribute(unsigned int index)
-{
+void rlEnableVertexAttribute(unsigned int index) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glEnableVertexAttribArray(index);
+ glEnableVertexAttribArray(index);
#endif
}
// Disable vertex attribute index
-void rlDisableVertexAttribute(unsigned int index)
-{
+void rlDisableVertexAttribute(unsigned int index) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glDisableVertexAttribArray(index);
+ glDisableVertexAttribArray(index);
#endif
}
// Draw vertex array
-void rlDrawVertexArray(int offset, int count)
-{
- glDrawArrays(GL_TRIANGLES, offset, count);
+void rlDrawVertexArray(int offset, int count) {
+ glDrawArrays(GL_TRIANGLES, offset, count);
}
// Draw vertex array elements
-void rlDrawVertexArrayElements(int offset, int count, const void *buffer)
-{
- // NOTE: Added pointer math separately from function to avoid UBSAN complaining
- unsigned short *bufferPtr = (unsigned short *)buffer;
- if (offset > 0) bufferPtr += offset;
+void rlDrawVertexArrayElements(int offset, int count, const void* buffer) {
+ // NOTE: Added pointer math separately from function to avoid UBSAN complaining
+ unsigned short* bufferPtr = (unsigned short*)buffer;
+ if (offset > 0)
+ bufferPtr += offset;
- glDrawElements(GL_TRIANGLES, count, GL_UNSIGNED_SHORT, (const unsigned short *)bufferPtr);
+ glDrawElements(GL_TRIANGLES, count, GL_UNSIGNED_SHORT, (const unsigned short*)bufferPtr);
}
// Draw vertex array instanced
-void rlDrawVertexArrayInstanced(int offset, int count, int instances)
-{
+void rlDrawVertexArrayInstanced(int offset, int count, int instances) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glDrawArraysInstanced(GL_TRIANGLES, 0, count, instances);
+ glDrawArraysInstanced(GL_TRIANGLES, 0, count, instances);
#endif
}
// Draw vertex array elements instanced
-void rlDrawVertexArrayElementsInstanced(int offset, int count, const void *buffer, int instances)
-{
+void rlDrawVertexArrayElementsInstanced(int offset, int count, const void* buffer, int instances) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- // NOTE: Added pointer math separately from function to avoid UBSAN complaining
- unsigned short *bufferPtr = (unsigned short *)buffer;
- if (offset > 0) bufferPtr += offset;
+ // NOTE: Added pointer math separately from function to avoid UBSAN complaining
+ unsigned short* bufferPtr = (unsigned short*)buffer;
+ if (offset > 0)
+ bufferPtr += offset;
- glDrawElementsInstanced(GL_TRIANGLES, count, GL_UNSIGNED_SHORT, (const unsigned short *)bufferPtr, instances);
+ glDrawElementsInstanced(GL_TRIANGLES, count, GL_UNSIGNED_SHORT, (const unsigned short*)bufferPtr, instances);
#endif
}
#if defined(GRAPHICS_API_OPENGL_11)
// Enable vertex state pointer
-void rlEnableStatePointer(int vertexAttribType, void *buffer)
-{
- if (buffer != NULL) glEnableClientState(vertexAttribType);
- switch (vertexAttribType)
- {
- case GL_VERTEX_ARRAY: glVertexPointer(3, GL_FLOAT, 0, buffer); break;
- case GL_TEXTURE_COORD_ARRAY: glTexCoordPointer(2, GL_FLOAT, 0, buffer); break;
- case GL_NORMAL_ARRAY: if (buffer != NULL) glNormalPointer(GL_FLOAT, 0, buffer); break;
- case GL_COLOR_ARRAY: if (buffer != NULL) glColorPointer(4, GL_UNSIGNED_BYTE, 0, buffer); break;
- //case GL_INDEX_ARRAY: if (buffer != NULL) glIndexPointer(GL_SHORT, 0, buffer); break; // Indexed colors
- default: break;
- }
+void rlEnableStatePointer(int vertexAttribType, void* buffer) {
+ if (buffer != NULL)
+ glEnableClientState(vertexAttribType);
+ switch (vertexAttribType) {
+ case GL_VERTEX_ARRAY:
+ glVertexPointer(3, GL_FLOAT, 0, buffer);
+ break;
+ case GL_TEXTURE_COORD_ARRAY:
+ glTexCoordPointer(2, GL_FLOAT, 0, buffer);
+ break;
+ case GL_NORMAL_ARRAY:
+ if (buffer != NULL)
+ glNormalPointer(GL_FLOAT, 0, buffer);
+ break;
+ case GL_COLOR_ARRAY:
+ if (buffer != NULL)
+ glColorPointer(4, GL_UNSIGNED_BYTE, 0, buffer);
+ break;
+ // case GL_INDEX_ARRAY: if (buffer != NULL) glIndexPointer(GL_SHORT, 0, buffer); break; // Indexed colors
+ default:
+ break;
+ }
}
// Disable vertex state pointer
-void rlDisableStatePointer(int vertexAttribType)
-{
- glDisableClientState(vertexAttribType);
+void rlDisableStatePointer(int vertexAttribType) {
+ glDisableClientState(vertexAttribType);
}
#endif
// Load vertex array object (VAO)
-unsigned int rlLoadVertexArray(void)
-{
- unsigned int vaoId = 0;
+unsigned int rlLoadVertexArray(void) {
+ unsigned int vaoId = 0;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- if (RLGL.ExtSupported.vao)
- {
- glGenVertexArrays(1, &vaoId);
- }
+ if (RLGL.ExtSupported.vao) {
+ glGenVertexArrays(1, &vaoId);
+ }
#endif
- return vaoId;
+ return vaoId;
}
// Set vertex attribute
-void rlSetVertexAttribute(unsigned int index, int compSize, int type, bool normalized, int stride, int offset)
-{
+void rlSetVertexAttribute(unsigned int index, int compSize, int type, bool normalized, int stride, int offset) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- // NOTE: Data type could be: GL_BYTE, GL_UNSIGNED_BYTE, GL_SHORT, GL_UNSIGNED_SHORT, GL_INT, GL_UNSIGNED_INT
- // Additional types (depends on OpenGL version or extensions):
- // - GL_HALF_FLOAT, GL_FLOAT, GL_DOUBLE, GL_FIXED,
- // - GL_INT_2_10_10_10_REV, GL_UNSIGNED_INT_2_10_10_10_REV, GL_UNSIGNED_INT_10F_11F_11F_REV
+ // NOTE: Data type could be: GL_BYTE, GL_UNSIGNED_BYTE, GL_SHORT, GL_UNSIGNED_SHORT, GL_INT, GL_UNSIGNED_INT
+ // Additional types (depends on OpenGL version or extensions):
+ // - GL_HALF_FLOAT, GL_FLOAT, GL_DOUBLE, GL_FIXED,
+ // - GL_INT_2_10_10_10_REV, GL_UNSIGNED_INT_2_10_10_10_REV, GL_UNSIGNED_INT_10F_11F_11F_REV
- size_t offsetNative = offset;
- glVertexAttribPointer(index, compSize, type, normalized, stride, (void *)offsetNative);
+ size_t offsetNative = offset;
+ glVertexAttribPointer(index, compSize, type, normalized, stride, (void*)offsetNative);
#endif
}
// Set vertex attribute divisor
-void rlSetVertexAttributeDivisor(unsigned int index, int divisor)
-{
+void rlSetVertexAttributeDivisor(unsigned int index, int divisor) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glVertexAttribDivisor(index, divisor);
+ glVertexAttribDivisor(index, divisor);
#endif
}
// Unload vertex array object (VAO)
-void rlUnloadVertexArray(unsigned int vaoId)
-{
+void rlUnloadVertexArray(unsigned int vaoId) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- if (RLGL.ExtSupported.vao)
- {
- glBindVertexArray(0);
- glDeleteVertexArrays(1, &vaoId);
- TRACELOG(RL_LOG_INFO, "VAO: [ID %i] Unloaded vertex array data from VRAM (GPU)", vaoId);
- }
+ if (RLGL.ExtSupported.vao) {
+ glBindVertexArray(0);
+ glDeleteVertexArrays(1, &vaoId);
+ TRACELOG(RL_LOG_INFO, "VAO: [ID %i] Unloaded vertex array data from VRAM (GPU)", vaoId);
+ }
#endif
}
// Unload vertex buffer (VBO)
-void rlUnloadVertexBuffer(unsigned int vboId)
-{
+void rlUnloadVertexBuffer(unsigned int vboId) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glDeleteBuffers(1, &vboId);
- //TRACELOG(RL_LOG_INFO, "VBO: Unloaded vertex data from VRAM (GPU)");
+ glDeleteBuffers(1, &vboId);
+ // TRACELOG(RL_LOG_INFO, "VBO: Unloaded vertex data from VRAM (GPU)");
#endif
}
@@ -3247,801 +3520,872 @@ void rlUnloadVertexBuffer(unsigned int vboId)
//-----------------------------------------------------------------------------------------------
// Load shader from code strings
// NOTE: If shader string is NULL, using default vertex/fragment shaders
-unsigned int rlLoadShaderCode(const char *vsCode, const char *fsCode)
-{
- unsigned int id = 0;
+unsigned int rlLoadShaderCode(const char* vsCode, const char* fsCode) {
+ unsigned int id = 0;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- unsigned int vertexShaderId = 0;
- unsigned int fragmentShaderId = 0;
-
- // Compile vertex shader (if provided)
- // NOTE: If not vertex shader is provided, use default one
- if (vsCode != NULL) vertexShaderId = rlCompileShader(vsCode, GL_VERTEX_SHADER);
- else vertexShaderId = RLGL.State.defaultVShaderId;
-
- // Compile fragment shader (if provided)
- // NOTE: If not vertex shader is provided, use default one
- if (fsCode != NULL) fragmentShaderId = rlCompileShader(fsCode, GL_FRAGMENT_SHADER);
- else fragmentShaderId = RLGL.State.defaultFShaderId;
-
- // In case vertex and fragment shader are the default ones, no need to recompile, we can just assign the default shader program id
- if ((vertexShaderId == RLGL.State.defaultVShaderId) && (fragmentShaderId == RLGL.State.defaultFShaderId)) id = RLGL.State.defaultShaderId;
- else if ((vertexShaderId > 0) && (fragmentShaderId > 0))
- {
- // One of or both shader are new, we need to compile a new shader program
- id = rlLoadShaderProgram(vertexShaderId, fragmentShaderId);
-
- // We can detach and delete vertex/fragment shaders (if not default ones)
- // NOTE: We detach shader before deletion to make sure memory is freed
- if (vertexShaderId != RLGL.State.defaultVShaderId)
- {
- // WARNING: Shader program linkage could fail and returned id is 0
- if (id > 0) glDetachShader(id, vertexShaderId);
- glDeleteShader(vertexShaderId);
- }
- if (fragmentShaderId != RLGL.State.defaultFShaderId)
- {
- // WARNING: Shader program linkage could fail and returned id is 0
- if (id > 0) glDetachShader(id, fragmentShaderId);
- glDeleteShader(fragmentShaderId);
- }
-
- // In case shader program loading failed, we assign default shader
- if (id == 0)
- {
- // In case shader loading fails, we return the default shader
- TRACELOG(RL_LOG_WARNING, "SHADER: Failed to load custom shader code, using default shader");
- id = RLGL.State.defaultShaderId;
- }
- /*
- else
- {
- // Get available shader uniforms
- // NOTE: This information is useful for debug...
- int uniformCount = -1;
- glGetProgramiv(id, GL_ACTIVE_UNIFORMS, &uniformCount);
-
- for (int i = 0; i < uniformCount; i++)
- {
- int namelen = -1;
- int num = -1;
- char name[256] = { 0 }; // Assume no variable names longer than 256
- GLenum type = GL_ZERO;
-
- // Get the name of the uniforms
- glGetActiveUniform(id, i, sizeof(name) - 1, &namelen, &num, &type, name);
-
- name[namelen] = 0;
- TRACELOGD("SHADER: [ID %i] Active uniform (%s) set at location: %i", id, name, glGetUniformLocation(id, name));
- }
- }
- */
- }
-#endif
-
- return id;
+ unsigned int vertexShaderId = 0;
+ unsigned int fragmentShaderId = 0;
+
+ // Compile vertex shader (if provided)
+ // NOTE: If not vertex shader is provided, use default one
+ if (vsCode != NULL)
+ vertexShaderId = rlCompileShader(vsCode, GL_VERTEX_SHADER);
+ else
+ vertexShaderId = RLGL.State.defaultVShaderId;
+
+ // Compile fragment shader (if provided)
+ // NOTE: If not vertex shader is provided, use default one
+ if (fsCode != NULL)
+ fragmentShaderId = rlCompileShader(fsCode, GL_FRAGMENT_SHADER);
+ else
+ fragmentShaderId = RLGL.State.defaultFShaderId;
+
+ // In case vertex and fragment shader are the default ones, no need to recompile, we can just assign the default shader program id
+ if ((vertexShaderId == RLGL.State.defaultVShaderId) && (fragmentShaderId == RLGL.State.defaultFShaderId))
+ id = RLGL.State.defaultShaderId;
+ else if ((vertexShaderId > 0) && (fragmentShaderId > 0)) {
+ // One of or both shader are new, we need to compile a new shader program
+ id = rlLoadShaderProgram(vertexShaderId, fragmentShaderId);
+
+ // We can detach and delete vertex/fragment shaders (if not default ones)
+ // NOTE: We detach shader before deletion to make sure memory is freed
+ if (vertexShaderId != RLGL.State.defaultVShaderId) {
+ // WARNING: Shader program linkage could fail and returned id is 0
+ if (id > 0)
+ glDetachShader(id, vertexShaderId);
+ glDeleteShader(vertexShaderId);
+ }
+ if (fragmentShaderId != RLGL.State.defaultFShaderId) {
+ // WARNING: Shader program linkage could fail and returned id is 0
+ if (id > 0)
+ glDetachShader(id, fragmentShaderId);
+ glDeleteShader(fragmentShaderId);
+ }
+
+ // In case shader program loading failed, we assign default shader
+ if (id == 0) {
+ // In case shader loading fails, we return the default shader
+ TRACELOG(RL_LOG_WARNING, "SHADER: Failed to load custom shader code, using default shader");
+ id = RLGL.State.defaultShaderId;
+ }
+ /*
+ else
+ {
+ // Get available shader uniforms
+ // NOTE: This information is useful for debug...
+ int uniformCount = -1;
+ glGetProgramiv(id, GL_ACTIVE_UNIFORMS, &uniformCount);
+
+ for (int i = 0; i < uniformCount; i++)
+ {
+ int namelen = -1;
+ int num = -1;
+ char name[256] = { 0 }; // Assume no variable names longer than 256
+ GLenum type = GL_ZERO;
+
+ // Get the name of the uniforms
+ glGetActiveUniform(id, i, sizeof(name) - 1, &namelen, &num, &type, name);
+
+ name[namelen] = 0;
+ TRACELOGD("SHADER: [ID %i] Active uniform (%s) set at location: %i", id, name, glGetUniformLocation(id, name));
+ }
+ }
+ */
+ }
+#endif
+
+ return id;
}
// Compile custom shader and return shader id
-unsigned int rlCompileShader(const char *shaderCode, int type)
-{
- unsigned int shader = 0;
+unsigned int rlCompileShader(const char* shaderCode, int type) {
+ unsigned int shader = 0;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- shader = glCreateShader(type);
- glShaderSource(shader, 1, &shaderCode, NULL);
-
- GLint success = 0;
- glCompileShader(shader);
- glGetShaderiv(shader, GL_COMPILE_STATUS, &success);
-
- if (success == GL_FALSE)
- {
- switch (type)
- {
- case GL_VERTEX_SHADER: TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to compile vertex shader code", shader); break;
- case GL_FRAGMENT_SHADER: TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to compile fragment shader code", shader); break;
- //case GL_GEOMETRY_SHADER:
- #if defined(GRAPHICS_API_OPENGL_43)
- case GL_COMPUTE_SHADER: TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to compile compute shader code", shader); break;
- #elif defined(GRAPHICS_API_OPENGL_33)
- case GL_COMPUTE_SHADER: TRACELOG(RL_LOG_WARNING, "SHADER: Compute shaders not enabled. Define GRAPHICS_API_OPENGL_43", shader); break;
- #endif
- default: break;
- }
-
- int maxLength = 0;
- glGetShaderiv(shader, GL_INFO_LOG_LENGTH, &maxLength);
-
- if (maxLength > 0)
- {
- int length = 0;
- char *log = (char *)RL_CALLOC(maxLength, sizeof(char));
- glGetShaderInfoLog(shader, maxLength, &length, log);
- TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Compile error: %s", shader, log);
- RL_FREE(log);
- }
-
- shader = 0;
- }
- else
- {
- switch (type)
- {
- case GL_VERTEX_SHADER: TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Vertex shader compiled successfully", shader); break;
- case GL_FRAGMENT_SHADER: TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Fragment shader compiled successfully", shader); break;
- //case GL_GEOMETRY_SHADER:
- #if defined(GRAPHICS_API_OPENGL_43)
- case GL_COMPUTE_SHADER: TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Compute shader compiled successfully", shader); break;
- #elif defined(GRAPHICS_API_OPENGL_33)
- case GL_COMPUTE_SHADER: TRACELOG(RL_LOG_WARNING, "SHADER: Compute shaders not enabled. Define GRAPHICS_API_OPENGL_43", shader); break;
- #endif
- default: break;
- }
- }
-#endif
-
- return shader;
+ shader = glCreateShader(type);
+ glShaderSource(shader, 1, &shaderCode, NULL);
+
+ GLint success = 0;
+ glCompileShader(shader);
+ glGetShaderiv(shader, GL_COMPILE_STATUS, &success);
+
+ if (success == GL_FALSE) {
+ switch (type) {
+ case GL_VERTEX_SHADER:
+ TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to compile vertex shader code", shader);
+ break;
+ case GL_FRAGMENT_SHADER:
+ TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to compile fragment shader code", shader);
+ break;
+ // case GL_GEOMETRY_SHADER:
+#if defined(GRAPHICS_API_OPENGL_43)
+ case GL_COMPUTE_SHADER:
+ TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to compile compute shader code", shader);
+ break;
+#elif defined(GRAPHICS_API_OPENGL_33)
+ case GL_COMPUTE_SHADER:
+ TRACELOG(RL_LOG_WARNING, "SHADER: Compute shaders not enabled. Define GRAPHICS_API_OPENGL_43", shader);
+ break;
+#endif
+ default:
+ break;
+ }
+
+ int maxLength = 0;
+ glGetShaderiv(shader, GL_INFO_LOG_LENGTH, &maxLength);
+
+ if (maxLength > 0) {
+ int length = 0;
+ char* log = (char*)RL_CALLOC(maxLength, sizeof(char));
+ glGetShaderInfoLog(shader, maxLength, &length, log);
+ TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Compile error: %s", shader, log);
+ RL_FREE(log);
+ }
+
+ shader = 0;
+ } else {
+ switch (type) {
+ case GL_VERTEX_SHADER:
+ TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Vertex shader compiled successfully", shader);
+ break;
+ case GL_FRAGMENT_SHADER:
+ TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Fragment shader compiled successfully", shader);
+ break;
+ // case GL_GEOMETRY_SHADER:
+#if defined(GRAPHICS_API_OPENGL_43)
+ case GL_COMPUTE_SHADER:
+ TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Compute shader compiled successfully", shader);
+ break;
+#elif defined(GRAPHICS_API_OPENGL_33)
+ case GL_COMPUTE_SHADER:
+ TRACELOG(RL_LOG_WARNING, "SHADER: Compute shaders not enabled. Define GRAPHICS_API_OPENGL_43", shader);
+ break;
+#endif
+ default:
+ break;
+ }
+ }
+#endif
+
+ return shader;
}
// Load custom shader strings and return program id
-unsigned int rlLoadShaderProgram(unsigned int vShaderId, unsigned int fShaderId)
-{
- unsigned int program = 0;
+unsigned int rlLoadShaderProgram(unsigned int vShaderId, unsigned int fShaderId) {
+ unsigned int program = 0;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- GLint success = 0;
- program = glCreateProgram();
+ GLint success = 0;
+ program = glCreateProgram();
- glAttachShader(program, vShaderId);
- glAttachShader(program, fShaderId);
+ glAttachShader(program, vShaderId);
+ glAttachShader(program, fShaderId);
- // NOTE: Default attribute shader locations must be Bound before linking
- glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION, RL_DEFAULT_SHADER_ATTRIB_NAME_POSITION);
- glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD, RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD);
- glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL, RL_DEFAULT_SHADER_ATTRIB_NAME_NORMAL);
- glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_COLOR, RL_DEFAULT_SHADER_ATTRIB_NAME_COLOR);
- glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_TANGENT, RL_DEFAULT_SHADER_ATTRIB_NAME_TANGENT);
- glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD2, RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD2);
+ // NOTE: Default attribute shader locations must be Bound before linking
+ glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION, RL_DEFAULT_SHADER_ATTRIB_NAME_POSITION);
+ glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD, RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD);
+ glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL, RL_DEFAULT_SHADER_ATTRIB_NAME_NORMAL);
+ glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_COLOR, RL_DEFAULT_SHADER_ATTRIB_NAME_COLOR);
+ glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_TANGENT, RL_DEFAULT_SHADER_ATTRIB_NAME_TANGENT);
+ glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD2, RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD2);
#ifdef RL_SUPPORT_MESH_GPU_SKINNING
- glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEIDS, RL_DEFAULT_SHADER_ATTRIB_NAME_BONEIDS);
- glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEWEIGHTS, RL_DEFAULT_SHADER_ATTRIB_NAME_BONEWEIGHTS);
+ glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEIDS, RL_DEFAULT_SHADER_ATTRIB_NAME_BONEIDS);
+ glBindAttribLocation(program, RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEWEIGHTS, RL_DEFAULT_SHADER_ATTRIB_NAME_BONEWEIGHTS);
#endif
- // NOTE: If some attrib name is no found on the shader, it locations becomes -1
+ // NOTE: If some attrib name is no found on the shader, it locations becomes -1
- glLinkProgram(program);
+ glLinkProgram(program);
- // NOTE: All uniform variables are intitialised to 0 when a program links
+ // NOTE: All uniform variables are intitialised to 0 when a program links
- glGetProgramiv(program, GL_LINK_STATUS, &success);
+ glGetProgramiv(program, GL_LINK_STATUS, &success);
- if (success == GL_FALSE)
- {
- TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to link shader program", program);
+ if (success == GL_FALSE) {
+ TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to link shader program", program);
- int maxLength = 0;
- glGetProgramiv(program, GL_INFO_LOG_LENGTH, &maxLength);
+ int maxLength = 0;
+ glGetProgramiv(program, GL_INFO_LOG_LENGTH, &maxLength);
- if (maxLength > 0)
- {
- int length = 0;
- char *log = (char *)RL_CALLOC(maxLength, sizeof(char));
- glGetProgramInfoLog(program, maxLength, &length, log);
- TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Link error: %s", program, log);
- RL_FREE(log);
- }
+ if (maxLength > 0) {
+ int length = 0;
+ char* log = (char*)RL_CALLOC(maxLength, sizeof(char));
+ glGetProgramInfoLog(program, maxLength, &length, log);
+ TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Link error: %s", program, log);
+ RL_FREE(log);
+ }
- glDeleteProgram(program);
+ glDeleteProgram(program);
- program = 0;
- }
- else
- {
- // Get the size of compiled shader program (not available on OpenGL ES 2.0)
- // NOTE: If GL_LINK_STATUS is GL_FALSE, program binary length is zero
- //GLint binarySize = 0;
- //glGetProgramiv(id, GL_PROGRAM_BINARY_LENGTH, &binarySize);
+ program = 0;
+ } else {
+ // Get the size of compiled shader program (not available on OpenGL ES 2.0)
+ // NOTE: If GL_LINK_STATUS is GL_FALSE, program binary length is zero
+ // GLint binarySize = 0;
+ // glGetProgramiv(id, GL_PROGRAM_BINARY_LENGTH, &binarySize);
- TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Program shader loaded successfully", program);
- }
+ TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Program shader loaded successfully", program);
+ }
#endif
- return program;
+ return program;
}
// Unload shader program
-void rlUnloadShaderProgram(unsigned int id)
-{
+void rlUnloadShaderProgram(unsigned int id) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glDeleteProgram(id);
+ glDeleteProgram(id);
- TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Unloaded shader program data from VRAM (GPU)", id);
+ TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Unloaded shader program data from VRAM (GPU)", id);
#endif
}
// Get shader location uniform
-int rlGetLocationUniform(unsigned int shaderId, const char *uniformName)
-{
- int location = -1;
+int rlGetLocationUniform(unsigned int shaderId, const char* uniformName) {
+ int location = -1;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- location = glGetUniformLocation(shaderId, uniformName);
+ location = glGetUniformLocation(shaderId, uniformName);
- //if (location == -1) TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to find shader uniform: %s", shaderId, uniformName);
- //else TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Shader uniform (%s) set at location: %i", shaderId, uniformName, location);
+ // if (location == -1) TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to find shader uniform: %s", shaderId, uniformName);
+ // else TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Shader uniform (%s) set at location: %i", shaderId, uniformName, location);
#endif
- return location;
+ return location;
+}
+
+int rlGetLocationUniformCurrent(const char* uniformName) {
+ return rlGetLocationUniform(RLGL.State.currentShaderId, uniformName);
}
// Get shader location attribute
-int rlGetLocationAttrib(unsigned int shaderId, const char *attribName)
-{
- int location = -1;
+int rlGetLocationAttrib(unsigned int shaderId, const char* attribName) {
+ int location = -1;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- location = glGetAttribLocation(shaderId, attribName);
+ location = glGetAttribLocation(shaderId, attribName);
- //if (location == -1) TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to find shader attribute: %s", shaderId, attribName);
- //else TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Shader attribute (%s) set at location: %i", shaderId, attribName, location);
+ // if (location == -1) TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to find shader attribute: %s", shaderId, attribName);
+ // else TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Shader attribute (%s) set at location: %i", shaderId, attribName, location);
#endif
- return location;
+ return location;
}
// Set shader value uniform
-void rlSetUniform(int locIndex, const void *value, int uniformType, int count)
-{
+void rlSetUniform(int locIndex, const void* value, int uniformType, int count) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- switch (uniformType)
- {
- case RL_SHADER_UNIFORM_FLOAT: glUniform1fv(locIndex, count, (float *)value); break;
- case RL_SHADER_UNIFORM_VEC2: glUniform2fv(locIndex, count, (float *)value); break;
- case RL_SHADER_UNIFORM_VEC3: glUniform3fv(locIndex, count, (float *)value); break;
- case RL_SHADER_UNIFORM_VEC4: glUniform4fv(locIndex, count, (float *)value); break;
- case RL_SHADER_UNIFORM_INT: glUniform1iv(locIndex, count, (int *)value); break;
- case RL_SHADER_UNIFORM_IVEC2: glUniform2iv(locIndex, count, (int *)value); break;
- case RL_SHADER_UNIFORM_IVEC3: glUniform3iv(locIndex, count, (int *)value); break;
- case RL_SHADER_UNIFORM_IVEC4: glUniform4iv(locIndex, count, (int *)value); break;
- #if !defined(GRAPHICS_API_OPENGL_ES2)
- case RL_SHADER_UNIFORM_UINT: glUniform1uiv(locIndex, count, (unsigned int *)value); break;
- case RL_SHADER_UNIFORM_UIVEC2: glUniform2uiv(locIndex, count, (unsigned int *)value); break;
- case RL_SHADER_UNIFORM_UIVEC3: glUniform3uiv(locIndex, count, (unsigned int *)value); break;
- case RL_SHADER_UNIFORM_UIVEC4: glUniform4uiv(locIndex, count, (unsigned int *)value); break;
- #endif
- case RL_SHADER_UNIFORM_SAMPLER2D: glUniform1iv(locIndex, count, (int *)value); break;
- default: TRACELOG(RL_LOG_WARNING, "SHADER: Failed to set uniform value, data type not recognized");
-
- // TODO: Support glUniform1uiv(), glUniform2uiv(), glUniform3uiv(), glUniform4uiv()
- }
+ switch (uniformType) {
+ case RL_SHADER_UNIFORM_FLOAT:
+ glUniform1fv(locIndex, count, (float*)value);
+ break;
+ case RL_SHADER_UNIFORM_VEC2:
+ glUniform2fv(locIndex, count, (float*)value);
+ break;
+ case RL_SHADER_UNIFORM_VEC3:
+ glUniform3fv(locIndex, count, (float*)value);
+ break;
+ case RL_SHADER_UNIFORM_VEC4:
+ glUniform4fv(locIndex, count, (float*)value);
+ break;
+ case RL_SHADER_UNIFORM_INT:
+ glUniform1iv(locIndex, count, (int*)value);
+ break;
+ case RL_SHADER_UNIFORM_IVEC2:
+ glUniform2iv(locIndex, count, (int*)value);
+ break;
+ case RL_SHADER_UNIFORM_IVEC3:
+ glUniform3iv(locIndex, count, (int*)value);
+ break;
+ case RL_SHADER_UNIFORM_IVEC4:
+ glUniform4iv(locIndex, count, (int*)value);
+ break;
+#if !defined(GRAPHICS_API_OPENGL_ES2)
+ case RL_SHADER_UNIFORM_UINT:
+ glUniform1uiv(locIndex, count, (unsigned int*)value);
+ break;
+ case RL_SHADER_UNIFORM_UIVEC2:
+ glUniform2uiv(locIndex, count, (unsigned int*)value);
+ break;
+ case RL_SHADER_UNIFORM_UIVEC3:
+ glUniform3uiv(locIndex, count, (unsigned int*)value);
+ break;
+ case RL_SHADER_UNIFORM_UIVEC4:
+ glUniform4uiv(locIndex, count, (unsigned int*)value);
+ break;
+#endif
+ case RL_SHADER_UNIFORM_SAMPLER2D:
+ glUniform1iv(locIndex, count, (int*)value);
+ break;
+ default:
+ TRACELOG(RL_LOG_WARNING, "SHADER: Failed to set uniform value, data type not recognized");
+
+ // TODO: Support glUniform1uiv(), glUniform2uiv(), glUniform3uiv(), glUniform4uiv()
+ }
#endif
}
// Set shader value attribute
-void rlSetVertexAttributeDefault(int locIndex, const void *value, int attribType, int count)
-{
+void rlSetVertexAttributeDefault(int locIndex, const void* value, int attribType, int count) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- switch (attribType)
- {
- case RL_SHADER_ATTRIB_FLOAT: if (count == 1) glVertexAttrib1fv(locIndex, (float *)value); break;
- case RL_SHADER_ATTRIB_VEC2: if (count == 2) glVertexAttrib2fv(locIndex, (float *)value); break;
- case RL_SHADER_ATTRIB_VEC3: if (count == 3) glVertexAttrib3fv(locIndex, (float *)value); break;
- case RL_SHADER_ATTRIB_VEC4: if (count == 4) glVertexAttrib4fv(locIndex, (float *)value); break;
- default: TRACELOG(RL_LOG_WARNING, "SHADER: Failed to set attrib default value, data type not recognized");
- }
+ switch (attribType) {
+ case RL_SHADER_ATTRIB_FLOAT:
+ if (count == 1)
+ glVertexAttrib1fv(locIndex, (float*)value);
+ break;
+ case RL_SHADER_ATTRIB_VEC2:
+ if (count == 2)
+ glVertexAttrib2fv(locIndex, (float*)value);
+ break;
+ case RL_SHADER_ATTRIB_VEC3:
+ if (count == 3)
+ glVertexAttrib3fv(locIndex, (float*)value);
+ break;
+ case RL_SHADER_ATTRIB_VEC4:
+ if (count == 4)
+ glVertexAttrib4fv(locIndex, (float*)value);
+ break;
+ default:
+ TRACELOG(RL_LOG_WARNING, "SHADER: Failed to set attrib default value, data type not recognized");
+ }
#endif
}
// Set shader value uniform matrix
-void rlSetUniformMatrix(int locIndex, RLMatrix mat)
-{
+void rlSetUniformMatrix(int locIndex, RLMatrix mat) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- float matfloat[16] = {
- mat.m0, mat.m1, mat.m2, mat.m3,
- mat.m4, mat.m5, mat.m6, mat.m7,
- mat.m8, mat.m9, mat.m10, mat.m11,
- mat.m12, mat.m13, mat.m14, mat.m15
- };
- glUniformMatrix4fv(locIndex, 1, false, matfloat);
+ float matfloat[16] = {
+ mat.m0, mat.m1, mat.m2, mat.m3,
+ mat.m4, mat.m5, mat.m6, mat.m7,
+ mat.m8, mat.m9, mat.m10, mat.m11,
+ mat.m12, mat.m13, mat.m14, mat.m15};
+ glUniformMatrix4fv(locIndex, 1, false, matfloat);
#endif
}
// Set shader value uniform matrix
-void rlSetUniformMatrices(int locIndex, const RLMatrix *matrices, int count)
-{
+void rlSetUniformMatrices(int locIndex, const RLMatrix* matrices, int count) {
#if defined(GRAPHICS_API_OPENGL_33)
- glUniformMatrix4fv(locIndex, count, true, (const float *)matrices);
+ glUniformMatrix4fv(locIndex, count, true, (const float*)matrices);
#elif defined(GRAPHICS_API_OPENGL_ES2)
- // WARNING: WebGL does not support RLMatrix transpose ("true" parameter)
- // REF: https://developer.mozilla.org/en-US/docs/Web/API/WebGLRenderingContext/uniformMatrix
- glUniformMatrix4fv(locIndex, count, false, (const float *)matrices);
+ // WARNING: WebGL does not support RLMatrix transpose ("true" parameter)
+ // REF: https://developer.mozilla.org/en-US/docs/Web/API/WebGLRenderingContext/uniformMatrix
+ glUniformMatrix4fv(locIndex, count, false, (const float*)matrices);
#endif
}
// Set shader value uniform sampler
-void rlSetUniformSampler(int locIndex, unsigned int textureId)
-{
+void rlSetUniformSampler(int locIndex, unsigned int textureId) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- // Check if texture is already active
- for (int i = 0; i < RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS; i++)
- {
- if (RLGL.State.activeTextureId[i] == textureId)
- {
- glUniform1i(locIndex, 1 + i);
- return;
- }
- }
-
- // Register a new active texture for the internal batch system
- // NOTE: Default texture is always activated as GL_TEXTURE0
- for (int i = 0; i < RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS; i++)
- {
- if (RLGL.State.activeTextureId[i] == 0)
- {
- glUniform1i(locIndex, 1 + i); // Activate new texture unit
- RLGL.State.activeTextureId[i] = textureId; // Save texture id for binding on drawing
- break;
- }
- }
+ // Check if texture is already active
+ for (int i = 0; i < RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS; i++) {
+ if (RLGL.State.activeTextureId[i] == textureId) {
+ glUniform1i(locIndex, 1 + i);
+ return;
+ }
+ }
+
+ // Register a new active texture for the internal batch system
+ // NOTE: Default texture is always activated as GL_TEXTURE0
+ for (int i = 0; i < RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS; i++) {
+ if (RLGL.State.activeTextureId[i] == 0) {
+ glUniform1i(locIndex, 1 + i); // Activate new texture unit
+ RLGL.State.activeTextureId[i] = textureId; // Save texture id for binding on drawing
+ break;
+ }
+ }
#endif
}
-
// Reset depth for next draw
-void rlResetDrawDepth()
-{
- RLGL.currentBatch->currentDepth = -1.0f;
+void rlResetDrawDepth() {
+ RLGL.currentBatch->currentDepth = -1.0f;
}
// Reset active texture units for next batch
-void rlClearActiveTextures()
-{
- for (int i = 0; i < RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS; i++) RLGL.State.activeTextureId[i] = 0;
+void rlClearActiveTextures() {
+ for (int i = 0; i < RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS; i++)
+ RLGL.State.activeTextureId[i] = 0;
}
// Set shader currently active (id and locations)
-void rlSetShader(unsigned int id, int *locs)
-{
+void rlSetShader(unsigned int id, const int* locs) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- if (RLGL.State.currentShaderId != id)
- {
- rlDrawRenderBatch(RLGL.currentBatch);
- RLGL.State.currentShaderId = id;
- RLGL.State.currentShaderLocs = locs;
- }
+ if (RLGL.State.currentShaderId != id) {
+ rlDrawRenderBatch(RLGL.currentBatch);
+ RLGL.State.currentShaderId = id;
+ RLGL.State.currentShaderLocs = locs;
+ }
#endif
}
unsigned int rlGetShaderCurrent() {
- return RLGL.State.currentShaderId;
+ return RLGL.State.currentShaderId;
}
// Load compute shader program
-unsigned int rlLoadComputeShaderProgram(unsigned int shaderId)
-{
- unsigned int program = 0;
+unsigned int rlLoadComputeShaderProgram(unsigned int shaderId) {
+ unsigned int program = 0;
#if defined(GRAPHICS_API_OPENGL_43)
- GLint success = 0;
- program = glCreateProgram();
- glAttachShader(program, shaderId);
- glLinkProgram(program);
-
- // NOTE: All uniform variables are intitialised to 0 when a program links
-
- glGetProgramiv(program, GL_LINK_STATUS, &success);
-
- if (success == GL_FALSE)
- {
- TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to link compute shader program", program);
-
- int maxLength = 0;
- glGetProgramiv(program, GL_INFO_LOG_LENGTH, &maxLength);
-
- if (maxLength > 0)
- {
- int length = 0;
- char *log = (char *)RL_CALLOC(maxLength, sizeof(char));
- glGetProgramInfoLog(program, maxLength, &length, log);
- TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Link error: %s", program, log);
- RL_FREE(log);
- }
-
- glDeleteProgram(program);
-
- program = 0;
- }
- else
- {
- // Get the size of compiled shader program (not available on OpenGL ES 2.0)
- // NOTE: If GL_LINK_STATUS is GL_FALSE, program binary length is zero
- //GLint binarySize = 0;
- //glGetProgramiv(id, GL_PROGRAM_BINARY_LENGTH, &binarySize);
-
- TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Compute shader program loaded successfully", program);
- }
+ GLint success = 0;
+ program = glCreateProgram();
+ glAttachShader(program, shaderId);
+ glLinkProgram(program);
+
+ // NOTE: All uniform variables are intitialised to 0 when a program links
+
+ glGetProgramiv(program, GL_LINK_STATUS, &success);
+
+ if (success == GL_FALSE) {
+ TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to link compute shader program", program);
+
+ int maxLength = 0;
+ glGetProgramiv(program, GL_INFO_LOG_LENGTH, &maxLength);
+
+ if (maxLength > 0) {
+ int length = 0;
+ char* log = (char*)RL_CALLOC(maxLength, sizeof(char));
+ glGetProgramInfoLog(program, maxLength, &length, log);
+ TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Link error: %s", program, log);
+ RL_FREE(log);
+ }
+
+ glDeleteProgram(program);
+
+ program = 0;
+ } else {
+ // Get the size of compiled shader program (not available on OpenGL ES 2.0)
+ // NOTE: If GL_LINK_STATUS is GL_FALSE, program binary length is zero
+ // GLint binarySize = 0;
+ // glGetProgramiv(id, GL_PROGRAM_BINARY_LENGTH, &binarySize);
+
+ TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Compute shader program loaded successfully", program);
+ }
#else
- TRACELOG(RL_LOG_WARNING, "SHADER: Compute shaders not enabled. Define GRAPHICS_API_OPENGL_43");
+ TRACELOG(RL_LOG_WARNING, "SHADER: Compute shaders not enabled. Define GRAPHICS_API_OPENGL_43");
#endif
- return program;
+ return program;
}
// Dispatch compute shader (equivalent to *draw* for graphics pilepine)
-void rlComputeShaderDispatch(unsigned int groupX, unsigned int groupY, unsigned int groupZ)
-{
+void rlComputeShaderDispatch(unsigned int groupX, unsigned int groupY, unsigned int groupZ) {
#if defined(GRAPHICS_API_OPENGL_43)
- glDispatchCompute(groupX, groupY, groupZ);
+ glDispatchCompute(groupX, groupY, groupZ);
#endif
}
// Load shader storage buffer object (SSBO)
-unsigned int rlLoadShaderBuffer(unsigned int size, const void *data, int usageHint)
-{
- unsigned int ssbo = 0;
+unsigned int rlLoadShaderBuffer(unsigned int size, const void* data, int usageHint) {
+ unsigned int ssbo = 0;
#if defined(GRAPHICS_API_OPENGL_43)
- glGenBuffers(1, &ssbo);
- glBindBuffer(GL_SHADER_STORAGE_BUFFER, ssbo);
- glBufferData(GL_SHADER_STORAGE_BUFFER, size, data, usageHint? usageHint : RL_STREAM_COPY);
- if (data == NULL) glClearBufferData(GL_SHADER_STORAGE_BUFFER, GL_R8UI, GL_RED_INTEGER, GL_UNSIGNED_BYTE, NULL); // Clear buffer data to 0
- glBindBuffer(GL_SHADER_STORAGE_BUFFER, 0);
+ glGenBuffers(1, &ssbo);
+ glBindBuffer(GL_SHADER_STORAGE_BUFFER, ssbo);
+ glBufferData(GL_SHADER_STORAGE_BUFFER, size, data, usageHint ? usageHint : RL_STREAM_COPY);
+ if (data == NULL)
+ glClearBufferData(GL_SHADER_STORAGE_BUFFER, GL_R8UI, GL_RED_INTEGER, GL_UNSIGNED_BYTE, NULL); // Clear buffer data to 0
+ glBindBuffer(GL_SHADER_STORAGE_BUFFER, 0);
#else
- TRACELOG(RL_LOG_WARNING, "SSBO: SSBO not enabled. Define GRAPHICS_API_OPENGL_43");
+ TRACELOG(RL_LOG_WARNING, "SSBO: SSBO not enabled. Define GRAPHICS_API_OPENGL_43");
#endif
- return ssbo;
+ return ssbo;
}
// Unload shader storage buffer object (SSBO)
-void rlUnloadShaderBuffer(unsigned int ssboId)
-{
+void rlUnloadShaderBuffer(unsigned int ssboId) {
#if defined(GRAPHICS_API_OPENGL_43)
- glDeleteBuffers(1, &ssboId);
+ glDeleteBuffers(1, &ssboId);
#else
- TRACELOG(RL_LOG_WARNING, "SSBO: SSBO not enabled. Define GRAPHICS_API_OPENGL_43");
+ TRACELOG(RL_LOG_WARNING, "SSBO: SSBO not enabled. Define GRAPHICS_API_OPENGL_43");
#endif
-
}
// Update SSBO buffer data
-void rlUpdateShaderBuffer(unsigned int id, const void *data, unsigned int dataSize, unsigned int offset)
-{
+void rlUpdateShaderBuffer(unsigned int id, const void* data, unsigned int dataSize, unsigned int offset) {
#if defined(GRAPHICS_API_OPENGL_43)
- glBindBuffer(GL_SHADER_STORAGE_BUFFER, id);
- glBufferSubData(GL_SHADER_STORAGE_BUFFER, offset, dataSize, data);
+ glBindBuffer(GL_SHADER_STORAGE_BUFFER, id);
+ glBufferSubData(GL_SHADER_STORAGE_BUFFER, offset, dataSize, data);
#endif
}
// Get SSBO buffer size
-unsigned int rlGetShaderBufferSize(unsigned int id)
-{
+unsigned int rlGetShaderBufferSize(unsigned int id) {
#if defined(GRAPHICS_API_OPENGL_43)
- GLint64 size = 0;
- glBindBuffer(GL_SHADER_STORAGE_BUFFER, id);
- glGetBufferParameteri64v(GL_SHADER_STORAGE_BUFFER, GL_BUFFER_SIZE, &size);
- return (size > 0)? (unsigned int)size : 0;
+ GLint64 size = 0;
+ glBindBuffer(GL_SHADER_STORAGE_BUFFER, id);
+ glGetBufferParameteri64v(GL_SHADER_STORAGE_BUFFER, GL_BUFFER_SIZE, &size);
+ return (size > 0) ? (unsigned int)size : 0;
#else
- return 0;
+ return 0;
#endif
}
// Read SSBO buffer data (GPU->CPU)
-void rlReadShaderBuffer(unsigned int id, void *dest, unsigned int count, unsigned int offset)
-{
+void rlReadShaderBuffer(unsigned int id, void* dest, unsigned int count, unsigned int offset) {
#if defined(GRAPHICS_API_OPENGL_43)
- glBindBuffer(GL_SHADER_STORAGE_BUFFER, id);
- glGetBufferSubData(GL_SHADER_STORAGE_BUFFER, offset, count, dest);
+ glBindBuffer(GL_SHADER_STORAGE_BUFFER, id);
+ glGetBufferSubData(GL_SHADER_STORAGE_BUFFER, offset, count, dest);
#endif
}
// Bind SSBO buffer
-void rlBindShaderBuffer(unsigned int id, unsigned int index)
-{
+void rlBindShaderBuffer(unsigned int id, unsigned int index) {
#if defined(GRAPHICS_API_OPENGL_43)
- glBindBufferBase(GL_SHADER_STORAGE_BUFFER, index, id);
+ glBindBufferBase(GL_SHADER_STORAGE_BUFFER, index, id);
#endif
}
// Copy SSBO buffer data
-void rlCopyShaderBuffer(unsigned int destId, unsigned int srcId, unsigned int destOffset, unsigned int srcOffset, unsigned int count)
-{
+void rlCopyShaderBuffer(unsigned int destId, unsigned int srcId, unsigned int destOffset, unsigned int srcOffset, unsigned int count) {
#if defined(GRAPHICS_API_OPENGL_43)
- glBindBuffer(GL_COPY_READ_BUFFER, srcId);
- glBindBuffer(GL_COPY_WRITE_BUFFER, destId);
- glCopyBufferSubData(GL_COPY_READ_BUFFER, GL_COPY_WRITE_BUFFER, srcOffset, destOffset, count);
+ glBindBuffer(GL_COPY_READ_BUFFER, srcId);
+ glBindBuffer(GL_COPY_WRITE_BUFFER, destId);
+ glCopyBufferSubData(GL_COPY_READ_BUFFER, GL_COPY_WRITE_BUFFER, srcOffset, destOffset, count);
#endif
}
// Bind image texture
-void rlBindImageTexture(unsigned int id, unsigned int index, int format, bool readonly)
-{
+void rlBindImageTexture(unsigned int id, unsigned int index, int format, bool readonly) {
#if defined(GRAPHICS_API_OPENGL_43)
- unsigned int glInternalFormat = 0, glFormat = 0, glType = 0;
+ unsigned int glInternalFormat = 0, glFormat = 0, glType = 0;
- rlGetGlTextureFormats(format, &glInternalFormat, &glFormat, &glType);
- glBindImageTexture(index, id, 0, 0, 0, readonly? GL_READ_ONLY : GL_READ_WRITE, glInternalFormat);
+ rlGetGlTextureFormats(format, &glInternalFormat, &glFormat, &glType);
+ glBindImageTexture(index, id, 0, 0, 0, readonly ? GL_READ_ONLY : GL_READ_WRITE, glInternalFormat);
#else
- TRACELOG(RL_LOG_WARNING, "TEXTURE: Image texture binding not enabled. Define GRAPHICS_API_OPENGL_43");
+ TRACELOG(RL_LOG_WARNING, "TEXTURE: Image texture binding not enabled. Define GRAPHICS_API_OPENGL_43");
#endif
}
// RLMatrix state management
//-----------------------------------------------------------------------------------------
// Get internal modelview matrix
-RLMatrix rlGetMatrixModelview(void)
-{
- RLMatrix matrix = rlMatrixIdentity();
+RLMatrix rlGetMatrixModelview(void) {
+ RLMatrix matrix = rlMatrixIdentity();
#if defined(GRAPHICS_API_OPENGL_11)
- float mat[16];
- glGetFloatv(GL_MODELVIEW_MATRIX, mat);
- matrix.m0 = mat[0];
- matrix.m1 = mat[1];
- matrix.m2 = mat[2];
- matrix.m3 = mat[3];
- matrix.m4 = mat[4];
- matrix.m5 = mat[5];
- matrix.m6 = mat[6];
- matrix.m7 = mat[7];
- matrix.m8 = mat[8];
- matrix.m9 = mat[9];
- matrix.m10 = mat[10];
- matrix.m11 = mat[11];
- matrix.m12 = mat[12];
- matrix.m13 = mat[13];
- matrix.m14 = mat[14];
- matrix.m15 = mat[15];
+ float mat[16];
+ glGetFloatv(GL_MODELVIEW_MATRIX, mat);
+ matrix.m0 = mat[0];
+ matrix.m1 = mat[1];
+ matrix.m2 = mat[2];
+ matrix.m3 = mat[3];
+ matrix.m4 = mat[4];
+ matrix.m5 = mat[5];
+ matrix.m6 = mat[6];
+ matrix.m7 = mat[7];
+ matrix.m8 = mat[8];
+ matrix.m9 = mat[9];
+ matrix.m10 = mat[10];
+ matrix.m11 = mat[11];
+ matrix.m12 = mat[12];
+ matrix.m13 = mat[13];
+ matrix.m14 = mat[14];
+ matrix.m15 = mat[15];
#else
- matrix = RLGL.State.modelview;
+ matrix = RLGL.State.modelview;
#endif
- return matrix;
+ return matrix;
}
// Get internal projection matrix
-RLMatrix rlGetMatrixProjection(void)
-{
+RLMatrix rlGetMatrixProjection(void) {
#if defined(GRAPHICS_API_OPENGL_11)
- float mat[16];
- glGetFloatv(GL_PROJECTION_MATRIX,mat);
- RLMatrix m;
- m.m0 = mat[0];
- m.m1 = mat[1];
- m.m2 = mat[2];
- m.m3 = mat[3];
- m.m4 = mat[4];
- m.m5 = mat[5];
- m.m6 = mat[6];
- m.m7 = mat[7];
- m.m8 = mat[8];
- m.m9 = mat[9];
- m.m10 = mat[10];
- m.m11 = mat[11];
- m.m12 = mat[12];
- m.m13 = mat[13];
- m.m14 = mat[14];
- m.m15 = mat[15];
- return m;
+ float mat[16];
+ glGetFloatv(GL_PROJECTION_MATRIX, mat);
+ RLMatrix m;
+ m.m0 = mat[0];
+ m.m1 = mat[1];
+ m.m2 = mat[2];
+ m.m3 = mat[3];
+ m.m4 = mat[4];
+ m.m5 = mat[5];
+ m.m6 = mat[6];
+ m.m7 = mat[7];
+ m.m8 = mat[8];
+ m.m9 = mat[9];
+ m.m10 = mat[10];
+ m.m11 = mat[11];
+ m.m12 = mat[12];
+ m.m13 = mat[13];
+ m.m14 = mat[14];
+ m.m15 = mat[15];
+ return m;
#else
- return RLGL.State.projection;
+ return RLGL.State.projection;
#endif
}
// Get internal accumulated transform matrix
-RLMatrix rlGetMatrixTransform(void)
-{
- RLMatrix mat = rlMatrixIdentity();
+RLMatrix rlGetMatrixTransform(void) {
+ RLMatrix mat = rlMatrixIdentity();
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- // TODO: Consider possible transform matrices in the RLGL.State.stack
- // Is this the right order? or should we start with the first stored matrix instead of the last one?
- //Matrix matStackTransform = rlMatrixIdentity();
- //for (int i = RLGL.State.stackCounter; i > 0; i--) matStackTransform = rlMatrixMultiply(RLGL.State.stack[i], matStackTransform);
- mat = RLGL.State.transform;
+ // TODO: Consider possible transform matrices in the RLGL.State.stack
+ // Is this the right order? or should we start with the first stored matrix instead of the last one?
+ // Matrix matStackTransform = rlMatrixIdentity();
+ // for (int i = RLGL.State.stackCounter; i > 0; i--) matStackTransform = rlMatrixMultiply(RLGL.State.stack[i], matStackTransform);
+ mat = RLGL.State.transform;
#endif
- return mat;
+ return mat;
}
// Get internal projection matrix for stereo render (selected eye)
-RLMatrix rlGetMatrixProjectionStereo(int eye)
-{
- RLMatrix mat = rlMatrixIdentity();
+RLMatrix rlGetMatrixProjectionStereo(int eye) {
+ RLMatrix mat = rlMatrixIdentity();
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- mat = RLGL.State.projectionStereo[eye];
+ mat = RLGL.State.projectionStereo[eye];
#endif
- return mat;
+ return mat;
}
// Get internal view offset matrix for stereo render (selected eye)
-RLMatrix rlGetMatrixViewOffsetStereo(int eye)
-{
- RLMatrix mat = rlMatrixIdentity();
+RLMatrix rlGetMatrixViewOffsetStereo(int eye) {
+ RLMatrix mat = rlMatrixIdentity();
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- mat = RLGL.State.viewOffsetStereo[eye];
+ mat = RLGL.State.viewOffsetStereo[eye];
#endif
- return mat;
+ return mat;
}
// Set a custom modelview matrix (replaces internal modelview matrix)
-void rlSetMatrixModelview(RLMatrix view)
-{
+void rlSetMatrixModelview(RLMatrix view) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- RLGL.State.modelview = view;
+ RLGL.State.modelview = view;
#endif
}
// Set a custom projection matrix (replaces internal projection matrix)
-void rlSetMatrixProjection(RLMatrix projection)
-{
+void rlSetMatrixProjection(RLMatrix projection) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- RLGL.State.projection = projection;
+ RLGL.State.projection = projection;
#endif
}
// Set eyes projection matrices for stereo rendering
-void rlSetMatrixProjectionStereo(RLMatrix right, RLMatrix left)
-{
+void rlSetMatrixProjectionStereo(RLMatrix right, RLMatrix left) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- RLGL.State.projectionStereo[0] = right;
- RLGL.State.projectionStereo[1] = left;
+ RLGL.State.projectionStereo[0] = right;
+ RLGL.State.projectionStereo[1] = left;
#endif
}
// Set eyes view offsets matrices for stereo rendering
-void rlSetMatrixViewOffsetStereo(RLMatrix right, RLMatrix left)
-{
+void rlSetMatrixViewOffsetStereo(RLMatrix right, RLMatrix left) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- RLGL.State.viewOffsetStereo[0] = right;
- RLGL.State.viewOffsetStereo[1] = left;
+ RLGL.State.viewOffsetStereo[0] = right;
+ RLGL.State.viewOffsetStereo[1] = left;
#endif
}
// Load and draw a quad in NDC
-void rlLoadDrawQuad(void)
-{
+void rlLoadDrawQuad(void) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- unsigned int quadVAO = 0;
- unsigned int quadVBO = 0;
-
- float vertices[] = {
- // Positions Texcoords
- -1.0f, 1.0f, 0.0f, 0.0f, 1.0f,
- -1.0f, -1.0f, 0.0f, 0.0f, 0.0f,
- 1.0f, 1.0f, 0.0f, 1.0f, 1.0f,
- 1.0f, -1.0f, 0.0f, 1.0f, 0.0f,
- };
-
- // Gen VAO to contain VBO
- glGenVertexArrays(1, &quadVAO);
- glBindVertexArray(quadVAO);
-
- // Gen and fill vertex buffer (VBO)
- glGenBuffers(1, &quadVBO);
- glBindBuffer(GL_ARRAY_BUFFER, quadVBO);
- glBufferData(GL_ARRAY_BUFFER, sizeof(vertices), &vertices, GL_STATIC_DRAW);
-
- // Bind vertex attributes (position, texcoords)
- glEnableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION);
- glVertexAttribPointer(RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION, 3, GL_FLOAT, GL_FALSE, 5*sizeof(float), (void *)0); // Positions
- glEnableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD);
- glVertexAttribPointer(RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD, 2, GL_FLOAT, GL_FALSE, 5*sizeof(float), (void *)(3*sizeof(float))); // Texcoords
-
- // Draw quad
- glBindVertexArray(quadVAO);
- glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
- glBindVertexArray(0);
-
- // Delete buffers (VBO and VAO)
- glDeleteBuffers(1, &quadVBO);
- glDeleteVertexArrays(1, &quadVAO);
+ unsigned int quadVAO = 0;
+ unsigned int quadVBO = 0;
+
+ float vertices[] = {
+ // Positions Texcoords
+ -1.0f,
+ 1.0f,
+ 0.0f,
+ 0.0f,
+ 1.0f,
+ -1.0f,
+ -1.0f,
+ 0.0f,
+ 0.0f,
+ 0.0f,
+ 1.0f,
+ 1.0f,
+ 0.0f,
+ 1.0f,
+ 1.0f,
+ 1.0f,
+ -1.0f,
+ 0.0f,
+ 1.0f,
+ 0.0f,
+ };
+
+ // Gen VAO to contain VBO
+ glGenVertexArrays(1, &quadVAO);
+ glBindVertexArray(quadVAO);
+
+ // Gen and fill vertex buffer (VBO)
+ glGenBuffers(1, &quadVBO);
+ glBindBuffer(GL_ARRAY_BUFFER, quadVBO);
+ glBufferData(GL_ARRAY_BUFFER, sizeof(vertices), &vertices, GL_STATIC_DRAW);
+
+ // Bind vertex attributes (position, texcoords)
+ glEnableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION);
+ glVertexAttribPointer(RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION, 3, GL_FLOAT, GL_FALSE, 5 * sizeof(float), (void*)0); // Positions
+ glEnableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD);
+ glVertexAttribPointer(RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD, 2, GL_FLOAT, GL_FALSE, 5 * sizeof(float), (void*)(3 * sizeof(float))); // Texcoords
+
+ // Draw quad
+ glBindVertexArray(quadVAO);
+ glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
+ glBindVertexArray(0);
+
+ // Delete buffers (VBO and VAO)
+ glDeleteBuffers(1, &quadVBO);
+ glDeleteVertexArrays(1, &quadVAO);
#endif
}
// Load and draw a cube in NDC
-void rlLoadDrawCube(void)
-{
+void rlLoadDrawCube(void) {
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- unsigned int cubeVAO = 0;
- unsigned int cubeVBO = 0;
-
- float vertices[] = {
- // Positions Normals Texcoords
- -1.0f, -1.0f, -1.0f, 0.0f, 0.0f, -1.0f, 0.0f, 0.0f,
- 1.0f, 1.0f, -1.0f, 0.0f, 0.0f, -1.0f, 1.0f, 1.0f,
- 1.0f, -1.0f, -1.0f, 0.0f, 0.0f, -1.0f, 1.0f, 0.0f,
- 1.0f, 1.0f, -1.0f, 0.0f, 0.0f, -1.0f, 1.0f, 1.0f,
- -1.0f, -1.0f, -1.0f, 0.0f, 0.0f, -1.0f, 0.0f, 0.0f,
- -1.0f, 1.0f, -1.0f, 0.0f, 0.0f, -1.0f, 0.0f, 1.0f,
- -1.0f, -1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 0.0f, 0.0f,
- 1.0f, -1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 0.0f,
- 1.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 1.0f,
- 1.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 1.0f,
- -1.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 0.0f, 1.0f,
- -1.0f, -1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 0.0f, 0.0f,
- -1.0f, 1.0f, 1.0f, -1.0f, 0.0f, 0.0f, 1.0f, 0.0f,
- -1.0f, 1.0f, -1.0f, -1.0f, 0.0f, 0.0f, 1.0f, 1.0f,
- -1.0f, -1.0f, -1.0f, -1.0f, 0.0f, 0.0f, 0.0f, 1.0f,
- -1.0f, -1.0f, -1.0f, -1.0f, 0.0f, 0.0f, 0.0f, 1.0f,
- -1.0f, -1.0f, 1.0f, -1.0f, 0.0f, 0.0f, 0.0f, 0.0f,
- -1.0f, 1.0f, 1.0f, -1.0f, 0.0f, 0.0f, 1.0f, 0.0f,
- 1.0f, 1.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 0.0f,
- 1.0f, -1.0f, -1.0f, 1.0f, 0.0f, 0.0f, 0.0f, 1.0f,
- 1.0f, 1.0f, -1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f,
- 1.0f, -1.0f, -1.0f, 1.0f, 0.0f, 0.0f, 0.0f, 1.0f,
- 1.0f, 1.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 0.0f,
- 1.0f, -1.0f, 1.0f, 1.0f, 0.0f, 0.0f, 0.0f, 0.0f,
- -1.0f, -1.0f, -1.0f, 0.0f, -1.0f, 0.0f, 0.0f, 1.0f,
- 1.0f, -1.0f, -1.0f, 0.0f, -1.0f, 0.0f, 1.0f, 1.0f,
- 1.0f, -1.0f, 1.0f, 0.0f, -1.0f, 0.0f, 1.0f, 0.0f,
- 1.0f, -1.0f, 1.0f, 0.0f, -1.0f, 0.0f, 1.0f, 0.0f,
- -1.0f, -1.0f, 1.0f, 0.0f, -1.0f, 0.0f, 0.0f, 0.0f,
- -1.0f, -1.0f, -1.0f, 0.0f, -1.0f, 0.0f, 0.0f, 1.0f,
- -1.0f, 1.0f, -1.0f, 0.0f, 1.0f, 0.0f, 0.0f, 1.0f,
- 1.0f, 1.0f, 1.0f, 0.0f, 1.0f, 0.0f, 1.0f, 0.0f,
- 1.0f, 1.0f, -1.0f, 0.0f, 1.0f, 0.0f, 1.0f, 1.0f,
- 1.0f, 1.0f, 1.0f, 0.0f, 1.0f, 0.0f, 1.0f, 0.0f,
- -1.0f, 1.0f, -1.0f, 0.0f, 1.0f, 0.0f, 0.0f, 1.0f,
- -1.0f, 1.0f, 1.0f, 0.0f, 1.0f, 0.0f, 0.0f, 0.0f
- };
-
- // Gen VAO to contain VBO
- glGenVertexArrays(1, &cubeVAO);
- glBindVertexArray(cubeVAO);
-
- // Gen and fill vertex buffer (VBO)
- glGenBuffers(1, &cubeVBO);
- glBindBuffer(GL_ARRAY_BUFFER, cubeVBO);
- glBufferData(GL_ARRAY_BUFFER, sizeof(vertices), vertices, GL_STATIC_DRAW);
-
- // Bind vertex attributes (position, normals, texcoords)
- glBindVertexArray(cubeVAO);
- glEnableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION);
- glVertexAttribPointer(RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION, 3, GL_FLOAT, GL_FALSE, 8*sizeof(float), (void *)0); // Positions
- glEnableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL);
- glVertexAttribPointer(RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL, 3, GL_FLOAT, GL_FALSE, 8*sizeof(float), (void *)(3*sizeof(float))); // Normals
- glEnableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD);
- glVertexAttribPointer(RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD, 2, GL_FLOAT, GL_FALSE, 8*sizeof(float), (void *)(6*sizeof(float))); // Texcoords
- glBindBuffer(GL_ARRAY_BUFFER, 0);
- glBindVertexArray(0);
-
- // Draw cube
- glBindVertexArray(cubeVAO);
- glDrawArrays(GL_TRIANGLES, 0, 36);
- glBindVertexArray(0);
-
- // Delete VBO and VAO
- glDeleteBuffers(1, &cubeVBO);
- glDeleteVertexArrays(1, &cubeVAO);
+ unsigned int cubeVAO = 0;
+ unsigned int cubeVBO = 0;
+
+ float vertices[] = {
+ // Positions Normals Texcoords
+ -1.0f, -1.0f, -1.0f, 0.0f, 0.0f, -1.0f, 0.0f, 0.0f,
+ 1.0f, 1.0f, -1.0f, 0.0f, 0.0f, -1.0f, 1.0f, 1.0f,
+ 1.0f, -1.0f, -1.0f, 0.0f, 0.0f, -1.0f, 1.0f, 0.0f,
+ 1.0f, 1.0f, -1.0f, 0.0f, 0.0f, -1.0f, 1.0f, 1.0f,
+ -1.0f, -1.0f, -1.0f, 0.0f, 0.0f, -1.0f, 0.0f, 0.0f,
+ -1.0f, 1.0f, -1.0f, 0.0f, 0.0f, -1.0f, 0.0f, 1.0f,
+ -1.0f, -1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 0.0f, 0.0f,
+ 1.0f, -1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 0.0f,
+ 1.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 1.0f,
+ 1.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 1.0f,
+ -1.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 0.0f, 1.0f,
+ -1.0f, -1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 0.0f, 0.0f,
+ -1.0f, 1.0f, 1.0f, -1.0f, 0.0f, 0.0f, 1.0f, 0.0f,
+ -1.0f, 1.0f, -1.0f, -1.0f, 0.0f, 0.0f, 1.0f, 1.0f,
+ -1.0f, -1.0f, -1.0f, -1.0f, 0.0f, 0.0f, 0.0f, 1.0f,
+ -1.0f, -1.0f, -1.0f, -1.0f, 0.0f, 0.0f, 0.0f, 1.0f,
+ -1.0f, -1.0f, 1.0f, -1.0f, 0.0f, 0.0f, 0.0f, 0.0f,
+ -1.0f, 1.0f, 1.0f, -1.0f, 0.0f, 0.0f, 1.0f, 0.0f,
+ 1.0f, 1.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 0.0f,
+ 1.0f, -1.0f, -1.0f, 1.0f, 0.0f, 0.0f, 0.0f, 1.0f,
+ 1.0f, 1.0f, -1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f,
+ 1.0f, -1.0f, -1.0f, 1.0f, 0.0f, 0.0f, 0.0f, 1.0f,
+ 1.0f, 1.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 0.0f,
+ 1.0f, -1.0f, 1.0f, 1.0f, 0.0f, 0.0f, 0.0f, 0.0f,
+ -1.0f, -1.0f, -1.0f, 0.0f, -1.0f, 0.0f, 0.0f, 1.0f,
+ 1.0f, -1.0f, -1.0f, 0.0f, -1.0f, 0.0f, 1.0f, 1.0f,
+ 1.0f, -1.0f, 1.0f, 0.0f, -1.0f, 0.0f, 1.0f, 0.0f,
+ 1.0f, -1.0f, 1.0f, 0.0f, -1.0f, 0.0f, 1.0f, 0.0f,
+ -1.0f, -1.0f, 1.0f, 0.0f, -1.0f, 0.0f, 0.0f, 0.0f,
+ -1.0f, -1.0f, -1.0f, 0.0f, -1.0f, 0.0f, 0.0f, 1.0f,
+ -1.0f, 1.0f, -1.0f, 0.0f, 1.0f, 0.0f, 0.0f, 1.0f,
+ 1.0f, 1.0f, 1.0f, 0.0f, 1.0f, 0.0f, 1.0f, 0.0f,
+ 1.0f, 1.0f, -1.0f, 0.0f, 1.0f, 0.0f, 1.0f, 1.0f,
+ 1.0f, 1.0f, 1.0f, 0.0f, 1.0f, 0.0f, 1.0f, 0.0f,
+ -1.0f, 1.0f, -1.0f, 0.0f, 1.0f, 0.0f, 0.0f, 1.0f,
+ -1.0f, 1.0f, 1.0f, 0.0f, 1.0f, 0.0f, 0.0f, 0.0f};
+
+ // Gen VAO to contain VBO
+ glGenVertexArrays(1, &cubeVAO);
+ glBindVertexArray(cubeVAO);
+
+ // Gen and fill vertex buffer (VBO)
+ glGenBuffers(1, &cubeVBO);
+ glBindBuffer(GL_ARRAY_BUFFER, cubeVBO);
+ glBufferData(GL_ARRAY_BUFFER, sizeof(vertices), vertices, GL_STATIC_DRAW);
+
+ // Bind vertex attributes (position, normals, texcoords)
+ glBindVertexArray(cubeVAO);
+ glEnableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION);
+ glVertexAttribPointer(RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION, 3, GL_FLOAT, GL_FALSE, 8 * sizeof(float), (void*)0); // Positions
+ glEnableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL);
+ glVertexAttribPointer(RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL, 3, GL_FLOAT, GL_FALSE, 8 * sizeof(float), (void*)(3 * sizeof(float))); // Normals
+ glEnableVertexAttribArray(RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD);
+ glVertexAttribPointer(RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD, 2, GL_FLOAT, GL_FALSE, 8 * sizeof(float), (void*)(6 * sizeof(float))); // Texcoords
+ glBindBuffer(GL_ARRAY_BUFFER, 0);
+ glBindVertexArray(0);
+
+ // Draw cube
+ glBindVertexArray(cubeVAO);
+ glDrawArrays(GL_TRIANGLES, 0, 36);
+ glBindVertexArray(0);
+
+ // Delete VBO and VAO
+ glDeleteBuffers(1, &cubeVBO);
+ glDeleteVertexArrays(1, &cubeVAO);
#endif
}
// Get name string for pixel format
-const char *rlGetPixelFormatName(unsigned int format)
-{
- switch (format)
- {
- case RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE: return "GRAYSCALE"; break; // 8 bit per pixel (no alpha)
- case RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA: return "GRAY_ALPHA"; break; // 8*2 bpp (2 channels)
- case RL_PIXELFORMAT_UNCOMPRESSED_R5G6B5: return "R5G6B5"; break; // 16 bpp
- case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8: return "R8G8B8"; break; // 24 bpp
- case RL_PIXELFORMAT_UNCOMPRESSED_R5G5B5A1: return "R5G5B5A1"; break; // 16 bpp (1 bit alpha)
- case RL_PIXELFORMAT_UNCOMPRESSED_R4G4B4A4: return "R4G4B4A4"; break; // 16 bpp (4 bit alpha)
- case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8: return "R8G8B8A8"; break; // 32 bpp
- case RL_PIXELFORMAT_UNCOMPRESSED_R32: return "R32"; break; // 32 bpp (1 channel - float)
- case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32: return "R32G32B32"; break; // 32*3 bpp (3 channels - float)
- case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32: return "R32G32B32A32"; break; // 32*4 bpp (4 channels - float)
- case RL_PIXELFORMAT_UNCOMPRESSED_R16: return "R16"; break; // 16 bpp (1 channel - half float)
- case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16: return "R16G16B16"; break; // 16*3 bpp (3 channels - half float)
- case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16: return "R16G16B16A16"; break; // 16*4 bpp (4 channels - half float)
- case RL_PIXELFORMAT_COMPRESSED_DXT1_RGB: return "DXT1_RGB"; break; // 4 bpp (no alpha)
- case RL_PIXELFORMAT_COMPRESSED_DXT1_RGBA: return "DXT1_RGBA"; break; // 4 bpp (1 bit alpha)
- case RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA: return "DXT3_RGBA"; break; // 8 bpp
- case RL_PIXELFORMAT_COMPRESSED_DXT5_RGBA: return "DXT5_RGBA"; break; // 8 bpp
- case RL_PIXELFORMAT_COMPRESSED_ETC1_RGB: return "ETC1_RGB"; break; // 4 bpp
- case RL_PIXELFORMAT_COMPRESSED_ETC2_RGB: return "ETC2_RGB"; break; // 4 bpp
- case RL_PIXELFORMAT_COMPRESSED_ETC2_EAC_RGBA: return "ETC2_RGBA"; break; // 8 bpp
- case RL_PIXELFORMAT_COMPRESSED_PVRT_RGB: return "PVRT_RGB"; break; // 4 bpp
- case RL_PIXELFORMAT_COMPRESSED_PVRT_RGBA: return "PVRT_RGBA"; break; // 4 bpp
- case RL_PIXELFORMAT_COMPRESSED_ASTC_4x4_RGBA: return "ASTC_4x4_RGBA"; break; // 8 bpp
- case RL_PIXELFORMAT_COMPRESSED_ASTC_8x8_RGBA: return "ASTC_8x8_RGBA"; break; // 2 bpp
- default: return "UNKNOWN"; break;
- }
+const char* rlGetPixelFormatName(unsigned int format) {
+ switch (format) {
+ case RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE:
+ return "GRAYSCALE";
+ break; // 8 bit per pixel (no alpha)
+ case RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA:
+ return "GRAY_ALPHA";
+ break; // 8*2 bpp (2 channels)
+ case RL_PIXELFORMAT_UNCOMPRESSED_R5G6B5:
+ return "R5G6B5";
+ break; // 16 bpp
+ case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8:
+ return "R8G8B8";
+ break; // 24 bpp
+ case RL_PIXELFORMAT_UNCOMPRESSED_R5G5B5A1:
+ return "R5G5B5A1";
+ break; // 16 bpp (1 bit alpha)
+ case RL_PIXELFORMAT_UNCOMPRESSED_R4G4B4A4:
+ return "R4G4B4A4";
+ break; // 16 bpp (4 bit alpha)
+ case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8:
+ return "R8G8B8A8";
+ break; // 32 bpp
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32:
+ return "R32";
+ break; // 32 bpp (1 channel - float)
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32:
+ return "R32G32B32";
+ break; // 32*3 bpp (3 channels - float)
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32:
+ return "R32G32B32A32";
+ break; // 32*4 bpp (4 channels - float)
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16:
+ return "R16";
+ break; // 16 bpp (1 channel - half float)
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16:
+ return "R16G16B16";
+ break; // 16*3 bpp (3 channels - half float)
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16:
+ return "R16G16B16A16";
+ break; // 16*4 bpp (4 channels - half float)
+ case RL_PIXELFORMAT_COMPRESSED_DXT1_RGB:
+ return "DXT1_RGB";
+ break; // 4 bpp (no alpha)
+ case RL_PIXELFORMAT_COMPRESSED_DXT1_RGBA:
+ return "DXT1_RGBA";
+ break; // 4 bpp (1 bit alpha)
+ case RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA:
+ return "DXT3_RGBA";
+ break; // 8 bpp
+ case RL_PIXELFORMAT_COMPRESSED_DXT5_RGBA:
+ return "DXT5_RGBA";
+ break; // 8 bpp
+ case RL_PIXELFORMAT_COMPRESSED_ETC1_RGB:
+ return "ETC1_RGB";
+ break; // 4 bpp
+ case RL_PIXELFORMAT_COMPRESSED_ETC2_RGB:
+ return "ETC2_RGB";
+ break; // 4 bpp
+ case RL_PIXELFORMAT_COMPRESSED_ETC2_EAC_RGBA:
+ return "ETC2_RGBA";
+ break; // 8 bpp
+ case RL_PIXELFORMAT_COMPRESSED_PVRT_RGB:
+ return "PVRT_RGB";
+ break; // 4 bpp
+ case RL_PIXELFORMAT_COMPRESSED_PVRT_RGBA:
+ return "PVRT_RGBA";
+ break; // 4 bpp
+ case RL_PIXELFORMAT_COMPRESSED_ASTC_4x4_RGBA:
+ return "ASTC_4x4_RGBA";
+ break; // 8 bpp
+ case RL_PIXELFORMAT_COMPRESSED_ASTC_8x8_RGBA:
+ return "ASTC_8x8_RGBA";
+ break; // 2 bpp
+ default:
+ return "UNKNOWN";
+ break;
+ }
}
//----------------------------------------------------------------------------------
@@ -4051,415 +4395,547 @@ const char *rlGetPixelFormatName(unsigned int format)
// Load default shader (just vertex positioning and texture coloring)
// NOTE: This shader program is used for internal buffers
// NOTE: Loaded: RLGL.State.defaultShaderId, RLGL.State.defaultShaderLocs
-static void rlLoadShaderDefault(void)
-{
- RLGL.State.defaultShaderLocs = (int *)RL_CALLOC(RL_MAX_SHADER_LOCATIONS, sizeof(int));
+static void rlLoadShaderDefault(void) {
+ RLGL.State.defaultShaderLocs = (int*)RL_CALLOC(RL_MAX_SHADER_LOCATIONS, sizeof(int));
- // NOTE: All locations must be reseted to -1 (no location)
- for (int i = 0; i < RL_MAX_SHADER_LOCATIONS; i++) RLGL.State.defaultShaderLocs[i] = -1;
+ // NOTE: All locations must be reseted to -1 (no location)
+ for (int i = 0; i < RL_MAX_SHADER_LOCATIONS; i++)
+ RLGL.State.defaultShaderLocs[i] = -1;
- // Vertex shader directly defined, no external file required
- const char *defaultVShaderCode =
+ // Vertex shader directly defined, no external file required
+ const char* defaultVShaderCode =
#if defined(GRAPHICS_API_OPENGL_21)
- "#version 120 \n"
- "attribute vec3 vertexPosition; \n"
- "attribute vec2 vertexTexCoord; \n"
- "attribute vec4 vertexColor; \n"
- "varying vec2 fragTexCoord; \n"
- "varying vec4 fragColor; \n"
+ "#version 120 \n"
+ "attribute vec3 vertexPosition; \n"
+ "attribute vec2 vertexTexCoord; \n"
+ "attribute vec4 vertexColor; \n"
+ "varying vec2 fragTexCoord; \n"
+ "varying vec4 fragColor; \n"
#elif defined(GRAPHICS_API_OPENGL_33)
- "#version 330 \n"
- "in vec3 vertexPosition; \n"
- "in vec2 vertexTexCoord; \n"
- "in vec4 vertexColor; \n"
- "out vec2 fragTexCoord; \n"
- "out vec4 fragColor; \n"
+ "#version 330 \n"
+ "in vec3 vertexPosition; \n"
+ "in vec2 vertexTexCoord; \n"
+ "in vec4 vertexColor; \n"
+ "out vec2 fragTexCoord; \n"
+ "out vec4 fragColor; \n"
#endif
#if defined(GRAPHICS_API_OPENGL_ES3)
- "#version 300 es \n"
- "precision mediump float; \n" // Precision required for OpenGL ES3 (WebGL 2) (on some browsers)
- "in vec3 vertexPosition; \n"
- "in vec2 vertexTexCoord; \n"
- "in vec4 vertexColor; \n"
- "out vec2 fragTexCoord; \n"
- "out vec4 fragColor; \n"
+ "#version 300 es \n"
+ "precision mediump float; \n" // Precision required for OpenGL ES3 (WebGL 2) (on some browsers)
+ "in vec3 vertexPosition; \n"
+ "in vec2 vertexTexCoord; \n"
+ "in vec4 vertexColor; \n"
+ "out vec2 fragTexCoord; \n"
+ "out vec4 fragColor; \n"
#elif defined(GRAPHICS_API_OPENGL_ES2)
- "#version 100 \n"
- "precision mediump float; \n" // Precision required for OpenGL ES2 (WebGL) (on some browsers)
- "attribute vec3 vertexPosition; \n"
- "attribute vec2 vertexTexCoord; \n"
- "attribute vec4 vertexColor; \n"
- "varying vec2 fragTexCoord; \n"
- "varying vec4 fragColor; \n"
-#endif
-
- "uniform mat4 mvp; \n"
- "void main() \n"
- "{ \n"
- " fragTexCoord = vertexTexCoord; \n"
- " fragColor = vertexColor; \n"
- " gl_Position = mvp*vec4(vertexPosition, 1.0); \n"
- "} \n";
-
- // Fragment shader directly defined, no external file required
- const char *defaultFShaderCode =
+ "#version 100 \n"
+ "precision mediump float; \n" // Precision required for OpenGL ES2 (WebGL) (on some browsers)
+ "attribute vec3 vertexPosition; \n"
+ "attribute vec2 vertexTexCoord; \n"
+ "attribute vec4 vertexColor; \n"
+ "varying vec2 fragTexCoord; \n"
+ "varying vec4 fragColor; \n"
+#endif
+
+ "uniform mat4 mvp; \n"
+ "void main() \n"
+ "{ \n"
+ " fragTexCoord = vertexTexCoord; \n"
+ " fragColor = vertexColor; \n"
+ " gl_Position = mvp*vec4(vertexPosition, 1.0); \n"
+ "} \n";
+
+ // Fragment shader directly defined, no external file required
+ const char* defaultFShaderCode =
#if defined(GRAPHICS_API_OPENGL_21)
- "#version 120 \n"
- "varying vec2 fragTexCoord; \n"
- "varying vec4 fragColor; \n"
- "uniform sampler2D texture0; \n"
- "uniform vec4 colDiffuse; \n"
- "void main() \n"
- "{ \n"
- " vec4 texelColor = texture2D(texture0, fragTexCoord); \n"
- " gl_FragColor = texelColor*colDiffuse*fragColor; \n"
- "} \n";
+ "#version 120 \n"
+ "varying vec2 fragTexCoord; \n"
+ "varying vec4 fragColor; \n"
+ "uniform sampler2D texture0; \n"
+ "uniform vec4 colDiffuse; \n"
+ "void main() \n"
+ "{ \n"
+ " vec4 texelColor = texture2D(texture0, fragTexCoord); \n"
+ " gl_FragColor = texelColor*colDiffuse*fragColor; \n"
+ "} \n";
#elif defined(GRAPHICS_API_OPENGL_33)
- "#version 330 \n"
- "in vec2 fragTexCoord; \n"
- "in vec4 fragColor; \n"
- "out vec4 finalColor; \n"
- "uniform sampler2D texture0; \n"
- "uniform vec4 colDiffuse; \n"
- "void main() \n"
- "{ \n"
- " vec4 texelColor = texture(texture0, fragTexCoord); \n"
- " finalColor = texelColor*colDiffuse*fragColor; \n"
- "} \n";
+ "#version 330 \n"
+ "in vec2 fragTexCoord; \n"
+ "in vec4 fragColor; \n"
+ "out vec4 finalColor; \n"
+ "uniform sampler2D texture0; \n"
+ "uniform vec4 colDiffuse = vec4(1.0); \n"
+ "void main() \n"
+ "{ \n"
+ " vec4 texelColor = texture(texture0, fragTexCoord); \n"
+ " finalColor = texelColor*colDiffuse*fragColor; \n"
+ "} \n";
#endif
#if defined(GRAPHICS_API_OPENGL_ES3)
- "#version 300 es \n"
- "precision mediump float; \n" // Precision required for OpenGL ES3 (WebGL 2)
- "in vec2 fragTexCoord; \n"
- "in vec4 fragColor; \n"
- "out vec4 finalColor; \n"
- "uniform sampler2D texture0; \n"
- "uniform vec4 colDiffuse; \n"
- "void main() \n"
- "{ \n"
- " vec4 texelColor = texture(texture0, fragTexCoord); \n"
- " finalColor = texelColor*colDiffuse*fragColor; \n"
- "} \n";
+ "#version 300 es \n"
+ "precision mediump float; \n" // Precision required for OpenGL ES3 (WebGL 2)
+ "in vec2 fragTexCoord; \n"
+ "in vec4 fragColor; \n"
+ "out vec4 finalColor; \n"
+ "uniform sampler2D texture0; \n"
+ "uniform vec4 colDiffuse; \n"
+ "void main() \n"
+ "{ \n"
+ " vec4 texelColor = texture(texture0, fragTexCoord); \n"
+ " finalColor = texelColor*colDiffuse*fragColor; \n"
+ "} \n";
#elif defined(GRAPHICS_API_OPENGL_ES2)
- "#version 100 \n"
- "precision mediump float; \n" // Precision required for OpenGL ES2 (WebGL)
- "varying vec2 fragTexCoord; \n"
- "varying vec4 fragColor; \n"
- "uniform sampler2D texture0; \n"
- "uniform vec4 colDiffuse; \n"
- "void main() \n"
- "{ \n"
- " vec4 texelColor = texture2D(texture0, fragTexCoord); \n"
- " gl_FragColor = texelColor*colDiffuse*fragColor; \n"
- "} \n";
-#endif
-
- // NOTE: Compiled vertex/fragment shaders are not deleted,
- // they are kept for re-use as default shaders in case some shader loading fails
- RLGL.State.defaultVShaderId = rlCompileShader(defaultVShaderCode, GL_VERTEX_SHADER); // Compile default vertex shader
- RLGL.State.defaultFShaderId = rlCompileShader(defaultFShaderCode, GL_FRAGMENT_SHADER); // Compile default fragment shader
-
- RLGL.State.defaultShaderId = rlLoadShaderProgram(RLGL.State.defaultVShaderId, RLGL.State.defaultFShaderId);
-
- if (RLGL.State.defaultShaderId > 0)
- {
- TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Default shader loaded successfully", RLGL.State.defaultShaderId);
-
- // Set default shader locations: attributes locations
- RLGL.State.defaultShaderLocs[RL_SHADER_LOC_VERTEX_POSITION] = glGetAttribLocation(RLGL.State.defaultShaderId, RL_DEFAULT_SHADER_ATTRIB_NAME_POSITION);
- RLGL.State.defaultShaderLocs[RL_SHADER_LOC_VERTEX_TEXCOORD01] = glGetAttribLocation(RLGL.State.defaultShaderId, RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD);
- RLGL.State.defaultShaderLocs[RL_SHADER_LOC_VERTEX_COLOR] = glGetAttribLocation(RLGL.State.defaultShaderId, RL_DEFAULT_SHADER_ATTRIB_NAME_COLOR);
-
- // Set default shader locations: uniform locations
- RLGL.State.defaultShaderLocs[RL_SHADER_LOC_MATRIX_MVP] = glGetUniformLocation(RLGL.State.defaultShaderId, RL_DEFAULT_SHADER_UNIFORM_NAME_MVP);
- RLGL.State.defaultShaderLocs[RL_SHADER_LOC_COLOR_DIFFUSE] = glGetUniformLocation(RLGL.State.defaultShaderId, RL_DEFAULT_SHADER_UNIFORM_NAME_COLOR);
- RLGL.State.defaultShaderLocs[RL_SHADER_LOC_MAP_DIFFUSE] = glGetUniformLocation(RLGL.State.defaultShaderId, RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE0);
- }
- else TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to load default shader", RLGL.State.defaultShaderId);
+ "#version 100 \n"
+ "precision mediump float; \n" // Precision required for OpenGL ES2 (WebGL)
+ "varying vec2 fragTexCoord; \n"
+ "varying vec4 fragColor; \n"
+ "uniform sampler2D texture0; \n"
+ "uniform vec4 colDiffuse; \n"
+ "void main() \n"
+ "{ \n"
+ " vec4 texelColor = texture2D(texture0, fragTexCoord); \n"
+ " gl_FragColor = texelColor*colDiffuse*fragColor; \n"
+ "} \n";
+#endif
+
+ // NOTE: Compiled vertex/fragment shaders are not deleted,
+ // they are kept for re-use as default shaders in case some shader loading fails
+ RLGL.State.defaultVShaderId = rlCompileShader(defaultVShaderCode, GL_VERTEX_SHADER); // Compile default vertex shader
+ RLGL.State.defaultFShaderId = rlCompileShader(defaultFShaderCode, GL_FRAGMENT_SHADER); // Compile default fragment shader
+
+ RLGL.State.defaultShaderId = rlLoadShaderProgram(RLGL.State.defaultVShaderId, RLGL.State.defaultFShaderId);
+
+ if (RLGL.State.defaultShaderId > 0) {
+ TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Default shader loaded successfully", RLGL.State.defaultShaderId);
+
+ // Set default shader locations: attributes locations
+ RLGL.State.defaultShaderLocs[RL_SHADER_LOC_VERTEX_POSITION] = glGetAttribLocation(RLGL.State.defaultShaderId, RL_DEFAULT_SHADER_ATTRIB_NAME_POSITION);
+ RLGL.State.defaultShaderLocs[RL_SHADER_LOC_VERTEX_TEXCOORD01] = glGetAttribLocation(RLGL.State.defaultShaderId, RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD);
+ RLGL.State.defaultShaderLocs[RL_SHADER_LOC_VERTEX_COLOR] = glGetAttribLocation(RLGL.State.defaultShaderId, RL_DEFAULT_SHADER_ATTRIB_NAME_COLOR);
+
+ // Set default shader locations: uniform locations
+ RLGL.State.defaultShaderLocs[RL_SHADER_LOC_MATRIX_MVP] = glGetUniformLocation(RLGL.State.defaultShaderId, RL_DEFAULT_SHADER_UNIFORM_NAME_MVP);
+ RLGL.State.defaultShaderLocs[RL_SHADER_LOC_COLOR_DIFFUSE] = glGetUniformLocation(RLGL.State.defaultShaderId, RL_DEFAULT_SHADER_UNIFORM_NAME_COLOR);
+ RLGL.State.defaultShaderLocs[RL_SHADER_LOC_MAP_DIFFUSE] = glGetUniformLocation(RLGL.State.defaultShaderId, RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE0);
+ } else
+ TRACELOG(RL_LOG_WARNING, "SHADER: [ID %i] Failed to load default shader", RLGL.State.defaultShaderId);
}
// Unload default shader
// NOTE: Unloads: RLGL.State.defaultShaderId, RLGL.State.defaultShaderLocs
-static void rlUnloadShaderDefault(void)
-{
- glUseProgram(0);
+static void rlUnloadShaderDefault(void) {
+ glUseProgram(0);
- glDetachShader(RLGL.State.defaultShaderId, RLGL.State.defaultVShaderId);
- glDetachShader(RLGL.State.defaultShaderId, RLGL.State.defaultFShaderId);
- glDeleteShader(RLGL.State.defaultVShaderId);
- glDeleteShader(RLGL.State.defaultFShaderId);
+ glDetachShader(RLGL.State.defaultShaderId, RLGL.State.defaultVShaderId);
+ glDetachShader(RLGL.State.defaultShaderId, RLGL.State.defaultFShaderId);
+ glDeleteShader(RLGL.State.defaultVShaderId);
+ glDeleteShader(RLGL.State.defaultFShaderId);
- glDeleteProgram(RLGL.State.defaultShaderId);
+ glDeleteProgram(RLGL.State.defaultShaderId);
- RL_FREE(RLGL.State.defaultShaderLocs);
+ RL_FREE(RLGL.State.defaultShaderLocs);
- TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Default shader unloaded successfully", RLGL.State.defaultShaderId);
+ TRACELOG(RL_LOG_INFO, "SHADER: [ID %i] Default shader unloaded successfully", RLGL.State.defaultShaderId);
}
#if defined(RLGL_SHOW_GL_DETAILS_INFO)
// Get compressed format official GL identifier name
-static const char *rlGetCompressedFormatName(int format)
-{
- switch (format)
- {
- // GL_EXT_texture_compression_s3tc
- case 0x83F0: return "GL_COMPRESSED_RGB_S3TC_DXT1_EXT"; break;
- case 0x83F1: return "GL_COMPRESSED_RGBA_S3TC_DXT1_EXT"; break;
- case 0x83F2: return "GL_COMPRESSED_RGBA_S3TC_DXT3_EXT"; break;
- case 0x83F3: return "GL_COMPRESSED_RGBA_S3TC_DXT5_EXT"; break;
- // GL_3DFX_texture_compression_FXT1
- case 0x86B0: return "GL_COMPRESSED_RGB_FXT1_3DFX"; break;
- case 0x86B1: return "GL_COMPRESSED_RGBA_FXT1_3DFX"; break;
- // GL_IMG_texture_compression_pvrtc
- case 0x8C00: return "GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG"; break;
- case 0x8C01: return "GL_COMPRESSED_RGB_PVRTC_2BPPV1_IMG"; break;
- case 0x8C02: return "GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG"; break;
- case 0x8C03: return "GL_COMPRESSED_RGBA_PVRTC_2BPPV1_IMG"; break;
- // GL_OES_compressed_ETC1_RGB8_texture
- case 0x8D64: return "GL_ETC1_RGB8_OES"; break;
- // GL_ARB_texture_compression_rgtc
- case 0x8DBB: return "GL_COMPRESSED_RED_RGTC1"; break;
- case 0x8DBC: return "GL_COMPRESSED_SIGNED_RED_RGTC1"; break;
- case 0x8DBD: return "GL_COMPRESSED_RG_RGTC2"; break;
- case 0x8DBE: return "GL_COMPRESSED_SIGNED_RG_RGTC2"; break;
- // GL_ARB_texture_compression_bptc
- case 0x8E8C: return "GL_COMPRESSED_RGBA_BPTC_UNORM_ARB"; break;
- case 0x8E8D: return "GL_COMPRESSED_SRGB_ALPHA_BPTC_UNORM_ARB"; break;
- case 0x8E8E: return "GL_COMPRESSED_RGB_BPTC_SIGNED_FLOAT_ARB"; break;
- case 0x8E8F: return "GL_COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT_ARB"; break;
- // GL_ARB_ES3_compatibility
- case 0x9274: return "GL_COMPRESSED_RGB8_ETC2"; break;
- case 0x9275: return "GL_COMPRESSED_SRGB8_ETC2"; break;
- case 0x9276: return "GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2"; break;
- case 0x9277: return "GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2"; break;
- case 0x9278: return "GL_COMPRESSED_RGBA8_ETC2_EAC"; break;
- case 0x9279: return "GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC"; break;
- case 0x9270: return "GL_COMPRESSED_R11_EAC"; break;
- case 0x9271: return "GL_COMPRESSED_SIGNED_R11_EAC"; break;
- case 0x9272: return "GL_COMPRESSED_RG11_EAC"; break;
- case 0x9273: return "GL_COMPRESSED_SIGNED_RG11_EAC"; break;
- // GL_KHR_texture_compression_astc_hdr
- case 0x93B0: return "GL_COMPRESSED_RGBA_ASTC_4x4_KHR"; break;
- case 0x93B1: return "GL_COMPRESSED_RGBA_ASTC_5x4_KHR"; break;
- case 0x93B2: return "GL_COMPRESSED_RGBA_ASTC_5x5_KHR"; break;
- case 0x93B3: return "GL_COMPRESSED_RGBA_ASTC_6x5_KHR"; break;
- case 0x93B4: return "GL_COMPRESSED_RGBA_ASTC_6x6_KHR"; break;
- case 0x93B5: return "GL_COMPRESSED_RGBA_ASTC_8x5_KHR"; break;
- case 0x93B6: return "GL_COMPRESSED_RGBA_ASTC_8x6_KHR"; break;
- case 0x93B7: return "GL_COMPRESSED_RGBA_ASTC_8x8_KHR"; break;
- case 0x93B8: return "GL_COMPRESSED_RGBA_ASTC_10x5_KHR"; break;
- case 0x93B9: return "GL_COMPRESSED_RGBA_ASTC_10x6_KHR"; break;
- case 0x93BA: return "GL_COMPRESSED_RGBA_ASTC_10x8_KHR"; break;
- case 0x93BB: return "GL_COMPRESSED_RGBA_ASTC_10x10_KHR"; break;
- case 0x93BC: return "GL_COMPRESSED_RGBA_ASTC_12x10_KHR"; break;
- case 0x93BD: return "GL_COMPRESSED_RGBA_ASTC_12x12_KHR"; break;
- case 0x93D0: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR"; break;
- case 0x93D1: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4_KHR"; break;
- case 0x93D2: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5_KHR"; break;
- case 0x93D3: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5_KHR"; break;
- case 0x93D4: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6_KHR"; break;
- case 0x93D5: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x5_KHR"; break;
- case 0x93D6: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x6_KHR"; break;
- case 0x93D7: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR"; break;
- case 0x93D8: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x5_KHR"; break;
- case 0x93D9: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x6_KHR"; break;
- case 0x93DA: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x8_KHR"; break;
- case 0x93DB: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x10_KHR"; break;
- case 0x93DC: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x10_KHR"; break;
- case 0x93DD: return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x12_KHR"; break;
- default: return "GL_COMPRESSED_UNKNOWN"; break;
- }
-}
-#endif // RLGL_SHOW_GL_DETAILS_INFO
-
-#endif // GRAPHICS_API_OPENGL_33 || GRAPHICS_API_OPENGL_ES2
+static const char* rlGetCompressedFormatName(int format) {
+ switch (format) {
+ // GL_EXT_texture_compression_s3tc
+ case 0x83F0:
+ return "GL_COMPRESSED_RGB_S3TC_DXT1_EXT";
+ break;
+ case 0x83F1:
+ return "GL_COMPRESSED_RGBA_S3TC_DXT1_EXT";
+ break;
+ case 0x83F2:
+ return "GL_COMPRESSED_RGBA_S3TC_DXT3_EXT";
+ break;
+ case 0x83F3:
+ return "GL_COMPRESSED_RGBA_S3TC_DXT5_EXT";
+ break;
+ // GL_3DFX_texture_compression_FXT1
+ case 0x86B0:
+ return "GL_COMPRESSED_RGB_FXT1_3DFX";
+ break;
+ case 0x86B1:
+ return "GL_COMPRESSED_RGBA_FXT1_3DFX";
+ break;
+ // GL_IMG_texture_compression_pvrtc
+ case 0x8C00:
+ return "GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG";
+ break;
+ case 0x8C01:
+ return "GL_COMPRESSED_RGB_PVRTC_2BPPV1_IMG";
+ break;
+ case 0x8C02:
+ return "GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG";
+ break;
+ case 0x8C03:
+ return "GL_COMPRESSED_RGBA_PVRTC_2BPPV1_IMG";
+ break;
+ // GL_OES_compressed_ETC1_RGB8_texture
+ case 0x8D64:
+ return "GL_ETC1_RGB8_OES";
+ break;
+ // GL_ARB_texture_compression_rgtc
+ case 0x8DBB:
+ return "GL_COMPRESSED_RED_RGTC1";
+ break;
+ case 0x8DBC:
+ return "GL_COMPRESSED_SIGNED_RED_RGTC1";
+ break;
+ case 0x8DBD:
+ return "GL_COMPRESSED_RG_RGTC2";
+ break;
+ case 0x8DBE:
+ return "GL_COMPRESSED_SIGNED_RG_RGTC2";
+ break;
+ // GL_ARB_texture_compression_bptc
+ case 0x8E8C:
+ return "GL_COMPRESSED_RGBA_BPTC_UNORM_ARB";
+ break;
+ case 0x8E8D:
+ return "GL_COMPRESSED_SRGB_ALPHA_BPTC_UNORM_ARB";
+ break;
+ case 0x8E8E:
+ return "GL_COMPRESSED_RGB_BPTC_SIGNED_FLOAT_ARB";
+ break;
+ case 0x8E8F:
+ return "GL_COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT_ARB";
+ break;
+ // GL_ARB_ES3_compatibility
+ case 0x9274:
+ return "GL_COMPRESSED_RGB8_ETC2";
+ break;
+ case 0x9275:
+ return "GL_COMPRESSED_SRGB8_ETC2";
+ break;
+ case 0x9276:
+ return "GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2";
+ break;
+ case 0x9277:
+ return "GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2";
+ break;
+ case 0x9278:
+ return "GL_COMPRESSED_RGBA8_ETC2_EAC";
+ break;
+ case 0x9279:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC";
+ break;
+ case 0x9270:
+ return "GL_COMPRESSED_R11_EAC";
+ break;
+ case 0x9271:
+ return "GL_COMPRESSED_SIGNED_R11_EAC";
+ break;
+ case 0x9272:
+ return "GL_COMPRESSED_RG11_EAC";
+ break;
+ case 0x9273:
+ return "GL_COMPRESSED_SIGNED_RG11_EAC";
+ break;
+ // GL_KHR_texture_compression_astc_hdr
+ case 0x93B0:
+ return "GL_COMPRESSED_RGBA_ASTC_4x4_KHR";
+ break;
+ case 0x93B1:
+ return "GL_COMPRESSED_RGBA_ASTC_5x4_KHR";
+ break;
+ case 0x93B2:
+ return "GL_COMPRESSED_RGBA_ASTC_5x5_KHR";
+ break;
+ case 0x93B3:
+ return "GL_COMPRESSED_RGBA_ASTC_6x5_KHR";
+ break;
+ case 0x93B4:
+ return "GL_COMPRESSED_RGBA_ASTC_6x6_KHR";
+ break;
+ case 0x93B5:
+ return "GL_COMPRESSED_RGBA_ASTC_8x5_KHR";
+ break;
+ case 0x93B6:
+ return "GL_COMPRESSED_RGBA_ASTC_8x6_KHR";
+ break;
+ case 0x93B7:
+ return "GL_COMPRESSED_RGBA_ASTC_8x8_KHR";
+ break;
+ case 0x93B8:
+ return "GL_COMPRESSED_RGBA_ASTC_10x5_KHR";
+ break;
+ case 0x93B9:
+ return "GL_COMPRESSED_RGBA_ASTC_10x6_KHR";
+ break;
+ case 0x93BA:
+ return "GL_COMPRESSED_RGBA_ASTC_10x8_KHR";
+ break;
+ case 0x93BB:
+ return "GL_COMPRESSED_RGBA_ASTC_10x10_KHR";
+ break;
+ case 0x93BC:
+ return "GL_COMPRESSED_RGBA_ASTC_12x10_KHR";
+ break;
+ case 0x93BD:
+ return "GL_COMPRESSED_RGBA_ASTC_12x12_KHR";
+ break;
+ case 0x93D0:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR";
+ break;
+ case 0x93D1:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4_KHR";
+ break;
+ case 0x93D2:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5_KHR";
+ break;
+ case 0x93D3:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5_KHR";
+ break;
+ case 0x93D4:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6_KHR";
+ break;
+ case 0x93D5:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x5_KHR";
+ break;
+ case 0x93D6:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x6_KHR";
+ break;
+ case 0x93D7:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR";
+ break;
+ case 0x93D8:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x5_KHR";
+ break;
+ case 0x93D9:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x6_KHR";
+ break;
+ case 0x93DA:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x8_KHR";
+ break;
+ case 0x93DB:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x10_KHR";
+ break;
+ case 0x93DC:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x10_KHR";
+ break;
+ case 0x93DD:
+ return "GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x12_KHR";
+ break;
+ default:
+ return "GL_COMPRESSED_UNKNOWN";
+ break;
+ }
+}
+#endif // RLGL_SHOW_GL_DETAILS_INFO
+
+#endif // GRAPHICS_API_OPENGL_33 || GRAPHICS_API_OPENGL_ES2
// Get pixel data size in bytes (image or texture)
// NOTE: Size depends on pixel format
-static int rlGetPixelDataSize(int width, int height, int format)
-{
- int dataSize = 0; // Size in bytes
- int bpp = 0; // Bits per pixel
-
- switch (format)
- {
- case RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE: bpp = 8; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA:
- case RL_PIXELFORMAT_UNCOMPRESSED_R5G6B5:
- case RL_PIXELFORMAT_UNCOMPRESSED_R5G5B5A1:
- case RL_PIXELFORMAT_UNCOMPRESSED_R4G4B4A4: bpp = 16; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8: bpp = 32; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8: bpp = 24; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R32: bpp = 32; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32: bpp = 32*3; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32: bpp = 32*4; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R16: bpp = 16; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16: bpp = 16*3; break;
- case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16: bpp = 16*4; break;
- case RL_PIXELFORMAT_COMPRESSED_DXT1_RGB:
- case RL_PIXELFORMAT_COMPRESSED_DXT1_RGBA:
- case RL_PIXELFORMAT_COMPRESSED_ETC1_RGB:
- case RL_PIXELFORMAT_COMPRESSED_ETC2_RGB:
- case RL_PIXELFORMAT_COMPRESSED_PVRT_RGB:
- case RL_PIXELFORMAT_COMPRESSED_PVRT_RGBA: bpp = 4; break;
- case RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA:
- case RL_PIXELFORMAT_COMPRESSED_DXT5_RGBA:
- case RL_PIXELFORMAT_COMPRESSED_ETC2_EAC_RGBA:
- case RL_PIXELFORMAT_COMPRESSED_ASTC_4x4_RGBA: bpp = 8; break;
- case RL_PIXELFORMAT_COMPRESSED_ASTC_8x8_RGBA: bpp = 2; break;
- default: break;
- }
-
- double bytesPerPixel = (double)bpp/8.0;
- dataSize = (int)(bytesPerPixel*width*height); // Total data size in bytes
-
- // Most compressed formats works on 4x4 blocks,
- // if texture is smaller, minimum dataSize is 8 or 16
- if ((width < 4) && (height < 4))
- {
- if ((format >= RL_PIXELFORMAT_COMPRESSED_DXT1_RGB) && (format < RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA)) dataSize = 8;
- else if ((format >= RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA) && (format < RL_PIXELFORMAT_COMPRESSED_ASTC_8x8_RGBA)) dataSize = 16;
- }
-
- return dataSize;
+static int rlGetPixelDataSize(int width, int height, int format) {
+ int dataSize = 0; // Size in bytes
+ int bpp = 0; // Bits per pixel
+
+ switch (format) {
+ case RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE:
+ bpp = 8;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA:
+ case RL_PIXELFORMAT_UNCOMPRESSED_R5G6B5:
+ case RL_PIXELFORMAT_UNCOMPRESSED_R5G5B5A1:
+ case RL_PIXELFORMAT_UNCOMPRESSED_R4G4B4A4:
+ bpp = 16;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8:
+ bpp = 32;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8:
+ bpp = 24;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32:
+ bpp = 32;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32:
+ bpp = 32 * 3;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32:
+ bpp = 32 * 4;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16:
+ bpp = 16;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16:
+ bpp = 16 * 3;
+ break;
+ case RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16:
+ bpp = 16 * 4;
+ break;
+ case RL_PIXELFORMAT_COMPRESSED_DXT1_RGB:
+ case RL_PIXELFORMAT_COMPRESSED_DXT1_RGBA:
+ case RL_PIXELFORMAT_COMPRESSED_ETC1_RGB:
+ case RL_PIXELFORMAT_COMPRESSED_ETC2_RGB:
+ case RL_PIXELFORMAT_COMPRESSED_PVRT_RGB:
+ case RL_PIXELFORMAT_COMPRESSED_PVRT_RGBA:
+ bpp = 4;
+ break;
+ case RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA:
+ case RL_PIXELFORMAT_COMPRESSED_DXT5_RGBA:
+ case RL_PIXELFORMAT_COMPRESSED_ETC2_EAC_RGBA:
+ case RL_PIXELFORMAT_COMPRESSED_ASTC_4x4_RGBA:
+ bpp = 8;
+ break;
+ case RL_PIXELFORMAT_COMPRESSED_ASTC_8x8_RGBA:
+ bpp = 2;
+ break;
+ default:
+ break;
+ }
+
+ double bytesPerPixel = (double)bpp / 8.0;
+ dataSize = (int)(bytesPerPixel * width * height); // Total data size in bytes
+
+ // Most compressed formats works on 4x4 blocks,
+ // if texture is smaller, minimum dataSize is 8 or 16
+ if ((width < 4) && (height < 4)) {
+ if ((format >= RL_PIXELFORMAT_COMPRESSED_DXT1_RGB) && (format < RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA))
+ dataSize = 8;
+ else if ((format >= RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA) && (format < RL_PIXELFORMAT_COMPRESSED_ASTC_8x8_RGBA))
+ dataSize = 16;
+ }
+
+ return dataSize;
}
// Auxiliar math functions
// Get float array of matrix data
-static rl_float16 rlMatrixToFloatV(RLMatrix mat)
-{
- rl_float16 result = { 0 };
-
- result.v[0] = mat.m0;
- result.v[1] = mat.m1;
- result.v[2] = mat.m2;
- result.v[3] = mat.m3;
- result.v[4] = mat.m4;
- result.v[5] = mat.m5;
- result.v[6] = mat.m6;
- result.v[7] = mat.m7;
- result.v[8] = mat.m8;
- result.v[9] = mat.m9;
- result.v[10] = mat.m10;
- result.v[11] = mat.m11;
- result.v[12] = mat.m12;
- result.v[13] = mat.m13;
- result.v[14] = mat.m14;
- result.v[15] = mat.m15;
-
- return result;
+static rl_float16 rlMatrixToFloatV(RLMatrix mat) {
+ rl_float16 result = {0};
+
+ result.v[0] = mat.m0;
+ result.v[1] = mat.m1;
+ result.v[2] = mat.m2;
+ result.v[3] = mat.m3;
+ result.v[4] = mat.m4;
+ result.v[5] = mat.m5;
+ result.v[6] = mat.m6;
+ result.v[7] = mat.m7;
+ result.v[8] = mat.m8;
+ result.v[9] = mat.m9;
+ result.v[10] = mat.m10;
+ result.v[11] = mat.m11;
+ result.v[12] = mat.m12;
+ result.v[13] = mat.m13;
+ result.v[14] = mat.m14;
+ result.v[15] = mat.m15;
+
+ return result;
}
// Get identity matrix
-static RLMatrix rlMatrixIdentity(void)
-{
- RLMatrix result = {
- 1.0f, 0.0f, 0.0f, 0.0f,
- 0.0f, 1.0f, 0.0f, 0.0f,
- 0.0f, 0.0f, 1.0f, 0.0f,
- 0.0f, 0.0f, 0.0f, 1.0f
- };
+static RLMatrix rlMatrixIdentity(void) {
+ RLMatrix result = {
+ 1.0f, 0.0f, 0.0f, 0.0f,
+ 0.0f, 1.0f, 0.0f, 0.0f,
+ 0.0f, 0.0f, 1.0f, 0.0f,
+ 0.0f, 0.0f, 0.0f, 1.0f};
- return result;
+ return result;
}
// Get two matrix multiplication
// NOTE: When multiplying matrices... the order matters!
-static RLMatrix rlMatrixMultiply(RLMatrix left, RLMatrix right)
-{
- RLMatrix result = { 0 };
-
- result.m0 = left.m0*right.m0 + left.m1*right.m4 + left.m2*right.m8 + left.m3*right.m12;
- result.m1 = left.m0*right.m1 + left.m1*right.m5 + left.m2*right.m9 + left.m3*right.m13;
- result.m2 = left.m0*right.m2 + left.m1*right.m6 + left.m2*right.m10 + left.m3*right.m14;
- result.m3 = left.m0*right.m3 + left.m1*right.m7 + left.m2*right.m11 + left.m3*right.m15;
- result.m4 = left.m4*right.m0 + left.m5*right.m4 + left.m6*right.m8 + left.m7*right.m12;
- result.m5 = left.m4*right.m1 + left.m5*right.m5 + left.m6*right.m9 + left.m7*right.m13;
- result.m6 = left.m4*right.m2 + left.m5*right.m6 + left.m6*right.m10 + left.m7*right.m14;
- result.m7 = left.m4*right.m3 + left.m5*right.m7 + left.m6*right.m11 + left.m7*right.m15;
- result.m8 = left.m8*right.m0 + left.m9*right.m4 + left.m10*right.m8 + left.m11*right.m12;
- result.m9 = left.m8*right.m1 + left.m9*right.m5 + left.m10*right.m9 + left.m11*right.m13;
- result.m10 = left.m8*right.m2 + left.m9*right.m6 + left.m10*right.m10 + left.m11*right.m14;
- result.m11 = left.m8*right.m3 + left.m9*right.m7 + left.m10*right.m11 + left.m11*right.m15;
- result.m12 = left.m12*right.m0 + left.m13*right.m4 + left.m14*right.m8 + left.m15*right.m12;
- result.m13 = left.m12*right.m1 + left.m13*right.m5 + left.m14*right.m9 + left.m15*right.m13;
- result.m14 = left.m12*right.m2 + left.m13*right.m6 + left.m14*right.m10 + left.m15*right.m14;
- result.m15 = left.m12*right.m3 + left.m13*right.m7 + left.m14*right.m11 + left.m15*right.m15;
-
- return result;
+static RLMatrix rlMatrixMultiply(RLMatrix left, RLMatrix right) {
+ RLMatrix result = {0};
+
+ result.m0 = left.m0 * right.m0 + left.m1 * right.m4 + left.m2 * right.m8 + left.m3 * right.m12;
+ result.m1 = left.m0 * right.m1 + left.m1 * right.m5 + left.m2 * right.m9 + left.m3 * right.m13;
+ result.m2 = left.m0 * right.m2 + left.m1 * right.m6 + left.m2 * right.m10 + left.m3 * right.m14;
+ result.m3 = left.m0 * right.m3 + left.m1 * right.m7 + left.m2 * right.m11 + left.m3 * right.m15;
+ result.m4 = left.m4 * right.m0 + left.m5 * right.m4 + left.m6 * right.m8 + left.m7 * right.m12;
+ result.m5 = left.m4 * right.m1 + left.m5 * right.m5 + left.m6 * right.m9 + left.m7 * right.m13;
+ result.m6 = left.m4 * right.m2 + left.m5 * right.m6 + left.m6 * right.m10 + left.m7 * right.m14;
+ result.m7 = left.m4 * right.m3 + left.m5 * right.m7 + left.m6 * right.m11 + left.m7 * right.m15;
+ result.m8 = left.m8 * right.m0 + left.m9 * right.m4 + left.m10 * right.m8 + left.m11 * right.m12;
+ result.m9 = left.m8 * right.m1 + left.m9 * right.m5 + left.m10 * right.m9 + left.m11 * right.m13;
+ result.m10 = left.m8 * right.m2 + left.m9 * right.m6 + left.m10 * right.m10 + left.m11 * right.m14;
+ result.m11 = left.m8 * right.m3 + left.m9 * right.m7 + left.m10 * right.m11 + left.m11 * right.m15;
+ result.m12 = left.m12 * right.m0 + left.m13 * right.m4 + left.m14 * right.m8 + left.m15 * right.m12;
+ result.m13 = left.m12 * right.m1 + left.m13 * right.m5 + left.m14 * right.m9 + left.m15 * right.m13;
+ result.m14 = left.m12 * right.m2 + left.m13 * right.m6 + left.m14 * right.m10 + left.m15 * right.m14;
+ result.m15 = left.m12 * right.m3 + left.m13 * right.m7 + left.m14 * right.m11 + left.m15 * right.m15;
+
+ return result;
}
// Transposes provided matrix
-static RLMatrix rlMatrixTranspose(RLMatrix mat)
-{
- RLMatrix result = { 0 };
-
- result.m0 = mat.m0;
- result.m1 = mat.m4;
- result.m2 = mat.m8;
- result.m3 = mat.m12;
- result.m4 = mat.m1;
- result.m5 = mat.m5;
- result.m6 = mat.m9;
- result.m7 = mat.m13;
- result.m8 = mat.m2;
- result.m9 = mat.m6;
- result.m10 = mat.m10;
- result.m11 = mat.m14;
- result.m12 = mat.m3;
- result.m13 = mat.m7;
- result.m14 = mat.m11;
- result.m15 = mat.m15;
-
- return result;
+static RLMatrix rlMatrixTranspose(RLMatrix mat) {
+ RLMatrix result = {0};
+
+ result.m0 = mat.m0;
+ result.m1 = mat.m4;
+ result.m2 = mat.m8;
+ result.m3 = mat.m12;
+ result.m4 = mat.m1;
+ result.m5 = mat.m5;
+ result.m6 = mat.m9;
+ result.m7 = mat.m13;
+ result.m8 = mat.m2;
+ result.m9 = mat.m6;
+ result.m10 = mat.m10;
+ result.m11 = mat.m14;
+ result.m12 = mat.m3;
+ result.m13 = mat.m7;
+ result.m14 = mat.m11;
+ result.m15 = mat.m15;
+
+ return result;
}
// Invert provided matrix
-static RLMatrix rlMatrixInvert(RLMatrix mat)
-{
- RLMatrix result = { 0 };
-
- // Cache the matrix values (speed optimization)
- float a00 = mat.m0, a01 = mat.m1, a02 = mat.m2, a03 = mat.m3;
- float a10 = mat.m4, a11 = mat.m5, a12 = mat.m6, a13 = mat.m7;
- float a20 = mat.m8, a21 = mat.m9, a22 = mat.m10, a23 = mat.m11;
- float a30 = mat.m12, a31 = mat.m13, a32 = mat.m14, a33 = mat.m15;
-
- float b00 = a00*a11 - a01*a10;
- float b01 = a00*a12 - a02*a10;
- float b02 = a00*a13 - a03*a10;
- float b03 = a01*a12 - a02*a11;
- float b04 = a01*a13 - a03*a11;
- float b05 = a02*a13 - a03*a12;
- float b06 = a20*a31 - a21*a30;
- float b07 = a20*a32 - a22*a30;
- float b08 = a20*a33 - a23*a30;
- float b09 = a21*a32 - a22*a31;
- float b10 = a21*a33 - a23*a31;
- float b11 = a22*a33 - a23*a32;
-
- // Calculate the invert determinant (inlined to avoid double-caching)
- float invDet = 1.0f/(b00*b11 - b01*b10 + b02*b09 + b03*b08 - b04*b07 + b05*b06);
-
- result.m0 = (a11*b11 - a12*b10 + a13*b09)*invDet;
- result.m1 = (-a01*b11 + a02*b10 - a03*b09)*invDet;
- result.m2 = (a31*b05 - a32*b04 + a33*b03)*invDet;
- result.m3 = (-a21*b05 + a22*b04 - a23*b03)*invDet;
- result.m4 = (-a10*b11 + a12*b08 - a13*b07)*invDet;
- result.m5 = (a00*b11 - a02*b08 + a03*b07)*invDet;
- result.m6 = (-a30*b05 + a32*b02 - a33*b01)*invDet;
- result.m7 = (a20*b05 - a22*b02 + a23*b01)*invDet;
- result.m8 = (a10*b10 - a11*b08 + a13*b06)*invDet;
- result.m9 = (-a00*b10 + a01*b08 - a03*b06)*invDet;
- result.m10 = (a30*b04 - a31*b02 + a33*b00)*invDet;
- result.m11 = (-a20*b04 + a21*b02 - a23*b00)*invDet;
- result.m12 = (-a10*b09 + a11*b07 - a12*b06)*invDet;
- result.m13 = (a00*b09 - a01*b07 + a02*b06)*invDet;
- result.m14 = (-a30*b03 + a31*b01 - a32*b00)*invDet;
- result.m15 = (a20*b03 - a21*b01 + a22*b00)*invDet;
-
- return result;
+static RLMatrix rlMatrixInvert(RLMatrix mat) {
+ RLMatrix result = {0};
+
+ // Cache the matrix values (speed optimization)
+ float a00 = mat.m0, a01 = mat.m1, a02 = mat.m2, a03 = mat.m3;
+ float a10 = mat.m4, a11 = mat.m5, a12 = mat.m6, a13 = mat.m7;
+ float a20 = mat.m8, a21 = mat.m9, a22 = mat.m10, a23 = mat.m11;
+ float a30 = mat.m12, a31 = mat.m13, a32 = mat.m14, a33 = mat.m15;
+
+ float b00 = a00 * a11 - a01 * a10;
+ float b01 = a00 * a12 - a02 * a10;
+ float b02 = a00 * a13 - a03 * a10;
+ float b03 = a01 * a12 - a02 * a11;
+ float b04 = a01 * a13 - a03 * a11;
+ float b05 = a02 * a13 - a03 * a12;
+ float b06 = a20 * a31 - a21 * a30;
+ float b07 = a20 * a32 - a22 * a30;
+ float b08 = a20 * a33 - a23 * a30;
+ float b09 = a21 * a32 - a22 * a31;
+ float b10 = a21 * a33 - a23 * a31;
+ float b11 = a22 * a33 - a23 * a32;
+
+ // Calculate the invert determinant (inlined to avoid double-caching)
+ float invDet = 1.0f / (b00 * b11 - b01 * b10 + b02 * b09 + b03 * b08 - b04 * b07 + b05 * b06);
+
+ result.m0 = (a11 * b11 - a12 * b10 + a13 * b09) * invDet;
+ result.m1 = (-a01 * b11 + a02 * b10 - a03 * b09) * invDet;
+ result.m2 = (a31 * b05 - a32 * b04 + a33 * b03) * invDet;
+ result.m3 = (-a21 * b05 + a22 * b04 - a23 * b03) * invDet;
+ result.m4 = (-a10 * b11 + a12 * b08 - a13 * b07) * invDet;
+ result.m5 = (a00 * b11 - a02 * b08 + a03 * b07) * invDet;
+ result.m6 = (-a30 * b05 + a32 * b02 - a33 * b01) * invDet;
+ result.m7 = (a20 * b05 - a22 * b02 + a23 * b01) * invDet;
+ result.m8 = (a10 * b10 - a11 * b08 + a13 * b06) * invDet;
+ result.m9 = (-a00 * b10 + a01 * b08 - a03 * b06) * invDet;
+ result.m10 = (a30 * b04 - a31 * b02 + a33 * b00) * invDet;
+ result.m11 = (-a20 * b04 + a21 * b02 - a23 * b00) * invDet;
+ result.m12 = (-a10 * b09 + a11 * b07 - a12 * b06) * invDet;
+ result.m13 = (a00 * b09 - a01 * b07 + a02 * b06) * invDet;
+ result.m14 = (-a30 * b03 + a31 * b01 - a32 * b00) * invDet;
+ result.m15 = (a20 * b03 - a21 * b01 + a22 * b00) * invDet;
+
+ return result;
}
\ No newline at end of file
diff --git a/Source/Renderer/raylib/rlgl.h b/Source/Renderer/raylib/rlgl.h
index 93be1c8895..721d9ed600 100644
--- a/Source/Renderer/raylib/rlgl.h
+++ b/Source/Renderer/raylib/rlgl.h
@@ -1,151 +1,151 @@
/**********************************************************************************************
-*
-* rlgl v5.0 - A multi-OpenGL abstraction layer with an immediate-mode style API
-*
-* DESCRIPTION:
-* An abstraction layer for multiple OpenGL versions (1.1, 2.1, 3.3 Core, 4.3 Core, ES 2.0)
-* that provides a pseudo-OpenGL 1.1 immediate-mode style API (rlVertex, rlTranslate, rlRotate...)
-*
-* ADDITIONAL NOTES:
-* When choosing an OpenGL backend different than OpenGL 1.1, some internal buffer are
-* initialized on rlglInit() to accumulate vertex data
-*
-* When an internal state change is required all the stored vertex data is renderer in batch,
-* additionally, rlDrawRenderBatchActive() could be called to force flushing of the batch
-*
-* Some resources are also loaded for convenience, here the complete list:
-* - Default batch (RLGL.defaultBatch): RenderBatch system to accumulate vertex data
-* - Default texture (RLGL.defaultTextureId): 1x1 white pixel R8G8B8A8
-* - Default shader (RLGL.State.defaultShaderId, RLGL.State.defaultShaderLocs)
-*
-* Internal buffer (and resources) must be manually unloaded calling rlglClose()
-*
-* CONFIGURATION:
-* #define GRAPHICS_API_OPENGL_11
-* #define GRAPHICS_API_OPENGL_21
-* #define GRAPHICS_API_OPENGL_33
-* #define GRAPHICS_API_OPENGL_43
-* #define GRAPHICS_API_OPENGL_ES2
-* #define GRAPHICS_API_OPENGL_ES3
-* Use selected OpenGL graphics backend, should be supported by platform
-* Those preprocessor defines are only used on rlgl module, if OpenGL version is
-* required by any other module, use rlGetVersion() to check it
-*
-* #define RLGL_IMPLEMENTATION
-* Generates the implementation of the library into the included file
-* If not defined, the library is in header only mode and can be included in other headers
-* or source files without problems. But only ONE file should hold the implementation
-*
-* #define RLGL_RENDER_TEXTURES_HINT
-* Enable framebuffer objects (fbo) support (enabled by default)
-* Some GPUs could not support them despite the OpenGL version
-*
-* #define RLGL_SHOW_GL_DETAILS_INFO
-* Show OpenGL extensions and capabilities detailed logs on init
-*
-* #define RLGL_ENABLE_OPENGL_DEBUG_CONTEXT
-* Enable debug context (only available on OpenGL 4.3)
-*
-* rlgl capabilities could be customized just defining some internal
-* values before library inclusion (default values listed):
-*
-* #define RL_DEFAULT_BATCH_BUFFER_ELEMENTS 8192 // Default internal render batch elements limits
-* #define RL_DEFAULT_BATCH_BUFFERS 1 // Default number of batch buffers (multi-buffering)
-* #define RL_DEFAULT_BATCH_DRAWCALLS 256 // Default number of batch draw calls (by state changes: mode, texture)
-* #define RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS 4 // Maximum number of textures units that can be activated on batch drawing (SetShaderValueTexture())
-*
-* #define RL_MAX_MATRIX_STACK_SIZE 32 // Maximum size of internal RLMatrix stack
-* #define RL_MAX_SHADER_LOCATIONS 32 // Maximum number of shader locations supported
-* #define RL_CULL_DISTANCE_NEAR 0.01 // Default projection matrix near cull distance
-* #define RL_CULL_DISTANCE_FAR 1000.0 // Default projection matrix far cull distance
-*
-* When loading a shader, the following vertex attributes and uniform
-* location names are tried to be set automatically:
-*
-* #define RL_DEFAULT_SHADER_ATTRIB_NAME_POSITION "vertexPosition" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION
-* #define RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD "vertexTexCoord" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD
-* #define RL_DEFAULT_SHADER_ATTRIB_NAME_NORMAL "vertexNormal" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL
-* #define RL_DEFAULT_SHADER_ATTRIB_NAME_COLOR "vertexColor" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_COLOR
-* #define RL_DEFAULT_SHADER_ATTRIB_NAME_TANGENT "vertexTangent" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_TANGENT
-* #define RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD2 "vertexTexCoord2" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD2
-* #define RL_DEFAULT_SHADER_ATTRIB_NAME_BONEIDS "vertexBoneIds" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEIDS
-* #define RL_DEFAULT_SHADER_ATTRIB_NAME_BONEWEIGHTS "vertexBoneWeights" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEWEIGHTS
-* #define RL_DEFAULT_SHADER_UNIFORM_NAME_MVP "mvp" // model-view-projection matrix
-* #define RL_DEFAULT_SHADER_UNIFORM_NAME_VIEW "matView" // view matrix
-* #define RL_DEFAULT_SHADER_UNIFORM_NAME_PROJECTION "matProjection" // projection matrix
-* #define RL_DEFAULT_SHADER_UNIFORM_NAME_MODEL "matModel" // model matrix
-* #define RL_DEFAULT_SHADER_UNIFORM_NAME_NORMAL "matNormal" // normal matrix (transpose(inverse(matModelView)))
-* #define RL_DEFAULT_SHADER_UNIFORM_NAME_COLOR "colDiffuse" // color diffuse (base tint color, multiplied by texture color)
-* #define RL_DEFAULT_SHADER_UNIFORM_NAME_BONE_MATRICES "boneMatrices" // bone matrices
-* #define RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE0 "texture0" // texture0 (texture slot active 0)
-* #define RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE1 "texture1" // texture1 (texture slot active 1)
-* #define RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE2 "texture2" // texture2 (texture slot active 2)
-*
-* DEPENDENCIES:
-* - OpenGL libraries (depending on platform and OpenGL version selected)
-* - GLAD OpenGL extensions loading library (only for OpenGL 3.3 Core, 4.3 Core)
-*
-*
-* LICENSE: zlib/libpng
-*
-* Copyright (c) 2014-2024 Ramon Santamaria (@raysan5)
-*
-* This software is provided "as-is", without any express or implied warranty. In no event
-* will the authors be held liable for any damages arising from the use of this software.
-*
-* Permission is granted to anyone to use this software for any purpose, including commercial
-* applications, and to alter it and redistribute it freely, subject to the following restrictions:
-*
-* 1. The origin of this software must not be misrepresented; you must not claim that you
-* wrote the original software. If you use this software in a product, an acknowledgment
-* in the product documentation would be appreciated but is not required.
-*
-* 2. Altered source versions must be plainly marked as such, and must not be misrepresented
-* as being the original software.
-*
-* 3. This notice may not be removed or altered from any source distribution.
-*
-**********************************************************************************************/
+ *
+ * rlgl v5.0 - A multi-OpenGL abstraction layer with an immediate-mode style API
+ *
+ * DESCRIPTION:
+ * An abstraction layer for multiple OpenGL versions (1.1, 2.1, 3.3 Core, 4.3 Core, ES 2.0)
+ * that provides a pseudo-OpenGL 1.1 immediate-mode style API (rlVertex, rlTranslate, rlRotate...)
+ *
+ * ADDITIONAL NOTES:
+ * When choosing an OpenGL backend different than OpenGL 1.1, some internal buffer are
+ * initialized on rlglInit() to accumulate vertex data
+ *
+ * When an internal state change is required all the stored vertex data is renderer in batch,
+ * additionally, rlDrawRenderBatchActive() could be called to force flushing of the batch
+ *
+ * Some resources are also loaded for convenience, here the complete list:
+ * - Default batch (RLGL.defaultBatch): RenderBatch system to accumulate vertex data
+ * - Default texture (RLGL.defaultTextureId): 1x1 white pixel R8G8B8A8
+ * - Default shader (RLGL.State.defaultShaderId, RLGL.State.defaultShaderLocs)
+ *
+ * Internal buffer (and resources) must be manually unloaded calling rlglClose()
+ *
+ * CONFIGURATION:
+ * #define GRAPHICS_API_OPENGL_11
+ * #define GRAPHICS_API_OPENGL_21
+ * #define GRAPHICS_API_OPENGL_33
+ * #define GRAPHICS_API_OPENGL_43
+ * #define GRAPHICS_API_OPENGL_ES2
+ * #define GRAPHICS_API_OPENGL_ES3
+ * Use selected OpenGL graphics backend, should be supported by platform
+ * Those preprocessor defines are only used on rlgl module, if OpenGL version is
+ * required by any other module, use rlGetVersion() to check it
+ *
+ * #define RLGL_IMPLEMENTATION
+ * Generates the implementation of the library into the included file
+ * If not defined, the library is in header only mode and can be included in other headers
+ * or source files without problems. But only ONE file should hold the implementation
+ *
+ * #define RLGL_RENDER_TEXTURES_HINT
+ * Enable framebuffer objects (fbo) support (enabled by default)
+ * Some GPUs could not support them despite the OpenGL version
+ *
+ * #define RLGL_SHOW_GL_DETAILS_INFO
+ * Show OpenGL extensions and capabilities detailed logs on init
+ *
+ * #define RLGL_ENABLE_OPENGL_DEBUG_CONTEXT
+ * Enable debug context (only available on OpenGL 4.3)
+ *
+ * rlgl capabilities could be customized just defining some internal
+ * values before library inclusion (default values listed):
+ *
+ * #define RL_DEFAULT_BATCH_BUFFER_ELEMENTS 8192 // Default internal render batch elements limits
+ * #define RL_DEFAULT_BATCH_BUFFERS 1 // Default number of batch buffers (multi-buffering)
+ * #define RL_DEFAULT_BATCH_DRAWCALLS 256 // Default number of batch draw calls (by state changes: mode, texture)
+ * #define RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS 4 // Maximum number of textures units that can be activated on batch drawing (SetShaderValueTexture())
+ *
+ * #define RL_MAX_MATRIX_STACK_SIZE 32 // Maximum size of internal RLMatrix stack
+ * #define RL_MAX_SHADER_LOCATIONS 32 // Maximum number of shader locations supported
+ * #define RL_CULL_DISTANCE_NEAR 0.01 // Default projection matrix near cull distance
+ * #define RL_CULL_DISTANCE_FAR 1000.0 // Default projection matrix far cull distance
+ *
+ * When loading a shader, the following vertex attributes and uniform
+ * location names are tried to be set automatically:
+ *
+ * #define RL_DEFAULT_SHADER_ATTRIB_NAME_POSITION "vertexPosition" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION
+ * #define RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD "vertexTexCoord" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD
+ * #define RL_DEFAULT_SHADER_ATTRIB_NAME_NORMAL "vertexNormal" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL
+ * #define RL_DEFAULT_SHADER_ATTRIB_NAME_COLOR "vertexColor" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_COLOR
+ * #define RL_DEFAULT_SHADER_ATTRIB_NAME_TANGENT "vertexTangent" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_TANGENT
+ * #define RL_DEFAULT_SHADER_ATTRIB_NAME_TEXCOORD2 "vertexTexCoord2" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD2
+ * #define RL_DEFAULT_SHADER_ATTRIB_NAME_BONEIDS "vertexBoneIds" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEIDS
+ * #define RL_DEFAULT_SHADER_ATTRIB_NAME_BONEWEIGHTS "vertexBoneWeights" // Bound by default to shader location: RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEWEIGHTS
+ * #define RL_DEFAULT_SHADER_UNIFORM_NAME_MVP "mvp" // model-view-projection matrix
+ * #define RL_DEFAULT_SHADER_UNIFORM_NAME_VIEW "matView" // view matrix
+ * #define RL_DEFAULT_SHADER_UNIFORM_NAME_PROJECTION "matProjection" // projection matrix
+ * #define RL_DEFAULT_SHADER_UNIFORM_NAME_MODEL "matModel" // model matrix
+ * #define RL_DEFAULT_SHADER_UNIFORM_NAME_NORMAL "matNormal" // normal matrix (transpose(inverse(matModelView)))
+ * #define RL_DEFAULT_SHADER_UNIFORM_NAME_COLOR "colDiffuse" // color diffuse (base tint color, multiplied by texture color)
+ * #define RL_DEFAULT_SHADER_UNIFORM_NAME_BONE_MATRICES "boneMatrices" // bone matrices
+ * #define RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE0 "texture0" // texture0 (texture slot active 0)
+ * #define RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE1 "texture1" // texture1 (texture slot active 1)
+ * #define RL_DEFAULT_SHADER_SAMPLER2D_NAME_TEXTURE2 "texture2" // texture2 (texture slot active 2)
+ *
+ * DEPENDENCIES:
+ * - OpenGL libraries (depending on platform and OpenGL version selected)
+ * - GLAD OpenGL extensions loading library (only for OpenGL 3.3 Core, 4.3 Core)
+ *
+ *
+ * LICENSE: zlib/libpng
+ *
+ * Copyright (c) 2014-2024 Ramon Santamaria (@raysan5)
+ *
+ * This software is provided "as-is", without any express or implied warranty. In no event
+ * will the authors be held liable for any damages arising from the use of this software.
+ *
+ * Permission is granted to anyone to use this software for any purpose, including commercial
+ * applications, and to alter it and redistribute it freely, subject to the following restrictions:
+ *
+ * 1. The origin of this software must not be misrepresented; you must not claim that you
+ * wrote the original software. If you use this software in a product, an acknowledgment
+ * in the product documentation would be appreciated but is not required.
+ *
+ * 2. Altered source versions must be plainly marked as such, and must not be misrepresented
+ * as being the original software.
+ *
+ * 3. This notice may not be removed or altered from any source distribution.
+ *
+ **********************************************************************************************/
#ifndef RLGL_H
#define RLGL_H
-#define RLGL_VERSION "5.0"
+#define RLGL_VERSION "5.0"
// Function specifiers in case library is build/used as a shared library
// NOTE: Microsoft specifiers to tell compiler that symbols are imported/exported from a .dll
// NOTE: visibility(default) attribute makes symbols "visible" when compiled with -fvisibility=hidden
#if defined(_WIN32) && defined(BUILD_LIBTYPE_SHARED)
- #define RLAPI __declspec(dllexport) // We are building the library as a Win32 shared library (.dll)
+#define RLAPI __declspec(dllexport) // We are building the library as a Win32 shared library (.dll)
#elif defined(BUILD_LIBTYPE_SHARED)
- #define RLAPI __attribute__((visibility("default"))) // We are building the library as a Unix shared library (.so/.dylib)
+#define RLAPI __attribute__((visibility("default"))) // We are building the library as a Unix shared library (.so/.dylib)
#elif defined(_WIN32) && defined(USE_LIBTYPE_SHARED)
- #define RLAPI __declspec(dllimport) // We are using the library as a Win32 shared library (.dll)
+#define RLAPI __declspec(dllimport) // We are using the library as a Win32 shared library (.dll)
#endif
// Function specifiers definition
#ifndef RLAPI
- #define RLAPI // Functions defined as 'extern' by default (implicit specifiers)
+#define RLAPI // Functions defined as 'extern' by default (implicit specifiers)
#endif
-
+#include
// Support TRACELOG macros
#ifndef TRACELOG
- #define TRACELOG(level, ...) (void)0
- #define TRACELOGD(...) (void)0
+#define TRACELOG(level, ...) (void)0
+#define TRACELOGD(...) (void)0
#endif
// Allow custom memory allocators
#ifndef RL_MALLOC
- #define RL_MALLOC(sz) malloc(sz)
+#define RL_MALLOC(sz) malloc(sz)
#endif
#ifndef RL_CALLOC
- #define RL_CALLOC(n,sz) calloc(n,sz)
+#define RL_CALLOC(n, sz) calloc(n, sz)
#endif
#ifndef RL_REALLOC
- #define RL_REALLOC(n,sz) realloc(n,sz)
+#define RL_REALLOC(n, sz) realloc(n, sz)
#endif
#ifndef RL_FREE
- #define RL_FREE(p) free(p)
+#define RL_FREE(p) free(p)
#endif
#define GRAPHICS_API_OPENGL_33
@@ -157,39 +157,39 @@
!defined(GRAPHICS_API_OPENGL_43) && \
!defined(GRAPHICS_API_OPENGL_ES2) && \
!defined(GRAPHICS_API_OPENGL_ES3)
- #define GRAPHICS_API_OPENGL_33
+#define GRAPHICS_API_OPENGL_33
#endif
// Security check in case multiple GRAPHICS_API_OPENGL_* defined
#if defined(GRAPHICS_API_OPENGL_11)
- #if defined(GRAPHICS_API_OPENGL_21)
- #undef GRAPHICS_API_OPENGL_21
- #endif
- #if defined(GRAPHICS_API_OPENGL_33)
- #undef GRAPHICS_API_OPENGL_33
- #endif
- #if defined(GRAPHICS_API_OPENGL_43)
- #undef GRAPHICS_API_OPENGL_43
- #endif
- #if defined(GRAPHICS_API_OPENGL_ES2)
- #undef GRAPHICS_API_OPENGL_ES2
- #endif
+#if defined(GRAPHICS_API_OPENGL_21)
+#undef GRAPHICS_API_OPENGL_21
+#endif
+#if defined(GRAPHICS_API_OPENGL_33)
+#undef GRAPHICS_API_OPENGL_33
+#endif
+#if defined(GRAPHICS_API_OPENGL_43)
+#undef GRAPHICS_API_OPENGL_43
+#endif
+#if defined(GRAPHICS_API_OPENGL_ES2)
+#undef GRAPHICS_API_OPENGL_ES2
+#endif
#endif
// OpenGL 2.1 uses most of OpenGL 3.3 Core functionality
// WARNING: Specific parts are checked with #if defines
#if defined(GRAPHICS_API_OPENGL_21)
- #define GRAPHICS_API_OPENGL_33
+#define GRAPHICS_API_OPENGL_33
#endif
// OpenGL 4.3 uses OpenGL 3.3 Core functionality
#if defined(GRAPHICS_API_OPENGL_43)
- #define GRAPHICS_API_OPENGL_33
+#define GRAPHICS_API_OPENGL_33
#endif
// OpenGL ES 3.0 uses OpenGL ES 2.0 functionality (and more)
#if defined(GRAPHICS_API_OPENGL_ES3)
- #define GRAPHICS_API_OPENGL_ES2
+#define GRAPHICS_API_OPENGL_ES2
#endif
// Support framebuffer objects by default
@@ -202,159 +202,159 @@
// Default internal render batch elements limits
#ifndef RL_DEFAULT_BATCH_BUFFER_ELEMENTS
- #if defined(GRAPHICS_API_OPENGL_11) || defined(GRAPHICS_API_OPENGL_33)
- // This is the maximum amount of elements (quads) per batch
- // NOTE: Be careful with text, every letter maps to a quad
- #define RL_DEFAULT_BATCH_BUFFER_ELEMENTS 8192
- #endif
- #if defined(GRAPHICS_API_OPENGL_ES2)
- // We reduce memory sizes for embedded systems (RPI and HTML5)
- // NOTE: On HTML5 (emscripten) this is allocated on heap,
- // by default it's only 16MB!...just take care...
- #define RL_DEFAULT_BATCH_BUFFER_ELEMENTS 2048
- #endif
+#if defined(GRAPHICS_API_OPENGL_11) || defined(GRAPHICS_API_OPENGL_33)
+// This is the maximum amount of elements (quads) per batch
+// NOTE: Be careful with text, every letter maps to a quad
+#define RL_DEFAULT_BATCH_BUFFER_ELEMENTS 8192
+#endif
+#if defined(GRAPHICS_API_OPENGL_ES2)
+// We reduce memory sizes for embedded systems (RPI and HTML5)
+// NOTE: On HTML5 (emscripten) this is allocated on heap,
+// by default it's only 16MB!...just take care...
+#define RL_DEFAULT_BATCH_BUFFER_ELEMENTS 2048
+#endif
#endif
#ifndef RL_DEFAULT_BATCH_BUFFERS
- #define RL_DEFAULT_BATCH_BUFFERS 1 // Default number of batch buffers (multi-buffering)
+#define RL_DEFAULT_BATCH_BUFFERS 1 // Default number of batch buffers (multi-buffering)
#endif
#ifndef RL_DEFAULT_BATCH_DRAWCALLS
- #define RL_DEFAULT_BATCH_DRAWCALLS 256 // Default number of batch draw calls (by state changes: mode, texture)
+#define RL_DEFAULT_BATCH_DRAWCALLS 256 // Default number of batch draw calls (by state changes: mode, texture)
#endif
#ifndef RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS
- #define RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS 16 // Maximum number of textures units that can be activated on batch drawing (SetShaderValueTexture())
+#define RL_DEFAULT_BATCH_MAX_TEXTURE_UNITS 16 // Maximum number of textures units that can be activated on batch drawing (SetShaderValueTexture())
#endif
// Internal RLMatrix stack
#ifndef RL_MAX_MATRIX_STACK_SIZE
- #define RL_MAX_MATRIX_STACK_SIZE 32 // Maximum size of RLMatrix stack
+#define RL_MAX_MATRIX_STACK_SIZE 32 // Maximum size of RLMatrix stack
#endif
// Shader limits
#ifndef RL_MAX_SHADER_LOCATIONS
- #define RL_MAX_SHADER_LOCATIONS 32 // Maximum number of shader locations supported
+#define RL_MAX_SHADER_LOCATIONS 32 // Maximum number of shader locations supported
#endif
// Projection matrix culling
#ifndef RL_CULL_DISTANCE_NEAR
- #define RL_CULL_DISTANCE_NEAR 0.01 // Default near cull distance
+#define RL_CULL_DISTANCE_NEAR 0.01 // Default near cull distance
#endif
#ifndef RL_CULL_DISTANCE_FAR
- #define RL_CULL_DISTANCE_FAR 1000.0 // Default far cull distance
+#define RL_CULL_DISTANCE_FAR 1000.0 // Default far cull distance
#endif
// Texture parameters (equivalent to OpenGL defines)
-#define RL_TEXTURE_WRAP_S 0x2802 // GL_TEXTURE_WRAP_S
-#define RL_TEXTURE_WRAP_T 0x2803 // GL_TEXTURE_WRAP_T
-#define RL_TEXTURE_MAG_FILTER 0x2800 // GL_TEXTURE_MAG_FILTER
-#define RL_TEXTURE_MIN_FILTER 0x2801 // GL_TEXTURE_MIN_FILTER
-
-#define RL_TEXTURE_FILTER_NEAREST 0x2600 // GL_NEAREST
-#define RL_TEXTURE_FILTER_LINEAR 0x2601 // GL_LINEAR
-#define RL_TEXTURE_FILTER_MIP_NEAREST 0x2700 // GL_NEAREST_MIPMAP_NEAREST
-#define RL_TEXTURE_FILTER_NEAREST_MIP_LINEAR 0x2702 // GL_NEAREST_MIPMAP_LINEAR
-#define RL_TEXTURE_FILTER_LINEAR_MIP_NEAREST 0x2701 // GL_LINEAR_MIPMAP_NEAREST
-#define RL_TEXTURE_FILTER_MIP_LINEAR 0x2703 // GL_LINEAR_MIPMAP_LINEAR
-#define RL_TEXTURE_FILTER_ANISOTROPIC 0x3000 // Anisotropic filter (custom identifier)
-#define RL_TEXTURE_MIPMAP_BIAS_RATIO 0x4000 // Texture mipmap bias, percentage ratio (custom identifier)
-
-#define RL_TEXTURE_WRAP_REPEAT 0x2901 // GL_REPEAT
-#define RL_TEXTURE_WRAP_CLAMP 0x812F // GL_CLAMP_TO_EDGE
-#define RL_TEXTURE_WRAP_MIRROR_REPEAT 0x8370 // GL_MIRRORED_REPEAT
-#define RL_TEXTURE_WRAP_MIRROR_CLAMP 0x8742 // GL_MIRROR_CLAMP_EXT
+#define RL_TEXTURE_WRAP_S 0x2802 // GL_TEXTURE_WRAP_S
+#define RL_TEXTURE_WRAP_T 0x2803 // GL_TEXTURE_WRAP_T
+#define RL_TEXTURE_MAG_FILTER 0x2800 // GL_TEXTURE_MAG_FILTER
+#define RL_TEXTURE_MIN_FILTER 0x2801 // GL_TEXTURE_MIN_FILTER
+
+#define RL_TEXTURE_FILTER_NEAREST 0x2600 // GL_NEAREST
+#define RL_TEXTURE_FILTER_LINEAR 0x2601 // GL_LINEAR
+#define RL_TEXTURE_FILTER_MIP_NEAREST 0x2700 // GL_NEAREST_MIPMAP_NEAREST
+#define RL_TEXTURE_FILTER_NEAREST_MIP_LINEAR 0x2702 // GL_NEAREST_MIPMAP_LINEAR
+#define RL_TEXTURE_FILTER_LINEAR_MIP_NEAREST 0x2701 // GL_LINEAR_MIPMAP_NEAREST
+#define RL_TEXTURE_FILTER_MIP_LINEAR 0x2703 // GL_LINEAR_MIPMAP_LINEAR
+#define RL_TEXTURE_FILTER_ANISOTROPIC 0x3000 // Anisotropic filter (custom identifier)
+#define RL_TEXTURE_MIPMAP_BIAS_RATIO 0x4000 // Texture mipmap bias, percentage ratio (custom identifier)
+
+#define RL_TEXTURE_WRAP_REPEAT 0x2901 // GL_REPEAT
+#define RL_TEXTURE_WRAP_CLAMP 0x812F // GL_CLAMP_TO_EDGE
+#define RL_TEXTURE_WRAP_MIRROR_REPEAT 0x8370 // GL_MIRRORED_REPEAT
+#define RL_TEXTURE_WRAP_MIRROR_CLAMP 0x8742 // GL_MIRROR_CLAMP_EXT
// RLMatrix modes (equivalent to OpenGL)
-#define RL_MODELVIEW 0x1700 // GL_MODELVIEW
-#define RL_PROJECTION 0x1701 // GL_PROJECTION
-#define RL_TEXTURE 0x1702 // GL_TEXTURE
+#define RL_MODELVIEW 0x1700 // GL_MODELVIEW
+#define RL_PROJECTION 0x1701 // GL_PROJECTION
+#define RL_TEXTURE 0x1702 // GL_TEXTURE
// Primitive assembly draw modes
-#define RL_LINES 0x0001 // GL_LINES
-#define RL_TRIANGLES 0x0004 // GL_TRIANGLES
-#define RL_QUADS 0x0007 // GL_QUADS
+#define RL_LINES 0x0001 // GL_LINES
+#define RL_TRIANGLES 0x0004 // GL_TRIANGLES
+#define RL_QUADS 0x0007 // GL_QUADS
// GL equivalent data types
-#define RL_UNSIGNED_BYTE 0x1401 // GL_UNSIGNED_BYTE
-#define RL_FLOAT 0x1406 // GL_FLOAT
+#define RL_UNSIGNED_BYTE 0x1401 // GL_UNSIGNED_BYTE
+#define RL_FLOAT 0x1406 // GL_FLOAT
// GL buffer usage hint
-#define RL_STREAM_DRAW 0x88E0 // GL_STREAM_DRAW
-#define RL_STREAM_READ 0x88E1 // GL_STREAM_READ
-#define RL_STREAM_COPY 0x88E2 // GL_STREAM_COPY
-#define RL_STATIC_DRAW 0x88E4 // GL_STATIC_DRAW
-#define RL_STATIC_READ 0x88E5 // GL_STATIC_READ
-#define RL_STATIC_COPY 0x88E6 // GL_STATIC_COPY
-#define RL_DYNAMIC_DRAW 0x88E8 // GL_DYNAMIC_DRAW
-#define RL_DYNAMIC_READ 0x88E9 // GL_DYNAMIC_READ
-#define RL_DYNAMIC_COPY 0x88EA // GL_DYNAMIC_COPY
+#define RL_STREAM_DRAW 0x88E0 // GL_STREAM_DRAW
+#define RL_STREAM_READ 0x88E1 // GL_STREAM_READ
+#define RL_STREAM_COPY 0x88E2 // GL_STREAM_COPY
+#define RL_STATIC_DRAW 0x88E4 // GL_STATIC_DRAW
+#define RL_STATIC_READ 0x88E5 // GL_STATIC_READ
+#define RL_STATIC_COPY 0x88E6 // GL_STATIC_COPY
+#define RL_DYNAMIC_DRAW 0x88E8 // GL_DYNAMIC_DRAW
+#define RL_DYNAMIC_READ 0x88E9 // GL_DYNAMIC_READ
+#define RL_DYNAMIC_COPY 0x88EA // GL_DYNAMIC_COPY
// GL Shader type
-#define RL_FRAGMENT_SHADER 0x8B30 // GL_FRAGMENT_SHADER
-#define RL_VERTEX_SHADER 0x8B31 // GL_VERTEX_SHADER
-#define RL_COMPUTE_SHADER 0x91B9 // GL_COMPUTE_SHADER
+#define RL_FRAGMENT_SHADER 0x8B30 // GL_FRAGMENT_SHADER
+#define RL_VERTEX_SHADER 0x8B31 // GL_VERTEX_SHADER
+#define RL_COMPUTE_SHADER 0x91B9 // GL_COMPUTE_SHADER
// GL blending factors
-#define RL_ZERO 0 // GL_ZERO
-#define RL_ONE 1 // GL_ONE
-#define RL_SRC_COLOR 0x0300 // GL_SRC_COLOR
-#define RL_ONE_MINUS_SRC_COLOR 0x0301 // GL_ONE_MINUS_SRC_COLOR
-#define RL_SRC_ALPHA 0x0302 // GL_SRC_ALPHA
-#define RL_ONE_MINUS_SRC_ALPHA 0x0303 // GL_ONE_MINUS_SRC_ALPHA
-#define RL_DST_ALPHA 0x0304 // GL_DST_ALPHA
-#define RL_ONE_MINUS_DST_ALPHA 0x0305 // GL_ONE_MINUS_DST_ALPHA
-#define RL_DST_COLOR 0x0306 // GL_DST_COLOR
-#define RL_ONE_MINUS_DST_COLOR 0x0307 // GL_ONE_MINUS_DST_COLOR
-#define RL_SRC_ALPHA_SATURATE 0x0308 // GL_SRC_ALPHA_SATURATE
-#define RL_CONSTANT_COLOR 0x8001 // GL_CONSTANT_COLOR
-#define RL_ONE_MINUS_CONSTANT_COLOR 0x8002 // GL_ONE_MINUS_CONSTANT_COLOR
-#define RL_CONSTANT_ALPHA 0x8003 // GL_CONSTANT_ALPHA
-#define RL_ONE_MINUS_CONSTANT_ALPHA 0x8004 // GL_ONE_MINUS_CONSTANT_ALPHA
+#define RL_ZERO 0 // GL_ZERO
+#define RL_ONE 1 // GL_ONE
+#define RL_SRC_COLOR 0x0300 // GL_SRC_COLOR
+#define RL_ONE_MINUS_SRC_COLOR 0x0301 // GL_ONE_MINUS_SRC_COLOR
+#define RL_SRC_ALPHA 0x0302 // GL_SRC_ALPHA
+#define RL_ONE_MINUS_SRC_ALPHA 0x0303 // GL_ONE_MINUS_SRC_ALPHA
+#define RL_DST_ALPHA 0x0304 // GL_DST_ALPHA
+#define RL_ONE_MINUS_DST_ALPHA 0x0305 // GL_ONE_MINUS_DST_ALPHA
+#define RL_DST_COLOR 0x0306 // GL_DST_COLOR
+#define RL_ONE_MINUS_DST_COLOR 0x0307 // GL_ONE_MINUS_DST_COLOR
+#define RL_SRC_ALPHA_SATURATE 0x0308 // GL_SRC_ALPHA_SATURATE
+#define RL_CONSTANT_COLOR 0x8001 // GL_CONSTANT_COLOR
+#define RL_ONE_MINUS_CONSTANT_COLOR 0x8002 // GL_ONE_MINUS_CONSTANT_COLOR
+#define RL_CONSTANT_ALPHA 0x8003 // GL_CONSTANT_ALPHA
+#define RL_ONE_MINUS_CONSTANT_ALPHA 0x8004 // GL_ONE_MINUS_CONSTANT_ALPHA
// GL blending functions/equations
-#define RL_FUNC_ADD 0x8006 // GL_FUNC_ADD
-#define RL_MIN 0x8007 // GL_MIN
-#define RL_MAX 0x8008 // GL_MAX
-#define RL_FUNC_SUBTRACT 0x800A // GL_FUNC_SUBTRACT
-#define RL_FUNC_REVERSE_SUBTRACT 0x800B // GL_FUNC_REVERSE_SUBTRACT
-#define RL_BLEND_EQUATION 0x8009 // GL_BLEND_EQUATION
-#define RL_BLEND_EQUATION_RGB 0x8009 // GL_BLEND_EQUATION_RGB // (Same as BLEND_EQUATION)
-#define RL_BLEND_EQUATION_ALPHA 0x883D // GL_BLEND_EQUATION_ALPHA
-#define RL_BLEND_DST_RGB 0x80C8 // GL_BLEND_DST_RGB
-#define RL_BLEND_SRC_RGB 0x80C9 // GL_BLEND_SRC_RGB
-#define RL_BLEND_DST_ALPHA 0x80CA // GL_BLEND_DST_ALPHA
-#define RL_BLEND_SRC_ALPHA 0x80CB // GL_BLEND_SRC_ALPHA
-#define RL_BLEND_COLOR 0x8005 // GL_BLEND_COLOR
-
-#define RL_READ_FRAMEBUFFER 0x8CA8 // GL_READ_FRAMEBUFFER
-#define RL_DRAW_FRAMEBUFFER 0x8CA9 // GL_DRAW_FRAMEBUFFER
+#define RL_FUNC_ADD 0x8006 // GL_FUNC_ADD
+#define RL_MIN 0x8007 // GL_MIN
+#define RL_MAX 0x8008 // GL_MAX
+#define RL_FUNC_SUBTRACT 0x800A // GL_FUNC_SUBTRACT
+#define RL_FUNC_REVERSE_SUBTRACT 0x800B // GL_FUNC_REVERSE_SUBTRACT
+#define RL_BLEND_EQUATION 0x8009 // GL_BLEND_EQUATION
+#define RL_BLEND_EQUATION_RGB 0x8009 // GL_BLEND_EQUATION_RGB // (Same as BLEND_EQUATION)
+#define RL_BLEND_EQUATION_ALPHA 0x883D // GL_BLEND_EQUATION_ALPHA
+#define RL_BLEND_DST_RGB 0x80C8 // GL_BLEND_DST_RGB
+#define RL_BLEND_SRC_RGB 0x80C9 // GL_BLEND_SRC_RGB
+#define RL_BLEND_DST_ALPHA 0x80CA // GL_BLEND_DST_ALPHA
+#define RL_BLEND_SRC_ALPHA 0x80CB // GL_BLEND_SRC_ALPHA
+#define RL_BLEND_COLOR 0x8005 // GL_BLEND_COLOR
+
+#define RL_READ_FRAMEBUFFER 0x8CA8 // GL_READ_FRAMEBUFFER
+#define RL_DRAW_FRAMEBUFFER 0x8CA9 // GL_DRAW_FRAMEBUFFER
// Default shader vertex attribute locations
#ifndef RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION
- #define RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION 0
+#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION 0
#endif
#ifndef RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD
- #define RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD 1
+#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD 1
#endif
#ifndef RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL
- #define RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL 2
+#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL 2
#endif
#ifndef RL_DEFAULT_SHADER_ATTRIB_LOCATION_COLOR
- #define RL_DEFAULT_SHADER_ATTRIB_LOCATION_COLOR 3
+#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_COLOR 3
#endif
- #ifndef RL_DEFAULT_SHADER_ATTRIB_LOCATION_TANGENT
-#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_TANGENT 4
+#ifndef RL_DEFAULT_SHADER_ATTRIB_LOCATION_TANGENT
+#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_TANGENT 4
#endif
#ifndef RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD2
- #define RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD2 5
+#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD2 5
#endif
#ifndef RL_DEFAULT_SHADER_ATTRIB_LOCATION_INDICES
- #define RL_DEFAULT_SHADER_ATTRIB_LOCATION_INDICES 6
+#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_INDICES 6
#endif
#ifdef RL_SUPPORT_MESH_GPU_SKINNING
#ifndef RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEIDS
- #define RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEIDS 7
+#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEIDS 7
#endif
#ifndef RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEWEIGHTS
- #define RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEWEIGHTS 8
+#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEWEIGHTS 8
#endif
#endif
@@ -362,275 +362,309 @@
// Types and Structures Definition
//----------------------------------------------------------------------------------
#if (defined(__STDC__) && __STDC_VERSION__ >= 199901L) || (defined(_MSC_VER) && _MSC_VER >= 1800)
- #include
+#include
#elif !defined(__cplusplus) && !defined(bool) && !defined(RL_BOOL_TYPE)
- // Boolean type
-typedef enum bool { false = 0, true = !false } bool;
+// Boolean type
+typedef enum bool {
+ false = 0,
+ true = !false
+} bool;
#endif
#if !defined(RL_MATRIX_TYPE)
// Matrix, 4x4 components, column major, OpenGL style, right handed
typedef struct RLMatrix {
- float m0, m4, m8, m12; // RLMatrix first row (4 components)
- float m1, m5, m9, m13; // RLMatrix second row (4 components)
- float m2, m6, m10, m14; // RLMatrix third row (4 components)
- float m3, m7, m11, m15; // RLMatrix fourth row (4 components)
+ float m0, m4, m8, m12; // RLMatrix first row (4 components)
+ float m1, m5, m9, m13; // RLMatrix second row (4 components)
+ float m2, m6, m10, m14; // RLMatrix third row (4 components)
+ float m3, m7, m11, m15; // RLMatrix fourth row (4 components)
} RLMatrix;
#define RL_MATRIX_TYPE
#endif
-// Dynamic vertex buffers (position + texcoords + colors + indices arrays)
-typedef struct rlVertexBuffer {
- int elementCount; // Number of elements in the buffer (QUADS)
-
- float *vertices; // Vertex position (XYZ - 3 components per vertex) (shader-location = 0)
- float *texcoords; // Vertex texture coordinates (UV - 2 components per vertex) (shader-location = 1)
- float *normals; // Vertex normal (XYZ - 3 components per vertex) (shader-location = 2)
- unsigned char *colors; // Vertex colors (RGBA - 4 components per vertex) (shader-location = 3)
-#if defined(GRAPHICS_API_OPENGL_11) || defined(GRAPHICS_API_OPENGL_33)
- unsigned int *indices; // Vertex indices (in case vertex data comes indexed) (6 indices per quad)
-#endif
-#if defined(GRAPHICS_API_OPENGL_ES2)
- unsigned short *indices; // Vertex indices (in case vertex data comes indexed) (6 indices per quad)
-#endif
- unsigned int vaoId; // OpenGL Vertex Array Object id
- unsigned int vboId[5]; // OpenGL Vertex Buffer Objects id (5 types of vertex data)
-} rlVertexBuffer;
-
-// Draw call type
-// NOTE: Only texture changes register a new draw, other state-change-related elements are not
-// used at this moment (vaoId, shaderId, matrices), raylib just forces a batch draw call if any
-// of those state-change happens (this is done in core module)
-typedef struct rlDrawCall {
- int mode; // Drawing mode: LINES, TRIANGLES, QUADS
- int vertexCount; // Number of vertex of the draw
- int vertexAlignment; // Number of vertex required for index alignment (LINES, TRIANGLES)
- //unsigned int vaoId; // Vertex array id to be used on the draw -> Using RLGL.currentBatch->vertexBuffer.vaoId
- //unsigned int shaderId; // Shader id to be used on the draw -> Using RLGL.currentShaderId
- //rlUniformValue* shaderUniforms;
- unsigned int textureId; // Texture id to be used on the draw -> Use to create new draw call if changes
-
- //Matrix projection; // Projection matrix for this draw -> Using RLGL.projection by default
- //Matrix modelview; // Modelview matrix for this draw -> Using RLGL.modelview by default
-} rlDrawCall;
-
-// rlRenderBatch type
-typedef struct rlRenderBatch {
- int bufferCount; // Number of vertex buffers (multi-buffering support)
- int currentBuffer; // Current buffer tracking in case of multi-buffering
- rlVertexBuffer *vertexBuffer; // Dynamic buffer(s) for vertex data
-
- rlDrawCall *draws; // Draw calls array, depends on textureId
- int drawCounter; // Draw calls counter
- float currentDepth; // Current depth value for next draw
- float currentZ; // Current z order added to depth.
-} rlRenderBatch;
-
// OpenGL version
typedef enum {
- RL_OPENGL_11 = 1, // OpenGL 1.1
- RL_OPENGL_21, // OpenGL 2.1 (GLSL 120)
- RL_OPENGL_33, // OpenGL 3.3 (GLSL 330)
- RL_OPENGL_43, // OpenGL 4.3 (using GLSL 330)
- RL_OPENGL_ES_20, // OpenGL ES 2.0 (GLSL 100)
- RL_OPENGL_ES_30 // OpenGL ES 3.0 (GLSL 300 es)
+ RL_OPENGL_11 = 1, // OpenGL 1.1
+ RL_OPENGL_21, // OpenGL 2.1 (GLSL 120)
+ RL_OPENGL_33, // OpenGL 3.3 (GLSL 330)
+ RL_OPENGL_43, // OpenGL 4.3 (using GLSL 330)
+ RL_OPENGL_ES_20, // OpenGL ES 2.0 (GLSL 100)
+ RL_OPENGL_ES_30 // OpenGL ES 3.0 (GLSL 300 es)
} rlGlVersion;
// Trace log level
// NOTE: Organized by priority level
typedef enum {
- RL_LOG_ALL = 0, // Display all logs
- RL_LOG_TRACE, // Trace logging, intended for internal use only
- RL_LOG_DEBUG, // Debug logging, used for internal debugging, it should be disabled on release builds
- RL_LOG_INFO, // Info logging, used for program execution info
- RL_LOG_WARNING, // Warning logging, used on recoverable failures
- RL_LOG_ERROR, // Error logging, used on unrecoverable failures
- RL_LOG_FATAL, // Fatal logging, used to abort program: exit(EXIT_FAILURE)
- RL_LOG_NONE // Disable logging
+ RL_LOG_ALL = 0, // Display all logs
+ RL_LOG_TRACE, // Trace logging, intended for internal use only
+ RL_LOG_DEBUG, // Debug logging, used for internal debugging, it should be disabled on release builds
+ RL_LOG_INFO, // Info logging, used for program execution info
+ RL_LOG_WARNING, // Warning logging, used on recoverable failures
+ RL_LOG_ERROR, // Error logging, used on unrecoverable failures
+ RL_LOG_FATAL, // Fatal logging, used to abort program: exit(EXIT_FAILURE)
+ RL_LOG_NONE // Disable logging
} rlTraceLogLevel;
// Texture pixel formats
// NOTE: Support depends on OpenGL version
typedef enum {
- RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE = 1, // 8 bit per pixel (no alpha)
- RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA, // 8*2 bpp (2 channels)
- RL_PIXELFORMAT_UNCOMPRESSED_R5G6B5, // 16 bpp
- RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8, // 24 bpp
- RL_PIXELFORMAT_UNCOMPRESSED_R5G5B5A1, // 16 bpp (1 bit alpha)
- RL_PIXELFORMAT_UNCOMPRESSED_R4G4B4A4, // 16 bpp (4 bit alpha)
- RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8, // 32 bpp
- RL_PIXELFORMAT_UNCOMPRESSED_R32, // 32 bpp (1 channel - float)
- RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32, // 32*3 bpp (3 channels - float)
- RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32, // 32*4 bpp (4 channels - float)
- RL_PIXELFORMAT_UNCOMPRESSED_R16, // 16 bpp (1 channel - half float)
- RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16, // 16*3 bpp (3 channels - half float)
- RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16, // 16*4 bpp (4 channels - half float)
- RL_PIXELFORMAT_COMPRESSED_DXT1_RGB, // 4 bpp (no alpha)
- RL_PIXELFORMAT_COMPRESSED_DXT1_RGBA, // 4 bpp (1 bit alpha)
- RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA, // 8 bpp
- RL_PIXELFORMAT_COMPRESSED_DXT5_RGBA, // 8 bpp
- RL_PIXELFORMAT_COMPRESSED_ETC1_RGB, // 4 bpp
- RL_PIXELFORMAT_COMPRESSED_ETC2_RGB, // 4 bpp
- RL_PIXELFORMAT_COMPRESSED_ETC2_EAC_RGBA, // 8 bpp
- RL_PIXELFORMAT_COMPRESSED_PVRT_RGB, // 4 bpp
- RL_PIXELFORMAT_COMPRESSED_PVRT_RGBA, // 4 bpp
- RL_PIXELFORMAT_COMPRESSED_ASTC_4x4_RGBA, // 8 bpp
- RL_PIXELFORMAT_COMPRESSED_ASTC_8x8_RGBA // 2 bpp
+ RL_PIXELFORMAT_UNCOMPRESSED_GRAYSCALE = 1, // 8 bit per pixel (no alpha)
+ RL_PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA, // 8*2 bpp (2 channels)
+ RL_PIXELFORMAT_UNCOMPRESSED_R5G6B5, // 16 bpp
+ RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8, // 24 bpp
+ RL_PIXELFORMAT_UNCOMPRESSED_R5G5B5A1, // 16 bpp (1 bit alpha)
+ RL_PIXELFORMAT_UNCOMPRESSED_R4G4B4A4, // 16 bpp (4 bit alpha)
+ RL_PIXELFORMAT_UNCOMPRESSED_R8G8B8A8, // 32 bpp
+ RL_PIXELFORMAT_UNCOMPRESSED_R32, // 32 bpp (1 channel - float)
+ RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32, // 32*3 bpp (3 channels - float)
+ RL_PIXELFORMAT_UNCOMPRESSED_R32G32B32A32, // 32*4 bpp (4 channels - float)
+ RL_PIXELFORMAT_UNCOMPRESSED_R16, // 16 bpp (1 channel - half float)
+ RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16, // 16*3 bpp (3 channels - half float)
+ RL_PIXELFORMAT_UNCOMPRESSED_R16G16B16A16, // 16*4 bpp (4 channels - half float)
+ RL_PIXELFORMAT_COMPRESSED_DXT1_RGB, // 4 bpp (no alpha)
+ RL_PIXELFORMAT_COMPRESSED_DXT1_RGBA, // 4 bpp (1 bit alpha)
+ RL_PIXELFORMAT_COMPRESSED_DXT3_RGBA, // 8 bpp
+ RL_PIXELFORMAT_COMPRESSED_DXT5_RGBA, // 8 bpp
+ RL_PIXELFORMAT_COMPRESSED_ETC1_RGB, // 4 bpp
+ RL_PIXELFORMAT_COMPRESSED_ETC2_RGB, // 4 bpp
+ RL_PIXELFORMAT_COMPRESSED_ETC2_EAC_RGBA, // 8 bpp
+ RL_PIXELFORMAT_COMPRESSED_PVRT_RGB, // 4 bpp
+ RL_PIXELFORMAT_COMPRESSED_PVRT_RGBA, // 4 bpp
+ RL_PIXELFORMAT_COMPRESSED_ASTC_4x4_RGBA, // 8 bpp
+ RL_PIXELFORMAT_COMPRESSED_ASTC_8x8_RGBA // 2 bpp
} rlPixelFormat;
// Texture parameters: filter mode
// NOTE 1: Filtering considers mipmaps if available in the texture
// NOTE 2: Filter is accordingly set for minification and magnification
typedef enum {
- RL_TEXTURE_FILTER_POINT = 0, // No filter, just pixel approximation
- RL_TEXTURE_FILTER_BILINEAR, // Linear filtering
- RL_TEXTURE_FILTER_TRILINEAR, // Trilinear filtering (linear with mipmaps)
- RL_TEXTURE_FILTER_ANISOTROPIC_4X, // Anisotropic filtering 4x
- RL_TEXTURE_FILTER_ANISOTROPIC_8X, // Anisotropic filtering 8x
- RL_TEXTURE_FILTER_ANISOTROPIC_16X, // Anisotropic filtering 16x
+ RL_TEXTURE_FILTER_POINT = 0, // No filter, just pixel approximation
+ RL_TEXTURE_FILTER_BILINEAR, // Linear filtering
+ RL_TEXTURE_FILTER_TRILINEAR, // Trilinear filtering (linear with mipmaps)
+ RL_TEXTURE_FILTER_ANISOTROPIC_4X, // Anisotropic filtering 4x
+ RL_TEXTURE_FILTER_ANISOTROPIC_8X, // Anisotropic filtering 8x
+ RL_TEXTURE_FILTER_ANISOTROPIC_16X, // Anisotropic filtering 16x
} rlTextureFilter;
// Color blending modes (pre-defined)
typedef enum {
- RL_BLEND_ALPHA = 0, // Blend textures considering alpha (default)
- RL_BLEND_ADDITIVE, // Blend textures adding colors
- RL_BLEND_MULTIPLIED, // Blend textures multiplying colors
- RL_BLEND_ADD_COLORS, // Blend textures adding colors (alternative)
- RL_BLEND_SUBTRACT_COLORS, // Blend textures subtracting colors (alternative)
- RL_BLEND_ALPHA_PREMULTIPLY, // Blend premultiplied textures considering alpha
- RL_BLEND_CUSTOM, // Blend textures using custom src/dst factors (use rlSetBlendFactors())
- RL_BLEND_CUSTOM_SEPARATE // Blend textures using custom src/dst factors (use rlSetBlendFactorsSeparate())
+ RL_BLEND_ALPHA = 0, // Blend textures considering alpha (default)
+ RL_BLEND_BURN,
+ RL_BLEND_DODGE,
+ RL_BLEND_SCREEN,
+ RL_BLEND_HSL_COLOR,
+ RL_BLEND_HSL_SATURATION,
+ RL_BLEND_HSL_LUMINOSITY,
+ RL_BLEND_HSL_HUE,
+ RL_BLEND_ADDITIVE, // Blend textures adding colors
+ RL_BLEND_MULTIPLIED, // Blend textures multiplying colors
+ RL_BLEND_ADD_COLORS, // Blend textures adding colors (alternative)
+ RL_BLEND_SUBTRACT_COLORS, // Blend textures subtracting colors (alternative)
+ RL_BLEND_ALPHA_PREMULTIPLY, // Blend premultiplied textures considering alpha
+ RL_BLEND_CUSTOM, // Blend textures using custom src/dst factors (use rlSetBlendFactors())
+ RL_BLEND_CUSTOM_SEPARATE // Blend textures using custom src/dst factors (use rlSetBlendFactorsSeparate())
} rlBlendMode;
// Shader location point type
typedef enum {
- RL_SHADER_LOC_VERTEX_POSITION = 0, // Shader location: vertex attribute: position
- RL_SHADER_LOC_VERTEX_TEXCOORD01, // Shader location: vertex attribute: texcoord01
- RL_SHADER_LOC_VERTEX_TEXCOORD02, // Shader location: vertex attribute: texcoord02
- RL_SHADER_LOC_VERTEX_NORMAL, // Shader location: vertex attribute: normal
- RL_SHADER_LOC_VERTEX_TANGENT, // Shader location: vertex attribute: tangent
- RL_SHADER_LOC_VERTEX_COLOR, // Shader location: vertex attribute: color
- RL_SHADER_LOC_MATRIX_MVP, // Shader location: matrix uniform: model-view-projection
- RL_SHADER_LOC_MATRIX_VIEW, // Shader location: matrix uniform: view (camera transform)
- RL_SHADER_LOC_MATRIX_PROJECTION, // Shader location: matrix uniform: projection
- RL_SHADER_LOC_MATRIX_MODEL, // Shader location: matrix uniform: model (transform)
- RL_SHADER_LOC_MATRIX_NORMAL, // Shader location: matrix uniform: normal
- RL_SHADER_LOC_VECTOR_VIEW, // Shader location: vector uniform: view
- RL_SHADER_LOC_COLOR_DIFFUSE, // Shader location: vector uniform: diffuse color
- RL_SHADER_LOC_COLOR_SPECULAR, // Shader location: vector uniform: specular color
- RL_SHADER_LOC_COLOR_AMBIENT, // Shader location: vector uniform: ambient color
- RL_SHADER_LOC_MAP_ALBEDO, // Shader location: sampler2d texture: albedo (same as: RL_SHADER_LOC_MAP_DIFFUSE)
- RL_SHADER_LOC_MAP_METALNESS, // Shader location: sampler2d texture: metalness (same as: RL_SHADER_LOC_MAP_SPECULAR)
- RL_SHADER_LOC_MAP_NORMAL, // Shader location: sampler2d texture: normal
- RL_SHADER_LOC_MAP_ROUGHNESS, // Shader location: sampler2d texture: roughness
- RL_SHADER_LOC_MAP_OCCLUSION, // Shader location: sampler2d texture: occlusion
- RL_SHADER_LOC_MAP_EMISSION, // Shader location: sampler2d texture: emission
- RL_SHADER_LOC_MAP_HEIGHT, // Shader location: sampler2d texture: height
- RL_SHADER_LOC_MAP_CUBEMAP, // Shader location: samplerCube texture: cubemap
- RL_SHADER_LOC_MAP_IRRADIANCE, // Shader location: samplerCube texture: irradiance
- RL_SHADER_LOC_MAP_PREFILTER, // Shader location: samplerCube texture: prefilter
- RL_SHADER_LOC_MAP_BRDF, // Shader location: sampler2d texture: brdf
- RL_SHADER_LOC_COUNT
+ RL_SHADER_LOC_VERTEX_POSITION = 0, // Shader location: vertex attribute: position
+ RL_SHADER_LOC_VERTEX_TEXCOORD01, // Shader location: vertex attribute: texcoord01
+ RL_SHADER_LOC_VERTEX_TEXCOORD02, // Shader location: vertex attribute: texcoord02
+ RL_SHADER_LOC_VERTEX_NORMAL, // Shader location: vertex attribute: normal
+ RL_SHADER_LOC_VERTEX_TANGENT, // Shader location: vertex attribute: tangent
+ RL_SHADER_LOC_VERTEX_COLOR, // Shader location: vertex attribute: color
+ RL_SHADER_LOC_MATRIX_MVP, // Shader location: matrix uniform: model-view-projection
+ RL_SHADER_LOC_MATRIX_VIEW, // Shader location: matrix uniform: view (camera transform)
+ RL_SHADER_LOC_MATRIX_PROJECTION, // Shader location: matrix uniform: projection
+ RL_SHADER_LOC_MATRIX_MODEL, // Shader location: matrix uniform: model (transform)
+ RL_SHADER_LOC_MATRIX_NORMAL, // Shader location: matrix uniform: normal
+ RL_SHADER_LOC_VECTOR_VIEW, // Shader location: vector uniform: view
+ RL_SHADER_LOC_COLOR_DIFFUSE, // Shader location: vector uniform: diffuse color
+ RL_SHADER_LOC_COLOR_SPECULAR, // Shader location: vector uniform: specular color
+ RL_SHADER_LOC_COLOR_AMBIENT, // Shader location: vector uniform: ambient color
+ RL_SHADER_LOC_MAP_ALBEDO, // Shader location: sampler2d texture: albedo (same as: RL_SHADER_LOC_MAP_DIFFUSE)
+ RL_SHADER_LOC_MAP_METALNESS, // Shader location: sampler2d texture: metalness (same as: RL_SHADER_LOC_MAP_SPECULAR)
+ RL_SHADER_LOC_MAP_NORMAL, // Shader location: sampler2d texture: normal
+ RL_SHADER_LOC_MAP_ROUGHNESS, // Shader location: sampler2d texture: roughness
+ RL_SHADER_LOC_MAP_OCCLUSION, // Shader location: sampler2d texture: occlusion
+ RL_SHADER_LOC_MAP_EMISSION, // Shader location: sampler2d texture: emission
+ RL_SHADER_LOC_MAP_HEIGHT, // Shader location: sampler2d texture: height
+ RL_SHADER_LOC_MAP_CUBEMAP, // Shader location: samplerCube texture: cubemap
+ RL_SHADER_LOC_MAP_IRRADIANCE, // Shader location: samplerCube texture: irradiance
+ RL_SHADER_LOC_MAP_PREFILTER, // Shader location: samplerCube texture: prefilter
+ RL_SHADER_LOC_MAP_BRDF, // Shader location: sampler2d texture: brdf
+ RL_SHADER_LOC_COUNT
} rlShaderLocationIndex;
-#define RL_SHADER_LOC_MAP_DIFFUSE RL_SHADER_LOC_MAP_ALBEDO
-#define RL_SHADER_LOC_MAP_SPECULAR RL_SHADER_LOC_MAP_METALNESS
+#define RL_SHADER_LOC_MAP_DIFFUSE RL_SHADER_LOC_MAP_ALBEDO
+#define RL_SHADER_LOC_MAP_SPECULAR RL_SHADER_LOC_MAP_METALNESS
// Shader uniform data type
typedef enum {
- RL_SHADER_UNIFORM_FLOAT = 0, // Shader uniform type: float
- RL_SHADER_UNIFORM_VEC2, // Shader uniform type: vec2 (2 float)
- RL_SHADER_UNIFORM_VEC3, // Shader uniform type: vec3 (3 float)
- RL_SHADER_UNIFORM_VEC4, // Shader uniform type: vec4 (4 float)
- RL_SHADER_UNIFORM_INT, // Shader uniform type: int
- RL_SHADER_UNIFORM_IVEC2, // Shader uniform type: ivec2 (2 int)
- RL_SHADER_UNIFORM_IVEC3, // Shader uniform type: ivec3 (3 int)
- RL_SHADER_UNIFORM_IVEC4, // Shader uniform type: ivec4 (4 int)
- RL_SHADER_UNIFORM_UINT, // Shader uniform type: unsigned int
- RL_SHADER_UNIFORM_UIVEC2, // Shader uniform type: uivec2 (2 unsigned int)
- RL_SHADER_UNIFORM_UIVEC3, // Shader uniform type: uivec3 (3 unsigned int)
- RL_SHADER_UNIFORM_UIVEC4, // Shader uniform type: uivec4 (4 unsigned int)
- RL_SHADER_UNIFORM_SAMPLER2D // Shader uniform type: sampler2d
+ RL_SHADER_UNIFORM_INVALID = -1,
+ RL_SHADER_UNIFORM_FLOAT = 0, // Shader uniform type: float
+ RL_SHADER_UNIFORM_VEC2, // Shader uniform type: vec2 (2 float)
+ RL_SHADER_UNIFORM_VEC3, // Shader uniform type: vec3 (3 float)
+ RL_SHADER_UNIFORM_VEC4, // Shader uniform type: vec4 (4 float)
+ RL_SHADER_UNIFORM_INT, // Shader uniform type: int
+ RL_SHADER_UNIFORM_IVEC2, // Shader uniform type: ivec2 (2 int)
+ RL_SHADER_UNIFORM_IVEC3, // Shader uniform type: ivec3 (3 int)
+ RL_SHADER_UNIFORM_IVEC4, // Shader uniform type: ivec4 (4 int)
+ RL_SHADER_UNIFORM_UINT, // Shader uniform type: unsigned int
+ RL_SHADER_UNIFORM_UIVEC2, // Shader uniform type: uivec2 (2 unsigned int)
+ RL_SHADER_UNIFORM_UIVEC3, // Shader uniform type: uivec3 (3 unsigned int)
+ RL_SHADER_UNIFORM_UIVEC4, // Shader uniform type: uivec4 (4 unsigned int)
+ RL_SHADER_UNIFORM_SAMPLER2D // Shader uniform type: sampler2d
} rlShaderUniformDataType;
// Shader attribute data types
typedef enum {
- RL_SHADER_ATTRIB_FLOAT = 0, // Shader attribute type: float
- RL_SHADER_ATTRIB_VEC2, // Shader attribute type: vec2 (2 float)
- RL_SHADER_ATTRIB_VEC3, // Shader attribute type: vec3 (3 float)
- RL_SHADER_ATTRIB_VEC4 // Shader attribute type: vec4 (4 float)
+ RL_SHADER_ATTRIB_FLOAT = 0, // Shader attribute type: float
+ RL_SHADER_ATTRIB_VEC2, // Shader attribute type: vec2 (2 float)
+ RL_SHADER_ATTRIB_VEC3, // Shader attribute type: vec3 (3 float)
+ RL_SHADER_ATTRIB_VEC4 // Shader attribute type: vec4 (4 float)
} rlShaderAttributeDataType;
// Framebuffer attachment type
// NOTE: By default up to 8 color channels defined, but it can be more
typedef enum {
- RL_ATTACHMENT_COLOR_CHANNEL0 = 0, // Framebuffer attachment type: color 0
- RL_ATTACHMENT_COLOR_CHANNEL1 = 1, // Framebuffer attachment type: color 1
- RL_ATTACHMENT_COLOR_CHANNEL2 = 2, // Framebuffer attachment type: color 2
- RL_ATTACHMENT_COLOR_CHANNEL3 = 3, // Framebuffer attachment type: color 3
- RL_ATTACHMENT_COLOR_CHANNEL4 = 4, // Framebuffer attachment type: color 4
- RL_ATTACHMENT_COLOR_CHANNEL5 = 5, // Framebuffer attachment type: color 5
- RL_ATTACHMENT_COLOR_CHANNEL6 = 6, // Framebuffer attachment type: color 6
- RL_ATTACHMENT_COLOR_CHANNEL7 = 7, // Framebuffer attachment type: color 7
- RL_ATTACHMENT_DEPTH = 100, // Framebuffer attachment type: depth
- RL_ATTACHMENT_STENCIL = 200, // Framebuffer attachment type: stencil
+ RL_ATTACHMENT_COLOR_CHANNEL0 = 0, // Framebuffer attachment type: color 0
+ RL_ATTACHMENT_COLOR_CHANNEL1 = 1, // Framebuffer attachment type: color 1
+ RL_ATTACHMENT_COLOR_CHANNEL2 = 2, // Framebuffer attachment type: color 2
+ RL_ATTACHMENT_COLOR_CHANNEL3 = 3, // Framebuffer attachment type: color 3
+ RL_ATTACHMENT_COLOR_CHANNEL4 = 4, // Framebuffer attachment type: color 4
+ RL_ATTACHMENT_COLOR_CHANNEL5 = 5, // Framebuffer attachment type: color 5
+ RL_ATTACHMENT_COLOR_CHANNEL6 = 6, // Framebuffer attachment type: color 6
+ RL_ATTACHMENT_COLOR_CHANNEL7 = 7, // Framebuffer attachment type: color 7
+ RL_ATTACHMENT_DEPTH = 100, // Framebuffer attachment type: depth
+ RL_ATTACHMENT_STENCIL = 200, // Framebuffer attachment type: stencil
} rlFramebufferAttachType;
// Framebuffer texture attachment type
typedef enum {
- RL_ATTACHMENT_CUBEMAP_POSITIVE_X = 0, // Framebuffer texture attachment type: cubemap, +X side
- RL_ATTACHMENT_CUBEMAP_NEGATIVE_X = 1, // Framebuffer texture attachment type: cubemap, -X side
- RL_ATTACHMENT_CUBEMAP_POSITIVE_Y = 2, // Framebuffer texture attachment type: cubemap, +Y side
- RL_ATTACHMENT_CUBEMAP_NEGATIVE_Y = 3, // Framebuffer texture attachment type: cubemap, -Y side
- RL_ATTACHMENT_CUBEMAP_POSITIVE_Z = 4, // Framebuffer texture attachment type: cubemap, +Z side
- RL_ATTACHMENT_CUBEMAP_NEGATIVE_Z = 5, // Framebuffer texture attachment type: cubemap, -Z side
- RL_ATTACHMENT_TEXTURE2D = 100, // Framebuffer texture attachment type: texture2d
- RL_ATTACHMENT_RENDERBUFFER = 200, // Framebuffer texture attachment type: renderbuffer
+ RL_ATTACHMENT_CUBEMAP_POSITIVE_X = 0, // Framebuffer texture attachment type: cubemap, +X side
+ RL_ATTACHMENT_CUBEMAP_NEGATIVE_X = 1, // Framebuffer texture attachment type: cubemap, -X side
+ RL_ATTACHMENT_CUBEMAP_POSITIVE_Y = 2, // Framebuffer texture attachment type: cubemap, +Y side
+ RL_ATTACHMENT_CUBEMAP_NEGATIVE_Y = 3, // Framebuffer texture attachment type: cubemap, -Y side
+ RL_ATTACHMENT_CUBEMAP_POSITIVE_Z = 4, // Framebuffer texture attachment type: cubemap, +Z side
+ RL_ATTACHMENT_CUBEMAP_NEGATIVE_Z = 5, // Framebuffer texture attachment type: cubemap, -Z side
+ RL_ATTACHMENT_TEXTURE2D = 100, // Framebuffer texture attachment type: texture2d
+ RL_ATTACHMENT_RENDERBUFFER = 200, // Framebuffer texture attachment type: renderbuffer
} rlFramebufferAttachTextureType;
// Face culling mode
typedef enum {
- RL_CULL_FACE_FRONT = 0,
- RL_CULL_FACE_BACK
+ RL_CULL_FACE_FRONT = 0,
+ RL_CULL_FACE_BACK
} rlCullMode;
+// Dynamic vertex buffers (position + texcoords + colors + indices arrays)
+typedef struct rlVertexBuffer {
+ int elementCount; // Number of elements in the buffer (QUADS)
+
+ float* vertices; // Vertex position (XYZ - 3 components per vertex) (shader-location = 0)
+ float* texcoords; // Vertex texture coordinates (UV - 2 components per vertex) (shader-location = 1)
+ float* normals; // Vertex normal (XYZ - 3 components per vertex) (shader-location = 2)
+ unsigned char* colors; // Vertex colors (RGBA - 4 components per vertex) (shader-location = 3)
+#if defined(GRAPHICS_API_OPENGL_11) || defined(GRAPHICS_API_OPENGL_33)
+ unsigned int* indices; // Vertex indices (in case vertex data comes indexed) (6 indices per quad)
+#endif
+#if defined(GRAPHICS_API_OPENGL_ES2)
+ unsigned short* indices; // Vertex indices (in case vertex data comes indexed) (6 indices per quad)
+#endif
+ unsigned int vaoId; // OpenGL Vertex Array Object id
+ unsigned int vboId[5]; // OpenGL Vertex Buffer Objects id (5 types of vertex data)
+} rlVertexBuffer;
+
+typedef struct rlUniformValue {
+ union {
+ RLMatrix matrixValue;
+ float vectorValue[4];
+ int integerValue[4];
+ unsigned int unsignedValue[4];
+ };
+ rlShaderUniformDataType uniformType;
+ int location;
+} rlUniformValue;
+
+// Draw call type
+// NOTE: Only texture changes register a new draw, other state-change-related elements are not
+// used at this moment (vaoId, shaderId, matrices), raylib just forces a batch draw call if any
+// of those state-change happens (this is done in core module)
+typedef struct rlDrawCall {
+ int mode; // Drawing mode: LINES, TRIANGLES, QUADS
+ int vertexCount; // Number of vertex of the draw
+ int vertexAlignment; // Number of vertex required for index alignment (LINES, TRIANGLES)
+ // unsigned int vaoId; // Vertex array id to be used on the draw -> Using RLGL.currentBatch->vertexBuffer.vaoId
+ // unsigned int shaderId; // Shader id to be used on the draw -> Using RLGL.currentShaderId
+ // rlUniformValue* shaderUniforms;
+ unsigned int textureId; // Texture id to be used on the draw -> Use to create new draw call if changes
+
+ // Blending variables
+ int currentBlendMode; // Blending mode active
+ int BlendSrcFactor; // Blending source factor
+ int BlendDstFactor; // Blending destination factor
+ int BlendEquation; // Blending equation
+ int BlendSrcFactorRGB; // Blending source RGB factor
+ int BlendDestFactorRGB; // Blending destination RGB factor
+ int BlendSrcFactorAlpha; // Blending source alpha factor
+ int BlendDestFactorAlpha; // Blending destination alpha factor
+ int BlendEquationRGB; // Blending equation for RGB
+ int BlendEquationAlpha; // Blending equation for alpha
+
+ // Matrix projection; // Projection matrix for this draw -> Using RLGL.projection by default
+ // Matrix modelview; // Modelview matrix for this draw -> Using RLGL.modelview by default
+} rlDrawCall;
+
+// rlRenderBatch type
+typedef struct rlRenderBatch {
+ int bufferCount; // Number of vertex buffers (multi-buffering support)
+ int currentBuffer; // Current buffer tracking in case of multi-buffering
+ rlVertexBuffer* vertexBuffer; // Dynamic buffer(s) for vertex data
+
+ rlDrawCall* draws; // Draw calls array, depends on textureId
+ int drawCounter; // Draw calls counter
+ float currentDepth; // Current depth value for next draw
+ float currentZ; // Current z order added to depth.
+} rlRenderBatch;
+
//------------------------------------------------------------------------------------
// Functions Declaration - RLMatrix operations
//------------------------------------------------------------------------------------
#if defined(__cplusplus)
-extern "C" { // Prevents name mangling of functions
+extern "C" { // Prevents name mangling of functions
#endif
-RLAPI void rlMatrixMode(int mode); // Choose the current matrix to be transformed
-RLAPI void rlPushMatrix(void); // Push the current matrix to stack
-RLAPI void rlPopMatrix(void); // Pop latest inserted matrix from stack
-RLAPI void rlLoadIdentity(void); // Reset current matrix to identity matrix
-RLAPI void rlTranslatef(float x, float y, float z); // Multiply the current matrix by a translation matrix
+RLAPI void rlMatrixMode(int mode); // Choose the current matrix to be transformed
+RLAPI void rlPushMatrix(void); // Push the current matrix to stack
+RLAPI void rlPopMatrix(void); // Pop latest inserted matrix from stack
+RLAPI void rlLoadIdentity(void); // Reset current matrix to identity matrix
+RLAPI void rlTranslatef(float x, float y, float z); // Multiply the current matrix by a translation matrix
RLAPI void rlRotatef(float angle, float x, float y, float z); // Multiply the current matrix by a rotation matrix
-RLAPI void rlScalef(float x, float y, float z); // Multiply the current matrix by a scaling matrix
-RLAPI void rlMultMatrixf(const float *matf); // Multiply the current matrix by another matrix
+RLAPI void rlScalef(float x, float y, float z); // Multiply the current matrix by a scaling matrix
+RLAPI void rlMultMatrixf(const float* matf); // Multiply the current matrix by another matrix
RLAPI void rlFrustum(double left, double right, double bottom, double top, double znear, double zfar);
RLAPI void rlOrtho(double left, double right, double bottom, double top, double znear, double zfar);
RLAPI void rlViewport(int x, int y, int width, int height); // Set the viewport area
-RLAPI void rlSetClipPlanes(double nearPlane, double farPlane); // Set clip planes distances
-RLAPI double rlGetCullDistanceNear(void); // Get cull plane distance near
-RLAPI double rlGetCullDistanceFar(void); // Get cull plane distance far
+RLAPI void rlSetClipPlanes(double nearPlane, double farPlane); // Set clip planes distances
+RLAPI double rlGetCullDistanceNear(void); // Get cull plane distance near
+RLAPI double rlGetCullDistanceFar(void); // Get cull plane distance far
//------------------------------------------------------------------------------------
// Functions Declaration - Vertex level operations
//------------------------------------------------------------------------------------
-RLAPI void rlBegin(int mode); // Initialize drawing mode (how to organize vertex)
-RLAPI void rlEnd(void); // Finish vertex providing
-RLAPI void rlVertex2i(int x, int y); // Define one vertex (position) - 2 int
-RLAPI void rlVertex2f(float x, float y); // Define one vertex (position) - 2 float
-RLAPI void rlVertex3f(float x, float y, float z); // Define one vertex (position) - 3 float
-RLAPI void rlTexCoord2f(float x, float y); // Define one vertex (texture coordinate) - 2 float
-RLAPI void rlNormal3f(float x, float y, float z); // Define one vertex (normal) - 3 float
+RLAPI void rlBegin(int mode); // Initialize drawing mode (how to organize vertex)
+RLAPI void rlEnd(void); // Finish vertex providing
+RLAPI void rlVertex2i(int x, int y); // Define one vertex (position) - 2 int
+RLAPI void rlVertex2f(float x, float y); // Define one vertex (position) - 2 float
+RLAPI void rlVertex3f(float x, float y, float z); // Define one vertex (position) - 3 float
+RLAPI void rlTexCoord2f(float x, float y); // Define one vertex (texture coordinate) - 2 float
+RLAPI void rlNormal3f(float x, float y, float z); // Define one vertex (normal) - 3 float
RLAPI void rlColor4ub(unsigned char r, unsigned char g, unsigned char b, unsigned char a); // Define one vertex (color) - 4 byte
-RLAPI void rlColor3f(float x, float y, float z); // Define one vertex (color) - 3 float
+RLAPI void rlColor3f(float x, float y, float z); // Define one vertex (color) - 3 float
RLAPI void rlColor4f(float x, float y, float z, float w); // Define one vertex (color) - 4 float
-RLAPI void rlZDepth(float z); // Set current draw depth for Vertex2(i,f).
+RLAPI void rlZDepth(float z); // Set current draw depth for Vertex2(i,f).
//------------------------------------------------------------------------------------
// Functions Declaration - OpenGL style functions (common to 1.1, 3.3+, ES2)
@@ -639,69 +673,71 @@ RLAPI void rlZDepth(float z); // Set current draw dept
//------------------------------------------------------------------------------------
// Vertex buffers state
-RLAPI bool rlEnableVertexArray(unsigned int vaoId); // Enable vertex array (VAO, if supported)
-RLAPI void rlDisableVertexArray(void); // Disable vertex array (VAO, if supported)
-RLAPI void rlEnableVertexBuffer(unsigned int id); // Enable vertex buffer (VBO)
-RLAPI void rlDisableVertexBuffer(void); // Disable vertex buffer (VBO)
+RLAPI bool rlEnableVertexArray(unsigned int vaoId); // Enable vertex array (VAO, if supported)
+RLAPI void rlDisableVertexArray(void); // Disable vertex array (VAO, if supported)
+RLAPI void rlEnableVertexBuffer(unsigned int id); // Enable vertex buffer (VBO)
+RLAPI void rlDisableVertexBuffer(void); // Disable vertex buffer (VBO)
RLAPI void rlEnableVertexBufferElement(unsigned int id); // Enable vertex buffer element (VBO element)
-RLAPI void rlDisableVertexBufferElement(void); // Disable vertex buffer element (VBO element)
+RLAPI void rlDisableVertexBufferElement(void); // Disable vertex buffer element (VBO element)
RLAPI void rlEnableVertexAttribute(unsigned int index); // Enable vertex attribute index
RLAPI void rlDisableVertexAttribute(unsigned int index); // Disable vertex attribute index
#if defined(GRAPHICS_API_OPENGL_11)
-RLAPI void rlEnableStatePointer(int vertexAttribType, void *buffer); // Enable attribute state pointer
+RLAPI void rlEnableStatePointer(int vertexAttribType, void* buffer); // Enable attribute state pointer
RLAPI void rlDisableStatePointer(int vertexAttribType); // Disable attribute state pointer
#endif
// Textures state
-RLAPI void rlActiveTextureSlot(int slot); // Select and active a texture slot
-RLAPI void rlEnableTexture(unsigned int id); // Enable texture
-RLAPI void rlDisableTexture(void); // Disable texture
-RLAPI void rlEnableTextureCubemap(unsigned int id); // Enable texture cubemap
-RLAPI void rlDisableTextureCubemap(void); // Disable texture cubemap
+RLAPI void rlActiveTextureSlot(int slot); // Select and active a texture slot
+RLAPI void rlEnableTexture(unsigned int id); // Enable texture
+RLAPI void rlDisableTexture(void); // Disable texture
+RLAPI void rlEnableTextureCubemap(unsigned int id); // Enable texture cubemap
+RLAPI void rlDisableTextureCubemap(void); // Disable texture cubemap
RLAPI void rlTextureParameters(unsigned int id, int param, int value); // Set texture parameters (filter, wrap)
RLAPI void rlCubemapParameters(unsigned int id, int param, int value); // Set cubemap parameters (filter, wrap)
// Shader state
-RLAPI void rlEnableShader(unsigned int id); // Enable shader program
-RLAPI void rlDisableShader(void); // Disable shader program
+RLAPI void rlEnableShader(unsigned int id); // Enable shader program
+RLAPI void rlDisableShader(void); // Disable shader program
// Framebuffer state
-RLAPI void rlEnableFramebuffer(unsigned int id); // Enable render texture (fbo)
-RLAPI void rlDisableFramebuffer(void); // Disable render texture (fbo), return to default framebuffer
-RLAPI unsigned int rlGetActiveFramebuffer(void); // Get the currently active render texture (fbo), 0 for default framebuffer
-RLAPI void rlActiveDrawBuffers(int count); // Activate multiple draw color buffers
+RLAPI void rlEnableFramebuffer(unsigned int id); // Enable render texture (fbo)
+RLAPI void rlDisableFramebuffer(void); // Disable render texture (fbo), return to default framebuffer
+RLAPI unsigned int rlGetActiveFramebuffer(void); // Get the currently active render texture (fbo), 0 for default framebuffer
+RLAPI void rlActiveDrawBuffers(int count); // Activate multiple draw color buffers
RLAPI void rlBlitFramebuffer(int srcX, int srcY, int srcWidth, int srcHeight, int dstX, int dstY, int dstWidth, int dstHeight, int bufferMask); // Blit active framebuffer to main framebuffer
RLAPI void rlBindFramebuffer(unsigned int target, unsigned int framebuffer); // Bind framebuffer (FBO)
// General render state
-RLAPI void rlEnableColorBlend(void); // Enable color blending
-RLAPI void rlDisableColorBlend(void); // Disable color blending
-RLAPI void rlEnableDepthTest(void); // Enable depth test
-RLAPI void rlDisableDepthTest(void); // Disable depth test
-RLAPI void rlEnableDepthMask(void); // Enable depth write
-RLAPI void rlDisableDepthMask(void); // Disable depth write
-RLAPI void rlEnableBackfaceCulling(void); // Enable backface culling
-RLAPI void rlDisableBackfaceCulling(void); // Disable backface culling
+RLAPI void rlEnableAdvancedColorBlend(void);
+RLAPI void rlDisableAdvancedColorBlend(void);
+RLAPI void rlEnableColorBlend(void); // Enable color blending
+RLAPI void rlDisableColorBlend(void); // Disable color blending
+RLAPI void rlEnableDepthTest(void); // Enable depth test
+RLAPI void rlDisableDepthTest(void); // Disable depth test
+RLAPI void rlEnableDepthMask(void); // Enable depth write
+RLAPI void rlDisableDepthMask(void); // Disable depth write
+RLAPI void rlEnableBackfaceCulling(void); // Enable backface culling
+RLAPI void rlDisableBackfaceCulling(void); // Disable backface culling
RLAPI void rlColorMask(bool r, bool g, bool b, bool a); // Color mask control
-RLAPI void rlSetCullFace(int mode); // Set face culling mode
-RLAPI void rlEnableScissorTest(void); // Enable scissor test
-RLAPI void rlDisableScissorTest(void); // Disable scissor test
+RLAPI void rlSetCullFace(int mode); // Set face culling mode
+RLAPI void rlEnableScissorTest(void); // Enable scissor test
+RLAPI void rlDisableScissorTest(void); // Disable scissor test
RLAPI void rlScissor(int x, int y, int width, int height); // Scissor test
-RLAPI void rlEnableWireMode(void); // Enable wire mode
-RLAPI void rlEnablePointMode(void); // Enable point mode
-RLAPI void rlDisableWireMode(void); // Disable wire (and point) mode
-RLAPI void rlSetLineWidth(float width); // Set the line drawing width
-RLAPI float rlGetLineWidth(void); // Get the line drawing width
-RLAPI void rlEnableSmoothLines(void); // Enable line aliasing
-RLAPI void rlDisableSmoothLines(void); // Disable line aliasing
-RLAPI void rlEnableStereoRender(void); // Enable stereo rendering
-RLAPI void rlDisableStereoRender(void); // Disable stereo rendering
-RLAPI bool rlIsStereoRenderEnabled(void); // Check if stereo render is enabled
+RLAPI void rlEnableWireMode(void); // Enable wire mode
+RLAPI void rlEnablePointMode(void); // Enable point mode
+RLAPI void rlDisableWireMode(void); // Disable wire (and point) mode
+RLAPI void rlSetLineWidth(float width); // Set the line drawing width
+RLAPI float rlGetLineWidth(void); // Get the line drawing width
+RLAPI void rlEnableSmoothLines(void); // Enable line aliasing
+RLAPI void rlDisableSmoothLines(void); // Disable line aliasing
+RLAPI void rlEnableStereoRender(void); // Enable stereo rendering
+RLAPI void rlDisableStereoRender(void); // Disable stereo rendering
+RLAPI bool rlIsStereoRenderEnabled(void); // Check if stereo render is enabled
RLAPI void rlClearColor(unsigned char r, unsigned char g, unsigned char b, unsigned char a); // Clear color buffer with color
-RLAPI void rlClearScreenBuffers(void); // Clear used screen buffers (color and depth)
-RLAPI void rlCheckErrors(void); // Check and log OpenGL error codes
-RLAPI void rlSetBlendMode(int mode); // Set blending mode
+RLAPI void rlClearScreenBuffers(void); // Clear used screen buffers (color and depth)
+RLAPI void rlCheckErrors(void); // Check and log OpenGL error codes
+RLAPI void rlSetBlendMode(int mode); // Set blending mode
RLAPI void rlSetBlendFactors(int glSrcFactor, int glDstFactor, int glEquation); // Set blending mode factor and equation (using OpenGL factors)
RLAPI void rlSetBlendFactorsSeparate(int glSrcRGB, int glDstRGB, int glSrcAlpha, int glDstAlpha, int glEqRGB, int glEqAlpha); // Set blending mode factors and equations separately (using OpenGL factors)
@@ -709,112 +745,113 @@ RLAPI void rlSetBlendFactorsSeparate(int glSrcRGB, int glDstRGB, int glSrcAlpha,
// Functions Declaration - rlgl functionality
//------------------------------------------------------------------------------------
// rlgl initialization functions
-RLAPI void rlglInit(int width, int height); // Initialize rlgl (buffers, shaders, textures, states)
-RLAPI void rlglClose(void); // De-initialize rlgl (buffers, shaders, textures)
-RLAPI void rlLoadExtensions(void *loader); // Load OpenGL extensions (loader function required)
-RLAPI int rlGetVersion(void); // Get current OpenGL version
-RLAPI void rlSetFramebufferWidth(int width); // Set current framebuffer width
-RLAPI int rlGetFramebufferWidth(void); // Get default framebuffer width
-RLAPI void rlSetFramebufferHeight(int height); // Set current framebuffer height
-RLAPI int rlGetFramebufferHeight(void); // Get default framebuffer height
-
-RLAPI unsigned int rlGetTextureIdDefault(void); // Get default texture id
-RLAPI unsigned int rlGetShaderIdDefault(void); // Get default shader id
-RLAPI int *rlGetShaderLocsDefault(void); // Get default shader locations
+RLAPI void rlglInit(int width, int height); // Initialize rlgl (buffers, shaders, textures, states)
+RLAPI void rlglClose(void); // De-initialize rlgl (buffers, shaders, textures)
+RLAPI void rlLoadExtensions(void* loader); // Load OpenGL extensions (loader function required)
+RLAPI int rlGetVersion(void); // Get current OpenGL version
+RLAPI void rlSetFramebufferWidth(int width); // Set current framebuffer width
+RLAPI int rlGetFramebufferWidth(void); // Get default framebuffer width
+RLAPI void rlSetFramebufferHeight(int height); // Set current framebuffer height
+RLAPI int rlGetFramebufferHeight(void); // Get default framebuffer height
+
+RLAPI unsigned int rlGetTextureIdDefault(void); // Get default texture id
+RLAPI unsigned int rlGetShaderIdDefault(void); // Get default shader id
+RLAPI int* rlGetShaderLocsDefault(void); // Get default shader locations
// Render batch management
// NOTE: rlgl provides a default render batch to behave like OpenGL 1.1 immediate mode
// but this render batch API is exposed in case of custom batches are required
RLAPI rlRenderBatch rlLoadRenderBatch(int numBuffers, int bufferElements); // Load a render batch system
-RLAPI void rlUnloadRenderBatch(rlRenderBatch batch); // Unload render batch system
-RLAPI void rlDrawRenderBatch(rlRenderBatch *batch); // Draw render batch data (Update->Draw->Reset)
-RLAPI void rlSetRenderBatchActive(rlRenderBatch *batch); // Set the active render batch for rlgl (NULL for default internal)
-RLAPI void rlDrawRenderBatchActive(void); // Update and draw internal render batch
-RLAPI bool rlCheckRenderBatchLimit(int vCount); // Check internal buffer overflow for a given number of vertex
+RLAPI void rlUnloadRenderBatch(rlRenderBatch batch); // Unload render batch system
+RLAPI void rlDrawRenderBatch(rlRenderBatch* batch); // Draw render batch data (Update->Draw->Reset)
+RLAPI void rlSetRenderBatchActive(rlRenderBatch* batch); // Set the active render batch for rlgl (NULL for default internal)
+RLAPI void rlDrawRenderBatchActive(void); // Update and draw internal render batch
+RLAPI bool rlCheckRenderBatchLimit(int vCount); // Check internal buffer overflow for a given number of vertex
-RLAPI void rlSetTexture(unsigned int id); // Set current texture for render batch and check buffers limits
+RLAPI void rlSetTexture(unsigned int id); // Set current texture for render batch and check buffers limits
RLAPI void rlClearActiveTextures();
RLAPI void rlResetDrawDepth();
//------------------------------------------------------------------------------------------------------------------------
// Vertex buffers management
-RLAPI unsigned int rlLoadVertexArray(void); // Load vertex array (vao) if supported
-RLAPI unsigned int rlLoadVertexBuffer(const void *buffer, int size, bool dynamic); // Load a vertex buffer object
-RLAPI unsigned int rlLoadVertexBufferElement(const void *buffer, int size, bool dynamic); // Load vertex buffer elements object
-RLAPI void rlUpdateVertexBuffer(unsigned int bufferId, const void *data, int dataSize, int offset); // Update vertex buffer object data on GPU buffer
-RLAPI void rlUpdateVertexBufferElements(unsigned int id, const void *data, int dataSize, int offset); // Update vertex buffer elements data on GPU buffer
-RLAPI void rlUnloadVertexArray(unsigned int vaoId); // Unload vertex array (vao)
-RLAPI void rlUnloadVertexBuffer(unsigned int vboId); // Unload vertex buffer object
+RLAPI unsigned int rlLoadVertexArray(void); // Load vertex array (vao) if supported
+RLAPI unsigned int rlLoadVertexBuffer(const void* buffer, int size, bool dynamic); // Load a vertex buffer object
+RLAPI unsigned int rlLoadVertexBufferElement(const void* buffer, int size, bool dynamic); // Load vertex buffer elements object
+RLAPI void rlUpdateVertexBuffer(unsigned int bufferId, const void* data, int dataSize, int offset); // Update vertex buffer object data on GPU buffer
+RLAPI void rlUpdateVertexBufferElements(unsigned int id, const void* data, int dataSize, int offset); // Update vertex buffer elements data on GPU buffer
+RLAPI void rlUnloadVertexArray(unsigned int vaoId); // Unload vertex array (vao)
+RLAPI void rlUnloadVertexBuffer(unsigned int vboId); // Unload vertex buffer object
RLAPI void rlSetVertexAttribute(unsigned int index, int compSize, int type, bool normalized, int stride, int offset); // Set vertex attribute data configuration
RLAPI void rlSetVertexAttributeDivisor(unsigned int index, int divisor); // Set vertex attribute data divisor
-RLAPI void rlSetVertexAttributeDefault(int locIndex, const void *value, int attribType, int count); // Set vertex attribute default value, when attribute to provided
-RLAPI void rlDrawVertexArray(int offset, int count); // Draw vertex array (currently active vao)
-RLAPI void rlDrawVertexArrayElements(int offset, int count, const void *buffer); // Draw vertex array elements
+RLAPI void rlSetVertexAttributeDefault(int locIndex, const void* value, int attribType, int count); // Set vertex attribute default value, when attribute to provided
+RLAPI void rlDrawVertexArray(int offset, int count); // Draw vertex array (currently active vao)
+RLAPI void rlDrawVertexArrayElements(int offset, int count, const void* buffer); // Draw vertex array elements
RLAPI void rlDrawVertexArrayInstanced(int offset, int count, int instances); // Draw vertex array (currently active vao) with instancing
-RLAPI void rlDrawVertexArrayElementsInstanced(int offset, int count, const void *buffer, int instances); // Draw vertex array elements with instancing
+RLAPI void rlDrawVertexArrayElementsInstanced(int offset, int count, const void* buffer, int instances); // Draw vertex array elements with instancing
// Textures management
-RLAPI unsigned int rlLoadTexture(const void *data, int width, int height, int format, int mipmapCount); // Load texture data
+RLAPI unsigned int rlLoadTexture(const void* data, int width, int height, int format, int mipmapCount); // Load texture data
RLAPI unsigned int rlLoadTextureDepth(int width, int height, bool useRenderBuffer); // Load depth texture/renderbuffer (to be attached to fbo)
-RLAPI unsigned int rlLoadTextureCubemap(const void *data, int size, int format, int mipmapCount); // Load texture cubemap data
-RLAPI void rlUpdateTexture(unsigned int id, int offsetX, int offsetY, int width, int height, int format, const void *data); // Update texture with new data on GPU
-RLAPI void rlGetGlTextureFormats(int format, unsigned int *glInternalFormat, unsigned int *glFormat, unsigned int *glType); // Get OpenGL internal formats
-RLAPI const char *rlGetPixelFormatName(unsigned int format); // Get name string for pixel format
-RLAPI void rlUnloadTexture(unsigned int id); // Unload texture from GPU memory
-RLAPI void rlGenTextureMipmaps(unsigned int id, int width, int height, int format, int *mipmaps); // Generate mipmap data for selected texture
-RLAPI void *rlReadTexturePixels(unsigned int id, int width, int height, int format); // Read texture pixel data
-RLAPI unsigned char *rlReadScreenPixels(int width, int height); // Read screen pixel data (color buffer)
+RLAPI unsigned int rlLoadTextureCubemap(const void* data, int size, int format, int mipmapCount); // Load texture cubemap data
+RLAPI void rlUpdateTexture(unsigned int id, int offsetX, int offsetY, int width, int height, int format, const void* data); // Update texture with new data on GPU
+RLAPI void rlGetGlTextureFormats(int format, unsigned int* glInternalFormat, unsigned int* glFormat, unsigned int* glType); // Get OpenGL internal formats
+RLAPI const char* rlGetPixelFormatName(unsigned int format); // Get name string for pixel format
+RLAPI void rlUnloadTexture(unsigned int id); // Unload texture from GPU memory
+RLAPI void rlGenTextureMipmaps(unsigned int id, int width, int height, int format, int* mipmaps); // Generate mipmap data for selected texture
+RLAPI void* rlReadTexturePixels(unsigned int id, int width, int height, int format); // Read texture pixel data
+RLAPI unsigned char* rlReadScreenPixels(int width, int height); // Read screen pixel data (color buffer)
// Framebuffer management (fbo)
-RLAPI unsigned int rlLoadFramebuffer(void); // Load an empty framebuffer
+RLAPI unsigned int rlLoadFramebuffer(void); // Load an empty framebuffer
RLAPI void rlFramebufferAttach(unsigned int fboId, unsigned int texId, int attachType, int texType, int mipLevel); // Attach texture/renderbuffer to a framebuffer
-RLAPI bool rlFramebufferComplete(unsigned int id); // Verify framebuffer is complete
-RLAPI void rlUnloadFramebuffer(unsigned int id); // Delete framebuffer from GPU
+RLAPI bool rlFramebufferComplete(unsigned int id); // Verify framebuffer is complete
+RLAPI void rlUnloadFramebuffer(unsigned int id); // Delete framebuffer from GPU
// Shaders management
-RLAPI unsigned int rlLoadShaderCode(const char *vsCode, const char *fsCode); // Load shader from code strings
-RLAPI unsigned int rlCompileShader(const char *shaderCode, int type); // Compile custom shader and return shader id (type: RL_VERTEX_SHADER, RL_FRAGMENT_SHADER, RL_COMPUTE_SHADER)
+RLAPI unsigned int rlLoadShaderCode(const char* vsCode, const char* fsCode); // Load shader from code strings
+RLAPI unsigned int rlCompileShader(const char* shaderCode, int type); // Compile custom shader and return shader id (type: RL_VERTEX_SHADER, RL_FRAGMENT_SHADER, RL_COMPUTE_SHADER)
RLAPI unsigned int rlLoadShaderProgram(unsigned int vShaderId, unsigned int fShaderId); // Load custom shader program
-RLAPI void rlUnloadShaderProgram(unsigned int id); // Unload shader program
-RLAPI int rlGetLocationUniform(unsigned int shaderId, const char *uniformName); // Get shader location uniform
-RLAPI int rlGetLocationAttrib(unsigned int shaderId, const char *attribName); // Get shader location attribute
-RLAPI void rlSetUniform(int locIndex, const void *value, int uniformType, int count); // Set shader value uniform
-RLAPI void rlSetUniformMatrix(int locIndex, RLMatrix mat); // Set shader value matrix
-RLAPI void rlSetUniformMatrices(int locIndex, const RLMatrix *mat, int count); // Set shader value matrices
-RLAPI void rlSetUniformSampler(int locIndex, unsigned int textureId); // Set shader value sampler
-RLAPI void rlSetShader(unsigned int id, int *locs); // Set shader currently active (id and locations)
+RLAPI void rlUnloadShaderProgram(unsigned int id); // Unload shader program
+RLAPI int rlGetLocationUniform(unsigned int shaderId, const char* uniformName); // Get shader location uniform
+RLAPI int rlGetLocationUniformCurrent(const char* uniformName);
+RLAPI int rlGetLocationAttrib(unsigned int shaderId, const char* attribName); // Get shader location attribute
+RLAPI void rlSetUniform(int locIndex, const void* value, int uniformType, int count); // Set shader value uniform
+RLAPI void rlSetUniformMatrix(int locIndex, RLMatrix mat); // Set shader value matrix
+RLAPI void rlSetUniformMatrices(int locIndex, const RLMatrix* mat, int count); // Set shader value matrices
+RLAPI void rlSetUniformSampler(int locIndex, unsigned int textureId); // Set shader value sampler
+RLAPI void rlSetShader(unsigned int id, const int* locs); // Set shader currently active (id and locations)
RLAPI unsigned int rlGetShaderCurrent();
// Compute shader management
-RLAPI unsigned int rlLoadComputeShaderProgram(unsigned int shaderId); // Load compute shader program
+RLAPI unsigned int rlLoadComputeShaderProgram(unsigned int shaderId); // Load compute shader program
RLAPI void rlComputeShaderDispatch(unsigned int groupX, unsigned int groupY, unsigned int groupZ); // Dispatch compute shader (equivalent to *draw* for graphics pipeline)
// Shader buffer storage object management (ssbo)
-RLAPI unsigned int rlLoadShaderBuffer(unsigned int size, const void *data, int usageHint); // Load shader storage buffer object (SSBO)
-RLAPI void rlUnloadShaderBuffer(unsigned int ssboId); // Unload shader storage buffer object (SSBO)
-RLAPI void rlUpdateShaderBuffer(unsigned int id, const void *data, unsigned int dataSize, unsigned int offset); // Update SSBO buffer data
-RLAPI void rlBindShaderBuffer(unsigned int id, unsigned int index); // Bind SSBO buffer
-RLAPI void rlReadShaderBuffer(unsigned int id, void *dest, unsigned int count, unsigned int offset); // Read SSBO buffer data (GPU->CPU)
+RLAPI unsigned int rlLoadShaderBuffer(unsigned int size, const void* data, int usageHint); // Load shader storage buffer object (SSBO)
+RLAPI void rlUnloadShaderBuffer(unsigned int ssboId); // Unload shader storage buffer object (SSBO)
+RLAPI void rlUpdateShaderBuffer(unsigned int id, const void* data, unsigned int dataSize, unsigned int offset); // Update SSBO buffer data
+RLAPI void rlBindShaderBuffer(unsigned int id, unsigned int index); // Bind SSBO buffer
+RLAPI void rlReadShaderBuffer(unsigned int id, void* dest, unsigned int count, unsigned int offset); // Read SSBO buffer data (GPU->CPU)
RLAPI void rlCopyShaderBuffer(unsigned int destId, unsigned int srcId, unsigned int destOffset, unsigned int srcOffset, unsigned int count); // Copy SSBO data between buffers
-RLAPI unsigned int rlGetShaderBufferSize(unsigned int id); // Get SSBO buffer size
+RLAPI unsigned int rlGetShaderBufferSize(unsigned int id); // Get SSBO buffer size
// Buffer management
-RLAPI void rlBindImageTexture(unsigned int id, unsigned int index, int format, bool readonly); // Bind image texture
+RLAPI void rlBindImageTexture(unsigned int id, unsigned int index, int format, bool readonly); // Bind image texture
// RLMatrix state management
-RLAPI RLMatrix rlGetMatrixModelview(void); // Get internal modelview matrix
-RLAPI RLMatrix rlGetMatrixProjection(void); // Get internal projection matrix
-RLAPI RLMatrix rlGetMatrixTransform(void); // Get internal accumulated transform matrix
-RLAPI RLMatrix rlGetMatrixProjectionStereo(int eye); // Get internal projection matrix for stereo render (selected eye)
-RLAPI RLMatrix rlGetMatrixViewOffsetStereo(int eye); // Get internal view offset matrix for stereo render (selected eye)
-RLAPI void rlSetMatrixProjection(RLMatrix proj); // Set a custom projection matrix (replaces internal projection matrix)
-RLAPI void rlSetMatrixModelview(RLMatrix view); // Set a custom modelview matrix (replaces internal modelview matrix)
-RLAPI void rlSetMatrixProjectionStereo(RLMatrix right, RLMatrix left); // Set eyes projection matrices for stereo rendering
-RLAPI void rlSetMatrixViewOffsetStereo(RLMatrix right, RLMatrix left); // Set eyes view offsets matrices for stereo rendering
+RLAPI RLMatrix rlGetMatrixModelview(void); // Get internal modelview matrix
+RLAPI RLMatrix rlGetMatrixProjection(void); // Get internal projection matrix
+RLAPI RLMatrix rlGetMatrixTransform(void); // Get internal accumulated transform matrix
+RLAPI RLMatrix rlGetMatrixProjectionStereo(int eye); // Get internal projection matrix for stereo render (selected eye)
+RLAPI RLMatrix rlGetMatrixViewOffsetStereo(int eye); // Get internal view offset matrix for stereo render (selected eye)
+RLAPI void rlSetMatrixProjection(RLMatrix proj); // Set a custom projection matrix (replaces internal projection matrix)
+RLAPI void rlSetMatrixModelview(RLMatrix view); // Set a custom modelview matrix (replaces internal modelview matrix)
+RLAPI void rlSetMatrixProjectionStereo(RLMatrix right, RLMatrix left); // Set eyes projection matrices for stereo rendering
+RLAPI void rlSetMatrixViewOffsetStereo(RLMatrix right, RLMatrix left); // Set eyes view offsets matrices for stereo rendering
// Quick and dirty cube/quad buffers load->draw->unload
-RLAPI void rlLoadDrawCube(void); // Load and draw a cube
-RLAPI void rlLoadDrawQuad(void); // Load and draw a quad
+RLAPI void rlLoadDrawCube(void); // Load and draw a cube
+RLAPI void rlLoadDrawQuad(void); // Load and draw a quad
#if defined(__cplusplus)
}
diff --git a/Source/Renderer/raylib/rshapes.c b/Source/Renderer/raylib/rshapes.c
index fe5f9d62ee..48c66ad4cd 100644
--- a/Source/Renderer/raylib/rshapes.c
+++ b/Source/Renderer/raylib/rshapes.c
@@ -1,63 +1,63 @@
/**********************************************************************************************
-*
-* rshapes - Basic functions to draw 2d shapes and check collisions
-*
-* ADDITIONAL NOTES:
-* Shapes can be draw using 3 types of primitives: LINES, TRIANGLES and QUADS.
-* Some functions implement two drawing options: TRIANGLES and QUADS, by default TRIANGLES
-* are used but QUADS implementation can be selected with SUPPORT_QUADS_DRAW_MODE define
-*
-* Some functions define texture coordinates (rlTexCoord2f()) for the shapes and use a
-* user-provided texture with SetShapesTexture(), the pourpouse of this implementation
-* is allowing to reduce draw calls when combined with a texture-atlas.
-*
-* By default, raylib sets the default texture and rectangle at InitWindow()[rcore] to one
-* white character of default font [rtext], this way, raylib text and shapes can be draw with
-* a single draw call and it also allows users to configure it the same way with their own fonts.
-*
-* CONFIGURATION:
-* #define SUPPORT_MODULE_RSHAPES
-* rshapes module is included in the build
-*
-* #define SUPPORT_QUADS_DRAW_MODE
-* Use QUADS instead of TRIANGLES for drawing when possible. Lines-based shapes still use LINES
-*
-*
-* LICENSE: zlib/libpng
-*
-* Copyright (c) 2013-2024 Ramon Santamaria (@raysan5)
-*
-* This software is provided "as-is", without any express or implied warranty. In no event
-* will the authors be held liable for any damages arising from the use of this software.
-*
-* Permission is granted to anyone to use this software for any purpose, including commercial
-* applications, and to alter it and redistribute it freely, subject to the following restrictions:
-*
-* 1. The origin of this software must not be misrepresented; you must not claim that you
-* wrote the original software. If you use this software in a product, an acknowledgment
-* in the product documentation would be appreciated but is not required.
-*
-* 2. Altered source versions must be plainly marked as such, and must not be misrepresented
-* as being the original software.
-*
-* 3. This notice may not be removed or altered from any source distribution.
-*
-**********************************************************************************************/
-
-#include "raylib.h" // Declares module functions
+ *
+ * rshapes - Basic functions to draw 2d shapes and check collisions
+ *
+ * ADDITIONAL NOTES:
+ * Shapes can be draw using 3 types of primitives: LINES, TRIANGLES and QUADS.
+ * Some functions implement two drawing options: TRIANGLES and QUADS, by default TRIANGLES
+ * are used but QUADS implementation can be selected with SUPPORT_QUADS_DRAW_MODE define
+ *
+ * Some functions define texture coordinates (rlTexCoord2f()) for the shapes and use a
+ * user-provided texture with SetShapesTexture(), the pourpouse of this implementation
+ * is allowing to reduce draw calls when combined with a texture-atlas.
+ *
+ * By default, raylib sets the default texture and rectangle at InitWindow()[rcore] to one
+ * white character of default font [rtext], this way, raylib text and shapes can be draw with
+ * a single draw call and it also allows users to configure it the same way with their own fonts.
+ *
+ * CONFIGURATION:
+ * #define SUPPORT_MODULE_RSHAPES
+ * rshapes module is included in the build
+ *
+ * #define SUPPORT_QUADS_DRAW_MODE
+ * Use QUADS instead of TRIANGLES for drawing when possible. Lines-based shapes still use LINES
+ *
+ *
+ * LICENSE: zlib/libpng
+ *
+ * Copyright (c) 2013-2024 Ramon Santamaria (@raysan5)
+ *
+ * This software is provided "as-is", without any express or implied warranty. In no event
+ * will the authors be held liable for any damages arising from the use of this software.
+ *
+ * Permission is granted to anyone to use this software for any purpose, including commercial
+ * applications, and to alter it and redistribute it freely, subject to the following restrictions:
+ *
+ * 1. The origin of this software must not be misrepresented; you must not claim that you
+ * wrote the original software. If you use this software in a product, an acknowledgment
+ * in the product documentation would be appreciated but is not required.
+ *
+ * 2. Altered source versions must be plainly marked as such, and must not be misrepresented
+ * as being the original software.
+ *
+ * 3. This notice may not be removed or altered from any source distribution.
+ *
+ **********************************************************************************************/
+
+#include "raylib.h" // Declares module functions
// Check if config flags have been externally provided on compilation line
#if !defined(EXTERNAL_CONFIG_FLAGS)
- #include "rlconfig.h" // Defines module configuration flags
+#include "rlconfig.h" // Defines module configuration flags
#endif
#if defined(SUPPORT_MODULE_RSHAPES)
-#include "rlgl.h" // OpenGL abstraction layer to OpenGL 1.1, 2.1, 3.3+ or ES2
+#include "rlgl.h" // OpenGL abstraction layer to OpenGL 1.1, 2.1, 3.3+ or ES2
-#include // Required for: sinf(), asinf(), cosf(), acosf(), sqrtf(), fabsf()
-#include // Required for: FLT_EPSILON
-#include // Required for: RL_FREE
+#include // Required for: sinf(), asinf(), cosf(), acosf(), sqrtf(), fabsf()
+#include // Required for: FLT_EPSILON
+#include // Required for: RL_FREE
//----------------------------------------------------------------------------------
// Defines and Macros
@@ -65,10 +65,10 @@
// Error rate to calculate how many segments we need to draw a smooth circle,
// taken from https://stackoverflow.com/a/2244088
#ifndef SMOOTH_CIRCLE_ERROR_RATE
- #define SMOOTH_CIRCLE_ERROR_RATE 0.5f // Circle error rate
+#define SMOOTH_CIRCLE_ERROR_RATE 0.5f // Circle error rate
#endif
#ifndef SPLINE_SEGMENT_DIVISIONS
- #define SPLINE_SEGMENT_DIVISIONS 24 // Spline segment divisions
+#define SPLINE_SEGMENT_DIVISIONS 24 // Spline segment divisions
#endif
//----------------------------------------------------------------------------------
@@ -79,13 +79,13 @@
//----------------------------------------------------------------------------------
// Global Variables Definition
//----------------------------------------------------------------------------------
-static Texture2D texShapes = { 1, 1, 1, 1, 7 }; // Texture used on shapes drawing (white pixel loaded by rlgl)
-static Rectangle texShapesRec = { 0.0f, 0.0f, 1.0f, 1.0f }; // Texture source rectangle used on shapes drawing
+static Texture2D texShapes = {1, 1, 1, 1, 7}; // Texture used on shapes drawing (white pixel loaded by rlgl)
+static Rectangle texShapesRec = {0.0f, 0.0f, 1.0f, 1.0f}; // Texture source rectangle used on shapes drawing
//----------------------------------------------------------------------------------
// Module specific Functions Declaration
//----------------------------------------------------------------------------------
-static float EaseCubicInOut(float t, float b, float c, float d); // Cubic easing
+static float EaseCubicInOut(float t, float b, float c, float d); // Cubic easing
//----------------------------------------------------------------------------------
// Module Functions Definition
@@ -94,1494 +94,1427 @@ static float EaseCubicInOut(float t, float b, float c, float d); // Cubic eas
// Set texture and rectangle to be used on shapes drawing
// NOTE: It can be useful when using basic shapes and one single font,
// defining a font char white rectangle would allow drawing everything in a single draw call
-void SetShapesTexture(Texture2D texture, Rectangle source)
-{
- // Reset texture to default pixel if required
- // WARNING: Shapes texture should be probably better validated,
- // it can break the rendering of all shapes if misused
- if ((texture.id == 0) || (source.width == 0) || (source.height == 0))
- {
- texShapes = (Texture2D){ 1, 1, 1, 1, 7 };
- texShapesRec = (Rectangle){ 0.0f, 0.0f, 1.0f, 1.0f };
- }
- else
- {
- texShapes = texture;
- texShapesRec = source;
- }
+void SetShapesTexture(Texture2D texture, Rectangle source) {
+ // Reset texture to default pixel if required
+ // WARNING: Shapes texture should be probably better validated,
+ // it can break the rendering of all shapes if misused
+ if ((texture.id == 0) || (source.width == 0) || (source.height == 0)) {
+ texShapes = (Texture2D){1, 1, 1, 1, 7};
+ texShapesRec = (Rectangle){0.0f, 0.0f, 1.0f, 1.0f};
+ } else {
+ texShapes = texture;
+ texShapesRec = source;
+ }
}
// Get texture that is used for shapes drawing
-Texture2D GetShapesTexture(void)
-{
- return texShapes;
+Texture2D GetShapesTexture(void) {
+ return texShapes;
}
// Get texture source rectangle that is used for shapes drawing
-Rectangle GetShapesTextureRectangle(void)
-{
- return texShapesRec;
+Rectangle GetShapesTextureRectangle(void) {
+ return texShapesRec;
}
// Draw a pixel
-void DrawPixel(int posX, int posY, RLColor color)
-{
- DrawPixelV((Vector2){ (float)posX, (float)posY }, color);
+void DrawPixel(int posX, int posY, RLColor color) {
+ DrawPixelV((Vector2){(float)posX, (float)posY}, color);
}
// Draw a pixel (Vector version)
-void DrawPixelV(Vector2 position, RLColor color)
-{
+void DrawPixelV(Vector2 position, RLColor color) {
#if defined(SUPPORT_QUADS_DRAW_MODE)
- rlSetTexture(GetShapesTexture().id);
- Rectangle shapeRect = GetShapesTextureRectangle();
+ rlSetTexture(GetShapesTexture().id);
+ Rectangle shapeRect = GetShapesTextureRectangle();
- rlBegin(RL_QUADS);
+ rlBegin(RL_QUADS);
- rlNormal3f(0.0f, 0.0f, 1.0f);
- rlColor4ub(color.r, color.g, color.b, color.a);
+ rlNormal3f(0.0f, 0.0f, 1.0f);
+ rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(position.x, position.y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(position.x, position.y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(position.x, position.y + 1);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(position.x, position.y + 1);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(position.x + 1, position.y + 1);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(position.x + 1, position.y + 1);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(position.x + 1, position.y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(position.x + 1, position.y);
- rlEnd();
+ rlEnd();
- rlSetTexture(0);
+ rlSetTexture(0);
#else
- rlBegin(RL_TRIANGLES);
+ rlBegin(RL_TRIANGLES);
- rlColor4ub(color.r, color.g, color.b, color.a);
+ rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(position.x, position.y);
- rlVertex2f(position.x, position.y + 1);
- rlVertex2f(position.x + 1, position.y);
+ rlVertex2f(position.x, position.y);
+ rlVertex2f(position.x, position.y + 1);
+ rlVertex2f(position.x + 1, position.y);
- rlVertex2f(position.x + 1, position.y);
- rlVertex2f(position.x, position.y + 1);
- rlVertex2f(position.x + 1, position.y + 1);
+ rlVertex2f(position.x + 1, position.y);
+ rlVertex2f(position.x, position.y + 1);
+ rlVertex2f(position.x + 1, position.y + 1);
- rlEnd();
+ rlEnd();
#endif
}
// Draw a line (using gl lines)
-void DrawLine(int startPosX, int startPosY, int endPosX, int endPosY, RLColor color)
-{
- rlBegin(RL_LINES);
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f((float)startPosX, (float)startPosY);
- rlVertex2f((float)endPosX, (float)endPosY);
- rlEnd();
+void DrawLine(int startPosX, int startPosY, int endPosX, int endPosY, RLColor color) {
+ rlBegin(RL_LINES);
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f((float)startPosX, (float)startPosY);
+ rlVertex2f((float)endPosX, (float)endPosY);
+ rlEnd();
}
// Draw a line (using gl lines)
-void DrawLineV(Vector2 startPos, Vector2 endPos, RLColor color)
-{
- rlBegin(RL_LINES);
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(startPos.x, startPos.y);
- rlVertex2f(endPos.x, endPos.y);
- rlEnd();
+void DrawLineV(Vector2 startPos, Vector2 endPos, RLColor color) {
+ rlBegin(RL_LINES);
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(startPos.x, startPos.y);
+ rlVertex2f(endPos.x, endPos.y);
+ rlEnd();
}
// Draw lines sequuence (using gl lines)
-void DrawLineStrip(const Vector2 *points, int pointCount, RLColor color)
-{
- if (pointCount < 2) return; // Security check
+void DrawLineStrip(const Vector2* points, int pointCount, RLColor color) {
+ if (pointCount < 2)
+ return; // Security check
- rlBegin(RL_LINES);
- rlColor4ub(color.r, color.g, color.b, color.a);
+ rlBegin(RL_LINES);
+ rlColor4ub(color.r, color.g, color.b, color.a);
- for (int i = 0; i < pointCount - 1; i++)
- {
- rlVertex2f(points[i].x, points[i].y);
- rlVertex2f(points[i + 1].x, points[i + 1].y);
- }
- rlEnd();
+ for (int i = 0; i < pointCount - 1; i++) {
+ rlVertex2f(points[i].x, points[i].y);
+ rlVertex2f(points[i + 1].x, points[i + 1].y);
+ }
+ rlEnd();
}
// Draw line using cubic-bezier spline, in-out interpolation, no control points
-void DrawLineBezier(Vector2 startPos, Vector2 endPos, float thick, RLColor color)
-{
- Vector2 previous = startPos;
- Vector2 current = { 0 };
+void DrawLineBezier(Vector2 startPos, Vector2 endPos, float thick, RLColor color) {
+ Vector2 previous = startPos;
+ Vector2 current = {0};
- Vector2 points[2*SPLINE_SEGMENT_DIVISIONS + 2] = { 0 };
+ Vector2 points[2 * SPLINE_SEGMENT_DIVISIONS + 2] = {0};
- for (int i = 1; i <= SPLINE_SEGMENT_DIVISIONS; i++)
- {
- // Cubic easing in-out
- // NOTE: Easing is calculated only for y position value
- current.y = EaseCubicInOut((float)i, startPos.y, endPos.y - startPos.y, (float)SPLINE_SEGMENT_DIVISIONS);
- current.x = previous.x + (endPos.x - startPos.x)/(float)SPLINE_SEGMENT_DIVISIONS;
+ for (int i = 1; i <= SPLINE_SEGMENT_DIVISIONS; i++) {
+ // Cubic easing in-out
+ // NOTE: Easing is calculated only for y position value
+ current.y = EaseCubicInOut((float)i, startPos.y, endPos.y - startPos.y, (float)SPLINE_SEGMENT_DIVISIONS);
+ current.x = previous.x + (endPos.x - startPos.x) / (float)SPLINE_SEGMENT_DIVISIONS;
- float dy = current.y - previous.y;
- float dx = current.x - previous.x;
- float size = 0.5f*thick/sqrtf(dx*dx+dy*dy);
+ float dy = current.y - previous.y;
+ float dx = current.x - previous.x;
+ float size = 0.5f * thick / sqrtf(dx * dx + dy * dy);
- if (i == 1)
- {
- points[0].x = previous.x + dy*size;
- points[0].y = previous.y - dx*size;
- points[1].x = previous.x - dy*size;
- points[1].y = previous.y + dx*size;
- }
+ if (i == 1) {
+ points[0].x = previous.x + dy * size;
+ points[0].y = previous.y - dx * size;
+ points[1].x = previous.x - dy * size;
+ points[1].y = previous.y + dx * size;
+ }
- points[2*i + 1].x = current.x - dy*size;
- points[2*i + 1].y = current.y + dx*size;
- points[2*i].x = current.x + dy*size;
- points[2*i].y = current.y - dx*size;
+ points[2 * i + 1].x = current.x - dy * size;
+ points[2 * i + 1].y = current.y + dx * size;
+ points[2 * i].x = current.x + dy * size;
+ points[2 * i].y = current.y - dx * size;
- previous = current;
- }
+ previous = current;
+ }
- DrawTriangleStrip(points, 2*SPLINE_SEGMENT_DIVISIONS + 2, color);
+ DrawTriangleStrip(points, 2 * SPLINE_SEGMENT_DIVISIONS + 2, color);
}
// Draw a line defining thickness
-void DrawLineEx(Vector2 startPos, Vector2 endPos, float thick, RLColor color)
-{
- Vector2 delta = { endPos.x - startPos.x, endPos.y - startPos.y };
- float length = sqrtf(delta.x*delta.x + delta.y*delta.y);
+void DrawLineEx(Vector2 startPos, Vector2 endPos, float thick, RLColor color) {
+ Vector2 delta = {endPos.x - startPos.x, endPos.y - startPos.y};
+ float length = sqrtf(delta.x * delta.x + delta.y * delta.y);
- if ((length > 0) && (thick > 0))
- {
- float scale = thick/(2*length);
+ if ((length > 0) && (thick > 0)) {
+ float scale = thick / (2 * length);
- Vector2 radius = { -scale*delta.y, scale*delta.x };
- Vector2 strip[4] = {
- { startPos.x - radius.x, startPos.y - radius.y },
- { startPos.x + radius.x, startPos.y + radius.y },
- { endPos.x - radius.x, endPos.y - radius.y },
- { endPos.x + radius.x, endPos.y + radius.y }
- };
+ Vector2 radius = {-scale * delta.y, scale * delta.x};
+ Vector2 strip[4] = {
+ {startPos.x - radius.x, startPos.y - radius.y},
+ {startPos.x + radius.x, startPos.y + radius.y},
+ {endPos.x - radius.x, endPos.y - radius.y},
+ {endPos.x + radius.x, endPos.y + radius.y}};
- DrawTriangleStrip(strip, 4, color);
- }
+ DrawTriangleStrip(strip, 4, color);
+ }
}
// Draw a color-filled circle
-void DrawCircle(int centerX, int centerY, float radius, RLColor color)
-{
- DrawCircleV((Vector2){ (float)centerX, (float)centerY }, radius, color);
+void DrawCircle(int centerX, int centerY, float radius, RLColor color) {
+ DrawCircleV((Vector2){(float)centerX, (float)centerY}, radius, color);
}
// Draw a color-filled circle (Vector version)
// NOTE: On OpenGL 3.3 and ES2 we use QUADS to avoid drawing order issues
-void DrawCircleV(Vector2 center, float radius, RLColor color)
-{
- DrawCircleSector(center, radius, 0, 360, 36, color);
+void DrawCircleV(Vector2 center, float radius, RLColor color) {
+ DrawCircleSector(center, radius, 0, 360, 36, color);
}
// Draw a piece of a circle
-void DrawCircleSector(Vector2 center, float radius, float startAngle, float endAngle, int segments, RLColor color)
-{
- if (radius <= 0.0f) radius = 0.1f; // Avoid div by zero
+void DrawCircleSector(Vector2 center, float radius, float startAngle, float endAngle, int segments, RLColor color) {
+ if (radius <= 0.0f)
+ radius = 0.1f; // Avoid div by zero
- // Function expects (endAngle > startAngle)
- if (endAngle < startAngle)
- {
- // Swap values
- float tmp = startAngle;
- startAngle = endAngle;
- endAngle = tmp;
- }
+ // Function expects (endAngle > startAngle)
+ if (endAngle < startAngle) {
+ // Swap values
+ float tmp = startAngle;
+ startAngle = endAngle;
+ endAngle = tmp;
+ }
- int minSegments = (int)ceilf((endAngle - startAngle)/90);
+ int minSegments = (int)ceilf((endAngle - startAngle) / 90);
- if (segments < minSegments)
- {
- // Calculate the maximum angle between segments based on the error rate (usually 0.5f)
- float th = acosf(2*powf(1 - SMOOTH_CIRCLE_ERROR_RATE/radius, 2) - 1);
- segments = (int)((endAngle - startAngle)*ceilf(2*PI/th)/360);
+ if (segments < minSegments) {
+ // Calculate the maximum angle between segments based on the error rate (usually 0.5f)
+ float th = acosf(2 * powf(1 - SMOOTH_CIRCLE_ERROR_RATE / radius, 2) - 1);
+ segments = (int)((endAngle - startAngle) * ceilf(2 * PI / th) / 360);
- if (segments <= 0) segments = minSegments;
- }
+ if (segments <= 0)
+ segments = minSegments;
+ }
- float stepLength = (endAngle - startAngle)/(float)segments;
- float angle = startAngle;
+ float stepLength = (endAngle - startAngle) / (float)segments;
+ float angle = startAngle;
#if defined(SUPPORT_QUADS_DRAW_MODE)
- rlSetTexture(GetShapesTexture().id);
- Rectangle shapeRect = GetShapesTextureRectangle();
+ rlSetTexture(GetShapesTexture().id);
+ Rectangle shapeRect = GetShapesTextureRectangle();
- rlBegin(RL_QUADS);
+ rlBegin(RL_QUADS);
- // NOTE: Every QUAD actually represents two segments
- for (int i = 0; i < segments/2; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
+ // NOTE: Every QUAD actually represents two segments
+ for (int i = 0; i < segments / 2; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x, center.y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x, center.y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength*2.0f))*radius, center.y + sinf(DEG2RAD*(angle + stepLength*2.0f))*radius);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength * 2.0f)) * radius, center.y + sinf(DEG2RAD * (angle + stepLength * 2.0f)) * radius);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*radius, center.y + sinf(DEG2RAD*(angle + stepLength))*radius);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * radius, center.y + sinf(DEG2RAD * (angle + stepLength)) * radius);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*radius, center.y + sinf(DEG2RAD*angle)*radius);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * radius, center.y + sinf(DEG2RAD * angle) * radius);
- angle += (stepLength*2.0f);
- }
+ angle += (stepLength * 2.0f);
+ }
- // NOTE: In case number of segments is odd, we add one last piece to the cake
- if ((((unsigned int)segments)%2) == 1)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
+ // NOTE: In case number of segments is odd, we add one last piece to the cake
+ if ((((unsigned int)segments) % 2) == 1) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x, center.y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x, center.y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*radius, center.y + sinf(DEG2RAD*(angle + stepLength))*radius);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * radius, center.y + sinf(DEG2RAD * (angle + stepLength)) * radius);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*radius, center.y + sinf(DEG2RAD*angle)*radius);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * radius, center.y + sinf(DEG2RAD * angle) * radius);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x, center.y);
- }
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x, center.y);
+ }
- rlEnd();
+ rlEnd();
- rlSetTexture(0);
+ rlSetTexture(0);
#else
- rlBegin(RL_TRIANGLES);
- for (int i = 0; i < segments; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
-
- rlVertex2f(center.x, center.y);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*radius, center.y + sinf(DEG2RAD*(angle + stepLength))*radius);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*radius, center.y + sinf(DEG2RAD*angle)*radius);
-
- angle += stepLength;
- }
- rlEnd();
+ rlBegin(RL_TRIANGLES);
+ for (int i = 0; i < segments; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+
+ rlVertex2f(center.x, center.y);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * radius, center.y + sinf(DEG2RAD * (angle + stepLength)) * radius);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * radius, center.y + sinf(DEG2RAD * angle) * radius);
+
+ angle += stepLength;
+ }
+ rlEnd();
#endif
}
// Draw a piece of a circle outlines
-void DrawCircleSectorLines(Vector2 center, float radius, float startAngle, float endAngle, int segments, RLColor color)
-{
- if (radius <= 0.0f) radius = 0.1f; // Avoid div by zero issue
-
- // Function expects (endAngle > startAngle)
- if (endAngle < startAngle)
- {
- // Swap values
- float tmp = startAngle;
- startAngle = endAngle;
- endAngle = tmp;
- }
-
- int minSegments = (int)ceilf((endAngle - startAngle)/90);
-
- if (segments < minSegments)
- {
- // Calculate the maximum angle between segments based on the error rate (usually 0.5f)
- float th = acosf(2*powf(1 - SMOOTH_CIRCLE_ERROR_RATE/radius, 2) - 1);
- segments = (int)((endAngle - startAngle)*ceilf(2*PI/th)/360);
-
- if (segments <= 0) segments = minSegments;
- }
-
- float stepLength = (endAngle - startAngle)/(float)segments;
- float angle = startAngle;
- bool showCapLines = true;
-
- rlBegin(RL_LINES);
- if (showCapLines)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(center.x, center.y);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*radius, center.y + sinf(DEG2RAD*angle)*radius);
- }
-
- for (int i = 0; i < segments; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
-
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*radius, center.y + sinf(DEG2RAD*angle)*radius);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*radius, center.y + sinf(DEG2RAD*(angle + stepLength))*radius);
-
- angle += stepLength;
- }
-
- if (showCapLines)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(center.x, center.y);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*radius, center.y + sinf(DEG2RAD*angle)*radius);
- }
- rlEnd();
+void DrawCircleSectorLines(Vector2 center, float radius, float startAngle, float endAngle, int segments, RLColor color) {
+ if (radius <= 0.0f)
+ radius = 0.1f; // Avoid div by zero issue
+
+ // Function expects (endAngle > startAngle)
+ if (endAngle < startAngle) {
+ // Swap values
+ float tmp = startAngle;
+ startAngle = endAngle;
+ endAngle = tmp;
+ }
+
+ int minSegments = (int)ceilf((endAngle - startAngle) / 90);
+
+ if (segments < minSegments) {
+ // Calculate the maximum angle between segments based on the error rate (usually 0.5f)
+ float th = acosf(2 * powf(1 - SMOOTH_CIRCLE_ERROR_RATE / radius, 2) - 1);
+ segments = (int)((endAngle - startAngle) * ceilf(2 * PI / th) / 360);
+
+ if (segments <= 0)
+ segments = minSegments;
+ }
+
+ float stepLength = (endAngle - startAngle) / (float)segments;
+ float angle = startAngle;
+ bool showCapLines = true;
+
+ rlBegin(RL_LINES);
+ if (showCapLines) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(center.x, center.y);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * radius, center.y + sinf(DEG2RAD * angle) * radius);
+ }
+
+ for (int i = 0; i < segments; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * radius, center.y + sinf(DEG2RAD * angle) * radius);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * radius, center.y + sinf(DEG2RAD * (angle + stepLength)) * radius);
+
+ angle += stepLength;
+ }
+
+ if (showCapLines) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(center.x, center.y);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * radius, center.y + sinf(DEG2RAD * angle) * radius);
+ }
+ rlEnd();
}
// Draw a gradient-filled circle
-void DrawCircleGradient(int centerX, int centerY, float radius, RLColor inner, RLColor outer)
-{
- rlBegin(RL_TRIANGLES);
- for (int i = 0; i < 360; i += 10)
- {
- rlColor4ub(inner.r, inner.g, inner.b, inner.a);
- rlVertex2f((float)centerX, (float)centerY);
- rlColor4ub(outer.r, outer.g, outer.b, outer.a);
- rlVertex2f((float)centerX + cosf(DEG2RAD*(i + 10))*radius, (float)centerY + sinf(DEG2RAD*(i + 10))*radius);
- rlColor4ub(outer.r, outer.g, outer.b, outer.a);
- rlVertex2f((float)centerX + cosf(DEG2RAD*i)*radius, (float)centerY + sinf(DEG2RAD*i)*radius);
- }
- rlEnd();
+void DrawCircleGradient(int centerX, int centerY, float radius, RLColor inner, RLColor outer) {
+ rlBegin(RL_TRIANGLES);
+ for (int i = 0; i < 360; i += 10) {
+ rlColor4ub(inner.r, inner.g, inner.b, inner.a);
+ rlVertex2f((float)centerX, (float)centerY);
+ rlColor4ub(outer.r, outer.g, outer.b, outer.a);
+ rlVertex2f((float)centerX + cosf(DEG2RAD * (i + 10)) * radius, (float)centerY + sinf(DEG2RAD * (i + 10)) * radius);
+ rlColor4ub(outer.r, outer.g, outer.b, outer.a);
+ rlVertex2f((float)centerX + cosf(DEG2RAD * i) * radius, (float)centerY + sinf(DEG2RAD * i) * radius);
+ }
+ rlEnd();
}
// Draw circle outline
-void DrawCircleLines(int centerX, int centerY, float radius, RLColor color)
-{
- DrawCircleLinesV((Vector2){ (float)centerX, (float)centerY }, radius, color);
+void DrawCircleLines(int centerX, int centerY, float radius, RLColor color) {
+ DrawCircleLinesV((Vector2){(float)centerX, (float)centerY}, radius, color);
}
// Draw circle outline (Vector version)
-void DrawCircleLinesV(Vector2 center, float radius, RLColor color)
-{
- rlBegin(RL_LINES);
- rlColor4ub(color.r, color.g, color.b, color.a);
+void DrawCircleLinesV(Vector2 center, float radius, RLColor color) {
+ rlBegin(RL_LINES);
+ rlColor4ub(color.r, color.g, color.b, color.a);
- // NOTE: Circle outline is drawn pixel by pixel every degree (0 to 360)
- for (int i = 0; i < 360; i += 10)
- {
- rlVertex2f(center.x + cosf(DEG2RAD*i)*radius, center.y + sinf(DEG2RAD*i)*radius);
- rlVertex2f(center.x + cosf(DEG2RAD*(i + 10))*radius, center.y + sinf(DEG2RAD*(i + 10))*radius);
- }
- rlEnd();
+ // NOTE: Circle outline is drawn pixel by pixel every degree (0 to 360)
+ for (int i = 0; i < 360; i += 10) {
+ rlVertex2f(center.x + cosf(DEG2RAD * i) * radius, center.y + sinf(DEG2RAD * i) * radius);
+ rlVertex2f(center.x + cosf(DEG2RAD * (i + 10)) * radius, center.y + sinf(DEG2RAD * (i + 10)) * radius);
+ }
+ rlEnd();
}
// Draw ellipse
-void DrawEllipse(int centerX, int centerY, float radiusH, float radiusV, RLColor color)
-{
- rlBegin(RL_TRIANGLES);
- for (int i = 0; i < 360; i += 10)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f((float)centerX, (float)centerY);
- rlVertex2f((float)centerX + cosf(DEG2RAD*(i + 10))*radiusH, (float)centerY + sinf(DEG2RAD*(i + 10))*radiusV);
- rlVertex2f((float)centerX + cosf(DEG2RAD*i)*radiusH, (float)centerY + sinf(DEG2RAD*i)*radiusV);
- }
- rlEnd();
+void DrawEllipse(int centerX, int centerY, float radiusH, float radiusV, RLColor color) {
+ rlBegin(RL_TRIANGLES);
+ for (int i = 0; i < 360; i += 10) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f((float)centerX, (float)centerY);
+ rlVertex2f((float)centerX + cosf(DEG2RAD * (i + 10)) * radiusH, (float)centerY + sinf(DEG2RAD * (i + 10)) * radiusV);
+ rlVertex2f((float)centerX + cosf(DEG2RAD * i) * radiusH, (float)centerY + sinf(DEG2RAD * i) * radiusV);
+ }
+ rlEnd();
}
// Draw ellipse outline
-void DrawEllipseLines(int centerX, int centerY, float radiusH, float radiusV, RLColor color)
-{
- rlBegin(RL_LINES);
- for (int i = 0; i < 360; i += 10)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(centerX + cosf(DEG2RAD*(i + 10))*radiusH, centerY + sinf(DEG2RAD*(i + 10))*radiusV);
- rlVertex2f(centerX + cosf(DEG2RAD*i)*radiusH, centerY + sinf(DEG2RAD*i)*radiusV);
- }
- rlEnd();
+void DrawEllipseLines(int centerX, int centerY, float radiusH, float radiusV, RLColor color) {
+ rlBegin(RL_LINES);
+ for (int i = 0; i < 360; i += 10) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(centerX + cosf(DEG2RAD * (i + 10)) * radiusH, centerY + sinf(DEG2RAD * (i + 10)) * radiusV);
+ rlVertex2f(centerX + cosf(DEG2RAD * i) * radiusH, centerY + sinf(DEG2RAD * i) * radiusV);
+ }
+ rlEnd();
}
// Draw ring
-void DrawRing(Vector2 center, float innerRadius, float outerRadius, float startAngle, float endAngle, int segments, RLColor color)
-{
- if (startAngle == endAngle) return;
-
- // Function expects (outerRadius > innerRadius)
- if (outerRadius < innerRadius)
- {
- float tmp = outerRadius;
- outerRadius = innerRadius;
- innerRadius = tmp;
-
- if (outerRadius <= 0.0f) outerRadius = 0.1f;
- }
-
- // Function expects (endAngle > startAngle)
- if (endAngle < startAngle)
- {
- // Swap values
- float tmp = startAngle;
- startAngle = endAngle;
- endAngle = tmp;
- }
-
- int minSegments = (int)ceilf((endAngle - startAngle)/90);
-
- if (segments < minSegments)
- {
- // Calculate the maximum angle between segments based on the error rate (usually 0.5f)
- float th = acosf(2*powf(1 - SMOOTH_CIRCLE_ERROR_RATE/outerRadius, 2) - 1);
- segments = (int)((endAngle - startAngle)*ceilf(2*PI/th)/360);
-
- if (segments <= 0) segments = minSegments;
- }
-
- // Not a ring
- if (innerRadius <= 0.0f)
- {
- DrawCircleSector(center, outerRadius, startAngle, endAngle, segments, color);
- return;
- }
-
- float stepLength = (endAngle - startAngle)/(float)segments;
- float angle = startAngle;
+void DrawRing(Vector2 center, float innerRadius, float outerRadius, float startAngle, float endAngle, int segments, RLColor color) {
+ if (startAngle == endAngle)
+ return;
+
+ // Function expects (outerRadius > innerRadius)
+ if (outerRadius < innerRadius) {
+ float tmp = outerRadius;
+ outerRadius = innerRadius;
+ innerRadius = tmp;
+
+ if (outerRadius <= 0.0f)
+ outerRadius = 0.1f;
+ }
+
+ // Function expects (endAngle > startAngle)
+ if (endAngle < startAngle) {
+ // Swap values
+ float tmp = startAngle;
+ startAngle = endAngle;
+ endAngle = tmp;
+ }
+
+ int minSegments = (int)ceilf((endAngle - startAngle) / 90);
+
+ if (segments < minSegments) {
+ // Calculate the maximum angle between segments based on the error rate (usually 0.5f)
+ float th = acosf(2 * powf(1 - SMOOTH_CIRCLE_ERROR_RATE / outerRadius, 2) - 1);
+ segments = (int)((endAngle - startAngle) * ceilf(2 * PI / th) / 360);
+
+ if (segments <= 0)
+ segments = minSegments;
+ }
+
+ // Not a ring
+ if (innerRadius <= 0.0f) {
+ DrawCircleSector(center, outerRadius, startAngle, endAngle, segments, color);
+ return;
+ }
+
+ float stepLength = (endAngle - startAngle) / (float)segments;
+ float angle = startAngle;
#if defined(SUPPORT_QUADS_DRAW_MODE)
- rlSetTexture(GetShapesTexture().id);
- Rectangle shapeRect = GetShapesTextureRectangle();
+ rlSetTexture(GetShapesTexture().id);
+ Rectangle shapeRect = GetShapesTextureRectangle();
- rlBegin(RL_QUADS);
- for (int i = 0; i < segments; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
+ rlBegin(RL_QUADS);
+ for (int i = 0; i < segments; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*outerRadius, center.y + sinf(DEG2RAD*angle)*outerRadius);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * outerRadius, center.y + sinf(DEG2RAD * angle) * outerRadius);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*innerRadius, center.y + sinf(DEG2RAD*angle)*innerRadius);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * innerRadius, center.y + sinf(DEG2RAD * angle) * innerRadius);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*innerRadius, center.y + sinf(DEG2RAD*(angle + stepLength))*innerRadius);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * innerRadius, center.y + sinf(DEG2RAD * (angle + stepLength)) * innerRadius);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*outerRadius, center.y + sinf(DEG2RAD*(angle + stepLength))*outerRadius);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * outerRadius, center.y + sinf(DEG2RAD * (angle + stepLength)) * outerRadius);
- angle += stepLength;
- }
- rlEnd();
+ angle += stepLength;
+ }
+ rlEnd();
- rlSetTexture(0);
+ rlSetTexture(0);
#else
- rlBegin(RL_TRIANGLES);
- for (int i = 0; i < segments; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
-
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*innerRadius, center.y + sinf(DEG2RAD*angle)*innerRadius);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*innerRadius, center.y + sinf(DEG2RAD*(angle + stepLength))*innerRadius);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*outerRadius, center.y + sinf(DEG2RAD*angle)*outerRadius);
-
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*innerRadius, center.y + sinf(DEG2RAD*(angle + stepLength))*innerRadius);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*outerRadius, center.y + sinf(DEG2RAD*(angle + stepLength))*outerRadius);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*outerRadius, center.y + sinf(DEG2RAD*angle)*outerRadius);
-
- angle += stepLength;
- }
- rlEnd();
+ rlBegin(RL_TRIANGLES);
+ for (int i = 0; i < segments; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * innerRadius, center.y + sinf(DEG2RAD * angle) * innerRadius);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * innerRadius, center.y + sinf(DEG2RAD * (angle + stepLength)) * innerRadius);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * outerRadius, center.y + sinf(DEG2RAD * angle) * outerRadius);
+
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * innerRadius, center.y + sinf(DEG2RAD * (angle + stepLength)) * innerRadius);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * outerRadius, center.y + sinf(DEG2RAD * (angle + stepLength)) * outerRadius);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * outerRadius, center.y + sinf(DEG2RAD * angle) * outerRadius);
+
+ angle += stepLength;
+ }
+ rlEnd();
#endif
}
// Draw ring outline
-void DrawRingLines(Vector2 center, float innerRadius, float outerRadius, float startAngle, float endAngle, int segments, RLColor color)
-{
- if (startAngle == endAngle) return;
-
- // Function expects (outerRadius > innerRadius)
- if (outerRadius < innerRadius)
- {
- float tmp = outerRadius;
- outerRadius = innerRadius;
- innerRadius = tmp;
-
- if (outerRadius <= 0.0f) outerRadius = 0.1f;
- }
-
- // Function expects (endAngle > startAngle)
- if (endAngle < startAngle)
- {
- // Swap values
- float tmp = startAngle;
- startAngle = endAngle;
- endAngle = tmp;
- }
-
- int minSegments = (int)ceilf((endAngle - startAngle)/90);
-
- if (segments < minSegments)
- {
- // Calculate the maximum angle between segments based on the error rate (usually 0.5f)
- float th = acosf(2*powf(1 - SMOOTH_CIRCLE_ERROR_RATE/outerRadius, 2) - 1);
- segments = (int)((endAngle - startAngle)*ceilf(2*PI/th)/360);
-
- if (segments <= 0) segments = minSegments;
- }
-
- if (innerRadius <= 0.0f)
- {
- DrawCircleSectorLines(center, outerRadius, startAngle, endAngle, segments, color);
- return;
- }
-
- float stepLength = (endAngle - startAngle)/(float)segments;
- float angle = startAngle;
- bool showCapLines = true;
-
- rlBegin(RL_LINES);
- if (showCapLines)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*outerRadius, center.y + sinf(DEG2RAD*angle)*outerRadius);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*innerRadius, center.y + sinf(DEG2RAD*angle)*innerRadius);
- }
-
- for (int i = 0; i < segments; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
-
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*outerRadius, center.y + sinf(DEG2RAD*angle)*outerRadius);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*outerRadius, center.y + sinf(DEG2RAD*(angle + stepLength))*outerRadius);
-
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*innerRadius, center.y + sinf(DEG2RAD*angle)*innerRadius);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*innerRadius, center.y + sinf(DEG2RAD*(angle + stepLength))*innerRadius);
-
- angle += stepLength;
- }
-
- if (showCapLines)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*outerRadius, center.y + sinf(DEG2RAD*angle)*outerRadius);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*innerRadius, center.y + sinf(DEG2RAD*angle)*innerRadius);
- }
- rlEnd();
+void DrawRingLines(Vector2 center, float innerRadius, float outerRadius, float startAngle, float endAngle, int segments, RLColor color) {
+ if (startAngle == endAngle)
+ return;
+
+ // Function expects (outerRadius > innerRadius)
+ if (outerRadius < innerRadius) {
+ float tmp = outerRadius;
+ outerRadius = innerRadius;
+ innerRadius = tmp;
+
+ if (outerRadius <= 0.0f)
+ outerRadius = 0.1f;
+ }
+
+ // Function expects (endAngle > startAngle)
+ if (endAngle < startAngle) {
+ // Swap values
+ float tmp = startAngle;
+ startAngle = endAngle;
+ endAngle = tmp;
+ }
+
+ int minSegments = (int)ceilf((endAngle - startAngle) / 90);
+
+ if (segments < minSegments) {
+ // Calculate the maximum angle between segments based on the error rate (usually 0.5f)
+ float th = acosf(2 * powf(1 - SMOOTH_CIRCLE_ERROR_RATE / outerRadius, 2) - 1);
+ segments = (int)((endAngle - startAngle) * ceilf(2 * PI / th) / 360);
+
+ if (segments <= 0)
+ segments = minSegments;
+ }
+
+ if (innerRadius <= 0.0f) {
+ DrawCircleSectorLines(center, outerRadius, startAngle, endAngle, segments, color);
+ return;
+ }
+
+ float stepLength = (endAngle - startAngle) / (float)segments;
+ float angle = startAngle;
+ bool showCapLines = true;
+
+ rlBegin(RL_LINES);
+ if (showCapLines) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * outerRadius, center.y + sinf(DEG2RAD * angle) * outerRadius);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * innerRadius, center.y + sinf(DEG2RAD * angle) * innerRadius);
+ }
+
+ for (int i = 0; i < segments; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * outerRadius, center.y + sinf(DEG2RAD * angle) * outerRadius);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * outerRadius, center.y + sinf(DEG2RAD * (angle + stepLength)) * outerRadius);
+
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * innerRadius, center.y + sinf(DEG2RAD * angle) * innerRadius);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * innerRadius, center.y + sinf(DEG2RAD * (angle + stepLength)) * innerRadius);
+
+ angle += stepLength;
+ }
+
+ if (showCapLines) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * outerRadius, center.y + sinf(DEG2RAD * angle) * outerRadius);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * innerRadius, center.y + sinf(DEG2RAD * angle) * innerRadius);
+ }
+ rlEnd();
}
// Draw a color-filled rectangle
-void DrawRectangle(int posX, int posY, int width, int height, RLColor color)
-{
- DrawRectangleV((Vector2){ (float)posX, (float)posY }, (Vector2){ (float)width, (float)height }, color);
+void DrawRectangle(int posX, int posY, int width, int height, RLColor color) {
+ DrawRectangleV((Vector2){(float)posX, (float)posY}, (Vector2){(float)width, (float)height}, color);
}
// Draw a color-filled rectangle (Vector version)
// NOTE: On OpenGL 3.3 and ES2 we use QUADS to avoid drawing order issues
-void DrawRectangleV(Vector2 position, Vector2 size, RLColor color)
-{
- DrawRectanglePro((Rectangle){ position.x, position.y, size.x, size.y }, (Vector2){ 0.0f, 0.0f }, 0.0f, color);
+void DrawRectangleV(Vector2 position, Vector2 size, RLColor color) {
+ DrawRectanglePro((Rectangle){position.x, position.y, size.x, size.y}, (Vector2){0.0f, 0.0f}, 0.0f, color);
}
// Draw a color-filled rectangle
-void DrawRectangleRec(Rectangle rec, RLColor color)
-{
- DrawRectanglePro(rec, (Vector2){ 0.0f, 0.0f }, 0.0f, color);
+void DrawRectangleRec(Rectangle rec, RLColor color) {
+ DrawRectanglePro(rec, (Vector2){0.0f, 0.0f}, 0.0f, color);
}
// Draw a color-filled rectangle with pro parameters
-void DrawRectanglePro(Rectangle rec, Vector2 origin, float rotation, RLColor color)
-{
- Vector2 topLeft = { 0 };
- Vector2 topRight = { 0 };
- Vector2 bottomLeft = { 0 };
- Vector2 bottomRight = { 0 };
-
- // Only calculate rotation if needed
- if (rotation == 0.0f)
- {
- float x = rec.x - origin.x;
- float y = rec.y - origin.y;
- topLeft = (Vector2){ x, y };
- topRight = (Vector2){ x + rec.width, y };
- bottomLeft = (Vector2){ x, y + rec.height };
- bottomRight = (Vector2){ x + rec.width, y + rec.height };
- }
- else
- {
- float sinRotation = sinf(rotation*DEG2RAD);
- float cosRotation = cosf(rotation*DEG2RAD);
- float x = rec.x;
- float y = rec.y;
- float dx = -origin.x;
- float dy = -origin.y;
-
- topLeft.x = x + dx*cosRotation - dy*sinRotation;
- topLeft.y = y + dx*sinRotation + dy*cosRotation;
-
- topRight.x = x + (dx + rec.width)*cosRotation - dy*sinRotation;
- topRight.y = y + (dx + rec.width)*sinRotation + dy*cosRotation;
-
- bottomLeft.x = x + dx*cosRotation - (dy + rec.height)*sinRotation;
- bottomLeft.y = y + dx*sinRotation + (dy + rec.height)*cosRotation;
-
- bottomRight.x = x + (dx + rec.width)*cosRotation - (dy + rec.height)*sinRotation;
- bottomRight.y = y + (dx + rec.width)*sinRotation + (dy + rec.height)*cosRotation;
- }
+void DrawRectanglePro(Rectangle rec, Vector2 origin, float rotation, RLColor color) {
+ Vector2 topLeft = {0};
+ Vector2 topRight = {0};
+ Vector2 bottomLeft = {0};
+ Vector2 bottomRight = {0};
+
+ // Only calculate rotation if needed
+ if (rotation == 0.0f) {
+ float x = rec.x - origin.x;
+ float y = rec.y - origin.y;
+ topLeft = (Vector2){x, y};
+ topRight = (Vector2){x + rec.width, y};
+ bottomLeft = (Vector2){x, y + rec.height};
+ bottomRight = (Vector2){x + rec.width, y + rec.height};
+ } else {
+ float sinRotation = sinf(rotation * DEG2RAD);
+ float cosRotation = cosf(rotation * DEG2RAD);
+ float x = rec.x;
+ float y = rec.y;
+ float dx = -origin.x;
+ float dy = -origin.y;
+
+ topLeft.x = x + dx * cosRotation - dy * sinRotation;
+ topLeft.y = y + dx * sinRotation + dy * cosRotation;
+
+ topRight.x = x + (dx + rec.width) * cosRotation - dy * sinRotation;
+ topRight.y = y + (dx + rec.width) * sinRotation + dy * cosRotation;
+
+ bottomLeft.x = x + dx * cosRotation - (dy + rec.height) * sinRotation;
+ bottomLeft.y = y + dx * sinRotation + (dy + rec.height) * cosRotation;
+
+ bottomRight.x = x + (dx + rec.width) * cosRotation - (dy + rec.height) * sinRotation;
+ bottomRight.y = y + (dx + rec.width) * sinRotation + (dy + rec.height) * cosRotation;
+ }
#if defined(SUPPORT_QUADS_DRAW_MODE)
- rlSetTexture(GetShapesTexture().id);
- Rectangle shapeRect = GetShapesTextureRectangle();
+ rlSetTexture(GetShapesTexture().id);
+ Rectangle shapeRect = GetShapesTextureRectangle();
- rlBegin(RL_QUADS);
+ rlBegin(RL_QUADS);
- rlNormal3f(0.0f, 0.0f, 1.0f);
- rlColor4ub(color.r, color.g, color.b, color.a);
+ rlNormal3f(0.0f, 0.0f, 1.0f);
+ rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(topLeft.x, topLeft.y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(topLeft.x, topLeft.y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(bottomLeft.x, bottomLeft.y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(bottomLeft.x, bottomLeft.y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(bottomRight.x, bottomRight.y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(bottomRight.x, bottomRight.y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(topRight.x, topRight.y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(topRight.x, topRight.y);
- rlEnd();
+ rlEnd();
- rlSetTexture(0);
+ rlSetTexture(0);
#else
- rlBegin(RL_TRIANGLES);
+ rlBegin(RL_TRIANGLES);
- rlColor4ub(color.r, color.g, color.b, color.a);
+ rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(topLeft.x, topLeft.y);
- rlVertex2f(bottomLeft.x, bottomLeft.y);
- rlVertex2f(topRight.x, topRight.y);
+ rlVertex2f(topLeft.x, topLeft.y);
+ rlVertex2f(bottomLeft.x, bottomLeft.y);
+ rlVertex2f(topRight.x, topRight.y);
- rlVertex2f(topRight.x, topRight.y);
- rlVertex2f(bottomLeft.x, bottomLeft.y);
- rlVertex2f(bottomRight.x, bottomRight.y);
+ rlVertex2f(topRight.x, topRight.y);
+ rlVertex2f(bottomLeft.x, bottomLeft.y);
+ rlVertex2f(bottomRight.x, bottomRight.y);
- rlEnd();
+ rlEnd();
#endif
}
// Draw a vertical-gradient-filled rectangle
-void DrawRectangleGradientV(int posX, int posY, int width, int height, RLColor top, RLColor bottom)
-{
- DrawRectangleGradientEx((Rectangle){ (float)posX, (float)posY, (float)width, (float)height }, top, bottom, bottom, top);
+void DrawRectangleGradientV(int posX, int posY, int width, int height, RLColor top, RLColor bottom) {
+ DrawRectangleGradientEx((Rectangle){(float)posX, (float)posY, (float)width, (float)height}, top, bottom, bottom, top);
}
// Draw a horizontal-gradient-filled rectangle
-void DrawRectangleGradientH(int posX, int posY, int width, int height, RLColor left, RLColor right)
-{
- DrawRectangleGradientEx((Rectangle){ (float)posX, (float)posY, (float)width, (float)height }, left, left, right, right);
+void DrawRectangleGradientH(int posX, int posY, int width, int height, RLColor left, RLColor right) {
+ DrawRectangleGradientEx((Rectangle){(float)posX, (float)posY, (float)width, (float)height}, left, left, right, right);
}
// Draw a gradient-filled rectangle
-void DrawRectangleGradientEx(Rectangle rec, RLColor topLeft, RLColor bottomLeft, RLColor topRight, RLColor bottomRight)
-{
- rlSetTexture(GetShapesTexture().id);
- Rectangle shapeRect = GetShapesTextureRectangle();
+void DrawRectangleGradientEx(Rectangle rec, RLColor topLeft, RLColor bottomLeft, RLColor topRight, RLColor bottomRight) {
+ rlSetTexture(GetShapesTexture().id);
+ Rectangle shapeRect = GetShapesTextureRectangle();
- rlBegin(RL_QUADS);
- rlNormal3f(0.0f, 0.0f, 1.0f);
+ rlBegin(RL_QUADS);
+ rlNormal3f(0.0f, 0.0f, 1.0f);
- // NOTE: Default raylib font character 95 is a white square
- rlColor4ub(topLeft.r, topLeft.g, topLeft.b, topLeft.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(rec.x, rec.y);
+ // NOTE: Default raylib font character 95 is a white square
+ rlColor4ub(topLeft.r, topLeft.g, topLeft.b, topLeft.a);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(rec.x, rec.y);
- rlColor4ub(bottomLeft.r, bottomLeft.g, bottomLeft.b, bottomLeft.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(rec.x, rec.y + rec.height);
+ rlColor4ub(bottomLeft.r, bottomLeft.g, bottomLeft.b, bottomLeft.a);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(rec.x, rec.y + rec.height);
- rlColor4ub(topRight.r, topRight.g, topRight.b, topRight.a);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(rec.x + rec.width, rec.y + rec.height);
+ rlColor4ub(topRight.r, topRight.g, topRight.b, topRight.a);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(rec.x + rec.width, rec.y + rec.height);
- rlColor4ub(bottomRight.r, bottomRight.g, bottomRight.b, bottomRight.a);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(rec.x + rec.width, rec.y);
- rlEnd();
+ rlColor4ub(bottomRight.r, bottomRight.g, bottomRight.b, bottomRight.a);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(rec.x + rec.width, rec.y);
+ rlEnd();
- rlSetTexture(0);
+ rlSetTexture(0);
}
// Draw rectangle outline
// WARNING: All Draw*Lines() functions use RL_LINES for drawing,
// it implies flushing the current batch and changing draw mode to RL_LINES
// but it solves another issue: https://github.com/raysan5/raylib/issues/3884
-void DrawRectangleLines(int posX, int posY, int width, int height, RLColor color)
-{
- RLMatrix mat = rlGetMatrixModelview();
- float zoomFactor = 0.5f/mat.m0;
- rlBegin(RL_LINES);
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f((float)posX - zoomFactor, (float)posY);
- rlVertex2f((float)posX + (float)width + zoomFactor, (float)posY);
-
- rlVertex2f((float)posX + (float)width, (float)posY - zoomFactor);
- rlVertex2f((float)posX + (float)width, (float)posY + (float)height + zoomFactor);
-
- rlVertex2f((float)posX + (float)width + zoomFactor, (float)posY + (float)height);
- rlVertex2f((float)posX - zoomFactor, (float)posY + (float)height);
-
- rlVertex2f((float)posX, (float)posY + (float)height + zoomFactor);
- rlVertex2f((float)posX, (float)posY - zoomFactor);
- rlEnd();
-/*
-// Previous implementation, it has issues... but it does not require view matrix...
-#if defined(SUPPORT_QUADS_DRAW_MODE)
- DrawRectangle(posX, posY, width, 1, color);
- DrawRectangle(posX + width - 1, posY + 1, 1, height - 2, color);
- DrawRectangle(posX, posY + height - 1, width, 1, color);
- DrawRectangle(posX, posY + 1, 1, height - 2, color);
-#else
- rlBegin(RL_LINES);
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f((float)posX, (float)posY);
- rlVertex2f((float)posX + (float)width, (float)posY + 1);
-
- rlVertex2f((float)posX + (float)width, (float)posY + 1);
- rlVertex2f((float)posX + (float)width, (float)posY + (float)height);
-
- rlVertex2f((float)posX + (float)width, (float)posY + (float)height);
- rlVertex2f((float)posX + 1, (float)posY + (float)height);
-
- rlVertex2f((float)posX + 1, (float)posY + (float)height);
- rlVertex2f((float)posX + 1, (float)posY + 1);
- rlEnd();
-//#endif
-*/
+void DrawRectangleLines(int posX, int posY, int width, int height, RLColor color) {
+ DrawRectangleLinesEx((Rectangle){(float)posX, (float)posY, (float)width, (float)height}, 1.0f, color);
+ /*
+ // DO NOT USE LINES MODE.
+ RLMatrix mat = rlGetMatrixModelview();
+ float zoomFactor = 0.5f / mat.m0;
+ rlBegin(RL_LINES);
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f((float)posX - zoomFactor, (float)posY);
+ rlVertex2f((float)posX + (float)width + zoomFactor, (float)posY);
+
+ rlVertex2f((float)posX + (float)width, (float)posY - zoomFactor);
+ rlVertex2f((float)posX + (float)width, (float)posY + (float)height + zoomFactor);
+
+ rlVertex2f((float)posX + (float)width + zoomFactor, (float)posY + (float)height);
+ rlVertex2f((float)posX - zoomFactor, (float)posY + (float)height);
+
+ rlVertex2f((float)posX, (float)posY + (float)height + zoomFactor);
+ rlVertex2f((float)posX, (float)posY - zoomFactor);
+ rlEnd();
+ // Previous implementation, it has issues... but it does not require view matrix...
+ #if defined(SUPPORT_QUADS_DRAW_MODE)
+ DrawRectangle(posX, posY, width, 1, color);
+ DrawRectangle(posX + width - 1, posY + 1, 1, height - 2, color);
+ DrawRectangle(posX, posY + height - 1, width, 1, color);
+ DrawRectangle(posX, posY + 1, 1, height - 2, color);
+ #else
+ rlBegin(RL_LINES);
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f((float)posX, (float)posY);
+ rlVertex2f((float)posX + (float)width, (float)posY + 1);
+
+ rlVertex2f((float)posX + (float)width, (float)posY + 1);
+ rlVertex2f((float)posX + (float)width, (float)posY + (float)height);
+
+ rlVertex2f((float)posX + (float)width, (float)posY + (float)height);
+ rlVertex2f((float)posX + 1, (float)posY + (float)height);
+
+ rlVertex2f((float)posX + 1, (float)posY + (float)height);
+ rlVertex2f((float)posX + 1, (float)posY + 1);
+ rlEnd();
+ //#endif
+ */
}
// Draw rectangle outline with extended parameters
-void DrawRectangleLinesEx(Rectangle rec, float lineThick, RLColor color)
-{
- if ((lineThick > rec.width) || (lineThick > rec.height))
- {
- if (rec.width >= rec.height) lineThick = rec.height/2;
- else if (rec.width <= rec.height) lineThick = rec.width/2;
- }
-
- // When rec = { x, y, 8.0f, 6.0f } and lineThick = 2, the following
- // four rectangles are drawn ([T]op, [B]ottom, [L]eft, [R]ight):
- //
- // TTTTTTTT
- // TTTTTTTT
- // LL RR
- // LL RR
- // BBBBBBBB
- // BBBBBBBB
- //
-
- Rectangle top = { rec.x, rec.y, rec.width, lineThick };
- Rectangle bottom = { rec.x, rec.y - lineThick + rec.height, rec.width, lineThick };
- Rectangle left = { rec.x, rec.y + lineThick, lineThick, rec.height - lineThick*2.0f };
- Rectangle right = { rec.x - lineThick + rec.width, rec.y + lineThick, lineThick, rec.height - lineThick*2.0f };
-
- DrawRectangleRec(top, color);
- DrawRectangleRec(bottom, color);
- DrawRectangleRec(left, color);
- DrawRectangleRec(right, color);
+void DrawRectangleLinesEx(Rectangle rec, float lineThick, RLColor color) {
+ if ((lineThick > rec.width) || (lineThick > rec.height)) {
+ if (rec.width >= rec.height)
+ lineThick = rec.height / 2;
+ else if (rec.width <= rec.height)
+ lineThick = rec.width / 2;
+ }
+
+ // When rec = { x, y, 8.0f, 6.0f } and lineThick = 2, the following
+ // four rectangles are drawn ([T]op, [B]ottom, [L]eft, [R]ight):
+ //
+ // TTTTTTTT
+ // TTTTTTTT
+ // LL RR
+ // LL RR
+ // BBBBBBBB
+ // BBBBBBBB
+ //
+
+ Rectangle top = {rec.x, rec.y, rec.width, lineThick};
+ Rectangle bottom = {rec.x, rec.y - lineThick + rec.height, rec.width, lineThick};
+ Rectangle left = {rec.x, rec.y + lineThick, lineThick, rec.height - lineThick * 2.0f};
+ Rectangle right = {rec.x - lineThick + rec.width, rec.y + lineThick, lineThick, rec.height - lineThick * 2.0f};
+
+ DrawRectangleRec(top, color);
+ DrawRectangleRec(bottom, color);
+ DrawRectangleRec(left, color);
+ DrawRectangleRec(right, color);
}
// Draw rectangle with rounded edges
-void DrawRectangleRounded(Rectangle rec, float roundness, int segments, RLColor color)
-{
- // Not a rounded rectangle
- if ((roundness <= 0.0f) || (rec.width < 1) || (rec.height < 1 ))
- {
- DrawRectangleRec(rec, color);
- return;
- }
-
- if (roundness >= 1.0f) roundness = 1.0f;
-
- // Calculate corner radius
- float radius = (rec.width > rec.height)? (rec.height*roundness)/2 : (rec.width*roundness)/2;
- if (radius <= 0.0f) return;
-
- // Calculate number of segments to use for the corners
- if (segments < 4)
- {
- // Calculate the maximum angle between segments based on the error rate (usually 0.5f)
- float th = acosf(2*powf(1 - SMOOTH_CIRCLE_ERROR_RATE/radius, 2) - 1);
- segments = (int)(ceilf(2*PI/th)/4.0f);
- if (segments <= 0) segments = 4;
- }
-
- float stepLength = 90.0f/(float)segments;
-
- /*
- Quick sketch to make sense of all of this,
- there are 9 parts to draw, also mark the 12 points we'll use
-
- P0____________________P1
- /| |\
- /1| 2 |3\
- P7 /__|____________________|__\ P2
- | |P8 P9| |
- | 8 | 9 | 4 |
- | __|____________________|__ |
- P6 \ |P11 P10| / P3
- \7| 6 |5/
- \|____________________|/
- P5 P4
- */
- // Coordinates of the 12 points that define the rounded rect
- const Vector2 point[12] = {
- {(float)rec.x + radius, rec.y}, {(float)(rec.x + rec.width) - radius, rec.y}, { rec.x + rec.width, (float)rec.y + radius }, // PO, P1, P2
- {rec.x + rec.width, (float)(rec.y + rec.height) - radius}, {(float)(rec.x + rec.width) - radius, rec.y + rec.height}, // P3, P4
- {(float)rec.x + radius, rec.y + rec.height}, { rec.x, (float)(rec.y + rec.height) - radius}, {rec.x, (float)rec.y + radius}, // P5, P6, P7
- {(float)rec.x + radius, (float)rec.y + radius}, {(float)(rec.x + rec.width) - radius, (float)rec.y + radius}, // P8, P9
- {(float)(rec.x + rec.width) - radius, (float)(rec.y + rec.height) - radius}, {(float)rec.x + radius, (float)(rec.y + rec.height) - radius} // P10, P11
- };
-
- const Vector2 centers[4] = { point[8], point[9], point[10], point[11] };
- const float angles[4] = { 180.0f, 270.0f, 0.0f, 90.0f };
+void DrawRectangleRounded(Rectangle rec, float roundness, int segments, RLColor color) {
+ // Not a rounded rectangle
+ if ((roundness <= 0.0f) || (rec.width < 1) || (rec.height < 1)) {
+ DrawRectangleRec(rec, color);
+ return;
+ }
+
+ if (roundness >= 1.0f)
+ roundness = 1.0f;
+
+ // Calculate corner radius
+ float radius = (rec.width > rec.height) ? (rec.height * roundness) / 2 : (rec.width * roundness) / 2;
+ if (radius <= 0.0f)
+ return;
+
+ // Calculate number of segments to use for the corners
+ if (segments < 4) {
+ // Calculate the maximum angle between segments based on the error rate (usually 0.5f)
+ float th = acosf(2 * powf(1 - SMOOTH_CIRCLE_ERROR_RATE / radius, 2) - 1);
+ segments = (int)(ceilf(2 * PI / th) / 4.0f);
+ if (segments <= 0)
+ segments = 4;
+ }
+
+ float stepLength = 90.0f / (float)segments;
+
+ /*
+ Quick sketch to make sense of all of this,
+ there are 9 parts to draw, also mark the 12 points we'll use
+
+ P0____________________P1
+ /| |\
+ /1| 2 |3\
+ P7 /__|____________________|__\ P2
+ | |P8 P9| |
+ | 8 | 9 | 4 |
+ | __|____________________|__ |
+ P6 \ |P11 P10| / P3
+ \7| 6 |5/
+ \|____________________|/
+ P5 P4
+ */
+ // Coordinates of the 12 points that define the rounded rect
+ const Vector2 point[12] = {
+ {(float)rec.x + radius, rec.y}, {(float)(rec.x + rec.width) - radius, rec.y}, {rec.x + rec.width, (float)rec.y + radius}, // PO, P1, P2
+ {rec.x + rec.width, (float)(rec.y + rec.height) - radius},
+ {(float)(rec.x + rec.width) - radius, rec.y + rec.height}, // P3, P4
+ {(float)rec.x + radius, rec.y + rec.height},
+ {rec.x, (float)(rec.y + rec.height) - radius},
+ {rec.x, (float)rec.y + radius}, // P5, P6, P7
+ {(float)rec.x + radius, (float)rec.y + radius},
+ {(float)(rec.x + rec.width) - radius, (float)rec.y + radius}, // P8, P9
+ {(float)(rec.x + rec.width) - radius, (float)(rec.y + rec.height) - radius},
+ {(float)rec.x + radius, (float)(rec.y + rec.height) - radius} // P10, P11
+ };
+
+ const Vector2 centers[4] = {point[8], point[9], point[10], point[11]};
+ const float angles[4] = {180.0f, 270.0f, 0.0f, 90.0f};
#if defined(SUPPORT_QUADS_DRAW_MODE)
- rlSetTexture(GetShapesTexture().id);
- Rectangle shapeRect = GetShapesTextureRectangle();
-
- rlBegin(RL_QUADS);
- // Draw all the 4 corners: [1] Upper Left Corner, [3] Upper Right Corner, [5] Lower Right Corner, [7] Lower Left Corner
- for (int k = 0; k < 4; ++k) // Hope the compiler is smart enough to unroll this loop
- {
- float angle = angles[k];
- const Vector2 center = centers[k];
-
- // NOTE: Every QUAD actually represents two segments
- for (int i = 0; i < segments/2; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x, center.y);
-
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength*2))*radius, center.y + sinf(DEG2RAD*(angle + stepLength*2))*radius);
-
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*radius, center.y + sinf(DEG2RAD*(angle + stepLength))*radius);
-
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*radius, center.y + sinf(DEG2RAD*angle)*radius);
-
- angle += (stepLength*2);
- }
-
- // NOTE: In case number of segments is odd, we add one last piece to the cake
- if (segments%2)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x, center.y);
-
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*radius, center.y + sinf(DEG2RAD*(angle + stepLength))*radius);
-
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*radius, center.y + sinf(DEG2RAD*angle)*radius);
-
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x, center.y);
- }
- }
-
- // [2] Upper Rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[0].x, point[0].y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[8].x, point[8].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[9].x, point[9].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[1].x, point[1].y);
-
- // [4] Right Rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[2].x, point[2].y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[9].x, point[9].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[10].x, point[10].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[3].x, point[3].y);
-
- // [6] Bottom Rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[11].x, point[11].y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[5].x, point[5].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[4].x, point[4].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[10].x, point[10].y);
-
- // [8] Left Rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[7].x, point[7].y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[6].x, point[6].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[11].x, point[11].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[8].x, point[8].y);
-
- // [9] Middle Rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[8].x, point[8].y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[11].x, point[11].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[10].x, point[10].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[9].x, point[9].y);
-
- rlEnd();
- rlSetTexture(0);
+ rlSetTexture(GetShapesTexture().id);
+ Rectangle shapeRect = GetShapesTextureRectangle();
+
+ rlBegin(RL_QUADS);
+ // Draw all the 4 corners: [1] Upper Left Corner, [3] Upper Right Corner, [5] Lower Right Corner, [7] Lower Left Corner
+ for (int k = 0; k < 4; ++k) // Hope the compiler is smart enough to unroll this loop
+ {
+ float angle = angles[k];
+ const Vector2 center = centers[k];
+
+ // NOTE: Every QUAD actually represents two segments
+ for (int i = 0; i < segments / 2; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x, center.y);
+
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength * 2)) * radius, center.y + sinf(DEG2RAD * (angle + stepLength * 2)) * radius);
+
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * radius, center.y + sinf(DEG2RAD * (angle + stepLength)) * radius);
+
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * radius, center.y + sinf(DEG2RAD * angle) * radius);
+
+ angle += (stepLength * 2);
+ }
+
+ // NOTE: In case number of segments is odd, we add one last piece to the cake
+ if (segments % 2) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x, center.y);
+
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * radius, center.y + sinf(DEG2RAD * (angle + stepLength)) * radius);
+
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * radius, center.y + sinf(DEG2RAD * angle) * radius);
+
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x, center.y);
+ }
+ }
+
+ // [2] Upper Rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[0].x, point[0].y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[8].x, point[8].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[9].x, point[9].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[1].x, point[1].y);
+
+ // [4] Right Rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[2].x, point[2].y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[9].x, point[9].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[10].x, point[10].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[3].x, point[3].y);
+
+ // [6] Bottom Rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[11].x, point[11].y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[5].x, point[5].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[4].x, point[4].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[10].x, point[10].y);
+
+ // [8] Left Rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[7].x, point[7].y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[6].x, point[6].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[11].x, point[11].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[8].x, point[8].y);
+
+ // [9] Middle Rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[8].x, point[8].y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[11].x, point[11].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[10].x, point[10].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[9].x, point[9].y);
+
+ rlEnd();
+ rlSetTexture(0);
#else
- rlBegin(RL_TRIANGLES);
-
- // Draw all of the 4 corners: [1] Upper Left Corner, [3] Upper Right Corner, [5] Lower Right Corner, [7] Lower Left Corner
- for (int k = 0; k < 4; ++k) // Hope the compiler is smart enough to unroll this loop
- {
- float angle = angles[k];
- const Vector2 center = centers[k];
- for (int i = 0; i < segments; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(center.x, center.y);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*radius, center.y + sinf(DEG2RAD*(angle + stepLength))*radius);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*radius, center.y + sinf(DEG2RAD*angle)*radius);
- angle += stepLength;
- }
- }
-
- // [2] Upper Rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(point[0].x, point[0].y);
- rlVertex2f(point[8].x, point[8].y);
- rlVertex2f(point[9].x, point[9].y);
- rlVertex2f(point[1].x, point[1].y);
- rlVertex2f(point[0].x, point[0].y);
- rlVertex2f(point[9].x, point[9].y);
-
- // [4] Right Rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(point[9].x, point[9].y);
- rlVertex2f(point[10].x, point[10].y);
- rlVertex2f(point[3].x, point[3].y);
- rlVertex2f(point[2].x, point[2].y);
- rlVertex2f(point[9].x, point[9].y);
- rlVertex2f(point[3].x, point[3].y);
-
- // [6] Bottom Rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(point[11].x, point[11].y);
- rlVertex2f(point[5].x, point[5].y);
- rlVertex2f(point[4].x, point[4].y);
- rlVertex2f(point[10].x, point[10].y);
- rlVertex2f(point[11].x, point[11].y);
- rlVertex2f(point[4].x, point[4].y);
-
- // [8] Left Rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(point[7].x, point[7].y);
- rlVertex2f(point[6].x, point[6].y);
- rlVertex2f(point[11].x, point[11].y);
- rlVertex2f(point[8].x, point[8].y);
- rlVertex2f(point[7].x, point[7].y);
- rlVertex2f(point[11].x, point[11].y);
-
- // [9] Middle Rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(point[8].x, point[8].y);
- rlVertex2f(point[11].x, point[11].y);
- rlVertex2f(point[10].x, point[10].y);
- rlVertex2f(point[9].x, point[9].y);
- rlVertex2f(point[8].x, point[8].y);
- rlVertex2f(point[10].x, point[10].y);
- rlEnd();
+ rlBegin(RL_TRIANGLES);
+
+ // Draw all of the 4 corners: [1] Upper Left Corner, [3] Upper Right Corner, [5] Lower Right Corner, [7] Lower Left Corner
+ for (int k = 0; k < 4; ++k) // Hope the compiler is smart enough to unroll this loop
+ {
+ float angle = angles[k];
+ const Vector2 center = centers[k];
+ for (int i = 0; i < segments; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(center.x, center.y);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * radius, center.y + sinf(DEG2RAD * (angle + stepLength)) * radius);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * radius, center.y + sinf(DEG2RAD * angle) * radius);
+ angle += stepLength;
+ }
+ }
+
+ // [2] Upper Rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(point[0].x, point[0].y);
+ rlVertex2f(point[8].x, point[8].y);
+ rlVertex2f(point[9].x, point[9].y);
+ rlVertex2f(point[1].x, point[1].y);
+ rlVertex2f(point[0].x, point[0].y);
+ rlVertex2f(point[9].x, point[9].y);
+
+ // [4] Right Rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(point[9].x, point[9].y);
+ rlVertex2f(point[10].x, point[10].y);
+ rlVertex2f(point[3].x, point[3].y);
+ rlVertex2f(point[2].x, point[2].y);
+ rlVertex2f(point[9].x, point[9].y);
+ rlVertex2f(point[3].x, point[3].y);
+
+ // [6] Bottom Rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(point[11].x, point[11].y);
+ rlVertex2f(point[5].x, point[5].y);
+ rlVertex2f(point[4].x, point[4].y);
+ rlVertex2f(point[10].x, point[10].y);
+ rlVertex2f(point[11].x, point[11].y);
+ rlVertex2f(point[4].x, point[4].y);
+
+ // [8] Left Rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(point[7].x, point[7].y);
+ rlVertex2f(point[6].x, point[6].y);
+ rlVertex2f(point[11].x, point[11].y);
+ rlVertex2f(point[8].x, point[8].y);
+ rlVertex2f(point[7].x, point[7].y);
+ rlVertex2f(point[11].x, point[11].y);
+
+ // [9] Middle Rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(point[8].x, point[8].y);
+ rlVertex2f(point[11].x, point[11].y);
+ rlVertex2f(point[10].x, point[10].y);
+ rlVertex2f(point[9].x, point[9].y);
+ rlVertex2f(point[8].x, point[8].y);
+ rlVertex2f(point[10].x, point[10].y);
+ rlEnd();
#endif
}
// Draw rectangle with rounded edges
// TODO: This function should be refactored to use RL_LINES, for consistency with other Draw*Lines()
-void DrawRectangleRoundedLines(Rectangle rec, float roundness, int segments, RLColor color)
-{
- DrawRectangleRoundedLinesEx(rec, roundness, segments, 1.0f, color);
+void DrawRectangleRoundedLines(Rectangle rec, float roundness, int segments, RLColor color) {
+ DrawRectangleRoundedLinesEx(rec, roundness, segments, 1.0f, color);
}
// Draw rectangle with rounded edges outline
-void DrawRectangleRoundedLinesEx(Rectangle rec, float roundness, int segments, float lineThick, RLColor color)
-{
- if (lineThick < 0) lineThick = 0;
-
- // Not a rounded rectangle
- if (roundness <= 0.0f)
- {
- DrawRectangleLinesEx((Rectangle){rec.x-lineThick, rec.y-lineThick, rec.width+2*lineThick, rec.height+2*lineThick}, lineThick, color);
- return;
- }
-
- if (roundness >= 1.0f) roundness = 1.0f;
-
- // Calculate corner radius
- float radius = (rec.width > rec.height)? (rec.height*roundness)/2 : (rec.width*roundness)/2;
- if (radius <= 0.0f) return;
-
- // Calculate number of segments to use for the corners
- if (segments < 4)
- {
- // Calculate the maximum angle between segments based on the error rate (usually 0.5f)
- float th = acosf(2*powf(1 - SMOOTH_CIRCLE_ERROR_RATE/radius, 2) - 1);
- segments = (int)(ceilf(2*PI/th)/2.0f);
- if (segments <= 0) segments = 4;
- }
-
- float stepLength = 90.0f/(float)segments;
- const float outerRadius = radius + lineThick, innerRadius = radius;
-
- /*
- Quick sketch to make sense of all of this,
- marks the 16 + 4(corner centers P16-19) points we'll use
-
- P0 ================== P1
- // P8 P9 \\
- // \\
- P7 // P15 P10 \\ P2
- || *P16 P17* ||
- || ||
- || P14 P11 ||
- P6 \\ *P19 P18* // P3
- \\ //
- \\ P13 P12 //
- P5 ================== P4
- */
- const Vector2 point[16] = {
- {(float)rec.x + innerRadius, rec.y - lineThick}, {(float)(rec.x + rec.width) - innerRadius, rec.y - lineThick}, { rec.x + rec.width + lineThick, (float)rec.y + innerRadius }, // PO, P1, P2
- {rec.x + rec.width + lineThick, (float)(rec.y + rec.height) - innerRadius}, {(float)(rec.x + rec.width) - innerRadius, rec.y + rec.height + lineThick}, // P3, P4
- {(float)rec.x + innerRadius, rec.y + rec.height + lineThick}, { rec.x - lineThick, (float)(rec.y + rec.height) - innerRadius}, {rec.x - lineThick, (float)rec.y + innerRadius}, // P5, P6, P7
- {(float)rec.x + innerRadius, rec.y}, {(float)(rec.x + rec.width) - innerRadius, rec.y}, // P8, P9
- { rec.x + rec.width, (float)rec.y + innerRadius }, {rec.x + rec.width, (float)(rec.y + rec.height) - innerRadius}, // P10, P11
- {(float)(rec.x + rec.width) - innerRadius, rec.y + rec.height}, {(float)rec.x + innerRadius, rec.y + rec.height}, // P12, P13
- { rec.x, (float)(rec.y + rec.height) - innerRadius}, {rec.x, (float)rec.y + innerRadius} // P14, P15
- };
-
- const Vector2 centers[4] = {
- {(float)rec.x + innerRadius, (float)rec.y + innerRadius}, {(float)(rec.x + rec.width) - innerRadius, (float)rec.y + innerRadius}, // P16, P17
- {(float)(rec.x + rec.width) - innerRadius, (float)(rec.y + rec.height) - innerRadius}, {(float)rec.x + innerRadius, (float)(rec.y + rec.height) - innerRadius} // P18, P19
- };
-
- const float angles[4] = { 180.0f, 270.0f, 0.0f, 90.0f };
-
- if (lineThick > 1)
- {
+void DrawRectangleRoundedLinesEx(Rectangle rec, float roundness, int segments, float lineThick, RLColor color) {
+ if (lineThick < 0)
+ lineThick = 0;
+
+ // Not a rounded rectangle
+ if (roundness <= 0.0f) {
+ DrawRectangleLinesEx((Rectangle){rec.x - lineThick, rec.y - lineThick, rec.width + 2 * lineThick, rec.height + 2 * lineThick}, lineThick, color);
+ return;
+ }
+
+ if (roundness >= 1.0f)
+ roundness = 1.0f;
+
+ // Calculate corner radius
+ float radius = (rec.width > rec.height) ? (rec.height * roundness) / 2 : (rec.width * roundness) / 2;
+ if (radius <= 0.0f)
+ return;
+
+ // Calculate number of segments to use for the corners
+ if (segments < 4) {
+ // Calculate the maximum angle between segments based on the error rate (usually 0.5f)
+ float th = acosf(2 * powf(1 - SMOOTH_CIRCLE_ERROR_RATE / radius, 2) - 1);
+ segments = (int)(ceilf(2 * PI / th) / 2.0f);
+ if (segments <= 0)
+ segments = 4;
+ }
+
+ float stepLength = 90.0f / (float)segments;
+ const float outerRadius = radius + lineThick, innerRadius = radius;
+
+ /*
+ Quick sketch to make sense of all of this,
+ marks the 16 + 4(corner centers P16-19) points we'll use
+
+ P0 ================== P1
+ // P8 P9 \\
+ // \\
+ P7 // P15 P10 \\ P2
+ || *P16 P17* ||
+ || ||
+ || P14 P11 ||
+ P6 \\ *P19 P18* // P3
+ \\ //
+ \\ P13 P12 //
+ P5 ================== P4
+ */
+ const Vector2 point[16] = {
+ {(float)rec.x + innerRadius, rec.y - lineThick}, {(float)(rec.x + rec.width) - innerRadius, rec.y - lineThick}, {rec.x + rec.width + lineThick, (float)rec.y + innerRadius}, // PO, P1, P2
+ {rec.x + rec.width + lineThick, (float)(rec.y + rec.height) - innerRadius},
+ {(float)(rec.x + rec.width) - innerRadius, rec.y + rec.height + lineThick}, // P3, P4
+ {(float)rec.x + innerRadius, rec.y + rec.height + lineThick},
+ {rec.x - lineThick, (float)(rec.y + rec.height) - innerRadius},
+ {rec.x - lineThick, (float)rec.y + innerRadius}, // P5, P6, P7
+ {(float)rec.x + innerRadius, rec.y},
+ {(float)(rec.x + rec.width) - innerRadius, rec.y}, // P8, P9
+ {rec.x + rec.width, (float)rec.y + innerRadius},
+ {rec.x + rec.width, (float)(rec.y + rec.height) - innerRadius}, // P10, P11
+ {(float)(rec.x + rec.width) - innerRadius, rec.y + rec.height},
+ {(float)rec.x + innerRadius, rec.y + rec.height}, // P12, P13
+ {rec.x, (float)(rec.y + rec.height) - innerRadius},
+ {rec.x, (float)rec.y + innerRadius} // P14, P15
+ };
+
+ const Vector2 centers[4] = {
+ {(float)rec.x + innerRadius, (float)rec.y + innerRadius}, {(float)(rec.x + rec.width) - innerRadius, (float)rec.y + innerRadius}, // P16, P17
+ {(float)(rec.x + rec.width) - innerRadius, (float)(rec.y + rec.height) - innerRadius},
+ {(float)rec.x + innerRadius, (float)(rec.y + rec.height) - innerRadius} // P18, P19
+ };
+
+ const float angles[4] = {180.0f, 270.0f, 0.0f, 90.0f};
+
+ if (lineThick > 1) {
#if defined(SUPPORT_QUADS_DRAW_MODE)
- rlSetTexture(GetShapesTexture().id);
- Rectangle shapeRect = GetShapesTextureRectangle();
-
- rlBegin(RL_QUADS);
-
- // Draw all the 4 corners first: Upper Left Corner, Upper Right Corner, Lower Right Corner, Lower Left Corner
- for (int k = 0; k < 4; ++k) // Hope the compiler is smart enough to unroll this loop
- {
- float angle = angles[k];
- const Vector2 center = centers[k];
- for (int i = 0; i < segments; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
-
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*innerRadius, center.y + sinf(DEG2RAD*angle)*innerRadius);
-
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*innerRadius, center.y + sinf(DEG2RAD*(angle + stepLength))*innerRadius);
-
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*outerRadius, center.y + sinf(DEG2RAD*(angle + stepLength))*outerRadius);
-
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*outerRadius, center.y + sinf(DEG2RAD*angle)*outerRadius);
-
- angle += stepLength;
- }
- }
-
- // Upper rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[0].x, point[0].y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[8].x, point[8].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[9].x, point[9].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[1].x, point[1].y);
-
- // Right rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[2].x, point[2].y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[10].x, point[10].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[11].x, point[11].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[3].x, point[3].y);
-
- // Lower rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[13].x, point[13].y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[5].x, point[5].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[4].x, point[4].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[12].x, point[12].y);
-
- // Left rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[15].x, point[15].y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[7].x, point[7].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(point[6].x, point[6].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(point[14].x, point[14].y);
-
- rlEnd();
- rlSetTexture(0);
+ rlSetTexture(GetShapesTexture().id);
+ Rectangle shapeRect = GetShapesTextureRectangle();
+
+ rlBegin(RL_QUADS);
+
+ // Draw all the 4 corners first: Upper Left Corner, Upper Right Corner, Lower Right Corner, Lower Left Corner
+ for (int k = 0; k < 4; ++k) // Hope the compiler is smart enough to unroll this loop
+ {
+ float angle = angles[k];
+ const Vector2 center = centers[k];
+ for (int i = 0; i < segments; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * innerRadius, center.y + sinf(DEG2RAD * angle) * innerRadius);
+
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * innerRadius, center.y + sinf(DEG2RAD * (angle + stepLength)) * innerRadius);
+
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * outerRadius, center.y + sinf(DEG2RAD * (angle + stepLength)) * outerRadius);
+
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * outerRadius, center.y + sinf(DEG2RAD * angle) * outerRadius);
+
+ angle += stepLength;
+ }
+ }
+
+ // Upper rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[0].x, point[0].y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[8].x, point[8].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[9].x, point[9].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[1].x, point[1].y);
+
+ // Right rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[2].x, point[2].y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[10].x, point[10].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[11].x, point[11].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[3].x, point[3].y);
+
+ // Lower rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[13].x, point[13].y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[5].x, point[5].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[4].x, point[4].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[12].x, point[12].y);
+
+ // Left rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[15].x, point[15].y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[7].x, point[7].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(point[6].x, point[6].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(point[14].x, point[14].y);
+
+ rlEnd();
+ rlSetTexture(0);
#else
- rlBegin(RL_TRIANGLES);
-
- // Draw all of the 4 corners first: Upper Left Corner, Upper Right Corner, Lower Right Corner, Lower Left Corner
- for (int k = 0; k < 4; ++k) // Hope the compiler is smart enough to unroll this loop
- {
- float angle = angles[k];
- const Vector2 center = centers[k];
-
- for (int i = 0; i < segments; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
-
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*innerRadius, center.y + sinf(DEG2RAD*angle)*innerRadius);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*innerRadius, center.y + sinf(DEG2RAD*(angle + stepLength))*innerRadius);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*outerRadius, center.y + sinf(DEG2RAD*angle)*outerRadius);
-
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*innerRadius, center.y + sinf(DEG2RAD*(angle + stepLength))*innerRadius);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*outerRadius, center.y + sinf(DEG2RAD*(angle + stepLength))*outerRadius);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*outerRadius, center.y + sinf(DEG2RAD*angle)*outerRadius);
-
- angle += stepLength;
- }
- }
-
- // Upper rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(point[0].x, point[0].y);
- rlVertex2f(point[8].x, point[8].y);
- rlVertex2f(point[9].x, point[9].y);
- rlVertex2f(point[1].x, point[1].y);
- rlVertex2f(point[0].x, point[0].y);
- rlVertex2f(point[9].x, point[9].y);
-
- // Right rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(point[10].x, point[10].y);
- rlVertex2f(point[11].x, point[11].y);
- rlVertex2f(point[3].x, point[3].y);
- rlVertex2f(point[2].x, point[2].y);
- rlVertex2f(point[10].x, point[10].y);
- rlVertex2f(point[3].x, point[3].y);
-
- // Lower rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(point[13].x, point[13].y);
- rlVertex2f(point[5].x, point[5].y);
- rlVertex2f(point[4].x, point[4].y);
- rlVertex2f(point[12].x, point[12].y);
- rlVertex2f(point[13].x, point[13].y);
- rlVertex2f(point[4].x, point[4].y);
-
- // Left rectangle
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(point[7].x, point[7].y);
- rlVertex2f(point[6].x, point[6].y);
- rlVertex2f(point[14].x, point[14].y);
- rlVertex2f(point[15].x, point[15].y);
- rlVertex2f(point[7].x, point[7].y);
- rlVertex2f(point[14].x, point[14].y);
- rlEnd();
+ rlBegin(RL_TRIANGLES);
+
+ // Draw all of the 4 corners first: Upper Left Corner, Upper Right Corner, Lower Right Corner, Lower Left Corner
+ for (int k = 0; k < 4; ++k) // Hope the compiler is smart enough to unroll this loop
+ {
+ float angle = angles[k];
+ const Vector2 center = centers[k];
+
+ for (int i = 0; i < segments; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * innerRadius, center.y + sinf(DEG2RAD * angle) * innerRadius);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * innerRadius, center.y + sinf(DEG2RAD * (angle + stepLength)) * innerRadius);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * outerRadius, center.y + sinf(DEG2RAD * angle) * outerRadius);
+
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * innerRadius, center.y + sinf(DEG2RAD * (angle + stepLength)) * innerRadius);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * outerRadius, center.y + sinf(DEG2RAD * (angle + stepLength)) * outerRadius);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * outerRadius, center.y + sinf(DEG2RAD * angle) * outerRadius);
+
+ angle += stepLength;
+ }
+ }
+
+ // Upper rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(point[0].x, point[0].y);
+ rlVertex2f(point[8].x, point[8].y);
+ rlVertex2f(point[9].x, point[9].y);
+ rlVertex2f(point[1].x, point[1].y);
+ rlVertex2f(point[0].x, point[0].y);
+ rlVertex2f(point[9].x, point[9].y);
+
+ // Right rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(point[10].x, point[10].y);
+ rlVertex2f(point[11].x, point[11].y);
+ rlVertex2f(point[3].x, point[3].y);
+ rlVertex2f(point[2].x, point[2].y);
+ rlVertex2f(point[10].x, point[10].y);
+ rlVertex2f(point[3].x, point[3].y);
+
+ // Lower rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(point[13].x, point[13].y);
+ rlVertex2f(point[5].x, point[5].y);
+ rlVertex2f(point[4].x, point[4].y);
+ rlVertex2f(point[12].x, point[12].y);
+ rlVertex2f(point[13].x, point[13].y);
+ rlVertex2f(point[4].x, point[4].y);
+
+ // Left rectangle
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(point[7].x, point[7].y);
+ rlVertex2f(point[6].x, point[6].y);
+ rlVertex2f(point[14].x, point[14].y);
+ rlVertex2f(point[15].x, point[15].y);
+ rlVertex2f(point[7].x, point[7].y);
+ rlVertex2f(point[14].x, point[14].y);
+ rlEnd();
#endif
- }
- else
- {
- // Use LINES to draw the outline
- rlBegin(RL_LINES);
-
- // Draw all the 4 corners first: Upper Left Corner, Upper Right Corner, Lower Right Corner, Lower Left Corner
- for (int k = 0; k < 4; ++k) // Hope the compiler is smart enough to unroll this loop
- {
- float angle = angles[k];
- const Vector2 center = centers[k];
-
- for (int i = 0; i < segments; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(center.x + cosf(DEG2RAD*angle)*outerRadius, center.y + sinf(DEG2RAD*angle)*outerRadius);
- rlVertex2f(center.x + cosf(DEG2RAD*(angle + stepLength))*outerRadius, center.y + sinf(DEG2RAD*(angle + stepLength))*outerRadius);
- angle += stepLength;
- }
- }
-
- // And now the remaining 4 lines
- for (int i = 0; i < 8; i += 2)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(point[i].x, point[i].y);
- rlVertex2f(point[i + 1].x, point[i + 1].y);
- }
-
- rlEnd();
- }
+ } else {
+ // Use LINES to draw the outline
+ rlBegin(RL_LINES);
+
+ // Draw all the 4 corners first: Upper Left Corner, Upper Right Corner, Lower Right Corner, Lower Left Corner
+ for (int k = 0; k < 4; ++k) // Hope the compiler is smart enough to unroll this loop
+ {
+ float angle = angles[k];
+ const Vector2 center = centers[k];
+
+ for (int i = 0; i < segments; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(center.x + cosf(DEG2RAD * angle) * outerRadius, center.y + sinf(DEG2RAD * angle) * outerRadius);
+ rlVertex2f(center.x + cosf(DEG2RAD * (angle + stepLength)) * outerRadius, center.y + sinf(DEG2RAD * (angle + stepLength)) * outerRadius);
+ angle += stepLength;
+ }
+ }
+
+ // And now the remaining 4 lines
+ for (int i = 0; i < 8; i += 2) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(point[i].x, point[i].y);
+ rlVertex2f(point[i + 1].x, point[i + 1].y);
+ }
+
+ rlEnd();
+ }
}
// Draw a triangle
// NOTE: Vertex must be provided in counter-clockwise order
-void DrawTriangle(Vector2 v1, Vector2 v2, Vector2 v3, RLColor color)
-{
+void DrawTriangle(Vector2 v1, Vector2 v2, Vector2 v3, RLColor color) {
#if defined(SUPPORT_QUADS_DRAW_MODE)
- rlSetTexture(GetShapesTexture().id);
- Rectangle shapeRect = GetShapesTextureRectangle();
+ rlSetTexture(GetShapesTexture().id);
+ Rectangle shapeRect = GetShapesTextureRectangle();
- rlBegin(RL_QUADS);
- rlColor4ub(color.r, color.g, color.b, color.a);
+ rlBegin(RL_QUADS);
+ rlColor4ub(color.r, color.g, color.b, color.a);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(v1.x, v1.y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(v1.x, v1.y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(v2.x, v2.y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(v2.x, v2.y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(v2.x, v2.y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(v2.x, v2.y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(v3.x, v3.y);
- rlEnd();
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(v3.x, v3.y);
+ rlEnd();
- rlSetTexture(0);
+ rlSetTexture(0);
#else
- rlBegin(RL_TRIANGLES);
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(v1.x, v1.y);
- rlVertex2f(v2.x, v2.y);
- rlVertex2f(v3.x, v3.y);
- rlEnd();
+ rlBegin(RL_TRIANGLES);
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(v1.x, v1.y);
+ rlVertex2f(v2.x, v2.y);
+ rlVertex2f(v3.x, v3.y);
+ rlEnd();
#endif
}
// Draw a triangle using lines
// NOTE: Vertex must be provided in counter-clockwise order
-void DrawTriangleLines(Vector2 v1, Vector2 v2, Vector2 v3, RLColor color)
-{
- rlBegin(RL_LINES);
- rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(v1.x, v1.y);
- rlVertex2f(v2.x, v2.y);
+void DrawTriangleLines(Vector2 v1, Vector2 v2, Vector2 v3, RLColor color) {
+ rlBegin(RL_LINES);
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ rlVertex2f(v1.x, v1.y);
+ rlVertex2f(v2.x, v2.y);
- rlVertex2f(v2.x, v2.y);
- rlVertex2f(v3.x, v3.y);
+ rlVertex2f(v2.x, v2.y);
+ rlVertex2f(v3.x, v3.y);
- rlVertex2f(v3.x, v3.y);
- rlVertex2f(v1.x, v1.y);
- rlEnd();
+ rlVertex2f(v3.x, v3.y);
+ rlVertex2f(v1.x, v1.y);
+ rlEnd();
}
// Draw a triangle fan defined by points
// NOTE: First vertex provided is the center, shared by all triangles
// By default, following vertex should be provided in counter-clockwise order
-void DrawTriangleFan(const Vector2 *points, int pointCount, RLColor color)
-{
- if (pointCount >= 3)
- {
- rlSetTexture(GetShapesTexture().id);
- Rectangle shapeRect = GetShapesTextureRectangle();
+void DrawTriangleFan(const Vector2* points, int pointCount, RLColor color) {
+ if (pointCount >= 3) {
+ rlSetTexture(GetShapesTexture().id);
+ Rectangle shapeRect = GetShapesTextureRectangle();
- rlBegin(RL_QUADS);
- rlColor4ub(color.r, color.g, color.b, color.a);
+ rlBegin(RL_QUADS);
+ rlColor4ub(color.r, color.g, color.b, color.a);
- for (int i = 1; i < pointCount - 1; i++)
- {
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(points[0].x, points[0].y);
+ for (int i = 1; i < pointCount - 1; i++) {
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(points[0].x, points[0].y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(points[i].x, points[i].y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(points[i].x, points[i].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(points[i + 1].x, points[i + 1].y);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(points[i + 1].x, points[i + 1].y);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(points[i + 1].x, points[i + 1].y);
- }
- rlEnd();
- rlSetTexture(0);
- }
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(points[i + 1].x, points[i + 1].y);
+ }
+ rlEnd();
+ rlSetTexture(0);
+ }
}
// Draw a triangle strip defined by points
// NOTE: Every new vertex connects with previous two
-void DrawTriangleStrip(const Vector2 *points, int pointCount, RLColor color)
-{
- if (pointCount >= 3)
- {
- rlBegin(RL_TRIANGLES);
- rlColor4ub(color.r, color.g, color.b, color.a);
-
- for (int i = 2; i < pointCount; i++)
- {
- if ((i%2) == 0)
- {
- rlVertex2f(points[i].x, points[i].y);
- rlVertex2f(points[i - 2].x, points[i - 2].y);
- rlVertex2f(points[i - 1].x, points[i - 1].y);
- }
- else
- {
- rlVertex2f(points[i].x, points[i].y);
- rlVertex2f(points[i - 1].x, points[i - 1].y);
- rlVertex2f(points[i - 2].x, points[i - 2].y);
- }
- }
- rlEnd();
- }
+void DrawTriangleStrip(const Vector2* points, int pointCount, RLColor color) {
+ if (pointCount >= 3) {
+ rlBegin(RL_TRIANGLES);
+ rlColor4ub(color.r, color.g, color.b, color.a);
+
+ for (int i = 2; i < pointCount; i++) {
+ if ((i % 2) == 0) {
+ rlVertex2f(points[i].x, points[i].y);
+ rlVertex2f(points[i - 2].x, points[i - 2].y);
+ rlVertex2f(points[i - 1].x, points[i - 1].y);
+ } else {
+ rlVertex2f(points[i].x, points[i].y);
+ rlVertex2f(points[i - 1].x, points[i - 1].y);
+ rlVertex2f(points[i - 2].x, points[i - 2].y);
+ }
+ }
+ rlEnd();
+ }
}
// Draw a regular polygon of n sides (Vector version)
-void DrawPoly(Vector2 center, int sides, float radius, float rotation, RLColor color)
-{
- if (sides < 3) sides = 3;
- float centralAngle = rotation*DEG2RAD;
- float angleStep = 360.0f/(float)sides*DEG2RAD;
+void DrawPoly(Vector2 center, int sides, float radius, float rotation, RLColor color) {
+ if (sides < 3)
+ sides = 3;
+ float centralAngle = rotation * DEG2RAD;
+ float angleStep = 360.0f / (float)sides * DEG2RAD;
#if defined(SUPPORT_QUADS_DRAW_MODE)
- rlSetTexture(GetShapesTexture().id);
- Rectangle shapeRect = GetShapesTextureRectangle();
+ rlSetTexture(GetShapesTexture().id);
+ Rectangle shapeRect = GetShapesTextureRectangle();
- rlBegin(RL_QUADS);
- for (int i = 0; i < sides; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- float nextAngle = centralAngle + angleStep;
+ rlBegin(RL_QUADS);
+ for (int i = 0; i < sides; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ float nextAngle = centralAngle + angleStep;
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x, center.y);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x, center.y);
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(centralAngle)*radius, center.y + sinf(centralAngle)*radius);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(centralAngle) * radius, center.y + sinf(centralAngle) * radius);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x + cosf(nextAngle)*radius, center.y + sinf(nextAngle)*radius);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x + cosf(nextAngle) * radius, center.y + sinf(nextAngle) * radius);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(centralAngle)*radius, center.y + sinf(centralAngle)*radius);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(centralAngle) * radius, center.y + sinf(centralAngle) * radius);
- centralAngle = nextAngle;
- }
- rlEnd();
- rlSetTexture(0);
+ centralAngle = nextAngle;
+ }
+ rlEnd();
+ rlSetTexture(0);
#else
- rlBegin(RL_TRIANGLES);
- for (int i = 0; i < sides; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
-
- rlVertex2f(center.x, center.y);
- rlVertex2f(center.x + cosf(centralAngle + angleStep)*radius, center.y + sinf(centralAngle + angleStep)*radius);
- rlVertex2f(center.x + cosf(centralAngle)*radius, center.y + sinf(centralAngle)*radius);
-
- centralAngle += angleStep;
- }
- rlEnd();
+ rlBegin(RL_TRIANGLES);
+ for (int i = 0; i < sides; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+
+ rlVertex2f(center.x, center.y);
+ rlVertex2f(center.x + cosf(centralAngle + angleStep) * radius, center.y + sinf(centralAngle + angleStep) * radius);
+ rlVertex2f(center.x + cosf(centralAngle) * radius, center.y + sinf(centralAngle) * radius);
+
+ centralAngle += angleStep;
+ }
+ rlEnd();
#endif
}
// Draw a polygon outline of n sides
-void DrawPolyLines(Vector2 center, int sides, float radius, float rotation, RLColor color)
-{
- if (sides < 3) sides = 3;
- float centralAngle = rotation*DEG2RAD;
- float angleStep = 360.0f/(float)sides*DEG2RAD;
+void DrawPolyLines(Vector2 center, int sides, float radius, float rotation, RLColor color) {
+ if (sides < 3)
+ sides = 3;
+ float centralAngle = rotation * DEG2RAD;
+ float angleStep = 360.0f / (float)sides * DEG2RAD;
- rlBegin(RL_LINES);
- for (int i = 0; i < sides; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
+ rlBegin(RL_LINES);
+ for (int i = 0; i < sides; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
- rlVertex2f(center.x + cosf(centralAngle)*radius, center.y + sinf(centralAngle)*radius);
- rlVertex2f(center.x + cosf(centralAngle + angleStep)*radius, center.y + sinf(centralAngle + angleStep)*radius);
+ rlVertex2f(center.x + cosf(centralAngle) * radius, center.y + sinf(centralAngle) * radius);
+ rlVertex2f(center.x + cosf(centralAngle + angleStep) * radius, center.y + sinf(centralAngle + angleStep) * radius);
- centralAngle += angleStep;
- }
- rlEnd();
+ centralAngle += angleStep;
+ }
+ rlEnd();
}
-void DrawPolyLinesEx(Vector2 center, int sides, float radius, float rotation, float lineThick, RLColor color)
-{
- if (sides < 3) sides = 3;
- float centralAngle = rotation*DEG2RAD;
- float exteriorAngle = 360.0f/(float)sides*DEG2RAD;
- float innerRadius = radius - (lineThick*cosf(DEG2RAD*exteriorAngle/2.0f));
+void DrawPolyLinesEx(Vector2 center, int sides, float radius, float rotation, float lineThick, RLColor color) {
+ if (sides < 3)
+ sides = 3;
+ float centralAngle = rotation * DEG2RAD;
+ float exteriorAngle = 360.0f / (float)sides * DEG2RAD;
+ float innerRadius = radius - (lineThick * cosf(DEG2RAD * exteriorAngle / 2.0f));
#if defined(SUPPORT_QUADS_DRAW_MODE)
- rlSetTexture(GetShapesTexture().id);
- Rectangle shapeRect = GetShapesTextureRectangle();
+ rlSetTexture(GetShapesTexture().id);
+ Rectangle shapeRect = GetShapesTextureRectangle();
- rlBegin(RL_QUADS);
- for (int i = 0; i < sides; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- float nextAngle = centralAngle + exteriorAngle;
+ rlBegin(RL_QUADS);
+ for (int i = 0; i < sides; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ float nextAngle = centralAngle + exteriorAngle;
- rlTexCoord2f(shapeRect.x/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(centralAngle)*radius, center.y + sinf(centralAngle)*radius);
+ rlTexCoord2f(shapeRect.x / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(centralAngle) * radius, center.y + sinf(centralAngle) * radius);
- rlTexCoord2f(shapeRect.x/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x + cosf(centralAngle)*innerRadius, center.y + sinf(centralAngle)*innerRadius);
+ rlTexCoord2f(shapeRect.x / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x + cosf(centralAngle) * innerRadius, center.y + sinf(centralAngle) * innerRadius);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, (shapeRect.y + shapeRect.height)/texShapes.height);
- rlVertex2f(center.x + cosf(nextAngle)*innerRadius, center.y + sinf(nextAngle)*innerRadius);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, (shapeRect.y + shapeRect.height) / texShapes.height);
+ rlVertex2f(center.x + cosf(nextAngle) * innerRadius, center.y + sinf(nextAngle) * innerRadius);
- rlTexCoord2f((shapeRect.x + shapeRect.width)/texShapes.width, shapeRect.y/texShapes.height);
- rlVertex2f(center.x + cosf(nextAngle)*radius, center.y + sinf(nextAngle)*radius);
+ rlTexCoord2f((shapeRect.x + shapeRect.width) / texShapes.width, shapeRect.y / texShapes.height);
+ rlVertex2f(center.x + cosf(nextAngle) * radius, center.y + sinf(nextAngle) * radius);
- centralAngle = nextAngle;
- }
- rlEnd();
- rlSetTexture(0);
+ centralAngle = nextAngle;
+ }
+ rlEnd();
+ rlSetTexture(0);
#else
- rlBegin(RL_TRIANGLES);
- for (int i = 0; i < sides; i++)
- {
- rlColor4ub(color.r, color.g, color.b, color.a);
- float nextAngle = centralAngle + exteriorAngle;
-
- rlVertex2f(center.x + cosf(nextAngle)*radius, center.y + sinf(nextAngle)*radius);
- rlVertex2f(center.x + cosf(centralAngle)*radius, center.y + sinf(centralAngle)*radius);
- rlVertex2f(center.x + cosf(centralAngle)*innerRadius, center.y + sinf(centralAngle)*innerRadius);
-
- rlVertex2f(center.x + cosf(centralAngle)*innerRadius, center.y + sinf(centralAngle)*innerRadius);
- rlVertex2f(center.x + cosf(nextAngle)*innerRadius, center.y + sinf(nextAngle)*innerRadius);
- rlVertex2f(center.x + cosf(nextAngle)*radius, center.y + sinf(nextAngle)*radius);
-
- centralAngle = nextAngle;
- }
- rlEnd();
+ rlBegin(RL_TRIANGLES);
+ for (int i = 0; i < sides; i++) {
+ rlColor4ub(color.r, color.g, color.b, color.a);
+ float nextAngle = centralAngle + exteriorAngle;
+
+ rlVertex2f(center.x + cosf(nextAngle) * radius, center.y + sinf(nextAngle) * radius);
+ rlVertex2f(center.x + cosf(centralAngle) * radius, center.y + sinf(centralAngle) * radius);
+ rlVertex2f(center.x + cosf(centralAngle) * innerRadius, center.y + sinf(centralAngle) * innerRadius);
+
+ rlVertex2f(center.x + cosf(centralAngle) * innerRadius, center.y + sinf(centralAngle) * innerRadius);
+ rlVertex2f(center.x + cosf(nextAngle) * innerRadius, center.y + sinf(nextAngle) * innerRadius);
+ rlVertex2f(center.x + cosf(nextAngle) * radius, center.y + sinf(nextAngle) * radius);
+
+ centralAngle = nextAngle;
+ }
+ rlEnd();
#endif
}
@@ -1590,589 +1523,542 @@ void DrawPolyLinesEx(Vector2 center, int sides, float radius, float rotation, fl
//----------------------------------------------------------------------------------
// Draw spline: linear, minimum 2 points
-void DrawSplineLinear(const Vector2 *points, int pointCount, float thick, RLColor color)
-{
- if (pointCount < 2) return;
+void DrawSplineLinear(const Vector2* points, int pointCount, float thick, RLColor color) {
+ if (pointCount < 2)
+ return;
#if defined(SUPPORT_SPLINE_MITERS)
- Vector2 prevNormal = (Vector2){-(points[1].y - points[0].y), (points[1].x - points[0].x)};
- float prevLength = sqrtf(prevNormal.x*prevNormal.x + prevNormal.y*prevNormal.y);
-
- if (prevLength > 0.0f)
- {
- prevNormal.x /= prevLength;
- prevNormal.y /= prevLength;
- }
- else
- {
- prevNormal.x = 0.0f;
- prevNormal.y = 0.0f;
- }
-
- Vector2 prevRadius = { 0.5f*thick*prevNormal.x, 0.5f*thick*prevNormal.y };
-
- for (int i = 0; i < pointCount - 1; i++)
- {
- Vector2 normal = { 0 };
-
- if (i < pointCount - 2)
- {
- normal = (Vector2){-(points[i + 2].y - points[i + 1].y), (points[i + 2].x - points[i + 1].x)};
- float normalLength = sqrtf(normal.x*normal.x + normal.y*normal.y);
-
- if (normalLength > 0.0f)
- {
- normal.x /= normalLength;
- normal.y /= normalLength;
- }
- else
- {
- normal.x = 0.0f;
- normal.y = 0.0f;
- }
- }
- else
- {
- normal = prevNormal;
- }
-
- Vector2 radius = { prevNormal.x + normal.x, prevNormal.y + normal.y };
- float radiusLength = sqrtf(radius.x*radius.x + radius.y*radius.y);
-
- if (radiusLength > 0.0f)
- {
- radius.x /= radiusLength;
- radius.y /= radiusLength;
- }
- else
- {
- radius.x = 0.0f;
- radius.y = 0.0f;
- }
-
- float cosTheta = radius.x*normal.x + radius.y*normal.y;
-
- if (cosTheta != 0.0f)
- {
- radius.x *= (thick*0.5f/cosTheta);
- radius.y *= (thick*0.5f/cosTheta);
- }
- else
- {
- radius.x = 0.0f;
- radius.y = 0.0f;
- }
-
- Vector2 strip[4] = {
- { points[i].x - prevRadius.x, points[i].y - prevRadius.y },
- { points[i].x + prevRadius.x, points[i].y + prevRadius.y },
- { points[i + 1].x - radius.x, points[i + 1].y - radius.y },
- { points[i + 1].x + radius.x, points[i + 1].y + radius.y }
- };
-
- DrawTriangleStrip(strip, 4, color);
-
- prevRadius = radius;
- prevNormal = normal;
- }
-
-#else // !SUPPORT_SPLINE_MITERS
-
- Vector2 delta = { 0 };
- float length = 0.0f;
- float scale = 0.0f;
-
- for (int i = 0; i < pointCount - 1; i++)
- {
- delta = (Vector2){ points[i + 1].x - points[i].x, points[i + 1].y - points[i].y };
- length = sqrtf(delta.x*delta.x + delta.y*delta.y);
-
- if (length > 0) scale = thick/(2*length);
-
- Vector2 radius = { -scale*delta.y, scale*delta.x };
- Vector2 strip[4] = {
- { points[i].x - radius.x, points[i].y - radius.y },
- { points[i].x + radius.x, points[i].y + radius.y },
- { points[i + 1].x - radius.x, points[i + 1].y - radius.y },
- { points[i + 1].x + radius.x, points[i + 1].y + radius.y }
- };
-
- DrawTriangleStrip(strip, 4, color);
- }
+ Vector2 prevNormal = (Vector2){-(points[1].y - points[0].y), (points[1].x - points[0].x)};
+ float prevLength = sqrtf(prevNormal.x * prevNormal.x + prevNormal.y * prevNormal.y);
+
+ if (prevLength > 0.0f) {
+ prevNormal.x /= prevLength;
+ prevNormal.y /= prevLength;
+ } else {
+ prevNormal.x = 0.0f;
+ prevNormal.y = 0.0f;
+ }
+
+ Vector2 prevRadius = {0.5f * thick * prevNormal.x, 0.5f * thick * prevNormal.y};
+
+ for (int i = 0; i < pointCount - 1; i++) {
+ Vector2 normal = {0};
+
+ if (i < pointCount - 2) {
+ normal = (Vector2){-(points[i + 2].y - points[i + 1].y), (points[i + 2].x - points[i + 1].x)};
+ float normalLength = sqrtf(normal.x * normal.x + normal.y * normal.y);
+
+ if (normalLength > 0.0f) {
+ normal.x /= normalLength;
+ normal.y /= normalLength;
+ } else {
+ normal.x = 0.0f;
+ normal.y = 0.0f;
+ }
+ } else {
+ normal = prevNormal;
+ }
+
+ Vector2 radius = {prevNormal.x + normal.x, prevNormal.y + normal.y};
+ float radiusLength = sqrtf(radius.x * radius.x + radius.y * radius.y);
+
+ if (radiusLength > 0.0f) {
+ radius.x /= radiusLength;
+ radius.y /= radiusLength;
+ } else {
+ radius.x = 0.0f;
+ radius.y = 0.0f;
+ }
+
+ float cosTheta = radius.x * normal.x + radius.y * normal.y;
+
+ if (cosTheta != 0.0f) {
+ radius.x *= (thick * 0.5f / cosTheta);
+ radius.y *= (thick * 0.5f / cosTheta);
+ } else {
+ radius.x = 0.0f;
+ radius.y = 0.0f;
+ }
+
+ Vector2 strip[4] = {
+ {points[i].x - prevRadius.x, points[i].y - prevRadius.y},
+ {points[i].x + prevRadius.x, points[i].y + prevRadius.y},
+ {points[i + 1].x - radius.x, points[i + 1].y - radius.y},
+ {points[i + 1].x + radius.x, points[i + 1].y + radius.y}};
+
+ DrawTriangleStrip(strip, 4, color);
+
+ prevRadius = radius;
+ prevNormal = normal;
+ }
+
+#else // !SUPPORT_SPLINE_MITERS
+
+ Vector2 delta = {0};
+ float length = 0.0f;
+ float scale = 0.0f;
+
+ for (int i = 0; i < pointCount - 1; i++) {
+ delta = (Vector2){points[i + 1].x - points[i].x, points[i + 1].y - points[i].y};
+ length = sqrtf(delta.x * delta.x + delta.y * delta.y);
+
+ if (length > 0)
+ scale = thick / (2 * length);
+
+ Vector2 radius = {-scale * delta.y, scale * delta.x};
+ Vector2 strip[4] = {
+ {points[i].x - radius.x, points[i].y - radius.y},
+ {points[i].x + radius.x, points[i].y + radius.y},
+ {points[i + 1].x - radius.x, points[i + 1].y - radius.y},
+ {points[i + 1].x + radius.x, points[i + 1].y + radius.y}};
+
+ DrawTriangleStrip(strip, 4, color);
+ }
#endif
#if defined(SUPPORT_SPLINE_SEGMENT_CAPS)
- // TODO: Add spline segment rounded caps at the begin/end of the spline
+ // TODO: Add spline segment rounded caps at the begin/end of the spline
#endif
}
// Draw spline: B-Spline, minimum 4 points
-void DrawSplineBasis(const Vector2 *points, int pointCount, float thick, RLColor color)
-{
- if (pointCount < 4) return;
-
- float a[4] = { 0 };
- float b[4] = { 0 };
- float dy = 0.0f;
- float dx = 0.0f;
- float size = 0.0f;
-
- Vector2 currentPoint = { 0 };
- Vector2 nextPoint = { 0 };
- Vector2 vertices[2*SPLINE_SEGMENT_DIVISIONS + 2] = { 0 };
-
- for (int i = 0; i < (pointCount - 3); i++)
- {
- float t = 0.0f;
- Vector2 p1 = points[i], p2 = points[i + 1], p3 = points[i + 2], p4 = points[i + 3];
-
- a[0] = (-p1.x + 3.0f*p2.x - 3.0f*p3.x + p4.x)/6.0f;
- a[1] = (3.0f*p1.x - 6.0f*p2.x + 3.0f*p3.x)/6.0f;
- a[2] = (-3.0f*p1.x + 3.0f*p3.x)/6.0f;
- a[3] = (p1.x + 4.0f*p2.x + p3.x)/6.0f;
-
- b[0] = (-p1.y + 3.0f*p2.y - 3.0f*p3.y + p4.y)/6.0f;
- b[1] = (3.0f*p1.y - 6.0f*p2.y + 3.0f*p3.y)/6.0f;
- b[2] = (-3.0f*p1.y + 3.0f*p3.y)/6.0f;
- b[3] = (p1.y + 4.0f*p2.y + p3.y)/6.0f;
-
- currentPoint.x = a[3];
- currentPoint.y = b[3];
-
- if (i == 0) DrawCircleV(currentPoint, thick/2.0f, color); // Draw init line circle-cap
-
- if (i > 0)
- {
- vertices[0].x = currentPoint.x + dy*size;
- vertices[0].y = currentPoint.y - dx*size;
- vertices[1].x = currentPoint.x - dy*size;
- vertices[1].y = currentPoint.y + dx*size;
- }
-
- for (int j = 1; j <= SPLINE_SEGMENT_DIVISIONS; j++)
- {
- t = ((float)j)/((float)SPLINE_SEGMENT_DIVISIONS);
-
- nextPoint.x = a[3] + t*(a[2] + t*(a[1] + t*a[0]));
- nextPoint.y = b[3] + t*(b[2] + t*(b[1] + t*b[0]));
-
- dy = nextPoint.y - currentPoint.y;
- dx = nextPoint.x - currentPoint.x;
- size = 0.5f*thick/sqrtf(dx*dx+dy*dy);
-
- if ((i == 0) && (j == 1))
- {
- vertices[0].x = currentPoint.x + dy*size;
- vertices[0].y = currentPoint.y - dx*size;
- vertices[1].x = currentPoint.x - dy*size;
- vertices[1].y = currentPoint.y + dx*size;
- }
-
- vertices[2*j + 1].x = nextPoint.x - dy*size;
- vertices[2*j + 1].y = nextPoint.y + dx*size;
- vertices[2*j].x = nextPoint.x + dy*size;
- vertices[2*j].y = nextPoint.y - dx*size;
-
- currentPoint = nextPoint;
- }
-
- DrawTriangleStrip(vertices, 2*SPLINE_SEGMENT_DIVISIONS + 2, color);
- }
-
- // Cap circle drawing at the end of every segment
- DrawCircleV(currentPoint, thick/2.0f, color);
+void DrawSplineBasis(const Vector2* points, int pointCount, float thick, RLColor color) {
+ if (pointCount < 4)
+ return;
+
+ float a[4] = {0};
+ float b[4] = {0};
+ float dy = 0.0f;
+ float dx = 0.0f;
+ float size = 0.0f;
+
+ Vector2 currentPoint = {0};
+ Vector2 nextPoint = {0};
+ Vector2 vertices[2 * SPLINE_SEGMENT_DIVISIONS + 2] = {0};
+
+ for (int i = 0; i < (pointCount - 3); i++) {
+ float t = 0.0f;
+ Vector2 p1 = points[i], p2 = points[i + 1], p3 = points[i + 2], p4 = points[i + 3];
+
+ a[0] = (-p1.x + 3.0f * p2.x - 3.0f * p3.x + p4.x) / 6.0f;
+ a[1] = (3.0f * p1.x - 6.0f * p2.x + 3.0f * p3.x) / 6.0f;
+ a[2] = (-3.0f * p1.x + 3.0f * p3.x) / 6.0f;
+ a[3] = (p1.x + 4.0f * p2.x + p3.x) / 6.0f;
+
+ b[0] = (-p1.y + 3.0f * p2.y - 3.0f * p3.y + p4.y) / 6.0f;
+ b[1] = (3.0f * p1.y - 6.0f * p2.y + 3.0f * p3.y) / 6.0f;
+ b[2] = (-3.0f * p1.y + 3.0f * p3.y) / 6.0f;
+ b[3] = (p1.y + 4.0f * p2.y + p3.y) / 6.0f;
+
+ currentPoint.x = a[3];
+ currentPoint.y = b[3];
+
+ if (i == 0)
+ DrawCircleV(currentPoint, thick / 2.0f, color); // Draw init line circle-cap
+
+ if (i > 0) {
+ vertices[0].x = currentPoint.x + dy * size;
+ vertices[0].y = currentPoint.y - dx * size;
+ vertices[1].x = currentPoint.x - dy * size;
+ vertices[1].y = currentPoint.y + dx * size;
+ }
+
+ for (int j = 1; j <= SPLINE_SEGMENT_DIVISIONS; j++) {
+ t = ((float)j) / ((float)SPLINE_SEGMENT_DIVISIONS);
+
+ nextPoint.x = a[3] + t * (a[2] + t * (a[1] + t * a[0]));
+ nextPoint.y = b[3] + t * (b[2] + t * (b[1] + t * b[0]));
+
+ dy = nextPoint.y - currentPoint.y;
+ dx = nextPoint.x - currentPoint.x;
+ size = 0.5f * thick / sqrtf(dx * dx + dy * dy);
+
+ if ((i == 0) && (j == 1)) {
+ vertices[0].x = currentPoint.x + dy * size;
+ vertices[0].y = currentPoint.y - dx * size;
+ vertices[1].x = currentPoint.x - dy * size;
+ vertices[1].y = currentPoint.y + dx * size;
+ }
+
+ vertices[2 * j + 1].x = nextPoint.x - dy * size;
+ vertices[2 * j + 1].y = nextPoint.y + dx * size;
+ vertices[2 * j].x = nextPoint.x + dy * size;
+ vertices[2 * j].y = nextPoint.y - dx * size;
+
+ currentPoint = nextPoint;
+ }
+
+ DrawTriangleStrip(vertices, 2 * SPLINE_SEGMENT_DIVISIONS + 2, color);
+ }
+
+ // Cap circle drawing at the end of every segment
+ DrawCircleV(currentPoint, thick / 2.0f, color);
}
// Draw spline: Catmull-Rom, minimum 4 points
-void DrawSplineCatmullRom(const Vector2 *points, int pointCount, float thick, RLColor color)
-{
- if (pointCount < 4) return;
+void DrawSplineCatmullRom(const Vector2* points, int pointCount, float thick, RLColor color) {
+ if (pointCount < 4)
+ return;
- float dy = 0.0f;
- float dx = 0.0f;
- float size = 0.0f;
+ float dy = 0.0f;
+ float dx = 0.0f;
+ float size = 0.0f;
- Vector2 currentPoint = points[1];
- Vector2 nextPoint = { 0 };
- Vector2 vertices[2*SPLINE_SEGMENT_DIVISIONS + 2] = { 0 };
+ Vector2 currentPoint = points[1];
+ Vector2 nextPoint = {0};
+ Vector2 vertices[2 * SPLINE_SEGMENT_DIVISIONS + 2] = {0};
- DrawCircleV(currentPoint, thick/2.0f, color); // Draw init line circle-cap
+ DrawCircleV(currentPoint, thick / 2.0f, color); // Draw init line circle-cap
- for (int i = 0; i < (pointCount - 3); i++)
- {
- float t = 0.0f;
- Vector2 p1 = points[i], p2 = points[i + 1], p3 = points[i + 2], p4 = points[i + 3];
+ for (int i = 0; i < (pointCount - 3); i++) {
+ float t = 0.0f;
+ Vector2 p1 = points[i], p2 = points[i + 1], p3 = points[i + 2], p4 = points[i + 3];
- if (i > 0)
- {
- vertices[0].x = currentPoint.x + dy*size;
- vertices[0].y = currentPoint.y - dx*size;
- vertices[1].x = currentPoint.x - dy*size;
- vertices[1].y = currentPoint.y + dx*size;
- }
+ if (i > 0) {
+ vertices[0].x = currentPoint.x + dy * size;
+ vertices[0].y = currentPoint.y - dx * size;
+ vertices[1].x = currentPoint.x - dy * size;
+ vertices[1].y = currentPoint.y + dx * size;
+ }
- for (int j = 1; j <= SPLINE_SEGMENT_DIVISIONS; j++)
- {
- t = ((float)j)/((float)SPLINE_SEGMENT_DIVISIONS);
+ for (int j = 1; j <= SPLINE_SEGMENT_DIVISIONS; j++) {
+ t = ((float)j) / ((float)SPLINE_SEGMENT_DIVISIONS);
- float q0 = (-1.0f*t*t*t) + (2.0f*t*t) + (-1.0f*t);
- float q1 = (3.0f*t*t*t) + (-5.0f*t*t) + 2.0f;
- float q2 = (-3.0f*t*t*t) + (4.0f*t*t) + t;
- float q3 = t*t*t - t*t;
+ float q0 = (-1.0f * t * t * t) + (2.0f * t * t) + (-1.0f * t);
+ float q1 = (3.0f * t * t * t) + (-5.0f * t * t) + 2.0f;
+ float q2 = (-3.0f * t * t * t) + (4.0f * t * t) + t;
+ float q3 = t * t * t - t * t;
- nextPoint.x = 0.5f*((p1.x*q0) + (p2.x*q1) + (p3.x*q2) + (p4.x*q3));
- nextPoint.y = 0.5f*((p1.y*q0) + (p2.y*q1) + (p3.y*q2) + (p4.y*q3));
+ nextPoint.x = 0.5f * ((p1.x * q0) + (p2.x * q1) + (p3.x * q2) + (p4.x * q3));
+ nextPoint.y = 0.5f * ((p1.y * q0) + (p2.y * q1) + (p3.y * q2) + (p4.y * q3));
- dy = nextPoint.y - currentPoint.y;
- dx = nextPoint.x - currentPoint.x;
- size = (0.5f*thick)/sqrtf(dx*dx + dy*dy);
+ dy = nextPoint.y - currentPoint.y;
+ dx = nextPoint.x - currentPoint.x;
+ size = (0.5f * thick) / sqrtf(dx * dx + dy * dy);
- if ((i == 0) && (j == 1))
- {
- vertices[0].x = currentPoint.x + dy*size;
- vertices[0].y = currentPoint.y - dx*size;
- vertices[1].x = currentPoint.x - dy*size;
- vertices[1].y = currentPoint.y + dx*size;
- }
+ if ((i == 0) && (j == 1)) {
+ vertices[0].x = currentPoint.x + dy * size;
+ vertices[0].y = currentPoint.y - dx * size;
+ vertices[1].x = currentPoint.x - dy * size;
+ vertices[1].y = currentPoint.y + dx * size;
+ }
- vertices[2*j + 1].x = nextPoint.x - dy*size;
- vertices[2*j + 1].y = nextPoint.y + dx*size;
- vertices[2*j].x = nextPoint.x + dy*size;
- vertices[2*j].y = nextPoint.y - dx*size;
+ vertices[2 * j + 1].x = nextPoint.x - dy * size;
+ vertices[2 * j + 1].y = nextPoint.y + dx * size;
+ vertices[2 * j].x = nextPoint.x + dy * size;
+ vertices[2 * j].y = nextPoint.y - dx * size;
- currentPoint = nextPoint;
- }
+ currentPoint = nextPoint;
+ }
- DrawTriangleStrip(vertices, 2*SPLINE_SEGMENT_DIVISIONS + 2, color);
- }
+ DrawTriangleStrip(vertices, 2 * SPLINE_SEGMENT_DIVISIONS + 2, color);
+ }
- // Cap circle drawing at the end of every segment
- DrawCircleV(currentPoint, thick/2.0f, color);
+ // Cap circle drawing at the end of every segment
+ DrawCircleV(currentPoint, thick / 2.0f, color);
}
// Draw spline: Quadratic Bezier, minimum 3 points (1 control point): [p1, c2, p3, c4...]
-void DrawSplineBezierQuadratic(const Vector2 *points, int pointCount, float thick, RLColor color)
-{
- if (pointCount >= 3)
- {
- for (int i = 0; i < pointCount - 2; i += 2) DrawSplineSegmentBezierQuadratic(points[i], points[i + 1], points[i + 2], thick, color);
+void DrawSplineBezierQuadratic(const Vector2* points, int pointCount, float thick, RLColor color) {
+ if (pointCount >= 3) {
+ for (int i = 0; i < pointCount - 2; i += 2)
+ DrawSplineSegmentBezierQuadratic(points[i], points[i + 1], points[i + 2], thick, color);
- // Cap circle drawing at the end of every segment
- //for (int i = 2; i < pointCount - 2; i += 2) DrawCircleV(points[i], thick/2.0f, color);
- }
+ // Cap circle drawing at the end of every segment
+ // for (int i = 2; i < pointCount - 2; i += 2) DrawCircleV(points[i], thick/2.0f, color);
+ }
}
// Draw spline: Cubic Bezier, minimum 4 points (2 control points): [p1, c2, c3, p4, c5, c6...]
-void DrawSplineBezierCubic(const Vector2 *points, int pointCount, float thick, RLColor color)
-{
- if (pointCount >= 4)
- {
- for (int i = 0; i < pointCount - 3; i += 3) DrawSplineSegmentBezierCubic(points[i], points[i + 1], points[i + 2], points[i + 3], thick, color);
+void DrawSplineBezierCubic(const Vector2* points, int pointCount, float thick, RLColor color) {
+ if (pointCount >= 4) {
+ for (int i = 0; i < pointCount - 3; i += 3)
+ DrawSplineSegmentBezierCubic(points[i], points[i + 1], points[i + 2], points[i + 3], thick, color);
- // Cap circle drawing at the end of every segment
- //for (int i = 3; i < pointCount - 3; i += 3) DrawCircleV(points[i], thick/2.0f, color);
- }
+ // Cap circle drawing at the end of every segment
+ // for (int i = 3; i < pointCount - 3; i += 3) DrawCircleV(points[i], thick/2.0f, color);
+ }
}
// Draw spline segment: Linear, 2 points
-void DrawSplineSegmentLinear(Vector2 p1, Vector2 p2, float thick, RLColor color)
-{
- // NOTE: For the linear spline we don't use subdivisions, just a single quad
+void DrawSplineSegmentLinear(Vector2 p1, Vector2 p2, float thick, RLColor color) {
+ // NOTE: For the linear spline we don't use subdivisions, just a single quad
- Vector2 delta = { p2.x - p1.x, p2.y - p1.y };
- float length = sqrtf(delta.x*delta.x + delta.y*delta.y);
+ Vector2 delta = {p2.x - p1.x, p2.y - p1.y};
+ float length = sqrtf(delta.x * delta.x + delta.y * delta.y);
- if ((length > 0) && (thick > 0))
- {
- float scale = thick/(2*length);
+ if ((length > 0) && (thick > 0)) {
+ float scale = thick / (2 * length);
- Vector2 radius = { -scale*delta.y, scale*delta.x };
- Vector2 strip[4] = {
- { p1.x - radius.x, p1.y - radius.y },
- { p1.x + radius.x, p1.y + radius.y },
- { p2.x - radius.x, p2.y - radius.y },
- { p2.x + radius.x, p2.y + radius.y }
- };
+ Vector2 radius = {-scale * delta.y, scale * delta.x};
+ Vector2 strip[4] = {
+ {p1.x - radius.x, p1.y - radius.y},
+ {p1.x + radius.x, p1.y + radius.y},
+ {p2.x - radius.x, p2.y - radius.y},
+ {p2.x + radius.x, p2.y + radius.y}};
- DrawTriangleStrip(strip, 4, color);
- }
+ DrawTriangleStrip(strip, 4, color);
+ }
}
// Draw spline segment: B-Spline, 4 points
-void DrawSplineSegmentBasis(Vector2 p1, Vector2 p2, Vector2 p3, Vector2 p4, float thick, RLColor color)
-{
- const float step = 1.0f/SPLINE_SEGMENT_DIVISIONS;
+void DrawSplineSegmentBasis(Vector2 p1, Vector2 p2, Vector2 p3, Vector2 p4, float thick, RLColor color) {
+ const float step = 1.0f / SPLINE_SEGMENT_DIVISIONS;
- Vector2 currentPoint = { 0 };
- Vector2 nextPoint = { 0 };
- float t = 0.0f;
+ Vector2 currentPoint = {0};
+ Vector2 nextPoint = {0};
+ float t = 0.0f;
- Vector2 points[2*SPLINE_SEGMENT_DIVISIONS + 2] = { 0 };
+ Vector2 points[2 * SPLINE_SEGMENT_DIVISIONS + 2] = {0};
- float a[4] = { 0 };
- float b[4] = { 0 };
+ float a[4] = {0};
+ float b[4] = {0};
- a[0] = (-p1.x + 3*p2.x - 3*p3.x + p4.x)/6.0f;
- a[1] = (3*p1.x - 6*p2.x + 3*p3.x)/6.0f;
- a[2] = (-3*p1.x + 3*p3.x)/6.0f;
- a[3] = (p1.x + 4*p2.x + p3.x)/6.0f;
+ a[0] = (-p1.x + 3 * p2.x - 3 * p3.x + p4.x) / 6.0f;
+ a[1] = (3 * p1.x - 6 * p2.x + 3 * p3.x) / 6.0f;
+ a[2] = (-3 * p1.x + 3 * p3.x) / 6.0f;
+ a[3] = (p1.x + 4 * p2.x + p3.x) / 6.0f;
- b[0] = (-p1.y + 3*p2.y - 3*p3.y + p4.y)/6.0f;
- b[1] = (3*p1.y - 6*p2.y + 3*p3.y)/6.0f;
- b[2] = (-3*p1.y + 3*p3.y)/6.0f;
- b[3] = (p1.y + 4*p2.y + p3.y)/6.0f;
+ b[0] = (-p1.y + 3 * p2.y - 3 * p3.y + p4.y) / 6.0f;
+ b[1] = (3 * p1.y - 6 * p2.y + 3 * p3.y) / 6.0f;
+ b[2] = (-3 * p1.y + 3 * p3.y) / 6.0f;
+ b[3] = (p1.y + 4 * p2.y + p3.y) / 6.0f;
- currentPoint.x = a[3];
- currentPoint.y = b[3];
+ currentPoint.x = a[3];
+ currentPoint.y = b[3];
- for (int i = 0; i <= SPLINE_SEGMENT_DIVISIONS; i++)
- {
- t = step*(float)i;
+ for (int i = 0; i <= SPLINE_SEGMENT_DIVISIONS; i++) {
+ t = step * (float)i;
- nextPoint.x = a[3] + t*(a[2] + t*(a[1] + t*a[0]));
- nextPoint.y = b[3] + t*(b[2] + t*(b[1] + t*b[0]));
+ nextPoint.x = a[3] + t * (a[2] + t * (a[1] + t * a[0]));
+ nextPoint.y = b[3] + t * (b[2] + t * (b[1] + t * b[0]));
- float dy = nextPoint.y - currentPoint.y;
- float dx = nextPoint.x - currentPoint.x;
- float size = (0.5f*thick)/sqrtf(dx*dx + dy*dy);
+ float dy = nextPoint.y - currentPoint.y;
+ float dx = nextPoint.x - currentPoint.x;
+ float size = (0.5f * thick) / sqrtf(dx * dx + dy * dy);
- if (i == 1)
- {
- points[0].x = currentPoint.x + dy*size;
- points[0].y = currentPoint.y - dx*size;
- points[1].x = currentPoint.x - dy*size;
- points[1].y = currentPoint.y + dx*size;
- }
+ if (i == 1) {
+ points[0].x = currentPoint.x + dy * size;
+ points[0].y = currentPoint.y - dx * size;
+ points[1].x = currentPoint.x - dy * size;
+ points[1].y = currentPoint.y + dx * size;
+ }
- points[2*i + 1].x = nextPoint.x - dy*size;
- points[2*i + 1].y = nextPoint.y + dx*size;
- points[2*i].x = nextPoint.x + dy*size;
- points[2*i].y = nextPoint.y - dx*size;
+ points[2 * i + 1].x = nextPoint.x - dy * size;
+ points[2 * i + 1].y = nextPoint.y + dx * size;
+ points[2 * i].x = nextPoint.x + dy * size;
+ points[2 * i].y = nextPoint.y - dx * size;
- currentPoint = nextPoint;
- }
+ currentPoint = nextPoint;
+ }
- DrawTriangleStrip(points, 2*SPLINE_SEGMENT_DIVISIONS+2, color);
+ DrawTriangleStrip(points, 2 * SPLINE_SEGMENT_DIVISIONS + 2, color);
}
// Draw spline segment: Catmull-Rom, 4 points
-void DrawSplineSegmentCatmullRom(Vector2 p1, Vector2 p2, Vector2 p3, Vector2 p4, float thick, RLColor color)
-{
- const float step = 1.0f/SPLINE_SEGMENT_DIVISIONS;
+void DrawSplineSegmentCatmullRom(Vector2 p1, Vector2 p2, Vector2 p3, Vector2 p4, float thick, RLColor color) {
+ const float step = 1.0f / SPLINE_SEGMENT_DIVISIONS;
- Vector2 currentPoint = p1;
- Vector2 nextPoint = { 0 };
- float t = 0.0f;
+ Vector2 currentPoint = p1;
+ Vector2 nextPoint = {0};
+ float t = 0.0f;
- Vector2 points[2*SPLINE_SEGMENT_DIVISIONS + 2] = { 0 };
+ Vector2 points[2 * SPLINE_SEGMENT_DIVISIONS + 2] = {0};
- for (int i = 0; i <= SPLINE_SEGMENT_DIVISIONS; i++)
- {
- t = step*(float)i;
+ for (int i = 0; i <= SPLINE_SEGMENT_DIVISIONS; i++) {
+ t = step * (float)i;
- float q0 = (-1*t*t*t) + (2*t*t) + (-1*t);
- float q1 = (3*t*t*t) + (-5*t*t) + 2;
- float q2 = (-3*t*t*t) + (4*t*t) + t;
- float q3 = t*t*t - t*t;
+ float q0 = (-1 * t * t * t) + (2 * t * t) + (-1 * t);
+ float q1 = (3 * t * t * t) + (-5 * t * t) + 2;
+ float q2 = (-3 * t * t * t) + (4 * t * t) + t;
+ float q3 = t * t * t - t * t;
- nextPoint.x = 0.5f*((p1.x*q0) + (p2.x*q1) + (p3.x*q2) + (p4.x*q3));
- nextPoint.y = 0.5f*((p1.y*q0) + (p2.y*q1) + (p3.y*q2) + (p4.y*q3));
+ nextPoint.x = 0.5f * ((p1.x * q0) + (p2.x * q1) + (p3.x * q2) + (p4.x * q3));
+ nextPoint.y = 0.5f * ((p1.y * q0) + (p2.y * q1) + (p3.y * q2) + (p4.y * q3));
- float dy = nextPoint.y - currentPoint.y;
- float dx = nextPoint.x - currentPoint.x;
- float size = (0.5f*thick)/sqrtf(dx*dx + dy*dy);
+ float dy = nextPoint.y - currentPoint.y;
+ float dx = nextPoint.x - currentPoint.x;
+ float size = (0.5f * thick) / sqrtf(dx * dx + dy * dy);
- if (i == 1)
- {
- points[0].x = currentPoint.x + dy*size;
- points[0].y = currentPoint.y - dx*size;
- points[1].x = currentPoint.x - dy*size;
- points[1].y = currentPoint.y + dx*size;
- }
+ if (i == 1) {
+ points[0].x = currentPoint.x + dy * size;
+ points[0].y = currentPoint.y - dx * size;
+ points[1].x = currentPoint.x - dy * size;
+ points[1].y = currentPoint.y + dx * size;
+ }
- points[2*i + 1].x = nextPoint.x - dy*size;
- points[2*i + 1].y = nextPoint.y + dx*size;
- points[2*i].x = nextPoint.x + dy*size;
- points[2*i].y = nextPoint.y - dx*size;
+ points[2 * i + 1].x = nextPoint.x - dy * size;
+ points[2 * i + 1].y = nextPoint.y + dx * size;
+ points[2 * i].x = nextPoint.x + dy * size;
+ points[2 * i].y = nextPoint.y - dx * size;
- currentPoint = nextPoint;
- }
+ currentPoint = nextPoint;
+ }
- DrawTriangleStrip(points, 2*SPLINE_SEGMENT_DIVISIONS + 2, color);
+ DrawTriangleStrip(points, 2 * SPLINE_SEGMENT_DIVISIONS + 2, color);
}
// Draw spline segment: Quadratic Bezier, 2 points, 1 control point
-void DrawSplineSegmentBezierQuadratic(Vector2 p1, Vector2 c2, Vector2 p3, float thick, RLColor color)
-{
- const float step = 1.0f/SPLINE_SEGMENT_DIVISIONS;
+void DrawSplineSegmentBezierQuadratic(Vector2 p1, Vector2 c2, Vector2 p3, float thick, RLColor color) {
+ const float step = 1.0f / SPLINE_SEGMENT_DIVISIONS;
- Vector2 previous = p1;
- Vector2 current = { 0 };
- float t = 0.0f;
+ Vector2 previous = p1;
+ Vector2 current = {0};
+ float t = 0.0f;
- Vector2 points[2*SPLINE_SEGMENT_DIVISIONS + 2] = { 0 };
+ Vector2 points[2 * SPLINE_SEGMENT_DIVISIONS + 2] = {0};
- for (int i = 1; i <= SPLINE_SEGMENT_DIVISIONS; i++)
- {
- t = step*(float)i;
+ for (int i = 1; i <= SPLINE_SEGMENT_DIVISIONS; i++) {
+ t = step * (float)i;
- float a = powf(1.0f - t, 2);
- float b = 2.0f*(1.0f - t)*t;
- float c = powf(t, 2);
+ float a = powf(1.0f - t, 2);
+ float b = 2.0f * (1.0f - t) * t;
+ float c = powf(t, 2);
- // NOTE: The easing functions aren't suitable here because they don't take a control point
- current.y = a*p1.y + b*c2.y + c*p3.y;
- current.x = a*p1.x + b*c2.x + c*p3.x;
+ // NOTE: The easing functions aren't suitable here because they don't take a control point
+ current.y = a * p1.y + b * c2.y + c * p3.y;
+ current.x = a * p1.x + b * c2.x + c * p3.x;
- float dy = current.y - previous.y;
- float dx = current.x - previous.x;
- float size = 0.5f*thick/sqrtf(dx*dx+dy*dy);
+ float dy = current.y - previous.y;
+ float dx = current.x - previous.x;
+ float size = 0.5f * thick / sqrtf(dx * dx + dy * dy);
- if (i == 1)
- {
- points[0].x = previous.x + dy*size;
- points[0].y = previous.y - dx*size;
- points[1].x = previous.x - dy*size;
- points[1].y = previous.y + dx*size;
- }
+ if (i == 1) {
+ points[0].x = previous.x + dy * size;
+ points[0].y = previous.y - dx * size;
+ points[1].x = previous.x - dy * size;
+ points[1].y = previous.y + dx * size;
+ }
- points[2*i + 1].x = current.x - dy*size;
- points[2*i + 1].y = current.y + dx*size;
- points[2*i].x = current.x + dy*size;
- points[2*i].y = current.y - dx*size;
+ points[2 * i + 1].x = current.x - dy * size;
+ points[2 * i + 1].y = current.y + dx * size;
+ points[2 * i].x = current.x + dy * size;
+ points[2 * i].y = current.y - dx * size;
- previous = current;
- }
+ previous = current;
+ }
- DrawTriangleStrip(points, 2*SPLINE_SEGMENT_DIVISIONS + 2, color);
+ DrawTriangleStrip(points, 2 * SPLINE_SEGMENT_DIVISIONS + 2, color);
}
// Draw spline segment: Cubic Bezier, 2 points, 2 control points
-void DrawSplineSegmentBezierCubic(Vector2 p1, Vector2 c2, Vector2 c3, Vector2 p4, float thick, RLColor color)
-{
- const float step = 1.0f/SPLINE_SEGMENT_DIVISIONS;
+void DrawSplineSegmentBezierCubic(Vector2 p1, Vector2 c2, Vector2 c3, Vector2 p4, float thick, RLColor color) {
+ const float step = 1.0f / SPLINE_SEGMENT_DIVISIONS;
- Vector2 previous = p1;
- Vector2 current = { 0 };
- float t = 0.0f;
+ Vector2 previous = p1;
+ Vector2 current = {0};
+ float t = 0.0f;
- Vector2 points[2*SPLINE_SEGMENT_DIVISIONS + 2] = { 0 };
+ Vector2 points[2 * SPLINE_SEGMENT_DIVISIONS + 2] = {0};
- for (int i = 1; i <= SPLINE_SEGMENT_DIVISIONS; i++)
- {
- t = step*(float)i;
+ for (int i = 1; i <= SPLINE_SEGMENT_DIVISIONS; i++) {
+ t = step * (float)i;
- float a = powf(1.0f - t, 3);
- float b = 3.0f*powf(1.0f - t, 2)*t;
- float c = 3.0f*(1.0f - t)*powf(t, 2);
- float d = powf(t, 3);
+ float a = powf(1.0f - t, 3);
+ float b = 3.0f * powf(1.0f - t, 2) * t;
+ float c = 3.0f * (1.0f - t) * powf(t, 2);
+ float d = powf(t, 3);
- current.y = a*p1.y + b*c2.y + c*c3.y + d*p4.y;
- current.x = a*p1.x + b*c2.x + c*c3.x + d*p4.x;
+ current.y = a * p1.y + b * c2.y + c * c3.y + d * p4.y;
+ current.x = a * p1.x + b * c2.x + c * c3.x + d * p4.x;
- float dy = current.y - previous.y;
- float dx = current.x - previous.x;
- float size = 0.5f*thick/sqrtf(dx*dx+dy*dy);
+ float dy = current.y - previous.y;
+ float dx = current.x - previous.x;
+ float size = 0.5f * thick / sqrtf(dx * dx + dy * dy);
- if (i == 1)
- {
- points[0].x = previous.x + dy*size;
- points[0].y = previous.y - dx*size;
- points[1].x = previous.x - dy*size;
- points[1].y = previous.y + dx*size;
- }
+ if (i == 1) {
+ points[0].x = previous.x + dy * size;
+ points[0].y = previous.y - dx * size;
+ points[1].x = previous.x - dy * size;
+ points[1].y = previous.y + dx * size;
+ }
- points[2*i + 1].x = current.x - dy*size;
- points[2*i + 1].y = current.y + dx*size;
- points[2*i].x = current.x + dy*size;
- points[2*i].y = current.y - dx*size;
+ points[2 * i + 1].x = current.x - dy * size;
+ points[2 * i + 1].y = current.y + dx * size;
+ points[2 * i].x = current.x + dy * size;
+ points[2 * i].y = current.y - dx * size;
- previous = current;
- }
+ previous = current;
+ }
- DrawTriangleStrip(points, 2*SPLINE_SEGMENT_DIVISIONS + 2, color);
+ DrawTriangleStrip(points, 2 * SPLINE_SEGMENT_DIVISIONS + 2, color);
}
// Get spline point for a given t [0.0f .. 1.0f], Linear
-Vector2 GetSplinePointLinear(Vector2 startPos, Vector2 endPos, float t)
-{
- Vector2 point = { 0 };
+Vector2 GetSplinePointLinear(Vector2 startPos, Vector2 endPos, float t) {
+ Vector2 point = {0};
- point.x = startPos.x*(1.0f - t) + endPos.x*t;
- point.y = startPos.y*(1.0f - t) + endPos.y*t;
+ point.x = startPos.x * (1.0f - t) + endPos.x * t;
+ point.y = startPos.y * (1.0f - t) + endPos.y * t;
- return point;
+ return point;
}
// Get spline point for a given t [0.0f .. 1.0f], B-Spline
-Vector2 GetSplinePointBasis(Vector2 p1, Vector2 p2, Vector2 p3, Vector2 p4, float t)
-{
- Vector2 point = { 0 };
+Vector2 GetSplinePointBasis(Vector2 p1, Vector2 p2, Vector2 p3, Vector2 p4, float t) {
+ Vector2 point = {0};
- float a[4] = { 0 };
- float b[4] = { 0 };
+ float a[4] = {0};
+ float b[4] = {0};
- a[0] = (-p1.x + 3*p2.x - 3*p3.x + p4.x)/6.0f;
- a[1] = (3*p1.x - 6*p2.x + 3*p3.x)/6.0f;
- a[2] = (-3*p1.x + 3*p3.x)/6.0f;
- a[3] = (p1.x + 4*p2.x + p3.x)/6.0f;
+ a[0] = (-p1.x + 3 * p2.x - 3 * p3.x + p4.x) / 6.0f;
+ a[1] = (3 * p1.x - 6 * p2.x + 3 * p3.x) / 6.0f;
+ a[2] = (-3 * p1.x + 3 * p3.x) / 6.0f;
+ a[3] = (p1.x + 4 * p2.x + p3.x) / 6.0f;
- b[0] = (-p1.y + 3*p2.y - 3*p3.y + p4.y)/6.0f;
- b[1] = (3*p1.y - 6*p2.y + 3*p3.y)/6.0f;
- b[2] = (-3*p1.y + 3*p3.y)/6.0f;
- b[3] = (p1.y + 4*p2.y + p3.y)/6.0f;
+ b[0] = (-p1.y + 3 * p2.y - 3 * p3.y + p4.y) / 6.0f;
+ b[1] = (3 * p1.y - 6 * p2.y + 3 * p3.y) / 6.0f;
+ b[2] = (-3 * p1.y + 3 * p3.y) / 6.0f;
+ b[3] = (p1.y + 4 * p2.y + p3.y) / 6.0f;
- point.x = a[3] + t*(a[2] + t*(a[1] + t*a[0]));
- point.y = b[3] + t*(b[2] + t*(b[1] + t*b[0]));
+ point.x = a[3] + t * (a[2] + t * (a[1] + t * a[0]));
+ point.y = b[3] + t * (b[2] + t * (b[1] + t * b[0]));
- return point;
+ return point;
}
// Get spline point for a given t [0.0f .. 1.0f], Catmull-Rom
-Vector2 GetSplinePointCatmullRom(Vector2 p1, Vector2 p2, Vector2 p3, Vector2 p4, float t)
-{
- Vector2 point = { 0 };
+Vector2 GetSplinePointCatmullRom(Vector2 p1, Vector2 p2, Vector2 p3, Vector2 p4, float t) {
+ Vector2 point = {0};
- float q0 = (-1*t*t*t) + (2*t*t) + (-1*t);
- float q1 = (3*t*t*t) + (-5*t*t) + 2;
- float q2 = (-3*t*t*t) + (4*t*t) + t;
- float q3 = t*t*t - t*t;
+ float q0 = (-1 * t * t * t) + (2 * t * t) + (-1 * t);
+ float q1 = (3 * t * t * t) + (-5 * t * t) + 2;
+ float q2 = (-3 * t * t * t) + (4 * t * t) + t;
+ float q3 = t * t * t - t * t;
- point.x = 0.5f*((p1.x*q0) + (p2.x*q1) + (p3.x*q2) + (p4.x*q3));
- point.y = 0.5f*((p1.y*q0) + (p2.y*q1) + (p3.y*q2) + (p4.y*q3));
+ point.x = 0.5f * ((p1.x * q0) + (p2.x * q1) + (p3.x * q2) + (p4.x * q3));
+ point.y = 0.5f * ((p1.y * q0) + (p2.y * q1) + (p3.y * q2) + (p4.y * q3));
- return point;
+ return point;
}
// Get spline point for a given t [0.0f .. 1.0f], Quadratic Bezier
-Vector2 GetSplinePointBezierQuad(Vector2 startPos, Vector2 controlPos, Vector2 endPos, float t)
-{
- Vector2 point = { 0 };
+Vector2 GetSplinePointBezierQuad(Vector2 startPos, Vector2 controlPos, Vector2 endPos, float t) {
+ Vector2 point = {0};
- float a = powf(1.0f - t, 2);
- float b = 2.0f*(1.0f - t)*t;
- float c = powf(t, 2);
+ float a = powf(1.0f - t, 2);
+ float b = 2.0f * (1.0f - t) * t;
+ float c = powf(t, 2);
- point.y = a*startPos.y + b*controlPos.y + c*endPos.y;
- point.x = a*startPos.x + b*controlPos.x + c*endPos.x;
+ point.y = a * startPos.y + b * controlPos.y + c * endPos.y;
+ point.x = a * startPos.x + b * controlPos.x + c * endPos.x;
- return point;
+ return point;
}
// Get spline point for a given t [0.0f .. 1.0f], Cubic Bezier
-Vector2 GetSplinePointBezierCubic(Vector2 startPos, Vector2 startControlPos, Vector2 endControlPos, Vector2 endPos, float t)
-{
- Vector2 point = { 0 };
+Vector2 GetSplinePointBezierCubic(Vector2 startPos, Vector2 startControlPos, Vector2 endControlPos, Vector2 endPos, float t) {
+ Vector2 point = {0};
- float a = powf(1.0f - t, 3);
- float b = 3.0f*powf(1.0f - t, 2)*t;
- float c = 3.0f*(1.0f - t)*powf(t, 2);
- float d = powf(t, 3);
+ float a = powf(1.0f - t, 3);
+ float b = 3.0f * powf(1.0f - t, 2) * t;
+ float c = 3.0f * (1.0f - t) * powf(t, 2);
+ float d = powf(t, 3);
- point.y = a*startPos.y + b*startControlPos.y + c*endControlPos.y + d*endPos.y;
- point.x = a*startPos.x + b*startControlPos.x + c*endControlPos.x + d*endPos.x;
+ point.y = a * startPos.y + b * startControlPos.y + c * endControlPos.y + d * endPos.y;
+ point.x = a * startPos.x + b * startControlPos.x + c * endControlPos.x + d * endPos.x;
- return point;
+ return point;
}
//----------------------------------------------------------------------------------
@@ -2180,215 +2066,213 @@ Vector2 GetSplinePointBezierCubic(Vector2 startPos, Vector2 startControlPos, Vec
//----------------------------------------------------------------------------------
// Check if point is inside rectangle
-bool CheckCollisionPointRec(Vector2 point, Rectangle rec)
-{
- bool collision = false;
+bool CheckCollisionPointRec(Vector2 point, Rectangle rec) {
+ bool collision = false;
- if ((point.x >= rec.x) && (point.x < (rec.x + rec.width)) && (point.y >= rec.y) && (point.y < (rec.y + rec.height))) collision = true;
+ if ((point.x >= rec.x) && (point.x < (rec.x + rec.width)) && (point.y >= rec.y) && (point.y < (rec.y + rec.height)))
+ collision = true;
- return collision;
+ return collision;
}
// Check if point is inside circle
-bool CheckCollisionPointCircle(Vector2 point, Vector2 center, float radius)
-{
- bool collision = false;
+bool CheckCollisionPointCircle(Vector2 point, Vector2 center, float radius) {
+ bool collision = false;
- float distanceSquared = (point.x - center.x)*(point.x - center.x) + (point.y - center.y)*(point.y - center.y);
+ float distanceSquared = (point.x - center.x) * (point.x - center.x) + (point.y - center.y) * (point.y - center.y);
- if (distanceSquared <= radius*radius) collision = true;
+ if (distanceSquared <= radius * radius)
+ collision = true;
- return collision;
+ return collision;
}
// Check if point is inside a triangle defined by three points (p1, p2, p3)
-bool CheckCollisionPointTriangle(Vector2 point, Vector2 p1, Vector2 p2, Vector2 p3)
-{
- bool collision = false;
+bool CheckCollisionPointTriangle(Vector2 point, Vector2 p1, Vector2 p2, Vector2 p3) {
+ bool collision = false;
- float alpha = ((p2.y - p3.y)*(point.x - p3.x) + (p3.x - p2.x)*(point.y - p3.y)) /
- ((p2.y - p3.y)*(p1.x - p3.x) + (p3.x - p2.x)*(p1.y - p3.y));
+ float alpha = ((p2.y - p3.y) * (point.x - p3.x) + (p3.x - p2.x) * (point.y - p3.y)) /
+ ((p2.y - p3.y) * (p1.x - p3.x) + (p3.x - p2.x) * (p1.y - p3.y));
- float beta = ((p3.y - p1.y)*(point.x - p3.x) + (p1.x - p3.x)*(point.y - p3.y)) /
- ((p2.y - p3.y)*(p1.x - p3.x) + (p3.x - p2.x)*(p1.y - p3.y));
+ float beta = ((p3.y - p1.y) * (point.x - p3.x) + (p1.x - p3.x) * (point.y - p3.y)) /
+ ((p2.y - p3.y) * (p1.x - p3.x) + (p3.x - p2.x) * (p1.y - p3.y));
- float gamma = 1.0f - alpha - beta;
+ float gamma = 1.0f - alpha - beta;
- if ((alpha > 0) && (beta > 0) && (gamma > 0)) collision = true;
+ if ((alpha > 0) && (beta > 0) && (gamma > 0))
+ collision = true;
- return collision;
+ return collision;
}
// Check if point is within a polygon described by array of vertices
// NOTE: Based on http://jeffreythompson.org/collision-detection/poly-point.php
-bool CheckCollisionPointPoly(Vector2 point, const Vector2 *points, int pointCount)
-{
- bool inside = false;
+bool CheckCollisionPointPoly(Vector2 point, const Vector2* points, int pointCount) {
+ bool inside = false;
- if (pointCount > 2)
- {
- for (int i = 0, j = pointCount - 1; i < pointCount; j = i++)
- {
- if ((points[i].y > point.y) != (points[j].y > point.y) &&
- (point.x < (points[j].x - points[i].x)*(point.y - points[i].y)/(points[j].y - points[i].y) + points[i].x))
- {
- inside = !inside;
- }
- }
- }
+ if (pointCount > 2) {
+ for (int i = 0, j = pointCount - 1; i < pointCount; j = i++) {
+ if ((points[i].y > point.y) != (points[j].y > point.y) &&
+ (point.x < (points[j].x - points[i].x) * (point.y - points[i].y) / (points[j].y - points[i].y) + points[i].x)) {
+ inside = !inside;
+ }
+ }
+ }
- return inside;
+ return inside;
}
// Check collision between two rectangles
-bool CheckCollisionRecs(Rectangle rec1, Rectangle rec2)
-{
- bool collision = false;
+bool CheckCollisionRecs(Rectangle rec1, Rectangle rec2) {
+ bool collision = false;
- if ((rec1.x < (rec2.x + rec2.width) && (rec1.x + rec1.width) > rec2.x) &&
- (rec1.y < (rec2.y + rec2.height) && (rec1.y + rec1.height) > rec2.y)) collision = true;
+ if ((rec1.x < (rec2.x + rec2.width) && (rec1.x + rec1.width) > rec2.x) &&
+ (rec1.y < (rec2.y + rec2.height) && (rec1.y + rec1.height) > rec2.y))
+ collision = true;
- return collision;
+ return collision;
}
// Check collision between two circles
-bool CheckCollisionCircles(Vector2 center1, float radius1, Vector2 center2, float radius2)
-{
- bool collision = false;
+bool CheckCollisionCircles(Vector2 center1, float radius1, Vector2 center2, float radius2) {
+ bool collision = false;
- float dx = center2.x - center1.x; // X distance between centers
- float dy = center2.y - center1.y; // Y distance between centers
+ float dx = center2.x - center1.x; // X distance between centers
+ float dy = center2.y - center1.y; // Y distance between centers
- float distanceSquared = dx*dx + dy*dy; // Distance between centers squared
- float radiusSum = radius1 + radius2;
+ float distanceSquared = dx * dx + dy * dy; // Distance between centers squared
+ float radiusSum = radius1 + radius2;
- collision = (distanceSquared <= (radiusSum*radiusSum));
+ collision = (distanceSquared <= (radiusSum * radiusSum));
- return collision;
+ return collision;
}
// Check collision between circle and rectangle
// NOTE: Reviewed version to take into account corner limit case
-bool CheckCollisionCircleRec(Vector2 center, float radius, Rectangle rec)
-{
- bool collision = false;
+bool CheckCollisionCircleRec(Vector2 center, float radius, Rectangle rec) {
+ bool collision = false;
- float recCenterX = rec.x + rec.width/2.0f;
- float recCenterY = rec.y + rec.height/2.0f;
+ float recCenterX = rec.x + rec.width / 2.0f;
+ float recCenterY = rec.y + rec.height / 2.0f;
- float dx = fabsf(center.x - recCenterX);
- float dy = fabsf(center.y - recCenterY);
+ float dx = fabsf(center.x - recCenterX);
+ float dy = fabsf(center.y - recCenterY);
- if (dx > (rec.width/2.0f + radius)) { return false; }
- if (dy > (rec.height/2.0f + radius)) { return false; }
+ if (dx > (rec.width / 2.0f + radius)) {
+ return false;
+ }
+ if (dy > (rec.height / 2.0f + radius)) {
+ return false;
+ }
- if (dx <= (rec.width/2.0f)) { return true; }
- if (dy <= (rec.height/2.0f)) { return true; }
+ if (dx <= (rec.width / 2.0f)) {
+ return true;
+ }
+ if (dy <= (rec.height / 2.0f)) {
+ return true;
+ }
- float cornerDistanceSq = (dx - rec.width/2.0f)*(dx - rec.width/2.0f) +
- (dy - rec.height/2.0f)*(dy - rec.height/2.0f);
+ float cornerDistanceSq = (dx - rec.width / 2.0f) * (dx - rec.width / 2.0f) +
+ (dy - rec.height / 2.0f) * (dy - rec.height / 2.0f);
- collision = (cornerDistanceSq <= (radius*radius));
+ collision = (cornerDistanceSq <= (radius * radius));
- return collision;
+ return collision;
}
// Check the collision between two lines defined by two points each, returns collision point by reference
-bool CheckCollisionLines(Vector2 startPos1, Vector2 endPos1, Vector2 startPos2, Vector2 endPos2, Vector2 *collisionPoint)
-{
- bool collision = false;
+bool CheckCollisionLines(Vector2 startPos1, Vector2 endPos1, Vector2 startPos2, Vector2 endPos2, Vector2* collisionPoint) {
+ bool collision = false;
- float div = (endPos2.y - startPos2.y)*(endPos1.x - startPos1.x) - (endPos2.x - startPos2.x)*(endPos1.y - startPos1.y);
+ float div = (endPos2.y - startPos2.y) * (endPos1.x - startPos1.x) - (endPos2.x - startPos2.x) * (endPos1.y - startPos1.y);
- if (fabsf(div) >= FLT_EPSILON)
- {
- collision = true;
+ if (fabsf(div) >= FLT_EPSILON) {
+ collision = true;
- float xi = ((startPos2.x - endPos2.x)*(startPos1.x*endPos1.y - startPos1.y*endPos1.x) - (startPos1.x - endPos1.x)*(startPos2.x*endPos2.y - startPos2.y*endPos2.x))/div;
- float yi = ((startPos2.y - endPos2.y)*(startPos1.x*endPos1.y - startPos1.y*endPos1.x) - (startPos1.y - endPos1.y)*(startPos2.x*endPos2.y - startPos2.y*endPos2.x))/div;
+ float xi = ((startPos2.x - endPos2.x) * (startPos1.x * endPos1.y - startPos1.y * endPos1.x) - (startPos1.x - endPos1.x) * (startPos2.x * endPos2.y - startPos2.y * endPos2.x)) / div;
+ float yi = ((startPos2.y - endPos2.y) * (startPos1.x * endPos1.y - startPos1.y * endPos1.x) - (startPos1.y - endPos1.y) * (startPos2.x * endPos2.y - startPos2.y * endPos2.x)) / div;
- if (((fabsf(startPos1.x - endPos1.x) > FLT_EPSILON) && (xi < fminf(startPos1.x, endPos1.x) || (xi > fmaxf(startPos1.x, endPos1.x)))) ||
- ((fabsf(startPos2.x - endPos2.x) > FLT_EPSILON) && (xi < fminf(startPos2.x, endPos2.x) || (xi > fmaxf(startPos2.x, endPos2.x)))) ||
- ((fabsf(startPos1.y - endPos1.y) > FLT_EPSILON) && (yi < fminf(startPos1.y, endPos1.y) || (yi > fmaxf(startPos1.y, endPos1.y)))) ||
- ((fabsf(startPos2.y - endPos2.y) > FLT_EPSILON) && (yi < fminf(startPos2.y, endPos2.y) || (yi > fmaxf(startPos2.y, endPos2.y))))) collision = false;
+ if (((fabsf(startPos1.x - endPos1.x) > FLT_EPSILON) && (xi < fminf(startPos1.x, endPos1.x) || (xi > fmaxf(startPos1.x, endPos1.x)))) ||
+ ((fabsf(startPos2.x - endPos2.x) > FLT_EPSILON) && (xi < fminf(startPos2.x, endPos2.x) || (xi > fmaxf(startPos2.x, endPos2.x)))) ||
+ ((fabsf(startPos1.y - endPos1.y) > FLT_EPSILON) && (yi < fminf(startPos1.y, endPos1.y) || (yi > fmaxf(startPos1.y, endPos1.y)))) ||
+ ((fabsf(startPos2.y - endPos2.y) > FLT_EPSILON) && (yi < fminf(startPos2.y, endPos2.y) || (yi > fmaxf(startPos2.y, endPos2.y)))))
+ collision = false;
- if (collision && (collisionPoint != 0))
- {
- collisionPoint->x = xi;
- collisionPoint->y = yi;
- }
- }
+ if (collision && (collisionPoint != 0)) {
+ collisionPoint->x = xi;
+ collisionPoint->y = yi;
+ }
+ }
- return collision;
+ return collision;
}
// Check if point belongs to line created between two points [p1] and [p2] with defined margin in pixels [threshold]
-bool CheckCollisionPointLine(Vector2 point, Vector2 p1, Vector2 p2, int threshold)
-{
- bool collision = false;
+bool CheckCollisionPointLine(Vector2 point, Vector2 p1, Vector2 p2, int threshold) {
+ bool collision = false;
- float dxc = point.x - p1.x;
- float dyc = point.y - p1.y;
- float dxl = p2.x - p1.x;
- float dyl = p2.y - p1.y;
- float cross = dxc*dyl - dyc*dxl;
+ float dxc = point.x - p1.x;
+ float dyc = point.y - p1.y;
+ float dxl = p2.x - p1.x;
+ float dyl = p2.y - p1.y;
+ float cross = dxc * dyl - dyc * dxl;
- if (fabsf(cross) < (threshold*fmaxf(fabsf(dxl), fabsf(dyl))))
- {
- if (fabsf(dxl) >= fabsf(dyl)) collision = (dxl > 0)? ((p1.x <= point.x) && (point.x <= p2.x)) : ((p2.x <= point.x) && (point.x <= p1.x));
- else collision = (dyl > 0)? ((p1.y <= point.y) && (point.y <= p2.y)) : ((p2.y <= point.y) && (point.y <= p1.y));
- }
+ if (fabsf(cross) < (threshold * fmaxf(fabsf(dxl), fabsf(dyl)))) {
+ if (fabsf(dxl) >= fabsf(dyl))
+ collision = (dxl > 0) ? ((p1.x <= point.x) && (point.x <= p2.x)) : ((p2.x <= point.x) && (point.x <= p1.x));
+ else
+ collision = (dyl > 0) ? ((p1.y <= point.y) && (point.y <= p2.y)) : ((p2.y <= point.y) && (point.y <= p1.y));
+ }
- return collision;
+ return collision;
}
// Check if circle collides with a line created betweeen two points [p1] and [p2]
-RLAPI bool CheckCollisionCircleLine(Vector2 center, float radius, Vector2 p1, Vector2 p2)
-{
- float dx = p1.x - p2.x;
- float dy = p1.y - p2.y;
+RLAPI bool CheckCollisionCircleLine(Vector2 center, float radius, Vector2 p1, Vector2 p2) {
+ float dx = p1.x - p2.x;
+ float dy = p1.y - p2.y;
- if ((fabsf(dx) + fabsf(dy)) <= FLT_EPSILON)
- {
- return CheckCollisionCircles(p1, 0, center, radius);
- }
+ if ((fabsf(dx) + fabsf(dy)) <= FLT_EPSILON) {
+ return CheckCollisionCircles(p1, 0, center, radius);
+ }
- float lengthSQ = ((dx*dx) + (dy*dy));
- float dotProduct = (((center.x - p1.x)*(p2.x - p1.x)) + ((center.y - p1.y)*(p2.y - p1.y)))/(lengthSQ);
+ float lengthSQ = ((dx * dx) + (dy * dy));
+ float dotProduct = (((center.x - p1.x) * (p2.x - p1.x)) + ((center.y - p1.y) * (p2.y - p1.y))) / (lengthSQ);
- if (dotProduct > 1.0f) dotProduct = 1.0f;
- else if (dotProduct < 0.0f) dotProduct = 0.0f;
+ if (dotProduct > 1.0f)
+ dotProduct = 1.0f;
+ else if (dotProduct < 0.0f)
+ dotProduct = 0.0f;
- float dx2 = (p1.x - (dotProduct*(dx))) - center.x;
- float dy2 = (p1.y - (dotProduct*(dy))) - center.y;
- float distanceSQ = ((dx2*dx2) + (dy2*dy2));
+ float dx2 = (p1.x - (dotProduct * (dx))) - center.x;
+ float dy2 = (p1.y - (dotProduct * (dy))) - center.y;
+ float distanceSQ = ((dx2 * dx2) + (dy2 * dy2));
- return (distanceSQ <= radius*radius);
+ return (distanceSQ <= radius * radius);
}
// Get collision rectangle for two rectangles collision
-Rectangle GetCollisionRec(Rectangle rec1, Rectangle rec2)
-{
- Rectangle overlap = { 0 };
-
- float left = (rec1.x > rec2.x)? rec1.x : rec2.x;
- float right1 = rec1.x + rec1.width;
- float right2 = rec2.x + rec2.width;
- float right = (right1 < right2)? right1 : right2;
- float top = (rec1.y > rec2.y)? rec1.y : rec2.y;
- float bottom1 = rec1.y + rec1.height;
- float bottom2 = rec2.y + rec2.height;
- float bottom = (bottom1 < bottom2)? bottom1 : bottom2;
-
- if ((left < right) && (top < bottom))
- {
- overlap.x = left;
- overlap.y = top;
- overlap.width = right - left;
- overlap.height = bottom - top;
- }
-
- return overlap;
+Rectangle GetCollisionRec(Rectangle rec1, Rectangle rec2) {
+ Rectangle overlap = {0};
+
+ float left = (rec1.x > rec2.x) ? rec1.x : rec2.x;
+ float right1 = rec1.x + rec1.width;
+ float right2 = rec2.x + rec2.width;
+ float right = (right1 < right2) ? right1 : right2;
+ float top = (rec1.y > rec2.y) ? rec1.y : rec2.y;
+ float bottom1 = rec1.y + rec1.height;
+ float bottom2 = rec2.y + rec2.height;
+ float bottom = (bottom1 < bottom2) ? bottom1 : bottom2;
+
+ if ((left < right) && (top < bottom)) {
+ overlap.x = left;
+ overlap.y = top;
+ overlap.width = right - left;
+ overlap.height = bottom - top;
+ }
+
+ return overlap;
}
//----------------------------------------------------------------------------------
@@ -2397,18 +2281,17 @@ Rectangle GetCollisionRec(Rectangle rec1, Rectangle rec2)
// Cubic easing in-out
// NOTE: Used by DrawLineBezier() only
-static float EaseCubicInOut(float t, float b, float c, float d)
-{
- float result = 0.0f;
+static float EaseCubicInOut(float t, float b, float c, float d) {
+ float result = 0.0f;
- if ((t /= 0.5f*d) < 1) result = 0.5f*c*t*t*t + b;
- else
- {
- t -= 2;
- result = 0.5f*c*(t*t*t + 2.0f) + b;
- }
+ if ((t /= 0.5f * d) < 1)
+ result = 0.5f * c * t * t * t + b;
+ else {
+ t -= 2;
+ result = 0.5f * c * (t * t * t + 2.0f) + b;
+ }
- return result;
+ return result;
}
-#endif // SUPPORT_MODULE_RSHAPES
+#endif // SUPPORT_MODULE_RSHAPES
diff --git a/Source/System/Constants.h b/Source/System/Constants.h
index ce04992d31..259d863d47 100644
--- a/Source/System/Constants.h
+++ b/Source/System/Constants.h
@@ -144,6 +144,7 @@ namespace RTE {
-1.0f, -1.0f, 0.0f, 1.0f};
static constexpr float c_GuiDepth = -100.0f;
+ static constexpr float c_PrimitiveDepth = -75.0f;
static constexpr float c_DefaultDrawDepth = 0.0f;
static constexpr float c_TerrainBGDepth = 50.0f;
static constexpr float c_BackgroundDepth = 100.0f;
diff --git a/Source/System/ContentFile.h b/Source/System/ContentFile.h
index febf9ab1f8..12d4772209 100644
--- a/Source/System/ContentFile.h
+++ b/Source/System/ContentFile.h
@@ -150,6 +150,9 @@ namespace RTE {
FMOD::Sound* GetAsSound(bool abortGameForInvalidSound = true, bool asyncLoading = true);
#pragma endregion
+ /// Copies the default palette to an sdl palette.
+ static SDL_Palette* DefaultPaletteToSDL();
+
private:
/// Enumeration for loading BITMAPs by bit depth. NOTE: This can't be lower down because s_LoadedBitmaps relies on this definition.
enum BitDepths {
@@ -200,8 +203,6 @@ namespace RTE {
#pragma endregion
#pragma region Data Handling
- /// Copies the default palette to an sdl palette.
- static SDL_Palette* DefaultPaletteToSDL();
/// Loads the data from dataPahtToLoad as an SDL_Surface.
/// This prevents allegro from doing anything to the image colors it'd otherwise be doing, like breaking the palette or removing alpha values.
diff --git a/Source/System/GraphicalPrimitive.cpp b/Source/System/GraphicalPrimitive.cpp
deleted file mode 100644
index 6f19674485..0000000000
--- a/Source/System/GraphicalPrimitive.cpp
+++ /dev/null
@@ -1,556 +0,0 @@
-#include "GraphicalPrimitive.h"
-#include "Matrix.h"
-#include "FrameMan.h"
-#include "SceneMan.h"
-
-#include "GUI.h"
-#include "AllegroBitmap.h"
-
-using namespace RTE;
-
-const GraphicalPrimitive::PrimitiveType GraphicalPrimitive::c_PrimitiveType = PrimitiveType::None;
-const GraphicalPrimitive::PrimitiveType LinePrimitive::c_PrimitiveType = PrimitiveType::Line;
-const GraphicalPrimitive::PrimitiveType ArcPrimitive::c_PrimitiveType = PrimitiveType::Arc;
-const GraphicalPrimitive::PrimitiveType SplinePrimitive::c_PrimitiveType = PrimitiveType::Spline;
-const GraphicalPrimitive::PrimitiveType BoxPrimitive::c_PrimitiveType = PrimitiveType::Box;
-const GraphicalPrimitive::PrimitiveType BoxFillPrimitive::c_PrimitiveType = PrimitiveType::BoxFill;
-const GraphicalPrimitive::PrimitiveType RoundedBoxPrimitive::c_PrimitiveType = PrimitiveType::RoundedBox;
-const GraphicalPrimitive::PrimitiveType RoundedBoxFillPrimitive::c_PrimitiveType = PrimitiveType::RoundedBoxFill;
-const GraphicalPrimitive::PrimitiveType CirclePrimitive::c_PrimitiveType = PrimitiveType::Circle;
-const GraphicalPrimitive::PrimitiveType CircleFillPrimitive::c_PrimitiveType = PrimitiveType::CircleFill;
-const GraphicalPrimitive::PrimitiveType EllipsePrimitive::c_PrimitiveType = PrimitiveType::Ellipse;
-const GraphicalPrimitive::PrimitiveType EllipseFillPrimitive::c_PrimitiveType = PrimitiveType::EllipseFill;
-const GraphicalPrimitive::PrimitiveType TrianglePrimitive::c_PrimitiveType = PrimitiveType::Triangle;
-const GraphicalPrimitive::PrimitiveType TriangleFillPrimitive::c_PrimitiveType = PrimitiveType::TriangleFill;
-const GraphicalPrimitive::PrimitiveType PolygonPrimitive::c_PrimitiveType = PrimitiveType::Polygon;
-const GraphicalPrimitive::PrimitiveType PolygonFillPrimitive::c_PrimitiveType = PrimitiveType::PolygonFill;
-const GraphicalPrimitive::PrimitiveType TextPrimitive::c_PrimitiveType = PrimitiveType::Text;
-const GraphicalPrimitive::PrimitiveType BitmapPrimitive::c_PrimitiveType = PrimitiveType::Bitmap;
-
-void GraphicalPrimitive::TranslateCoordinates(Vector targetPos, const Vector& scenePos, Vector& drawLeftPos, Vector& drawRightPos) const {
- drawLeftPos = scenePos;
- drawRightPos = scenePos;
-
- if (g_SceneMan.SceneWrapsX()) {
- float sceneWidth = static_cast(g_SceneMan.GetSceneWidth());
- if (targetPos.m_X <= sceneWidth && targetPos.m_X > sceneWidth / 2) {
- targetPos.m_X -= sceneWidth;
- }
- drawLeftPos.m_X = (drawLeftPos.m_X > 0) ? (drawLeftPos.m_X -= sceneWidth) : (drawLeftPos.m_X -= sceneWidth + targetPos.m_X);
- }
- drawLeftPos.m_X -= targetPos.m_X;
- drawRightPos.m_X -= targetPos.m_X;
-
- if (g_SceneMan.SceneWrapsY()) {
- float sceneHeight = static_cast(g_SceneMan.GetSceneHeight());
- if (targetPos.m_Y <= sceneHeight && targetPos.m_Y > sceneHeight / 2) {
- targetPos.m_Y -= sceneHeight;
- }
- drawLeftPos.m_Y = (drawLeftPos.m_Y > 0) ? (drawLeftPos.m_Y -= sceneHeight) : (drawLeftPos.m_Y -= sceneHeight + targetPos.m_Y);
- }
- drawLeftPos.m_Y -= targetPos.m_Y;
- drawRightPos.m_Y -= targetPos.m_Y;
-}
-
-void LinePrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos;
- Vector drawEnd = m_EndPos - targetPos;
- line(drawScreen, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), drawEnd.GetFloorIntX(), drawEnd.GetFloorIntY(), m_Color);
- } else {
- Vector drawStartLeft;
- Vector drawEndLeft;
- Vector drawStartRight;
- Vector drawEndRight;
-
- TranslateCoordinates(targetPos, m_StartPos, drawStartLeft, drawStartRight);
- TranslateCoordinates(targetPos, m_EndPos, drawEndLeft, drawEndRight);
-
- line(drawScreen, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), drawEndLeft.GetFloorIntX(), drawEndLeft.GetFloorIntY(), m_Color);
- line(drawScreen, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), drawEndRight.GetFloorIntX(), drawEndRight.GetFloorIntY(), m_Color);
- }
-}
-
-void ArcPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos;
- if (m_Thickness > 1) {
- for (int i = 0; i < m_Thickness; i++) {
- arc(drawScreen, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), ftofix(GetAllegroAngle(m_StartAngle)), ftofix(GetAllegroAngle(m_EndAngle)), (m_Radius - (m_Thickness / 2)) + i, m_Color);
- }
- } else {
- arc(drawScreen, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), ftofix(GetAllegroAngle(m_StartAngle)), ftofix(GetAllegroAngle(m_EndAngle)), m_Radius, m_Color);
- }
- } else {
- Vector drawStartLeft;
- Vector drawStartRight;
-
- TranslateCoordinates(targetPos, m_StartPos, drawStartLeft, drawStartRight);
-
- if (m_Thickness > 1) {
- for (int i = 0; i < m_Thickness; i++) {
- arc(drawScreen, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), ftofix(GetAllegroAngle(m_StartAngle)), ftofix(GetAllegroAngle(m_EndAngle)), (m_Radius - (m_Thickness / 2)) + i, m_Color);
- arc(drawScreen, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), ftofix(GetAllegroAngle(m_StartAngle)), ftofix(GetAllegroAngle(m_EndAngle)), (m_Radius - (m_Thickness / 2)) + i, m_Color);
- }
- } else {
- arc(drawScreen, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), ftofix(GetAllegroAngle(m_StartAngle)), ftofix(GetAllegroAngle(m_EndAngle)), m_Radius, m_Color);
- arc(drawScreen, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), ftofix(GetAllegroAngle(m_StartAngle)), ftofix(GetAllegroAngle(m_EndAngle)), m_Radius, m_Color);
- }
- }
-}
-
-void SplinePrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos;
- Vector drawGuideA = m_GuidePointAPos - targetPos;
- Vector drawGuideB = m_GuidePointBPos - targetPos;
- Vector drawEnd = m_EndPos - targetPos;
-
- std::array guidePoints = {drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), drawGuideA.GetFloorIntX(), drawGuideA.GetFloorIntY(), drawGuideB.GetFloorIntX(), drawGuideB.GetFloorIntY(), drawEnd.GetFloorIntX(), drawEnd.GetFloorIntY()};
- spline(drawScreen, guidePoints.data(), m_Color);
- } else {
- Vector drawStartLeft;
- Vector drawGuideALeft;
- Vector drawGuideBLeft;
- Vector drawEndLeft;
- Vector drawStartRight;
- Vector drawGuideARight;
- Vector drawGuideBRight;
- Vector drawEndRight;
-
- TranslateCoordinates(targetPos, m_StartPos, drawStartLeft, drawStartRight);
- TranslateCoordinates(targetPos, m_GuidePointAPos, drawGuideALeft, drawGuideARight);
- TranslateCoordinates(targetPos, m_GuidePointBPos, drawGuideBLeft, drawGuideBRight);
- TranslateCoordinates(targetPos, m_EndPos, drawEndLeft, drawEndRight);
-
- std::array guidePointsLeft = {drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), drawGuideALeft.GetFloorIntX(), drawGuideALeft.GetFloorIntY(), drawGuideBLeft.GetFloorIntX(), drawGuideBLeft.GetFloorIntY(), drawEndLeft.GetFloorIntX(), drawEndLeft.GetFloorIntY()};
- std::array guidePointsRight = {drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), drawGuideARight.GetFloorIntX(), drawGuideARight.GetFloorIntY(), drawGuideBRight.GetFloorIntX(), drawGuideBRight.GetFloorIntY(), drawEndRight.GetFloorIntX(), drawEndRight.GetFloorIntY()};
- spline(drawScreen, guidePointsLeft.data(), m_Color);
- spline(drawScreen, guidePointsRight.data(), m_Color);
- }
-}
-
-void BoxPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos;
- Vector drawEnd = m_EndPos - targetPos;
- rect(drawScreen, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), drawEnd.GetFloorIntX(), drawEnd.GetFloorIntY(), m_Color);
- } else {
- Vector drawStartLeft;
- Vector drawEndLeft;
- Vector drawStartRight;
- Vector drawEndRight;
-
- TranslateCoordinates(targetPos, m_StartPos, drawStartLeft, drawStartRight);
- TranslateCoordinates(targetPos, m_EndPos, drawEndLeft, drawEndRight);
-
- rect(drawScreen, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), drawEndLeft.GetFloorIntX(), drawEndLeft.GetFloorIntY(), m_Color);
- rect(drawScreen, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), drawEndRight.GetFloorIntX(), drawEndRight.GetFloorIntY(), m_Color);
- }
-}
-
-void BoxFillPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos;
- Vector drawEnd = m_EndPos - targetPos;
- rectfill(drawScreen, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), drawEnd.GetFloorIntX(), drawEnd.GetFloorIntY(), m_Color);
- } else {
- Vector drawStartLeft;
- Vector drawEndLeft;
- Vector drawStartRight;
- Vector drawEndRight;
-
- TranslateCoordinates(targetPos, m_StartPos, drawStartLeft, drawStartRight);
- TranslateCoordinates(targetPos, m_EndPos, drawEndLeft, drawEndRight);
-
- rectfill(drawScreen, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), drawEndLeft.GetFloorIntX(), drawEndLeft.GetFloorIntY(), m_Color);
- rectfill(drawScreen, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), drawEndRight.GetFloorIntX(), drawEndRight.GetFloorIntY(), m_Color);
- }
-}
-
-void RoundedBoxPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (m_StartPos.m_X > m_EndPos.m_X) {
- std::swap(m_StartPos.m_X, m_EndPos.m_X);
- }
- if (m_StartPos.m_Y > m_EndPos.m_Y) {
- std::swap(m_StartPos.m_Y, m_EndPos.m_Y);
- }
-
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos;
- Vector drawEnd = m_EndPos - targetPos;
-
- arc(drawScreen, drawStart.GetFloorIntX() + m_CornerRadius, drawStart.GetFloorIntY() + m_CornerRadius, itofix(64), itofix(128), m_CornerRadius, m_Color);
- arc(drawScreen, drawStart.GetFloorIntX() + m_CornerRadius, drawEnd.GetFloorIntY() - m_CornerRadius, itofix(128), itofix(-64), m_CornerRadius, m_Color);
- arc(drawScreen, drawEnd.GetFloorIntX() - m_CornerRadius, drawStart.GetFloorIntY() + m_CornerRadius, itofix(0), itofix(64), m_CornerRadius, m_Color);
- arc(drawScreen, drawEnd.GetFloorIntX() - m_CornerRadius, drawEnd.GetFloorIntY() - m_CornerRadius, itofix(-64), itofix(0), m_CornerRadius, m_Color);
-
- hline(drawScreen, drawStart.GetFloorIntX() + m_CornerRadius, drawStart.GetFloorIntY(), drawEnd.GetFloorIntX() - m_CornerRadius, m_Color);
- hline(drawScreen, drawStart.GetFloorIntX() + m_CornerRadius, drawEnd.GetFloorIntY(), drawEnd.GetFloorIntX() - m_CornerRadius, m_Color);
- vline(drawScreen, drawStart.GetFloorIntX(), drawStart.GetFloorIntY() + m_CornerRadius, drawEnd.GetFloorIntY() - m_CornerRadius, m_Color);
- vline(drawScreen, drawEnd.GetFloorIntX(), drawStart.GetFloorIntY() + m_CornerRadius, drawEnd.GetFloorIntY() - m_CornerRadius, m_Color);
- } else {
- Vector drawStartLeft;
- Vector drawEndLeft;
- Vector drawStartRight;
- Vector drawEndRight;
-
- TranslateCoordinates(targetPos, m_StartPos, drawStartLeft, drawStartRight);
- TranslateCoordinates(targetPos, m_EndPos, drawEndLeft, drawEndRight);
-
- arc(drawScreen, drawStartLeft.GetFloorIntX() + m_CornerRadius, drawStartLeft.GetFloorIntY() + m_CornerRadius, itofix(64), itofix(128), m_CornerRadius, m_Color);
- arc(drawScreen, drawStartLeft.GetFloorIntX() + m_CornerRadius, drawEndLeft.GetFloorIntY() - m_CornerRadius, itofix(128), itofix(-64), m_CornerRadius, m_Color);
- arc(drawScreen, drawEndLeft.GetFloorIntX() - m_CornerRadius, drawStartLeft.GetFloorIntY() + m_CornerRadius, itofix(0), itofix(64), m_CornerRadius, m_Color);
- arc(drawScreen, drawEndLeft.GetFloorIntX() - m_CornerRadius, drawEndLeft.GetFloorIntY() - m_CornerRadius, itofix(-64), itofix(0), m_CornerRadius, m_Color);
- hline(drawScreen, drawStartLeft.GetFloorIntX() + m_CornerRadius, drawStartLeft.GetFloorIntY(), drawEndLeft.GetFloorIntX() - m_CornerRadius, m_Color);
- hline(drawScreen, drawStartLeft.GetFloorIntX() + m_CornerRadius, drawEndLeft.GetFloorIntY(), drawEndLeft.GetFloorIntX() - m_CornerRadius, m_Color);
- vline(drawScreen, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY() + m_CornerRadius, drawEndLeft.GetFloorIntY() - m_CornerRadius, m_Color);
- vline(drawScreen, drawEndLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY() + m_CornerRadius, drawEndLeft.GetFloorIntY() - m_CornerRadius, m_Color);
-
- arc(drawScreen, drawStartRight.GetFloorIntX() + m_CornerRadius, drawStartRight.GetFloorIntY() + m_CornerRadius, itofix(64), itofix(128), m_CornerRadius, m_Color);
- arc(drawScreen, drawStartRight.GetFloorIntX() + m_CornerRadius, drawEndRight.GetFloorIntY() - m_CornerRadius, itofix(128), itofix(-64), m_CornerRadius, m_Color);
- arc(drawScreen, drawEndRight.GetFloorIntX() - m_CornerRadius, drawStartRight.GetFloorIntY() + m_CornerRadius, itofix(0), itofix(64), m_CornerRadius, m_Color);
- arc(drawScreen, drawEndRight.GetFloorIntX() - m_CornerRadius, drawEndRight.GetFloorIntY() - m_CornerRadius, itofix(-64), itofix(0), m_CornerRadius, m_Color);
- hline(drawScreen, drawStartRight.GetFloorIntX() + m_CornerRadius, drawStartRight.GetFloorIntY(), drawEndRight.GetFloorIntX() - m_CornerRadius, m_Color);
- hline(drawScreen, drawStartRight.GetFloorIntX() + m_CornerRadius, drawEndRight.GetFloorIntY(), drawEndRight.GetFloorIntX() - m_CornerRadius, m_Color);
- vline(drawScreen, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY() + m_CornerRadius, drawEndRight.GetFloorIntY() - m_CornerRadius, m_Color);
- vline(drawScreen, drawEndRight.GetFloorIntX(), drawStartRight.GetFloorIntY() + m_CornerRadius, drawEndRight.GetFloorIntY() - m_CornerRadius, m_Color);
- }
-}
-
-void RoundedBoxFillPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (m_StartPos.m_X > m_EndPos.m_X) {
- std::swap(m_StartPos.m_X, m_EndPos.m_X);
- }
- if (m_StartPos.m_Y > m_EndPos.m_Y) {
- std::swap(m_StartPos.m_Y, m_EndPos.m_Y);
- }
-
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos;
- Vector drawEnd = m_EndPos - targetPos;
-
- circlefill(drawScreen, drawStart.GetFloorIntX() + m_CornerRadius, drawStart.GetFloorIntY() + m_CornerRadius, m_CornerRadius, m_Color);
- circlefill(drawScreen, drawStart.GetFloorIntX() + m_CornerRadius, drawEnd.GetFloorIntY() - m_CornerRadius, m_CornerRadius, m_Color);
- circlefill(drawScreen, drawEnd.GetFloorIntX() - m_CornerRadius, drawStart.GetFloorIntY() + m_CornerRadius, m_CornerRadius, m_Color);
- circlefill(drawScreen, drawEnd.GetFloorIntX() - m_CornerRadius, drawEnd.GetFloorIntY() - m_CornerRadius, m_CornerRadius, m_Color);
-
- rectfill(drawScreen, drawStart.GetFloorIntX(), drawStart.GetFloorIntY() + m_CornerRadius, drawEnd.GetFloorIntX(), drawEnd.GetFloorIntY() - m_CornerRadius, m_Color);
- rectfill(drawScreen, drawStart.GetFloorIntX() + m_CornerRadius, drawStart.GetFloorIntY(), drawEnd.GetFloorIntX() - m_CornerRadius, drawEnd.GetFloorIntY(), m_Color);
- } else {
- Vector drawStartLeft;
- Vector drawEndLeft;
- Vector drawStartRight;
- Vector drawEndRight;
-
- TranslateCoordinates(targetPos, m_StartPos, drawStartLeft, drawStartRight);
- TranslateCoordinates(targetPos, m_EndPos, drawEndLeft, drawEndRight);
-
- circlefill(drawScreen, drawStartLeft.GetFloorIntX() + m_CornerRadius, drawStartLeft.GetFloorIntY() + m_CornerRadius, m_CornerRadius, m_Color);
- circlefill(drawScreen, drawStartLeft.GetFloorIntX() + m_CornerRadius, drawEndLeft.GetFloorIntY() - m_CornerRadius, m_CornerRadius, m_Color);
- circlefill(drawScreen, drawEndLeft.GetFloorIntX() - m_CornerRadius, drawStartLeft.GetFloorIntY() + m_CornerRadius, m_CornerRadius, m_Color);
- circlefill(drawScreen, drawEndLeft.GetFloorIntX() - m_CornerRadius, drawEndLeft.GetFloorIntY() - m_CornerRadius, m_CornerRadius, m_Color);
- rectfill(drawScreen, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY() + m_CornerRadius, drawEndLeft.GetFloorIntX(), drawEndLeft.GetFloorIntY() - m_CornerRadius, m_Color);
- rectfill(drawScreen, drawStartLeft.GetFloorIntX() + m_CornerRadius, drawStartLeft.GetFloorIntY(), drawEndLeft.GetFloorIntX() - m_CornerRadius, drawEndLeft.GetFloorIntY(), m_Color);
-
- circlefill(drawScreen, drawStartRight.GetFloorIntX() + m_CornerRadius, drawStartRight.GetFloorIntY() + m_CornerRadius, m_CornerRadius, m_Color);
- circlefill(drawScreen, drawStartRight.GetFloorIntX() + m_CornerRadius, drawEndRight.GetFloorIntY() - m_CornerRadius, m_CornerRadius, m_Color);
- circlefill(drawScreen, drawEndRight.GetFloorIntX() - m_CornerRadius, drawStartRight.GetFloorIntY() + m_CornerRadius, m_CornerRadius, m_Color);
- circlefill(drawScreen, drawEndRight.GetFloorIntX() - m_CornerRadius, drawEndRight.GetFloorIntY() - m_CornerRadius, m_CornerRadius, m_Color);
- rectfill(drawScreen, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY() + m_CornerRadius, drawEndRight.GetFloorIntX(), drawEndRight.GetFloorIntY() - m_CornerRadius, m_Color);
- rectfill(drawScreen, drawStartRight.GetFloorIntX() + m_CornerRadius, drawStartRight.GetFloorIntY(), drawEndRight.GetFloorIntX() - m_CornerRadius, drawEndRight.GetFloorIntY(), m_Color);
- }
-}
-
-void CirclePrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos;
- circle(drawScreen, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), m_Radius, m_Color);
- } else {
- Vector drawStartLeft;
- Vector drawStartRight;
-
- TranslateCoordinates(targetPos, m_StartPos, drawStartLeft, drawStartRight);
-
- circle(drawScreen, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), m_Radius, m_Color);
- circle(drawScreen, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), m_Radius, m_Color);
- }
-}
-
-void CircleFillPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos;
- circlefill(drawScreen, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), m_Radius, m_Color);
- } else {
- Vector drawStartLeft;
- Vector drawStartRight;
-
- TranslateCoordinates(targetPos, m_StartPos, drawStartLeft, drawStartRight);
-
- circlefill(drawScreen, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), m_Radius, m_Color);
- circlefill(drawScreen, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), m_Radius, m_Color);
- }
-}
-
-void EllipsePrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos;
- ellipse(drawScreen, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), m_HorizRadius, m_VertRadius, m_Color);
- } else {
- Vector drawStartLeft;
- Vector drawStartRight;
-
- TranslateCoordinates(targetPos, m_StartPos, drawStartLeft, drawStartRight);
-
- ellipse(drawScreen, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), m_HorizRadius, m_VertRadius, m_Color);
- ellipse(drawScreen, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), m_HorizRadius, m_VertRadius, m_Color);
- }
-}
-
-void EllipseFillPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos;
- ellipsefill(drawScreen, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), m_HorizRadius, m_VertRadius, m_Color);
- } else {
- Vector drawStartLeft;
- Vector drawStartRight;
-
- TranslateCoordinates(targetPos, m_StartPos, drawStartLeft, drawStartRight);
-
- ellipsefill(drawScreen, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), m_HorizRadius, m_VertRadius, m_Color);
- ellipsefill(drawScreen, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), m_HorizRadius, m_VertRadius, m_Color);
- }
-}
-
-void TrianglePrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawPointA = m_PointAPos - targetPos;
- Vector drawPointB = m_PointBPos - targetPos;
- Vector drawPointC = m_PointCPos - targetPos;
- line(drawScreen, drawPointA.GetFloorIntX(), drawPointA.GetFloorIntY(), drawPointB.GetFloorIntX(), drawPointB.GetFloorIntY(), m_Color);
- line(drawScreen, drawPointB.GetFloorIntX(), drawPointB.GetFloorIntY(), drawPointC.GetFloorIntX(), drawPointC.GetFloorIntY(), m_Color);
- line(drawScreen, drawPointC.GetFloorIntX(), drawPointC.GetFloorIntY(), drawPointA.GetFloorIntX(), drawPointA.GetFloorIntY(), m_Color);
- } else {
- Vector drawPointALeft;
- Vector drawPointBLeft;
- Vector drawPointCLeft;
- Vector drawPointARight;
- Vector drawPointBRight;
- Vector drawPointCRight;
-
- TranslateCoordinates(targetPos, m_PointAPos, drawPointALeft, drawPointARight);
- TranslateCoordinates(targetPos, m_PointBPos, drawPointBLeft, drawPointBRight);
- TranslateCoordinates(targetPos, m_PointCPos, drawPointCLeft, drawPointCRight);
-
- line(drawScreen, drawPointALeft.GetFloorIntX(), drawPointALeft.GetFloorIntY(), drawPointBLeft.GetFloorIntX(), drawPointBLeft.GetFloorIntY(), m_Color);
- line(drawScreen, drawPointARight.GetFloorIntX(), drawPointARight.GetFloorIntY(), drawPointBRight.GetFloorIntX(), drawPointBRight.GetFloorIntY(), m_Color);
- line(drawScreen, drawPointBLeft.GetFloorIntX(), drawPointBLeft.GetFloorIntY(), drawPointCLeft.GetFloorIntX(), drawPointCLeft.GetFloorIntY(), m_Color);
- line(drawScreen, drawPointBRight.GetFloorIntX(), drawPointBRight.GetFloorIntY(), drawPointCRight.GetFloorIntX(), drawPointCRight.GetFloorIntY(), m_Color);
- line(drawScreen, drawPointCLeft.GetFloorIntX(), drawPointCLeft.GetFloorIntY(), drawPointALeft.GetFloorIntX(), drawPointALeft.GetFloorIntY(), m_Color);
- line(drawScreen, drawPointCRight.GetFloorIntX(), drawPointCRight.GetFloorIntY(), drawPointARight.GetFloorIntX(), drawPointARight.GetFloorIntY(), m_Color);
- }
-}
-
-void TriangleFillPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawPointA = m_PointAPos - targetPos;
- Vector drawPointB = m_PointBPos - targetPos;
- Vector drawPointC = m_PointCPos - targetPos;
- triangle(drawScreen, drawPointA.GetFloorIntX(), drawPointA.GetFloorIntY(), drawPointB.GetFloorIntX(), drawPointB.GetFloorIntY(), drawPointC.GetFloorIntX(), drawPointC.GetFloorIntY(), m_Color);
- } else {
- Vector drawPointALeft;
- Vector drawPointBLeft;
- Vector drawPointCLeft;
- Vector drawPointARight;
- Vector drawPointBRight;
- Vector drawPointCRight;
-
- TranslateCoordinates(targetPos, m_PointAPos, drawPointALeft, drawPointARight);
- TranslateCoordinates(targetPos, m_PointBPos, drawPointBLeft, drawPointBRight);
- TranslateCoordinates(targetPos, m_PointCPos, drawPointCLeft, drawPointCRight);
-
- triangle(drawScreen, drawPointALeft.GetFloorIntX(), drawPointALeft.GetFloorIntY(), drawPointBLeft.GetFloorIntX(), drawPointBLeft.GetFloorIntY(), drawPointCLeft.GetFloorIntX(), drawPointCLeft.GetFloorIntY(), m_Color);
- triangle(drawScreen, drawPointARight.GetFloorIntX(), drawPointARight.GetFloorIntY(), drawPointBRight.GetFloorIntX(), drawPointBRight.GetFloorIntY(), drawPointCRight.GetFloorIntX(), drawPointCRight.GetFloorIntY(), m_Color);
- }
-}
-
-void PolygonPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart;
- Vector drawEnd;
- for (int i = 0; i < m_Vertices.size(); ++i) {
- drawStart = m_StartPos - targetPos + (*m_Vertices[i]);
- drawEnd = m_StartPos - targetPos + ((i + 1 < m_Vertices.size()) ? *m_Vertices[i + 1] : *m_Vertices[0]);
- line(drawScreen, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), drawEnd.GetFloorIntX(), drawEnd.GetFloorIntY(), m_Color);
- }
- } else {
- Vector drawStartLeft;
- Vector drawStartRight;
- Vector drawEndLeft;
- Vector drawEndRight;
- for (int i = 0; i < m_Vertices.size(); ++i) {
- TranslateCoordinates(targetPos, m_StartPos + (*m_Vertices[i]), drawStartLeft, drawStartRight);
- TranslateCoordinates(targetPos, m_StartPos + ((i + 1 < m_Vertices.size()) ? *m_Vertices[i + 1] : *m_Vertices[0]), drawEndLeft, drawEndRight);
-
- line(drawScreen, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), drawEndLeft.GetFloorIntX(), drawEndLeft.GetFloorIntY(), m_Color);
- line(drawScreen, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), drawEndRight.GetFloorIntX(), drawEndRight.GetFloorIntY(), m_Color);
- }
- }
-}
-
-void PolygonFillPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- size_t drawPointsSize = m_Vertices.size() * 2;
-
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos;
-
- std::vector drawPoints = {};
- drawPoints.reserve(drawPointsSize);
-
- for (const Vector* vertice: m_Vertices) {
- drawPoints.insert(drawPoints.end(), {drawStart.GetFloorIntX() + vertice->GetFloorIntX(), drawStart.GetFloorIntY() + vertice->GetFloorIntY()});
- }
- polygon(drawScreen, m_Vertices.size(), drawPoints.data(), m_Color);
- } else {
- std::vector drawPointsLeft = {};
- drawPointsLeft.reserve(drawPointsSize);
-
- std::vector drawPointsRight = {};
- drawPointsRight.reserve(drawPointsSize);
-
- Vector drawPointLeft;
- Vector drawPointRight;
- for (const Vector* vertice: m_Vertices) {
- TranslateCoordinates(targetPos, m_StartPos + (*vertice), drawPointLeft, drawPointRight);
-
- drawPointsLeft.insert(drawPointsLeft.end(), {drawPointLeft.GetFloorIntX(), drawPointLeft.GetFloorIntY()});
- drawPointsRight.insert(drawPointsRight.end(), {drawPointRight.GetFloorIntX(), drawPointRight.GetFloorIntY()});
- }
- polygon(drawScreen, m_Vertices.size(), drawPointsLeft.data(), m_Color);
- polygon(drawScreen, m_Vertices.size(), drawPointsRight.data(), m_Color);
- }
-}
-
-void TextPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (m_Text.empty()) {
- return;
- }
-
- AllegroBitmap playerGUIBitmap(drawScreen);
- GUIFont* font = m_IsSmall ? g_FrameMan.GetSmallFont() : g_FrameMan.GetLargeFont();
- Matrix rotation = Matrix(m_RotAngle);
- Vector targetPosAdjustment = Vector();
-
- BITMAP* tempDrawBitmap = nullptr;
- if (m_BlendMode > DrawBlendMode::NoBlend || m_RotAngle != 0) {
- int textWidth = font->CalculateWidth(m_Text);
- int textHeight = font->CalculateHeight(m_Text);
-
- tempDrawBitmap = create_bitmap_ex(8, textWidth * 2, textHeight);
- clear_to_color(tempDrawBitmap, ColorKeys::g_MaskColor);
- AllegroBitmap tempDrawAllegroBitmap(tempDrawBitmap);
- font->DrawAligned(&tempDrawAllegroBitmap, textWidth, 0, m_Text, m_Alignment);
-
- targetPosAdjustment = Vector(static_cast(textWidth), 0);
- }
-
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos - targetPosAdjustment;
-
- if (m_BlendMode > DrawBlendMode::NoBlend) {
- if (m_RotAngle != 0) {
- rotate_sprite_trans(drawScreen, tempDrawBitmap, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), ftofix(rotation.GetAllegroAngle()));
- } else {
- draw_trans_sprite(drawScreen, tempDrawBitmap, drawStart.GetFloorIntX(), drawStart.GetFloorIntY());
- }
- } else {
- if (m_RotAngle != 0) {
- rotate_sprite(drawScreen, tempDrawBitmap, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), ftofix(rotation.GetAllegroAngle()));
- } else {
- font->DrawAligned(&playerGUIBitmap, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), m_Text, m_Alignment);
- }
- }
- } else {
- Vector drawStartLeft;
- Vector drawStartRight;
-
- TranslateCoordinates(targetPos - targetPosAdjustment, m_StartPos, drawStartLeft, drawStartRight);
-
- if (m_BlendMode > DrawBlendMode::NoBlend) {
- if (m_RotAngle != 0) {
- rotate_sprite_trans(drawScreen, tempDrawBitmap, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), ftofix(rotation.GetAllegroAngle()));
- rotate_sprite_trans(drawScreen, tempDrawBitmap, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), ftofix(rotation.GetAllegroAngle()));
- } else {
- draw_trans_sprite(drawScreen, tempDrawBitmap, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY());
- draw_trans_sprite(drawScreen, tempDrawBitmap, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY());
- }
- } else {
- if (m_RotAngle != 0) {
- rotate_sprite(drawScreen, tempDrawBitmap, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), ftofix(rotation.GetAllegroAngle()));
- rotate_sprite(drawScreen, tempDrawBitmap, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), ftofix(rotation.GetAllegroAngle()));
- } else {
- font->DrawAligned(&playerGUIBitmap, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), m_Text, m_Alignment);
- font->DrawAligned(&playerGUIBitmap, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), m_Text, m_Alignment);
- }
- }
- }
- if (tempDrawBitmap) {
- destroy_bitmap(tempDrawBitmap);
- }
-}
-
-void BitmapPrimitive::Draw(BITMAP* drawScreen, const Vector& targetPos) {
- if (!m_Bitmap) {
- return;
- }
-
- BITMAP* bitmapToDraw = create_bitmap_ex(8, m_Bitmap->w * m_Scale, m_Bitmap->h * m_Scale);
- clear_to_color(bitmapToDraw, ColorKeys::g_MaskColor);
- if (m_Scale == 1.0f) {
- draw_sprite(bitmapToDraw, m_Bitmap, 0, 0);
- } else {
- stretch_sprite(bitmapToDraw, m_Bitmap, 0, 0, m_Bitmap->w * m_Scale, m_Bitmap->h * m_Scale);
- }
-
- if (m_HFlipped || m_VFlipped) {
- BITMAP* flipBitmap = create_bitmap_ex(8, bitmapToDraw->w, bitmapToDraw->h);
- clear_to_color(flipBitmap, ColorKeys::g_MaskColor);
-
- if (m_HFlipped && !m_VFlipped) {
- draw_sprite_h_flip(flipBitmap, bitmapToDraw, 0, 0);
- } else if (!m_HFlipped && m_VFlipped) {
- draw_sprite_v_flip(flipBitmap, bitmapToDraw, 0, 0);
- } else if (m_HFlipped && m_VFlipped) {
- draw_sprite_vh_flip(flipBitmap, bitmapToDraw, 0, 0);
- }
-
- blit(flipBitmap, bitmapToDraw, 0, 0, 0, 0, bitmapToDraw->w, bitmapToDraw->h);
- destroy_bitmap(flipBitmap);
- }
-
- Matrix rotation = Matrix(m_RotAngle);
-
- if (!g_SceneMan.SceneWrapsX() && !g_SceneMan.SceneWrapsY()) {
- Vector drawStart = m_StartPos - targetPos;
- if (m_BlendMode > DrawBlendMode::NoBlend) {
- pivot_scaled_sprite_trans(drawScreen, bitmapToDraw, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), bitmapToDraw->w / 2, bitmapToDraw->h / 2, ftofix(rotation.GetAllegroAngle()), ftofix(1.0));
- } else {
- pivot_scaled_sprite(drawScreen, bitmapToDraw, drawStart.GetFloorIntX(), drawStart.GetFloorIntY(), bitmapToDraw->w / 2, bitmapToDraw->h / 2, ftofix(rotation.GetAllegroAngle()), ftofix(1.0));
- }
- } else {
- Vector drawStartLeft;
- Vector drawStartRight;
-
- TranslateCoordinates(targetPos, m_StartPos, drawStartLeft, drawStartRight);
-
- // Take into account the h-flipped pivot point
- if (m_BlendMode > DrawBlendMode::NoBlend) {
- pivot_scaled_sprite_trans(drawScreen, bitmapToDraw, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), bitmapToDraw->w / 2, bitmapToDraw->h / 2, ftofix(rotation.GetAllegroAngle()), ftofix(1.0));
- pivot_scaled_sprite_trans(drawScreen, bitmapToDraw, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), bitmapToDraw->w / 2, bitmapToDraw->h / 2, ftofix(rotation.GetAllegroAngle()), ftofix(1.0));
- } else {
- pivot_scaled_sprite(drawScreen, bitmapToDraw, drawStartLeft.GetFloorIntX(), drawStartLeft.GetFloorIntY(), bitmapToDraw->w / 2, bitmapToDraw->h / 2, ftofix(rotation.GetAllegroAngle()), ftofix(1.0));
- pivot_scaled_sprite(drawScreen, bitmapToDraw, drawStartRight.GetFloorIntX(), drawStartRight.GetFloorIntY(), bitmapToDraw->w / 2, bitmapToDraw->h / 2, ftofix(rotation.GetAllegroAngle()), ftofix(1.0));
- }
- }
- destroy_bitmap(bitmapToDraw);
-}
diff --git a/Source/System/RTEError.cpp b/Source/System/RTEError.cpp
index f8c7164ddc..619088b341 100644
--- a/Source/System/RTEError.cpp
+++ b/Source/System/RTEError.cpp
@@ -434,9 +434,20 @@ void RTEError::DumpHardwareInfo() {
std::string glVersion = reinterpret_cast(glGetString(GL_VERSION));
std::string glVendor = reinterpret_cast(glGetString(GL_VENDOR));
std::string glRenderer = reinterpret_cast(glGetString(GL_RENDERER));
+
+ std::string glExtentions = "";
+ GLint numExt = 0;
+ glGetIntegerv(GL_NUM_EXTENSIONS, &numExt);
+ for(GLint i = 0; i < numExt; i++) {
+ glExtentions += "\t";
+ glExtentions += reinterpret_cast(glGetStringi(GL_EXTENSIONS, i));
+ glExtentions += "\n";
+ }
+
std::string hwInfo = "GL Version: " + glVersion + "\n" +
"GL Vendor: " + glVendor + "\n" +
- "GL Renderer: " + glRenderer + "\n";
+ "GL Renderer: " + glRenderer + "\n" +
+ "Available Extensions: \n" + glExtentions + "\n";
#if defined(_MSC_VER) || defined(__linux__)
int vendorRegs[4] = {0};
diff --git a/Source/System/meson.build b/Source/System/meson.build
index 21e110a549..8128bb4645 100644
--- a/Source/System/meson.build
+++ b/Source/System/meson.build
@@ -10,7 +10,6 @@ sources += files(
'ContentFile.cpp',
'Controller.cpp',
'GenericSavedData.cpp',
-'GraphicalPrimitive.cpp',
'Writer.cpp',
'Box.cpp',
'Entity.cpp',
diff --git a/external/include/glad-2.0.0-beta/glad/gl.h b/external/include/glad-2.0.0-beta/glad/gl.h
index 53a0bc5888..10544d5689 100644
--- a/external/include/glad-2.0.0-beta/glad/gl.h
+++ b/external/include/glad-2.0.0-beta/glad/gl.h
@@ -1,14 +1,14 @@
/**
- * Loader generated by glad 2.0.8 on Tue Oct 29 11:42:04 2024
+ * Loader generated by glad 2.0.8 on Tue Mar 11 14:58:38 2025
*
* SPDX-License-Identifier: (WTFPL OR CC0-1.0) AND Apache-2.0
*
* Generator: C/C++
* Specification: gl
- * Extensions: 116
+ * Extensions: 115
*
* APIs:
- * - gl:core=4.3
+ * - gl:compatibility=4.3
*
* Options:
* - ALIAS = False
@@ -19,10 +19,10 @@
* - ON_DEMAND = False
*
* Commandline:
- * --api='gl:core=4.3' --extensions='GL_ARB_ES2_compatibility,GL_ARB_ES3_1_compatibility,GL_ARB_ES3_2_compatibility,GL_ARB_ES3_compatibility,GL_ARB_blend_func_extended,GL_ARB_buffer_storage,GL_ARB_clear_buffer_object,GL_ARB_clear_texture,GL_ARB_color_buffer_float,GL_ARB_compatibility,GL_ARB_compressed_texture_pixel_storage,GL_ARB_compute_shader,GL_ARB_compute_variable_group_size,GL_ARB_copy_buffer,GL_ARB_copy_image,GL_ARB_debug_output,GL_ARB_depth_buffer_float,GL_ARB_depth_clamp,GL_ARB_depth_texture,GL_ARB_direct_state_access,GL_ARB_draw_buffers,GL_ARB_draw_buffers_blend,GL_ARB_draw_elements_base_vertex,GL_ARB_draw_indirect,GL_ARB_draw_instanced,GL_ARB_enhanced_layouts,GL_ARB_explicit_attrib_location,GL_ARB_explicit_uniform_location,GL_ARB_fragment_coord_conventions,GL_ARB_fragment_layer_viewport,GL_ARB_fragment_program,GL_ARB_fragment_program_shadow,GL_ARB_fragment_shader,GL_ARB_fragment_shader_interlock,GL_ARB_framebuffer_no_attachments,GL_ARB_framebuffer_object,GL_ARB_framebuffer_sRGB,GL_ARB_geometry_shader4,GL_ARB_get_program_binary,GL_ARB_get_texture_sub_image,GL_ARB_gl_spirv,GL_ARB_gpu_shader5,GL_ARB_gpu_shader_fp64,GL_ARB_gpu_shader_int64,GL_ARB_half_float_pixel,GL_ARB_half_float_vertex,GL_ARB_instanced_arrays,GL_ARB_internalformat_query,GL_ARB_internalformat_query2,GL_ARB_map_buffer_range,GL_ARB_multi_bind,GL_ARB_multi_draw_indirect,GL_ARB_multisample,GL_ARB_multitexture,GL_ARB_occlusion_query,GL_ARB_occlusion_query2,GL_ARB_pipeline_statistics_query,GL_ARB_query_buffer_object,GL_ARB_sample_locations,GL_ARB_sample_shading,GL_ARB_seamless_cube_map,GL_ARB_seamless_cubemap_per_texture,GL_ARB_shader_atomic_counter_ops,GL_ARB_shader_atomic_counters,GL_ARB_shader_bit_encoding,GL_ARB_shader_clock,GL_ARB_shader_image_load_store,GL_ARB_shader_image_size,GL_ARB_shader_objects,GL_ARB_shader_storage_buffer_object,GL_ARB_shader_texture_lod,GL_ARB_shading_language_100,GL_ARB_shading_language_420pack,GL_ARB_shading_language_include,GL_ARB_shading_language_packing,GL_ARB_spirv_extensions,GL_ARB_tessellation_shader,GL_ARB_texture_border_clamp,GL_ARB_texture_buffer_object_rgb32,GL_ARB_texture_compression,GL_ARB_texture_cube_map,GL_ARB_texture_cube_map_array,GL_ARB_texture_env_add,GL_ARB_texture_filter_anisotropic,GL_ARB_texture_filter_minmax,GL_ARB_texture_float,GL_ARB_texture_mirror_clamp_to_edge,GL_ARB_texture_mirrored_repeat,GL_ARB_texture_multisample,GL_ARB_texture_non_power_of_two,GL_ARB_texture_rg,GL_ARB_texture_storage,GL_ARB_texture_swizzle,GL_ARB_texture_view,GL_ARB_timer_query,GL_ARB_transpose_matrix,GL_ARB_uniform_buffer_object,GL_ARB_vertex_array_bgra,GL_ARB_vertex_array_object,GL_ARB_vertex_attrib_binding,GL_ARB_vertex_buffer_object,GL_ARB_vertex_program,GL_ARB_vertex_shader,GL_EXT_draw_instanced,GL_EXT_fog_coord,GL_EXT_framebuffer_blit,GL_EXT_framebuffer_multisample,GL_EXT_framebuffer_object,GL_EXT_framebuffer_sRGB,GL_EXT_texture_compression_s3tc,GL_EXT_texture_filter_anisotropic,GL_EXT_texture_mirror_clamp,GL_KHR_texture_compression_astc_hdr,GL_KHR_texture_compression_astc_ldr,GL_OES_compressed_paletted_texture,GL_OES_fixed_point' c --debug
+ * --api='gl:compatibility=4.3' --extensions='GL_ARB_ES3_2_compatibility,GL_ARB_ES3_compatibility,GL_ARB_blend_func_extended,GL_ARB_buffer_storage,GL_ARB_clear_buffer_object,GL_ARB_clear_texture,GL_ARB_color_buffer_float,GL_ARB_compatibility,GL_ARB_compressed_texture_pixel_storage,GL_ARB_compute_shader,GL_ARB_compute_variable_group_size,GL_ARB_copy_buffer,GL_ARB_copy_image,GL_ARB_debug_output,GL_ARB_depth_buffer_float,GL_ARB_depth_clamp,GL_ARB_depth_texture,GL_ARB_direct_state_access,GL_ARB_draw_buffers,GL_ARB_draw_buffers_blend,GL_ARB_draw_elements_base_vertex,GL_ARB_draw_indirect,GL_ARB_draw_instanced,GL_ARB_enhanced_layouts,GL_ARB_explicit_attrib_location,GL_ARB_explicit_uniform_location,GL_ARB_fragment_coord_conventions,GL_ARB_fragment_layer_viewport,GL_ARB_fragment_program,GL_ARB_fragment_program_shadow,GL_ARB_fragment_shader,GL_ARB_fragment_shader_interlock,GL_ARB_framebuffer_no_attachments,GL_ARB_framebuffer_object,GL_ARB_framebuffer_sRGB,GL_ARB_geometry_shader4,GL_ARB_get_program_binary,GL_ARB_get_texture_sub_image,GL_ARB_gl_spirv,GL_ARB_gpu_shader5,GL_ARB_gpu_shader_fp64,GL_ARB_gpu_shader_int64,GL_ARB_half_float_pixel,GL_ARB_half_float_vertex,GL_ARB_instanced_arrays,GL_ARB_internalformat_query,GL_ARB_internalformat_query2,GL_ARB_map_buffer_range,GL_ARB_multi_bind,GL_ARB_multi_draw_indirect,GL_ARB_multisample,GL_ARB_multitexture,GL_ARB_occlusion_query,GL_ARB_occlusion_query2,GL_ARB_pipeline_statistics_query,GL_ARB_query_buffer_object,GL_ARB_sample_locations,GL_ARB_sample_shading,GL_ARB_seamless_cube_map,GL_ARB_seamless_cubemap_per_texture,GL_ARB_shader_atomic_counter_ops,GL_ARB_shader_atomic_counters,GL_ARB_shader_bit_encoding,GL_ARB_shader_clock,GL_ARB_shader_image_load_store,GL_ARB_shader_image_size,GL_ARB_shader_objects,GL_ARB_shader_storage_buffer_object,GL_ARB_shader_texture_lod,GL_ARB_shading_language_100,GL_ARB_shading_language_420pack,GL_ARB_shading_language_include,GL_ARB_shading_language_packing,GL_ARB_spirv_extensions,GL_ARB_tessellation_shader,GL_ARB_texture_border_clamp,GL_ARB_texture_buffer_object_rgb32,GL_ARB_texture_compression,GL_ARB_texture_cube_map,GL_ARB_texture_cube_map_array,GL_ARB_texture_env_add,GL_ARB_texture_filter_anisotropic,GL_ARB_texture_filter_minmax,GL_ARB_texture_float,GL_ARB_texture_mirror_clamp_to_edge,GL_ARB_texture_mirrored_repeat,GL_ARB_texture_multisample,GL_ARB_texture_non_power_of_two,GL_ARB_texture_rg,GL_ARB_texture_storage,GL_ARB_texture_swizzle,GL_ARB_texture_view,GL_ARB_timer_query,GL_ARB_transpose_matrix,GL_ARB_uniform_buffer_object,GL_ARB_vertex_array_bgra,GL_ARB_vertex_array_object,GL_ARB_vertex_attrib_binding,GL_ARB_vertex_buffer_object,GL_ARB_vertex_program,GL_ARB_vertex_shader,GL_EXT_draw_instanced,GL_EXT_fog_coord,GL_EXT_framebuffer_blit,GL_EXT_framebuffer_multisample,GL_EXT_framebuffer_object,GL_EXT_framebuffer_sRGB,GL_EXT_texture_compression_s3tc,GL_EXT_texture_filter_anisotropic,GL_EXT_texture_mirror_clamp,GL_KHR_blend_equation_advanced,GL_KHR_blend_equation_advanced_coherent,GL_KHR_debug,GL_KHR_texture_compression_astc_hdr,GL_KHR_texture_compression_astc_ldr' c --debug
*
* Online:
- * http://glad.sh/#api=gl%3Acore%3D4.3&generator=c&options=DEBUG
+ * http://glad.sh/#api=gl%3Acompatibility%3D4.3&generator=c&options=DEBUG
*
*/
@@ -176,6 +176,21 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#endif /* GLAD_PLATFORM_H_ */
+#define GL_2D 0x0600
+#define GL_2_BYTES 0x1407
+#define GL_3D 0x0601
+#define GL_3D_COLOR 0x0602
+#define GL_3D_COLOR_TEXTURE 0x0603
+#define GL_3_BYTES 0x1408
+#define GL_4D_COLOR_TEXTURE 0x0604
+#define GL_4_BYTES 0x1409
+#define GL_ACCUM 0x0100
+#define GL_ACCUM_ALPHA_BITS 0x0D5B
+#define GL_ACCUM_BLUE_BITS 0x0D5A
+#define GL_ACCUM_BUFFER_BIT 0x00000200
+#define GL_ACCUM_CLEAR_VALUE 0x0B80
+#define GL_ACCUM_GREEN_BITS 0x0D59
+#define GL_ACCUM_RED_BITS 0x0D58
#define GL_ACTIVE_ATOMIC_COUNTER_BUFFERS 0x92D9
#define GL_ACTIVE_ATTRIBUTES 0x8B89
#define GL_ACTIVE_ATTRIBUTE_MAX_LENGTH 0x8B8A
@@ -193,14 +208,31 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH 0x8A35
#define GL_ACTIVE_UNIFORM_MAX_LENGTH 0x8B87
#define GL_ACTIVE_VARIABLES 0x9305
+#define GL_ADD 0x0104
+#define GL_ADD_SIGNED 0x8574
#define GL_ALIASED_LINE_WIDTH_RANGE 0x846E
+#define GL_ALIASED_POINT_SIZE_RANGE 0x846D
+#define GL_ALL_ATTRIB_BITS 0xFFFFFFFF
#define GL_ALL_BARRIER_BITS 0xFFFFFFFF
#define GL_ALL_SHADER_BITS 0xFFFFFFFF
#define GL_ALPHA 0x1906
+#define GL_ALPHA12 0x803D
+#define GL_ALPHA16 0x803E
#define GL_ALPHA16F_ARB 0x881C
#define GL_ALPHA32F_ARB 0x8816
+#define GL_ALPHA4 0x803B
+#define GL_ALPHA8 0x803C
+#define GL_ALPHA_BIAS 0x0D1D
+#define GL_ALPHA_BITS 0x0D55
+#define GL_ALPHA_INTEGER 0x8D97
+#define GL_ALPHA_SCALE 0x0D1C
+#define GL_ALPHA_TEST 0x0BC0
+#define GL_ALPHA_TEST_FUNC 0x0BC1
+#define GL_ALPHA_TEST_REF 0x0BC2
#define GL_ALREADY_SIGNALED 0x911A
#define GL_ALWAYS 0x0207
+#define GL_AMBIENT 0x1200
+#define GL_AMBIENT_AND_DIFFUSE 0x1602
#define GL_AND 0x1501
#define GL_AND_INVERTED 0x1504
#define GL_AND_REVERSE 0x1502
@@ -228,7 +260,14 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_ATOMIC_COUNTER_BUFFER_SIZE 0x92C3
#define GL_ATOMIC_COUNTER_BUFFER_START 0x92C2
#define GL_ATTACHED_SHADERS 0x8B85
+#define GL_ATTRIB_STACK_DEPTH 0x0BB0
#define GL_AUTO_GENERATE_MIPMAP 0x8295
+#define GL_AUTO_NORMAL 0x0D80
+#define GL_AUX0 0x0409
+#define GL_AUX1 0x040A
+#define GL_AUX2 0x040B
+#define GL_AUX3 0x040C
+#define GL_AUX_BUFFERS 0x0C00
#define GL_BACK 0x0405
#define GL_BACK_LEFT 0x0402
#define GL_BACK_RIGHT 0x0403
@@ -236,7 +275,10 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_BGRA 0x80E1
#define GL_BGRA_INTEGER 0x8D9B
#define GL_BGR_INTEGER 0x8D9A
+#define GL_BITMAP 0x1A00
+#define GL_BITMAP_TOKEN 0x0704
#define GL_BLEND 0x0BE2
+#define GL_BLEND_ADVANCED_COHERENT_KHR 0x9285
#define GL_BLEND_COLOR 0x8005
#define GL_BLEND_DST 0x0BE0
#define GL_BLEND_DST_ALPHA 0x80CA
@@ -249,7 +291,10 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_BLEND_SRC_RGB 0x80C9
#define GL_BLOCK_INDEX 0x92FD
#define GL_BLUE 0x1905
+#define GL_BLUE_BIAS 0x0D1B
+#define GL_BLUE_BITS 0x0D54
#define GL_BLUE_INTEGER 0x8D96
+#define GL_BLUE_SCALE 0x0D1A
#define GL_BOOL 0x8B56
#define GL_BOOL_ARB 0x8B56
#define GL_BOOL_VEC2 0x8B57
@@ -279,21 +324,33 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_BUFFER_USAGE_ARB 0x8765
#define GL_BUFFER_VARIABLE 0x92E5
#define GL_BYTE 0x1400
+#define GL_C3F_V3F 0x2A24
+#define GL_C4F_N3F_V3F 0x2A26
+#define GL_C4UB_V2F 0x2A22
+#define GL_C4UB_V3F 0x2A23
#define GL_CAVEAT_SUPPORT 0x82B8
#define GL_CCW 0x0901
+#define GL_CLAMP 0x2900
+#define GL_CLAMP_FRAGMENT_COLOR 0x891B
#define GL_CLAMP_FRAGMENT_COLOR_ARB 0x891B
#define GL_CLAMP_READ_COLOR 0x891C
#define GL_CLAMP_READ_COLOR_ARB 0x891C
#define GL_CLAMP_TO_BORDER 0x812D
#define GL_CLAMP_TO_BORDER_ARB 0x812D
#define GL_CLAMP_TO_EDGE 0x812F
+#define GL_CLAMP_VERTEX_COLOR 0x891A
#define GL_CLAMP_VERTEX_COLOR_ARB 0x891A
#define GL_CLEAR 0x1500
#define GL_CLEAR_BUFFER 0x82B4
#define GL_CLEAR_TEXTURE 0x9365
+#define GL_CLIENT_ACTIVE_TEXTURE 0x84E1
#define GL_CLIENT_ACTIVE_TEXTURE_ARB 0x84E1
+#define GL_CLIENT_ALL_ATTRIB_BITS 0xFFFFFFFF
+#define GL_CLIENT_ATTRIB_STACK_DEPTH 0x0BB1
#define GL_CLIENT_MAPPED_BUFFER_BARRIER_BIT 0x00004000
+#define GL_CLIENT_PIXEL_STORE_BIT 0x00000001
#define GL_CLIENT_STORAGE_BIT 0x0200
+#define GL_CLIENT_VERTEX_ARRAY_BIT 0x00000002
#define GL_CLIPPING_INPUT_PRIMITIVES 0x82F6
#define GL_CLIPPING_INPUT_PRIMITIVES_ARB 0x82F6
#define GL_CLIPPING_OUTPUT_PRIMITIVES 0x82F7
@@ -306,8 +363,23 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_CLIP_DISTANCE5 0x3005
#define GL_CLIP_DISTANCE6 0x3006
#define GL_CLIP_DISTANCE7 0x3007
+#define GL_CLIP_PLANE0 0x3000
+#define GL_CLIP_PLANE1 0x3001
+#define GL_CLIP_PLANE2 0x3002
+#define GL_CLIP_PLANE3 0x3003
+#define GL_CLIP_PLANE4 0x3004
+#define GL_CLIP_PLANE5 0x3005
+#define GL_COEFF 0x0A00
#define GL_COLOR 0x1800
+#define GL_COLORBURN_KHR 0x929A
+#define GL_COLORDODGE_KHR 0x9299
+#define GL_COLOR_ARRAY 0x8076
+#define GL_COLOR_ARRAY_BUFFER_BINDING 0x8898
#define GL_COLOR_ARRAY_BUFFER_BINDING_ARB 0x8898
+#define GL_COLOR_ARRAY_POINTER 0x8090
+#define GL_COLOR_ARRAY_SIZE 0x8081
+#define GL_COLOR_ARRAY_STRIDE 0x8083
+#define GL_COLOR_ARRAY_TYPE 0x8082
#define GL_COLOR_ATTACHMENT0 0x8CE0
#define GL_COLOR_ATTACHMENT0_EXT 0x8CE0
#define GL_COLOR_ATTACHMENT1 0x8CE1
@@ -360,16 +432,32 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_COLOR_CLEAR_VALUE 0x0C22
#define GL_COLOR_COMPONENTS 0x8283
#define GL_COLOR_ENCODING 0x8296
+#define GL_COLOR_INDEX 0x1900
+#define GL_COLOR_INDEXES 0x1603
#define GL_COLOR_LOGIC_OP 0x0BF2
+#define GL_COLOR_MATERIAL 0x0B57
+#define GL_COLOR_MATERIAL_FACE 0x0B55
+#define GL_COLOR_MATERIAL_PARAMETER 0x0B56
#define GL_COLOR_RENDERABLE 0x8286
+#define GL_COLOR_SUM 0x8458
#define GL_COLOR_SUM_ARB 0x8458
#define GL_COLOR_WRITEMASK 0x0C23
+#define GL_COMBINE 0x8570
+#define GL_COMBINE_ALPHA 0x8572
+#define GL_COMBINE_RGB 0x8571
#define GL_COMMAND_BARRIER_BIT 0x00000040
#define GL_COMPARE_REF_TO_TEXTURE 0x884E
+#define GL_COMPARE_R_TO_TEXTURE 0x884E
#define GL_COMPATIBLE_SUBROUTINES 0x8E4B
+#define GL_COMPILE 0x1300
+#define GL_COMPILE_AND_EXECUTE 0x1301
#define GL_COMPILE_STATUS 0x8B81
+#define GL_COMPRESSED_ALPHA 0x84E9
#define GL_COMPRESSED_ALPHA_ARB 0x84E9
+#define GL_COMPRESSED_INTENSITY 0x84EC
#define GL_COMPRESSED_INTENSITY_ARB 0x84EC
+#define GL_COMPRESSED_LUMINANCE 0x84EA
+#define GL_COMPRESSED_LUMINANCE_ALPHA 0x84EB
#define GL_COMPRESSED_LUMINANCE_ALPHA_ARB 0x84EB
#define GL_COMPRESSED_LUMINANCE_ARB 0x84EA
#define GL_COMPRESSED_R11_EAC 0x9270
@@ -410,6 +498,8 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_COMPRESSED_SIGNED_RED_RGTC1 0x8DBC
#define GL_COMPRESSED_SIGNED_RG11_EAC 0x9273
#define GL_COMPRESSED_SIGNED_RG_RGTC2 0x8DBE
+#define GL_COMPRESSED_SLUMINANCE 0x8C4A
+#define GL_COMPRESSED_SLUMINANCE_ALPHA 0x8C4B
#define GL_COMPRESSED_SRGB 0x8C48
#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x10_KHR 0x93DB
#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x5_KHR 0x93D8
@@ -441,7 +531,9 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_COMPUTE_TEXTURE 0x82A0
#define GL_COMPUTE_WORK_GROUP_SIZE 0x8267
#define GL_CONDITION_SATISFIED 0x911C
+#define GL_CONSTANT 0x8576
#define GL_CONSTANT_ALPHA 0x8003
+#define GL_CONSTANT_ATTENUATION 0x1207
#define GL_CONSTANT_COLOR 0x8001
#define GL_CONTEXT_COMPATIBILITY_PROFILE_BIT 0x00000002
#define GL_CONTEXT_CORE_PROFILE_BIT 0x00000001
@@ -449,23 +541,41 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_CONTEXT_FLAG_DEBUG_BIT 0x00000002
#define GL_CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT 0x00000001
#define GL_CONTEXT_PROFILE_MASK 0x9126
+#define GL_COORD_REPLACE 0x8862
#define GL_COPY 0x1503
#define GL_COPY_INVERTED 0x150C
+#define GL_COPY_PIXEL_TOKEN 0x0706
#define GL_COPY_READ_BUFFER 0x8F36
#define GL_COPY_READ_BUFFER_BINDING 0x8F36
#define GL_COPY_WRITE_BUFFER 0x8F37
#define GL_COPY_WRITE_BUFFER_BINDING 0x8F37
#define GL_CULL_FACE 0x0B44
#define GL_CULL_FACE_MODE 0x0B45
+#define GL_CURRENT_BIT 0x00000001
+#define GL_CURRENT_COLOR 0x0B00
+#define GL_CURRENT_FOG_COORD 0x8453
+#define GL_CURRENT_FOG_COORDINATE 0x8453
#define GL_CURRENT_FOG_COORDINATE_EXT 0x8453
+#define GL_CURRENT_INDEX 0x0B01
#define GL_CURRENT_MATRIX_ARB 0x8641
#define GL_CURRENT_MATRIX_STACK_DEPTH_ARB 0x8640
+#define GL_CURRENT_NORMAL 0x0B02
#define GL_CURRENT_PROGRAM 0x8B8D
#define GL_CURRENT_QUERY 0x8865
#define GL_CURRENT_QUERY_ARB 0x8865
+#define GL_CURRENT_RASTER_COLOR 0x0B04
+#define GL_CURRENT_RASTER_DISTANCE 0x0B09
+#define GL_CURRENT_RASTER_INDEX 0x0B05
+#define GL_CURRENT_RASTER_POSITION 0x0B07
+#define GL_CURRENT_RASTER_POSITION_VALID 0x0B08
+#define GL_CURRENT_RASTER_SECONDARY_COLOR 0x845F
+#define GL_CURRENT_RASTER_TEXTURE_COORDS 0x0B06
+#define GL_CURRENT_SECONDARY_COLOR 0x8459
+#define GL_CURRENT_TEXTURE_COORDS 0x0B03
#define GL_CURRENT_VERTEX_ATTRIB 0x8626
#define GL_CURRENT_VERTEX_ATTRIB_ARB 0x8626
#define GL_CW 0x0900
+#define GL_DARKEN_KHR 0x9297
#define GL_DEBUG_CALLBACK_FUNCTION 0x8244
#define GL_DEBUG_CALLBACK_FUNCTION_ARB 0x8244
#define GL_DEBUG_CALLBACK_USER_PARAM 0x8245
@@ -512,6 +622,7 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_DEBUG_TYPE_PUSH_GROUP 0x8269
#define GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR 0x824E
#define GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR_ARB 0x824E
+#define GL_DECAL 0x2101
#define GL_DECR 0x1E03
#define GL_DECR_WRAP 0x8508
#define GL_DELETE_STATUS 0x8B80
@@ -520,6 +631,8 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_DEPTH32F_STENCIL8 0x8CAD
#define GL_DEPTH_ATTACHMENT 0x8D00
#define GL_DEPTH_ATTACHMENT_EXT 0x8D00
+#define GL_DEPTH_BIAS 0x0D1F
+#define GL_DEPTH_BITS 0x0D56
#define GL_DEPTH_BUFFER_BIT 0x00000100
#define GL_DEPTH_CLAMP 0x864F
#define GL_DEPTH_CLEAR_VALUE 0x0B73
@@ -535,16 +648,24 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_DEPTH_FUNC 0x0B74
#define GL_DEPTH_RANGE 0x0B70
#define GL_DEPTH_RENDERABLE 0x8287
+#define GL_DEPTH_SCALE 0x0D1E
#define GL_DEPTH_STENCIL 0x84F9
#define GL_DEPTH_STENCIL_ATTACHMENT 0x821A
#define GL_DEPTH_STENCIL_TEXTURE_MODE 0x90EA
#define GL_DEPTH_TEST 0x0B71
+#define GL_DEPTH_TEXTURE_MODE 0x884B
#define GL_DEPTH_TEXTURE_MODE_ARB 0x884B
#define GL_DEPTH_WRITEMASK 0x0B72
+#define GL_DIFFERENCE_KHR 0x929E
+#define GL_DIFFUSE 0x1201
#define GL_DISPATCH_INDIRECT_BUFFER 0x90EE
#define GL_DISPATCH_INDIRECT_BUFFER_BINDING 0x90EF
+#define GL_DISPLAY_LIST 0x82E7
#define GL_DITHER 0x0BD0
+#define GL_DOMAIN 0x0A02
#define GL_DONT_CARE 0x1100
+#define GL_DOT3_RGB 0x86AE
+#define GL_DOT3_RGBA 0x86AF
#define GL_DOUBLE 0x140A
#define GL_DOUBLEBUFFER 0x0C32
#define GL_DOUBLE_MAT2 0x8F46
@@ -598,6 +719,7 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_DRAW_FRAMEBUFFER_EXT 0x8CA9
#define GL_DRAW_INDIRECT_BUFFER 0x8F3F
#define GL_DRAW_INDIRECT_BUFFER_BINDING 0x8F43
+#define GL_DRAW_PIXEL_TOKEN 0x0705
#define GL_DST_ALPHA 0x0304
#define GL_DST_COLOR 0x0306
#define GL_DYNAMIC_COPY 0x88EA
@@ -607,24 +729,41 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_DYNAMIC_READ 0x88E9
#define GL_DYNAMIC_READ_ARB 0x88E9
#define GL_DYNAMIC_STORAGE_BIT 0x0100
+#define GL_EDGE_FLAG 0x0B43
+#define GL_EDGE_FLAG_ARRAY 0x8079
+#define GL_EDGE_FLAG_ARRAY_BUFFER_BINDING 0x889B
#define GL_EDGE_FLAG_ARRAY_BUFFER_BINDING_ARB 0x889B
+#define GL_EDGE_FLAG_ARRAY_POINTER 0x8093
+#define GL_EDGE_FLAG_ARRAY_STRIDE 0x808C
#define GL_ELEMENT_ARRAY_BARRIER_BIT 0x00000002
#define GL_ELEMENT_ARRAY_BUFFER 0x8893
#define GL_ELEMENT_ARRAY_BUFFER_ARB 0x8893
#define GL_ELEMENT_ARRAY_BUFFER_BINDING 0x8895
#define GL_ELEMENT_ARRAY_BUFFER_BINDING_ARB 0x8895
+#define GL_EMISSION 0x1600
+#define GL_ENABLE_BIT 0x00002000
#define GL_EQUAL 0x0202
#define GL_EQUIV 0x1509
+#define GL_EVAL_BIT 0x00010000
+#define GL_EXCLUSION_KHR 0x92A0
+#define GL_EXP 0x0800
+#define GL_EXP2 0x0801
#define GL_EXTENSIONS 0x1F03
+#define GL_EYE_LINEAR 0x2400
+#define GL_EYE_PLANE 0x2502
#define GL_FALSE 0
#define GL_FASTEST 0x1101
+#define GL_FEEDBACK 0x1C01
+#define GL_FEEDBACK_BUFFER_POINTER 0x0DF0
+#define GL_FEEDBACK_BUFFER_SIZE 0x0DF1
+#define GL_FEEDBACK_BUFFER_TYPE 0x0DF2
#define GL_FILL 0x1B02
#define GL_FILTER 0x829A
#define GL_FIRST_VERTEX_CONVENTION 0x8E4D
#define GL_FIXED 0x140C
-#define GL_FIXED_OES 0x140C
#define GL_FIXED_ONLY 0x891D
#define GL_FIXED_ONLY_ARB 0x891D
+#define GL_FLAT 0x1D00
#define GL_FLOAT 0x1406
#define GL_FLOAT_32_UNSIGNED_INT_24_8_REV 0x8DAD
#define GL_FLOAT_MAT2 0x8B5A
@@ -645,15 +784,39 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_FLOAT_VEC3_ARB 0x8B51
#define GL_FLOAT_VEC4 0x8B52
#define GL_FLOAT_VEC4_ARB 0x8B52
+#define GL_FOG 0x0B60
+#define GL_FOG_BIT 0x00000080
+#define GL_FOG_COLOR 0x0B66
+#define GL_FOG_COORD 0x8451
+#define GL_FOG_COORDINATE 0x8451
+#define GL_FOG_COORDINATE_ARRAY 0x8457
+#define GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING 0x889D
#define GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING_ARB 0x889D
#define GL_FOG_COORDINATE_ARRAY_EXT 0x8457
+#define GL_FOG_COORDINATE_ARRAY_POINTER 0x8456
#define GL_FOG_COORDINATE_ARRAY_POINTER_EXT 0x8456
+#define GL_FOG_COORDINATE_ARRAY_STRIDE 0x8455
#define GL_FOG_COORDINATE_ARRAY_STRIDE_EXT 0x8455
+#define GL_FOG_COORDINATE_ARRAY_TYPE 0x8454
#define GL_FOG_COORDINATE_ARRAY_TYPE_EXT 0x8454
#define GL_FOG_COORDINATE_EXT 0x8451
+#define GL_FOG_COORDINATE_SOURCE 0x8450
#define GL_FOG_COORDINATE_SOURCE_EXT 0x8450
+#define GL_FOG_COORD_ARRAY 0x8457
+#define GL_FOG_COORD_ARRAY_BUFFER_BINDING 0x889D
+#define GL_FOG_COORD_ARRAY_POINTER 0x8456
+#define GL_FOG_COORD_ARRAY_STRIDE 0x8455
+#define GL_FOG_COORD_ARRAY_TYPE 0x8454
+#define GL_FOG_COORD_SRC 0x8450
+#define GL_FOG_DENSITY 0x0B62
+#define GL_FOG_END 0x0B64
+#define GL_FOG_HINT 0x0C54
+#define GL_FOG_INDEX 0x0B61
+#define GL_FOG_MODE 0x0B65
+#define GL_FOG_START 0x0B63
#define GL_FRACTIONAL_EVEN 0x8E7C
#define GL_FRACTIONAL_ODD 0x8E7B
+#define GL_FRAGMENT_DEPTH 0x8452
#define GL_FRAGMENT_DEPTH_EXT 0x8452
#define GL_FRAGMENT_INTERPOLATION_OFFSET_BITS 0x8E5D
#define GL_FRAGMENT_PROGRAM_ARB 0x8804
@@ -735,6 +898,8 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_FUNC_ADD 0x8006
#define GL_FUNC_REVERSE_SUBTRACT 0x800B
#define GL_FUNC_SUBTRACT 0x800A
+#define GL_GENERATE_MIPMAP 0x8191
+#define GL_GENERATE_MIPMAP_HINT 0x8192
#define GL_GEOMETRY_INPUT_TYPE 0x8917
#define GL_GEOMETRY_INPUT_TYPE_ARB 0x8DDB
#define GL_GEOMETRY_OUTPUT_TYPE 0x8918
@@ -755,11 +920,20 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_GET_TEXTURE_IMAGE_TYPE 0x8292
#define GL_GREATER 0x0204
#define GL_GREEN 0x1904
+#define GL_GREEN_BIAS 0x0D19
+#define GL_GREEN_BITS 0x0D53
#define GL_GREEN_INTEGER 0x8D95
+#define GL_GREEN_SCALE 0x0D18
#define GL_HALF_FLOAT 0x140B
#define GL_HALF_FLOAT_ARB 0x140B
+#define GL_HARDLIGHT_KHR 0x929B
#define GL_HIGH_FLOAT 0x8DF2
#define GL_HIGH_INT 0x8DF5
+#define GL_HINT_BIT 0x00008000
+#define GL_HSL_COLOR_KHR 0x92AF
+#define GL_HSL_HUE_KHR 0x92AD
+#define GL_HSL_LUMINOSITY_KHR 0x92B0
+#define GL_HSL_SATURATION_KHR 0x92AE
#define GL_IMAGE_1D 0x904C
#define GL_IMAGE_1D_ARRAY 0x9052
#define GL_IMAGE_2D 0x904D
@@ -799,15 +973,33 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_IMPLEMENTATION_COLOR_READ_TYPE 0x8B9A
#define GL_INCR 0x1E02
#define GL_INCR_WRAP 0x8507
+#define GL_INDEX 0x8222
+#define GL_INDEX_ARRAY 0x8077
+#define GL_INDEX_ARRAY_BUFFER_BINDING 0x8899
#define GL_INDEX_ARRAY_BUFFER_BINDING_ARB 0x8899
+#define GL_INDEX_ARRAY_POINTER 0x8091
+#define GL_INDEX_ARRAY_STRIDE 0x8086
+#define GL_INDEX_ARRAY_TYPE 0x8085
+#define GL_INDEX_BITS 0x0D51
+#define GL_INDEX_CLEAR_VALUE 0x0C20
+#define GL_INDEX_LOGIC_OP 0x0BF1
+#define GL_INDEX_MODE 0x0C30
+#define GL_INDEX_OFFSET 0x0D13
+#define GL_INDEX_SHIFT 0x0D12
+#define GL_INDEX_WRITEMASK 0x0C21
#define GL_INFO_LOG_LENGTH 0x8B84
#define GL_INT 0x1404
#define GL_INT64_ARB 0x140E
#define GL_INT64_VEC2_ARB 0x8FE9
#define GL_INT64_VEC3_ARB 0x8FEA
#define GL_INT64_VEC4_ARB 0x8FEB
+#define GL_INTENSITY 0x8049
+#define GL_INTENSITY12 0x804C
+#define GL_INTENSITY16 0x804D
#define GL_INTENSITY16F_ARB 0x881D
#define GL_INTENSITY32F_ARB 0x8817
+#define GL_INTENSITY4 0x804A
+#define GL_INTENSITY8 0x804B
#define GL_INTERLEAVED_ATTRIBS 0x8C8C
#define GL_INTERNALFORMAT_ALPHA_SIZE 0x8274
#define GL_INTERNALFORMAT_ALPHA_TYPE 0x827B
@@ -824,6 +1016,7 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_INTERNALFORMAT_STENCIL_SIZE 0x8276
#define GL_INTERNALFORMAT_STENCIL_TYPE 0x827D
#define GL_INTERNALFORMAT_SUPPORTED 0x826F
+#define GL_INTERPOLATE 0x8575
#define GL_INT_2_10_10_10_REV 0x8D9F
#define GL_INT_IMAGE_1D 0x9057
#define GL_INT_IMAGE_1D_ARRAY 0x905D
@@ -870,42 +1063,106 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_LEFT 0x0406
#define GL_LEQUAL 0x0203
#define GL_LESS 0x0201
+#define GL_LIGHT0 0x4000
+#define GL_LIGHT1 0x4001
+#define GL_LIGHT2 0x4002
+#define GL_LIGHT3 0x4003
+#define GL_LIGHT4 0x4004
+#define GL_LIGHT5 0x4005
+#define GL_LIGHT6 0x4006
+#define GL_LIGHT7 0x4007
+#define GL_LIGHTEN_KHR 0x9298
+#define GL_LIGHTING 0x0B50
+#define GL_LIGHTING_BIT 0x00000040
+#define GL_LIGHT_MODEL_AMBIENT 0x0B53
+#define GL_LIGHT_MODEL_COLOR_CONTROL 0x81F8
+#define GL_LIGHT_MODEL_LOCAL_VIEWER 0x0B51
+#define GL_LIGHT_MODEL_TWO_SIDE 0x0B52
#define GL_LINE 0x1B01
#define GL_LINEAR 0x2601
+#define GL_LINEAR_ATTENUATION 0x1208
#define GL_LINEAR_MIPMAP_LINEAR 0x2703
#define GL_LINEAR_MIPMAP_NEAREST 0x2701
#define GL_LINES 0x0001
#define GL_LINES_ADJACENCY 0x000A
#define GL_LINES_ADJACENCY_ARB 0x000A
+#define GL_LINE_BIT 0x00000004
#define GL_LINE_LOOP 0x0002
+#define GL_LINE_RESET_TOKEN 0x0707
#define GL_LINE_SMOOTH 0x0B20
#define GL_LINE_SMOOTH_HINT 0x0C52
+#define GL_LINE_STIPPLE 0x0B24
+#define GL_LINE_STIPPLE_PATTERN 0x0B25
+#define GL_LINE_STIPPLE_REPEAT 0x0B26
#define GL_LINE_STRIP 0x0003
#define GL_LINE_STRIP_ADJACENCY 0x000B
#define GL_LINE_STRIP_ADJACENCY_ARB 0x000B
+#define GL_LINE_TOKEN 0x0702
#define GL_LINE_WIDTH 0x0B21
#define GL_LINE_WIDTH_GRANULARITY 0x0B23
#define GL_LINE_WIDTH_RANGE 0x0B22
#define GL_LINK_STATUS 0x8B82
+#define GL_LIST_BASE 0x0B32
+#define GL_LIST_BIT 0x00020000
+#define GL_LIST_INDEX 0x0B33
+#define GL_LIST_MODE 0x0B30
+#define GL_LOAD 0x0101
#define GL_LOCATION 0x930E
#define GL_LOCATION_COMPONENT 0x934A
#define GL_LOCATION_INDEX 0x930F
+#define GL_LOGIC_OP 0x0BF1
#define GL_LOGIC_OP_MODE 0x0BF0
#define GL_LOWER_LEFT 0x8CA1
#define GL_LOW_FLOAT 0x8DF0
#define GL_LOW_INT 0x8DF3
+#define GL_LUMINANCE 0x1909
+#define GL_LUMINANCE12 0x8041
+#define GL_LUMINANCE12_ALPHA12 0x8047
+#define GL_LUMINANCE12_ALPHA4 0x8046
+#define GL_LUMINANCE16 0x8042
#define GL_LUMINANCE16F_ARB 0x881E
+#define GL_LUMINANCE16_ALPHA16 0x8048
#define GL_LUMINANCE32F_ARB 0x8818
+#define GL_LUMINANCE4 0x803F
+#define GL_LUMINANCE4_ALPHA4 0x8043
+#define GL_LUMINANCE6_ALPHA2 0x8044
+#define GL_LUMINANCE8 0x8040
+#define GL_LUMINANCE8_ALPHA8 0x8045
+#define GL_LUMINANCE_ALPHA 0x190A
#define GL_LUMINANCE_ALPHA16F_ARB 0x881F
#define GL_LUMINANCE_ALPHA32F_ARB 0x8819
#define GL_MAJOR_VERSION 0x821B
#define GL_MANUAL_GENERATE_MIPMAP 0x8294
+#define GL_MAP1_COLOR_4 0x0D90
+#define GL_MAP1_GRID_DOMAIN 0x0DD0
+#define GL_MAP1_GRID_SEGMENTS 0x0DD1
+#define GL_MAP1_INDEX 0x0D91
+#define GL_MAP1_NORMAL 0x0D92
+#define GL_MAP1_TEXTURE_COORD_1 0x0D93
+#define GL_MAP1_TEXTURE_COORD_2 0x0D94
+#define GL_MAP1_TEXTURE_COORD_3 0x0D95
+#define GL_MAP1_TEXTURE_COORD_4 0x0D96
+#define GL_MAP1_VERTEX_3 0x0D97
+#define GL_MAP1_VERTEX_4 0x0D98
+#define GL_MAP2_COLOR_4 0x0DB0
+#define GL_MAP2_GRID_DOMAIN 0x0DD2
+#define GL_MAP2_GRID_SEGMENTS 0x0DD3
+#define GL_MAP2_INDEX 0x0DB1
+#define GL_MAP2_NORMAL 0x0DB2
+#define GL_MAP2_TEXTURE_COORD_1 0x0DB3
+#define GL_MAP2_TEXTURE_COORD_2 0x0DB4
+#define GL_MAP2_TEXTURE_COORD_3 0x0DB5
+#define GL_MAP2_TEXTURE_COORD_4 0x0DB6
+#define GL_MAP2_VERTEX_3 0x0DB7
+#define GL_MAP2_VERTEX_4 0x0DB8
#define GL_MAP_COHERENT_BIT 0x0080
+#define GL_MAP_COLOR 0x0D10
#define GL_MAP_FLUSH_EXPLICIT_BIT 0x0010
#define GL_MAP_INVALIDATE_BUFFER_BIT 0x0008
#define GL_MAP_INVALIDATE_RANGE_BIT 0x0004
#define GL_MAP_PERSISTENT_BIT 0x0040
#define GL_MAP_READ_BIT 0x0001
+#define GL_MAP_STENCIL 0x0D11
#define GL_MAP_UNSYNCHRONIZED_BIT 0x0020
#define GL_MAP_WRITE_BIT 0x0002
#define GL_MATRIX0_ARB 0x88C0
@@ -940,13 +1197,17 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_MATRIX7_ARB 0x88C7
#define GL_MATRIX8_ARB 0x88C8
#define GL_MATRIX9_ARB 0x88C9
+#define GL_MATRIX_MODE 0x0BA0
#define GL_MATRIX_STRIDE 0x92FF
#define GL_MAX 0x8008
#define GL_MAX_3D_TEXTURE_SIZE 0x8073
#define GL_MAX_ARRAY_TEXTURE_LAYERS 0x88FF
#define GL_MAX_ATOMIC_COUNTER_BUFFER_BINDINGS 0x92DC
#define GL_MAX_ATOMIC_COUNTER_BUFFER_SIZE 0x92D8
+#define GL_MAX_ATTRIB_STACK_DEPTH 0x0D35
+#define GL_MAX_CLIENT_ATTRIB_STACK_DEPTH 0x0D3B
#define GL_MAX_CLIP_DISTANCES 0x0D32
+#define GL_MAX_CLIP_PLANES 0x0D32
#define GL_MAX_COLOR_ATTACHMENTS 0x8CDF
#define GL_MAX_COLOR_ATTACHMENTS_EXT 0x8CDF
#define GL_MAX_COLOR_TEXTURE_SAMPLES 0x910E
@@ -996,6 +1257,7 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_MAX_ELEMENTS_INDICES 0x80E9
#define GL_MAX_ELEMENTS_VERTICES 0x80E8
#define GL_MAX_ELEMENT_INDEX 0x8D6B
+#define GL_MAX_EVAL_ORDER 0x0D30
#define GL_MAX_FRAGMENT_ATOMIC_COUNTERS 0x92D6
#define GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS 0x92D0
#define GL_MAX_FRAGMENT_IMAGE_UNIFORMS 0x90CE
@@ -1033,10 +1295,15 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_MAX_INTEGER_SAMPLES 0x9110
#define GL_MAX_LABEL_LENGTH 0x82E8
#define GL_MAX_LAYERS 0x8281
+#define GL_MAX_LIGHTS 0x0D31
+#define GL_MAX_LIST_NESTING 0x0B31
+#define GL_MAX_MODELVIEW_STACK_DEPTH 0x0D36
#define GL_MAX_NAME_LENGTH 0x92F6
+#define GL_MAX_NAME_STACK_DEPTH 0x0D37
#define GL_MAX_NUM_ACTIVE_VARIABLES 0x92F7
#define GL_MAX_NUM_COMPATIBLE_SUBROUTINES 0x92F8
#define GL_MAX_PATCH_VERTICES 0x8E7D
+#define GL_MAX_PIXEL_MAP_TABLE 0x0D34
#define GL_MAX_PROGRAM_ADDRESS_REGISTERS_ARB 0x88B1
#define GL_MAX_PROGRAM_ALU_INSTRUCTIONS_ARB 0x880B
#define GL_MAX_PROGRAM_ATTRIBS_ARB 0x88AD
@@ -1059,6 +1326,7 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET 0x8E5F
#define GL_MAX_PROGRAM_TEX_INDIRECTIONS_ARB 0x880D
#define GL_MAX_PROGRAM_TEX_INSTRUCTIONS_ARB 0x880C
+#define GL_MAX_PROJECTION_STACK_DEPTH 0x0D38
#define GL_MAX_RECTANGLE_TEXTURE_SIZE 0x84F8
#define GL_MAX_RENDERBUFFER_SIZE 0x84E8
#define GL_MAX_RENDERBUFFER_SIZE_EXT 0x84E8
@@ -1092,6 +1360,7 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_MAX_TESS_GEN_LEVEL 0x8E7E
#define GL_MAX_TESS_PATCH_COMPONENTS 0x8E84
#define GL_MAX_TEXTURE_BUFFER_SIZE 0x8C2B
+#define GL_MAX_TEXTURE_COORDS 0x8871
#define GL_MAX_TEXTURE_COORDS_ARB 0x8871
#define GL_MAX_TEXTURE_IMAGE_UNITS 0x8872
#define GL_MAX_TEXTURE_IMAGE_UNITS_ARB 0x8872
@@ -1099,6 +1368,8 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_MAX_TEXTURE_MAX_ANISOTROPY 0x84FF
#define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF
#define GL_MAX_TEXTURE_SIZE 0x0D33
+#define GL_MAX_TEXTURE_STACK_DEPTH 0x0D39
+#define GL_MAX_TEXTURE_UNITS 0x84E2
#define GL_MAX_TEXTURE_UNITS_ARB 0x84E2
#define GL_MAX_TRANSFORM_FEEDBACK_BUFFERS 0x8E70
#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS 0x8C8A
@@ -1148,14 +1419,23 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_MIRROR_CLAMP_TO_BORDER_EXT 0x8912
#define GL_MIRROR_CLAMP_TO_EDGE 0x8743
#define GL_MIRROR_CLAMP_TO_EDGE_EXT 0x8743
+#define GL_MODELVIEW 0x1700
+#define GL_MODELVIEW_MATRIX 0x0BA6
+#define GL_MODELVIEW_STACK_DEPTH 0x0BA3
+#define GL_MODULATE 0x2100
+#define GL_MULT 0x0103
+#define GL_MULTIPLY_KHR 0x9294
#define GL_MULTISAMPLE 0x809D
#define GL_MULTISAMPLE_ARB 0x809D
+#define GL_MULTISAMPLE_BIT 0x20000000
#define GL_MULTISAMPLE_BIT_ARB 0x20000000
#define GL_MULTISAMPLE_LINE_WIDTH_GRANULARITY_ARB 0x9382
#define GL_MULTISAMPLE_LINE_WIDTH_RANGE_ARB 0x9381
+#define GL_N3F_V3F 0x2A25
#define GL_NAMED_STRING_LENGTH_ARB 0x8DE9
#define GL_NAMED_STRING_TYPE_ARB 0x8DEA
#define GL_NAME_LENGTH 0x92F9
+#define GL_NAME_STACK_DEPTH 0x0D70
#define GL_NAND 0x150E
#define GL_NEAREST 0x2600
#define GL_NEAREST_MIPMAP_LINEAR 0x2702
@@ -1165,7 +1445,14 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_NONE 0
#define GL_NOOP 0x1505
#define GL_NOR 0x1508
+#define GL_NORMALIZE 0x0BA1
+#define GL_NORMAL_ARRAY 0x8075
+#define GL_NORMAL_ARRAY_BUFFER_BINDING 0x8897
#define GL_NORMAL_ARRAY_BUFFER_BINDING_ARB 0x8897
+#define GL_NORMAL_ARRAY_POINTER 0x808F
+#define GL_NORMAL_ARRAY_STRIDE 0x807F
+#define GL_NORMAL_ARRAY_TYPE 0x807E
+#define GL_NORMAL_MAP 0x8511
#define GL_NORMAL_MAP_ARB 0x8511
#define GL_NOTEQUAL 0x0205
#define GL_NO_ERROR 0
@@ -1187,7 +1474,9 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_OBJECT_COMPILE_STATUS_ARB 0x8B81
#define GL_OBJECT_DELETE_STATUS_ARB 0x8B80
#define GL_OBJECT_INFO_LOG_LENGTH_ARB 0x8B84
+#define GL_OBJECT_LINEAR 0x2401
#define GL_OBJECT_LINK_STATUS_ARB 0x8B82
+#define GL_OBJECT_PLANE 0x2501
#define GL_OBJECT_SHADER_SOURCE_LENGTH_ARB 0x8B88
#define GL_OBJECT_SUBTYPE_ARB 0x8B4F
#define GL_OBJECT_TYPE 0x9112
@@ -1203,10 +1492,18 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_ONE_MINUS_SRC1_COLOR 0x88FA
#define GL_ONE_MINUS_SRC_ALPHA 0x0303
#define GL_ONE_MINUS_SRC_COLOR 0x0301
+#define GL_OPERAND0_ALPHA 0x8598
+#define GL_OPERAND0_RGB 0x8590
+#define GL_OPERAND1_ALPHA 0x8599
+#define GL_OPERAND1_RGB 0x8591
+#define GL_OPERAND2_ALPHA 0x859A
+#define GL_OPERAND2_RGB 0x8592
#define GL_OR 0x1507
+#define GL_ORDER 0x0A01
#define GL_OR_INVERTED 0x150D
#define GL_OR_REVERSE 0x150B
#define GL_OUT_OF_MEMORY 0x0505
+#define GL_OVERLAY_KHR 0x9296
#define GL_PACK_ALIGNMENT 0x0D05
#define GL_PACK_COMPRESSED_BLOCK_DEPTH 0x912D
#define GL_PACK_COMPRESSED_BLOCK_HEIGHT 0x912C
@@ -1219,32 +1516,55 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_PACK_SKIP_PIXELS 0x0D04
#define GL_PACK_SKIP_ROWS 0x0D03
#define GL_PACK_SWAP_BYTES 0x0D00
-#define GL_PALETTE4_R5_G6_B5_OES 0x8B92
-#define GL_PALETTE4_RGB5_A1_OES 0x8B94
-#define GL_PALETTE4_RGB8_OES 0x8B90
-#define GL_PALETTE4_RGBA4_OES 0x8B93
-#define GL_PALETTE4_RGBA8_OES 0x8B91
-#define GL_PALETTE8_R5_G6_B5_OES 0x8B97
-#define GL_PALETTE8_RGB5_A1_OES 0x8B99
-#define GL_PALETTE8_RGB8_OES 0x8B95
-#define GL_PALETTE8_RGBA4_OES 0x8B98
-#define GL_PALETTE8_RGBA8_OES 0x8B96
+#define GL_PASS_THROUGH_TOKEN 0x0700
#define GL_PATCHES 0x000E
#define GL_PATCH_DEFAULT_INNER_LEVEL 0x8E73
#define GL_PATCH_DEFAULT_OUTER_LEVEL 0x8E74
#define GL_PATCH_VERTICES 0x8E72
+#define GL_PERSPECTIVE_CORRECTION_HINT 0x0C50
#define GL_PIXEL_BUFFER_BARRIER_BIT 0x00000080
+#define GL_PIXEL_MAP_A_TO_A 0x0C79
+#define GL_PIXEL_MAP_A_TO_A_SIZE 0x0CB9
+#define GL_PIXEL_MAP_B_TO_B 0x0C78
+#define GL_PIXEL_MAP_B_TO_B_SIZE 0x0CB8
+#define GL_PIXEL_MAP_G_TO_G 0x0C77
+#define GL_PIXEL_MAP_G_TO_G_SIZE 0x0CB7
+#define GL_PIXEL_MAP_I_TO_A 0x0C75
+#define GL_PIXEL_MAP_I_TO_A_SIZE 0x0CB5
+#define GL_PIXEL_MAP_I_TO_B 0x0C74
+#define GL_PIXEL_MAP_I_TO_B_SIZE 0x0CB4
+#define GL_PIXEL_MAP_I_TO_G 0x0C73
+#define GL_PIXEL_MAP_I_TO_G_SIZE 0x0CB3
+#define GL_PIXEL_MAP_I_TO_I 0x0C70
+#define GL_PIXEL_MAP_I_TO_I_SIZE 0x0CB0
+#define GL_PIXEL_MAP_I_TO_R 0x0C72
+#define GL_PIXEL_MAP_I_TO_R_SIZE 0x0CB2
+#define GL_PIXEL_MAP_R_TO_R 0x0C76
+#define GL_PIXEL_MAP_R_TO_R_SIZE 0x0CB6
+#define GL_PIXEL_MAP_S_TO_S 0x0C71
+#define GL_PIXEL_MAP_S_TO_S_SIZE 0x0CB1
+#define GL_PIXEL_MODE_BIT 0x00000020
#define GL_PIXEL_PACK_BUFFER 0x88EB
#define GL_PIXEL_PACK_BUFFER_BINDING 0x88ED
#define GL_PIXEL_UNPACK_BUFFER 0x88EC
#define GL_PIXEL_UNPACK_BUFFER_BINDING 0x88EF
#define GL_POINT 0x1B00
#define GL_POINTS 0x0000
+#define GL_POINT_BIT 0x00000002
+#define GL_POINT_DISTANCE_ATTENUATION 0x8129
#define GL_POINT_FADE_THRESHOLD_SIZE 0x8128
#define GL_POINT_SIZE 0x0B11
#define GL_POINT_SIZE_GRANULARITY 0x0B13
+#define GL_POINT_SIZE_MAX 0x8127
+#define GL_POINT_SIZE_MIN 0x8126
#define GL_POINT_SIZE_RANGE 0x0B12
+#define GL_POINT_SMOOTH 0x0B10
+#define GL_POINT_SMOOTH_HINT 0x0C51
+#define GL_POINT_SPRITE 0x8861
#define GL_POINT_SPRITE_COORD_ORIGIN 0x8CA0
+#define GL_POINT_TOKEN 0x0701
+#define GL_POLYGON 0x0009
+#define GL_POLYGON_BIT 0x00000008
#define GL_POLYGON_MODE 0x0B40
#define GL_POLYGON_OFFSET_FACTOR 0x8038
#define GL_POLYGON_OFFSET_FILL 0x8037
@@ -1253,6 +1573,12 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_POLYGON_OFFSET_UNITS 0x2A00
#define GL_POLYGON_SMOOTH 0x0B41
#define GL_POLYGON_SMOOTH_HINT 0x0C53
+#define GL_POLYGON_STIPPLE 0x0B42
+#define GL_POLYGON_STIPPLE_BIT 0x00000010
+#define GL_POLYGON_TOKEN 0x0703
+#define GL_POSITION 0x1203
+#define GL_PREVIOUS 0x8578
+#define GL_PRIMARY_COLOR 0x8577
#define GL_PRIMITIVES_GENERATED 0x8C87
#define GL_PRIMITIVES_SUBMITTED 0x82EF
#define GL_PRIMITIVES_SUBMITTED_ARB 0x82EF
@@ -1298,6 +1624,9 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_PROGRAM_TEX_INDIRECTIONS_ARB 0x8807
#define GL_PROGRAM_TEX_INSTRUCTIONS_ARB 0x8806
#define GL_PROGRAM_UNDER_NATIVE_LIMITS_ARB 0x88B6
+#define GL_PROJECTION 0x1701
+#define GL_PROJECTION_MATRIX 0x0BA7
+#define GL_PROJECTION_STACK_DEPTH 0x0BA4
#define GL_PROVOKING_VERTEX 0x8E4F
#define GL_PROXY_TEXTURE_1D 0x8063
#define GL_PROXY_TEXTURE_1D_ARRAY 0x8C19
@@ -1311,8 +1640,11 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_PROXY_TEXTURE_CUBE_MAP_ARRAY 0x900B
#define GL_PROXY_TEXTURE_CUBE_MAP_ARRAY_ARB 0x900B
#define GL_PROXY_TEXTURE_RECTANGLE 0x84F7
+#define GL_Q 0x2003
+#define GL_QUADRATIC_ATTENUATION 0x1209
#define GL_QUADS 0x0007
#define GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION 0x8E4C
+#define GL_QUAD_STRIP 0x0008
#define GL_QUERY 0x82E3
#define GL_QUERY_BUFFER 0x9192
#define GL_QUERY_BUFFER_BARRIER_BIT 0x00008000
@@ -1329,6 +1661,7 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_QUERY_RESULT_NO_WAIT 0x9194
#define GL_QUERY_TARGET 0x82EA
#define GL_QUERY_WAIT 0x8E13
+#define GL_R 0x2002
#define GL_R11F_G11F_B10F 0x8C3A
#define GL_R16 0x822A
#define GL_R16F 0x822D
@@ -1357,14 +1690,19 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_READ_WRITE 0x88BA
#define GL_READ_WRITE_ARB 0x88BA
#define GL_RED 0x1903
+#define GL_RED_BIAS 0x0D15
+#define GL_RED_BITS 0x0D52
#define GL_RED_INTEGER 0x8D94
+#define GL_RED_SCALE 0x0D14
#define GL_REFERENCED_BY_COMPUTE_SHADER 0x930B
#define GL_REFERENCED_BY_FRAGMENT_SHADER 0x930A
#define GL_REFERENCED_BY_GEOMETRY_SHADER 0x9309
#define GL_REFERENCED_BY_TESS_CONTROL_SHADER 0x9307
#define GL_REFERENCED_BY_TESS_EVALUATION_SHADER 0x9308
#define GL_REFERENCED_BY_VERTEX_SHADER 0x9306
+#define GL_REFLECTION_MAP 0x8512
#define GL_REFLECTION_MAP_ARB 0x8512
+#define GL_RENDER 0x1C00
#define GL_RENDERBUFFER 0x8D41
#define GL_RENDERBUFFER_ALPHA_SIZE 0x8D53
#define GL_RENDERBUFFER_ALPHA_SIZE_EXT 0x8D53
@@ -1390,8 +1728,11 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_RENDERBUFFER_WIDTH 0x8D42
#define GL_RENDERBUFFER_WIDTH_EXT 0x8D42
#define GL_RENDERER 0x1F01
+#define GL_RENDER_MODE 0x0C40
#define GL_REPEAT 0x2901
#define GL_REPLACE 0x1E01
+#define GL_RESCALE_NORMAL 0x803A
+#define GL_RETURN 0x0102
#define GL_RG 0x8227
#define GL_RG16 0x822C
#define GL_RG16F 0x822F
@@ -1449,9 +1790,12 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_RGBA8_SNORM 0x8F97
#define GL_RGBA_FLOAT_MODE_ARB 0x8820
#define GL_RGBA_INTEGER 0x8D99
+#define GL_RGBA_MODE 0x0C31
#define GL_RGB_INTEGER 0x8D98
+#define GL_RGB_SCALE 0x8573
#define GL_RG_INTEGER 0x8228
#define GL_RIGHT 0x0407
+#define GL_S 0x2000
#define GL_SAMPLER 0x82E6
#define GL_SAMPLER_1D 0x8B5D
#define GL_SAMPLER_1D_ARB 0x8B5D
@@ -1507,10 +1851,22 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_SAMPLE_POSITION 0x8E50
#define GL_SAMPLE_SHADING 0x8C36
#define GL_SAMPLE_SHADING_ARB 0x8C36
+#define GL_SCISSOR_BIT 0x00080000
#define GL_SCISSOR_BOX 0x0C10
#define GL_SCISSOR_TEST 0x0C11
+#define GL_SCREEN_KHR 0x9295
+#define GL_SECONDARY_COLOR_ARRAY 0x845E
+#define GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING 0x889C
#define GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING_ARB 0x889C
+#define GL_SECONDARY_COLOR_ARRAY_POINTER 0x845D
+#define GL_SECONDARY_COLOR_ARRAY_SIZE 0x845A
+#define GL_SECONDARY_COLOR_ARRAY_STRIDE 0x845C
+#define GL_SECONDARY_COLOR_ARRAY_TYPE 0x845B
+#define GL_SELECT 0x1C02
+#define GL_SELECTION_BUFFER_POINTER 0x0DF3
+#define GL_SELECTION_BUFFER_SIZE 0x0DF4
#define GL_SEPARATE_ATTRIBS 0x8C8D
+#define GL_SEPARATE_SPECULAR_COLOR 0x81FA
#define GL_SET 0x150F
#define GL_SHADER 0x82E1
#define GL_SHADER_BINARY_FORMATS 0x8DF8
@@ -1532,8 +1888,10 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_SHADER_STORAGE_BUFFER_SIZE 0x90D5
#define GL_SHADER_STORAGE_BUFFER_START 0x90D4
#define GL_SHADER_TYPE 0x8B4F
+#define GL_SHADE_MODEL 0x0B54
#define GL_SHADING_LANGUAGE_VERSION 0x8B8C
#define GL_SHADING_LANGUAGE_VERSION_ARB 0x8B8C
+#define GL_SHININESS 0x1601
#define GL_SHORT 0x1402
#define GL_SIGNALED 0x9119
#define GL_SIGNED_NORMALIZED 0x8F9C
@@ -1541,16 +1899,38 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_WRITE 0x82AE
#define GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_TEST 0x82AD
#define GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_WRITE 0x82AF
+#define GL_SINGLE_COLOR 0x81F9
+#define GL_SLUMINANCE 0x8C46
+#define GL_SLUMINANCE8 0x8C47
+#define GL_SLUMINANCE8_ALPHA8 0x8C45
+#define GL_SLUMINANCE_ALPHA 0x8C44
+#define GL_SMOOTH 0x1D01
#define GL_SMOOTH_LINE_WIDTH_GRANULARITY 0x0B23
#define GL_SMOOTH_LINE_WIDTH_RANGE 0x0B22
#define GL_SMOOTH_POINT_SIZE_GRANULARITY 0x0B13
#define GL_SMOOTH_POINT_SIZE_RANGE 0x0B12
+#define GL_SOFTLIGHT_KHR 0x929C
+#define GL_SOURCE0_ALPHA 0x8588
+#define GL_SOURCE0_RGB 0x8580
#define GL_SOURCE1_ALPHA 0x8589
+#define GL_SOURCE1_RGB 0x8581
+#define GL_SOURCE2_ALPHA 0x858A
+#define GL_SOURCE2_RGB 0x8582
+#define GL_SPECULAR 0x1202
+#define GL_SPHERE_MAP 0x2402
#define GL_SPIR_V_BINARY 0x9552
#define GL_SPIR_V_BINARY_ARB 0x9552
#define GL_SPIR_V_EXTENSIONS 0x9553
+#define GL_SPOT_CUTOFF 0x1206
+#define GL_SPOT_DIRECTION 0x1204
+#define GL_SPOT_EXPONENT 0x1205
+#define GL_SRC0_ALPHA 0x8588
+#define GL_SRC0_RGB 0x8580
#define GL_SRC1_ALPHA 0x8589
#define GL_SRC1_COLOR 0x88F9
+#define GL_SRC1_RGB 0x8581
+#define GL_SRC2_ALPHA 0x858A
+#define GL_SRC2_RGB 0x8582
#define GL_SRC_ALPHA 0x0302
#define GL_SRC_ALPHA_SATURATE 0x0308
#define GL_SRC_COLOR 0x0300
@@ -1579,6 +1959,7 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_STENCIL_BACK_REF 0x8CA3
#define GL_STENCIL_BACK_VALUE_MASK 0x8CA4
#define GL_STENCIL_BACK_WRITEMASK 0x8CA5
+#define GL_STENCIL_BITS 0x0D57
#define GL_STENCIL_BUFFER_BIT 0x00000400
#define GL_STENCIL_CLEAR_VALUE 0x0B91
#define GL_STENCIL_COMPONENTS 0x8285
@@ -1608,12 +1989,21 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_STREAM_READ 0x88E1
#define GL_STREAM_READ_ARB 0x88E1
#define GL_SUBPIXEL_BITS 0x0D50
+#define GL_SUBTRACT 0x84E7
#define GL_SYNC_CONDITION 0x9113
#define GL_SYNC_FENCE 0x9116
#define GL_SYNC_FLAGS 0x9115
#define GL_SYNC_FLUSH_COMMANDS_BIT 0x00000001
#define GL_SYNC_GPU_COMMANDS_COMPLETE 0x9117
#define GL_SYNC_STATUS 0x9114
+#define GL_T 0x2001
+#define GL_T2F_C3F_V3F 0x2A2A
+#define GL_T2F_C4F_N3F_V3F 0x2A2C
+#define GL_T2F_C4UB_V3F 0x2A29
+#define GL_T2F_N3F_V3F 0x2A2B
+#define GL_T2F_V3F 0x2A27
+#define GL_T4F_C4F_N3F_V4F 0x2A2D
+#define GL_T4F_V4F 0x2A28
#define GL_TESS_CONTROL_OUTPUT_VERTICES 0x8E75
#define GL_TESS_CONTROL_SHADER 0x8E88
#define GL_TESS_CONTROL_SHADER_BIT 0x00000008
@@ -1722,9 +2112,11 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_TEXTURE_BINDING_CUBE_MAP_ARRAY 0x900A
#define GL_TEXTURE_BINDING_CUBE_MAP_ARRAY_ARB 0x900A
#define GL_TEXTURE_BINDING_RECTANGLE 0x84F6
+#define GL_TEXTURE_BIT 0x00040000
#define GL_TEXTURE_BLUE_SIZE 0x805E
#define GL_TEXTURE_BLUE_TYPE 0x8C12
#define GL_TEXTURE_BLUE_TYPE_ARB 0x8C12
+#define GL_TEXTURE_BORDER 0x1005
#define GL_TEXTURE_BORDER_COLOR 0x1004
#define GL_TEXTURE_BUFFER 0x8C2A
#define GL_TEXTURE_BUFFER_DATA_STORE_BINDING 0x8C2D
@@ -1733,6 +2125,7 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_TEXTURE_BUFFER_SIZE 0x919E
#define GL_TEXTURE_COMPARE_FUNC 0x884D
#define GL_TEXTURE_COMPARE_MODE 0x884C
+#define GL_TEXTURE_COMPONENTS 0x1003
#define GL_TEXTURE_COMPRESSED 0x86A1
#define GL_TEXTURE_COMPRESSED_ARB 0x86A1
#define GL_TEXTURE_COMPRESSED_BLOCK_HEIGHT 0x82B2
@@ -1742,7 +2135,13 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_TEXTURE_COMPRESSED_IMAGE_SIZE_ARB 0x86A0
#define GL_TEXTURE_COMPRESSION_HINT 0x84EF
#define GL_TEXTURE_COMPRESSION_HINT_ARB 0x84EF
+#define GL_TEXTURE_COORD_ARRAY 0x8078
+#define GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING 0x889A
#define GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING_ARB 0x889A
+#define GL_TEXTURE_COORD_ARRAY_POINTER 0x8092
+#define GL_TEXTURE_COORD_ARRAY_SIZE 0x8088
+#define GL_TEXTURE_COORD_ARRAY_STRIDE 0x808A
+#define GL_TEXTURE_COORD_ARRAY_TYPE 0x8089
#define GL_TEXTURE_CUBE_MAP 0x8513
#define GL_TEXTURE_CUBE_MAP_ARB 0x8513
#define GL_TEXTURE_CUBE_MAP_ARRAY 0x9009
@@ -1765,10 +2164,19 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_TEXTURE_DEPTH_SIZE_ARB 0x884A
#define GL_TEXTURE_DEPTH_TYPE 0x8C16
#define GL_TEXTURE_DEPTH_TYPE_ARB 0x8C16
+#define GL_TEXTURE_ENV 0x2300
+#define GL_TEXTURE_ENV_COLOR 0x2201
+#define GL_TEXTURE_ENV_MODE 0x2200
#define GL_TEXTURE_FETCH_BARRIER_BIT 0x00000008
+#define GL_TEXTURE_FILTER_CONTROL 0x8500
#define GL_TEXTURE_FIXED_SAMPLE_LOCATIONS 0x9107
#define GL_TEXTURE_GATHER 0x82A2
#define GL_TEXTURE_GATHER_SHADOW 0x82A3
+#define GL_TEXTURE_GEN_MODE 0x2500
+#define GL_TEXTURE_GEN_Q 0x0C63
+#define GL_TEXTURE_GEN_R 0x0C62
+#define GL_TEXTURE_GEN_S 0x0C60
+#define GL_TEXTURE_GEN_T 0x0C61
#define GL_TEXTURE_GREEN_SIZE 0x805D
#define GL_TEXTURE_GREEN_TYPE 0x8C11
#define GL_TEXTURE_GREEN_TYPE_ARB 0x8C11
@@ -1777,25 +2185,33 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_TEXTURE_IMAGE_TYPE 0x8290
#define GL_TEXTURE_IMMUTABLE_FORMAT 0x912F
#define GL_TEXTURE_IMMUTABLE_LEVELS 0x82DF
+#define GL_TEXTURE_INTENSITY_SIZE 0x8061
+#define GL_TEXTURE_INTENSITY_TYPE 0x8C15
#define GL_TEXTURE_INTENSITY_TYPE_ARB 0x8C15
#define GL_TEXTURE_INTERNAL_FORMAT 0x1003
#define GL_TEXTURE_LOD_BIAS 0x8501
+#define GL_TEXTURE_LUMINANCE_SIZE 0x8060
+#define GL_TEXTURE_LUMINANCE_TYPE 0x8C14
#define GL_TEXTURE_LUMINANCE_TYPE_ARB 0x8C14
#define GL_TEXTURE_MAG_FILTER 0x2800
+#define GL_TEXTURE_MATRIX 0x0BA8
#define GL_TEXTURE_MAX_ANISOTROPY 0x84FE
#define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE
#define GL_TEXTURE_MAX_LEVEL 0x813D
#define GL_TEXTURE_MAX_LOD 0x813B
#define GL_TEXTURE_MIN_FILTER 0x2801
#define GL_TEXTURE_MIN_LOD 0x813A
+#define GL_TEXTURE_PRIORITY 0x8066
#define GL_TEXTURE_RECTANGLE 0x84F5
#define GL_TEXTURE_REDUCTION_MODE_ARB 0x9366
#define GL_TEXTURE_RED_SIZE 0x805C
#define GL_TEXTURE_RED_TYPE 0x8C10
#define GL_TEXTURE_RED_TYPE_ARB 0x8C10
+#define GL_TEXTURE_RESIDENT 0x8067
#define GL_TEXTURE_SAMPLES 0x9106
#define GL_TEXTURE_SHADOW 0x82A1
#define GL_TEXTURE_SHARED_SIZE 0x8C3F
+#define GL_TEXTURE_STACK_DEPTH 0x0BA5
#define GL_TEXTURE_STENCIL_SIZE 0x88F1
#define GL_TEXTURE_SWIZZLE_A 0x8E45
#define GL_TEXTURE_SWIZZLE_B 0x8E44
@@ -1819,6 +2235,7 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_TIME_ELAPSED 0x88BF
#define GL_TOP_LEVEL_ARRAY_SIZE 0x930C
#define GL_TOP_LEVEL_ARRAY_STRIDE 0x930D
+#define GL_TRANSFORM_BIT 0x00001000
#define GL_TRANSFORM_FEEDBACK 0x8E22
#define GL_TRANSFORM_FEEDBACK_ACTIVE 0x8E24
#define GL_TRANSFORM_FEEDBACK_BARRIER_BIT 0x00000800
@@ -1837,10 +2254,14 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_TRANSFORM_FEEDBACK_VARYING 0x92F4
#define GL_TRANSFORM_FEEDBACK_VARYINGS 0x8C83
#define GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH 0x8C76
+#define GL_TRANSPOSE_COLOR_MATRIX 0x84E6
#define GL_TRANSPOSE_COLOR_MATRIX_ARB 0x84E6
#define GL_TRANSPOSE_CURRENT_MATRIX_ARB 0x88B7
+#define GL_TRANSPOSE_MODELVIEW_MATRIX 0x84E3
#define GL_TRANSPOSE_MODELVIEW_MATRIX_ARB 0x84E3
+#define GL_TRANSPOSE_PROJECTION_MATRIX 0x84E4
#define GL_TRANSPOSE_PROJECTION_MATRIX_ARB 0x84E4
+#define GL_TRANSPOSE_TEXTURE_MATRIX 0x84E5
#define GL_TRANSPOSE_TEXTURE_MATRIX_ARB 0x84E5
#define GL_TRIANGLES 0x0004
#define GL_TRIANGLES_ADJACENCY 0x000C
@@ -1945,12 +2366,19 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_UNSIGNED_SHORT_5_6_5 0x8363
#define GL_UNSIGNED_SHORT_5_6_5_REV 0x8364
#define GL_UPPER_LEFT 0x8CA2
+#define GL_V2F 0x2A20
+#define GL_V3F 0x2A21
#define GL_VALIDATE_STATUS 0x8B83
#define GL_VENDOR 0x1F00
#define GL_VERSION 0x1F02
#define GL_VERTEX_ARRAY 0x8074
#define GL_VERTEX_ARRAY_BINDING 0x85B5
+#define GL_VERTEX_ARRAY_BUFFER_BINDING 0x8896
#define GL_VERTEX_ARRAY_BUFFER_BINDING_ARB 0x8896
+#define GL_VERTEX_ARRAY_POINTER 0x808E
+#define GL_VERTEX_ARRAY_SIZE 0x807A
+#define GL_VERTEX_ARRAY_STRIDE 0x807C
+#define GL_VERTEX_ARRAY_TYPE 0x807B
#define GL_VERTEX_ATTRIB_ARRAY_BARRIER_BIT 0x00000001
#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING 0x889F
#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB 0x889F
@@ -1979,6 +2407,7 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_VERTEX_PROGRAM_ARB 0x8620
#define GL_VERTEX_PROGRAM_POINT_SIZE 0x8642
#define GL_VERTEX_PROGRAM_POINT_SIZE_ARB 0x8642
+#define GL_VERTEX_PROGRAM_TWO_SIDE 0x8643
#define GL_VERTEX_PROGRAM_TWO_SIDE_ARB 0x8643
#define GL_VERTEX_SHADER 0x8B31
#define GL_VERTEX_SHADER_ARB 0x8B31
@@ -1991,6 +2420,7 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_VERTICES_SUBMITTED 0x82EE
#define GL_VERTICES_SUBMITTED_ARB 0x82EE
#define GL_VIEWPORT 0x0BA2
+#define GL_VIEWPORT_BIT 0x00000800
#define GL_VIEWPORT_BOUNDS_RANGE 0x825D
#define GL_VIEWPORT_INDEX_PROVOKING_VERTEX 0x825F
#define GL_VIEWPORT_SUBPIXEL_BITS 0x825C
@@ -2032,11 +2462,14 @@ typedef void (*GLADpostcallback)(void *ret, const char *name, GLADapiproc apipro
#define GL_VIEW_COMPATIBILITY_CLASS 0x82B6
#define GL_WAIT_FAILED 0x911D
#define GL_WEIGHTED_AVERAGE_ARB 0x9367
+#define GL_WEIGHT_ARRAY_BUFFER_BINDING 0x889E
#define GL_WEIGHT_ARRAY_BUFFER_BINDING_ARB 0x889E
#define GL_WRITE_ONLY 0x88B9
#define GL_WRITE_ONLY_ARB 0x88B9
#define GL_XOR 0x1506
#define GL_ZERO 0
+#define GL_ZOOM_X 0x0D16
+#define GL_ZOOM_Y 0x0D17
#include
@@ -2136,10 +2569,6 @@ GLAD_API_CALL int GLAD_GL_VERSION_4_1;
GLAD_API_CALL int GLAD_GL_VERSION_4_2;
#define GL_VERSION_4_3 1
GLAD_API_CALL int GLAD_GL_VERSION_4_3;
-#define GL_ARB_ES2_compatibility 1
-GLAD_API_CALL int GLAD_GL_ARB_ES2_compatibility;
-#define GL_ARB_ES3_1_compatibility 1
-GLAD_API_CALL int GLAD_GL_ARB_ES3_1_compatibility;
#define GL_ARB_ES3_2_compatibility 1
GLAD_API_CALL int GLAD_GL_ARB_ES3_2_compatibility;
#define GL_ARB_ES3_compatibility 1
@@ -2360,23 +2789,28 @@ GLAD_API_CALL int GLAD_GL_EXT_texture_compression_s3tc;
GLAD_API_CALL int GLAD_GL_EXT_texture_filter_anisotropic;
#define GL_EXT_texture_mirror_clamp 1
GLAD_API_CALL int GLAD_GL_EXT_texture_mirror_clamp;
+#define GL_KHR_blend_equation_advanced 1
+GLAD_API_CALL int GLAD_GL_KHR_blend_equation_advanced;
+#define GL_KHR_blend_equation_advanced_coherent 1
+GLAD_API_CALL int GLAD_GL_KHR_blend_equation_advanced_coherent;
+#define GL_KHR_debug 1
+GLAD_API_CALL int GLAD_GL_KHR_debug;
#define GL_KHR_texture_compression_astc_hdr 1
GLAD_API_CALL int GLAD_GL_KHR_texture_compression_astc_hdr;
#define GL_KHR_texture_compression_astc_ldr 1
GLAD_API_CALL int GLAD_GL_KHR_texture_compression_astc_ldr;
-#define GL_OES_compressed_paletted_texture 1
-GLAD_API_CALL int GLAD_GL_OES_compressed_paletted_texture;
-#define GL_OES_fixed_point 1
-GLAD_API_CALL int GLAD_GL_OES_fixed_point;
-typedef void (GLAD_API_PTR *PFNGLACCUMXOESPROC)(GLenum op, GLfixed value);
+typedef void (GLAD_API_PTR *PFNGLACCUMPROC)(GLenum op, GLfloat value);
typedef void (GLAD_API_PTR *PFNGLACTIVESHADERPROGRAMPROC)(GLuint pipeline, GLuint program);
typedef void (GLAD_API_PTR *PFNGLACTIVETEXTUREPROC)(GLenum texture);
typedef void (GLAD_API_PTR *PFNGLACTIVETEXTUREARBPROC)(GLenum texture);
-typedef void (GLAD_API_PTR *PFNGLALPHAFUNCXOESPROC)(GLenum func, GLfixed ref);
+typedef void (GLAD_API_PTR *PFNGLALPHAFUNCPROC)(GLenum func, GLfloat ref);
+typedef GLboolean (GLAD_API_PTR *PFNGLARETEXTURESRESIDENTPROC)(GLsizei n, const GLuint * textures, GLboolean * residences);
+typedef void (GLAD_API_PTR *PFNGLARRAYELEMENTPROC)(GLint i);
typedef void (GLAD_API_PTR *PFNGLATTACHOBJECTARBPROC)(GLhandleARB containerObj, GLhandleARB obj);
typedef void (GLAD_API_PTR *PFNGLATTACHSHADERPROC)(GLuint program, GLuint shader);
+typedef void (GLAD_API_PTR *PFNGLBEGINPROC)(GLenum mode);
typedef void (GLAD_API_PTR *PFNGLBEGINCONDITIONALRENDERPROC)(GLuint id, GLenum mode);
typedef void (GLAD_API_PTR *PFNGLBEGINQUERYPROC)(GLenum target, GLuint id);
typedef void (GLAD_API_PTR *PFNGLBEGINQUERYARBPROC)(GLenum target, GLuint id);
@@ -2409,9 +2843,9 @@ typedef void (GLAD_API_PTR *PFNGLBINDTRANSFORMFEEDBACKPROC)(GLenum target, GLuin
typedef void (GLAD_API_PTR *PFNGLBINDVERTEXARRAYPROC)(GLuint array);
typedef void (GLAD_API_PTR *PFNGLBINDVERTEXBUFFERPROC)(GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
typedef void (GLAD_API_PTR *PFNGLBINDVERTEXBUFFERSPROC)(GLuint first, GLsizei count, const GLuint * buffers, const GLintptr * offsets, const GLsizei * strides);
-typedef void (GLAD_API_PTR *PFNGLBITMAPXOESPROC)(GLsizei width, GLsizei height, GLfixed xorig, GLfixed yorig, GLfixed xmove, GLfixed ymove, const GLubyte * bitmap);
+typedef void (GLAD_API_PTR *PFNGLBITMAPPROC)(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte * bitmap);
+typedef void (GLAD_API_PTR *PFNGLBLENDBARRIERKHRPROC)(void);
typedef void (GLAD_API_PTR *PFNGLBLENDCOLORPROC)(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
-typedef void (GLAD_API_PTR *PFNGLBLENDCOLORXOESPROC)(GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);
typedef void (GLAD_API_PTR *PFNGLBLENDEQUATIONPROC)(GLenum mode);
typedef void (GLAD_API_PTR *PFNGLBLENDEQUATIONSEPARATEPROC)(GLenum modeRGB, GLenum modeAlpha);
typedef void (GLAD_API_PTR *PFNGLBLENDEQUATIONSEPARATEIPROC)(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
@@ -2432,13 +2866,15 @@ typedef void (GLAD_API_PTR *PFNGLBUFFERDATAARBPROC)(GLenum target, GLsizeiptrARB
typedef void (GLAD_API_PTR *PFNGLBUFFERSTORAGEPROC)(GLenum target, GLsizeiptr size, const void * data, GLbitfield flags);
typedef void (GLAD_API_PTR *PFNGLBUFFERSUBDATAPROC)(GLenum target, GLintptr offset, GLsizeiptr size, const void * data);
typedef void (GLAD_API_PTR *PFNGLBUFFERSUBDATAARBPROC)(GLenum target, GLintptrARB offset, GLsizeiptrARB size, const void * data);
+typedef void (GLAD_API_PTR *PFNGLCALLLISTPROC)(GLuint list);
+typedef void (GLAD_API_PTR *PFNGLCALLLISTSPROC)(GLsizei n, GLenum type, const void * lists);
typedef GLenum (GLAD_API_PTR *PFNGLCHECKFRAMEBUFFERSTATUSPROC)(GLenum target);
typedef GLenum (GLAD_API_PTR *PFNGLCHECKFRAMEBUFFERSTATUSEXTPROC)(GLenum target);
typedef GLenum (GLAD_API_PTR *PFNGLCHECKNAMEDFRAMEBUFFERSTATUSPROC)(GLuint framebuffer, GLenum target);
typedef void (GLAD_API_PTR *PFNGLCLAMPCOLORPROC)(GLenum target, GLenum clamp);
typedef void (GLAD_API_PTR *PFNGLCLAMPCOLORARBPROC)(GLenum target, GLenum clamp);
typedef void (GLAD_API_PTR *PFNGLCLEARPROC)(GLbitfield mask);
-typedef void (GLAD_API_PTR *PFNGLCLEARACCUMXOESPROC)(GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);
+typedef void (GLAD_API_PTR *PFNGLCLEARACCUMPROC)(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
typedef void (GLAD_API_PTR *PFNGLCLEARBUFFERDATAPROC)(GLenum target, GLenum internalformat, GLenum format, GLenum type, const void * data);
typedef void (GLAD_API_PTR *PFNGLCLEARBUFFERSUBDATAPROC)(GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void * data);
typedef void (GLAD_API_PTR *PFNGLCLEARBUFFERFIPROC)(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
@@ -2446,10 +2882,9 @@ typedef void (GLAD_API_PTR *PFNGLCLEARBUFFERFVPROC)(GLenum buffer, GLint drawbuf
typedef void (GLAD_API_PTR *PFNGLCLEARBUFFERIVPROC)(GLenum buffer, GLint drawbuffer, const GLint * value);
typedef void (GLAD_API_PTR *PFNGLCLEARBUFFERUIVPROC)(GLenum buffer, GLint drawbuffer, const GLuint * value);
typedef void (GLAD_API_PTR *PFNGLCLEARCOLORPROC)(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
-typedef void (GLAD_API_PTR *PFNGLCLEARCOLORXOESPROC)(GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);
typedef void (GLAD_API_PTR *PFNGLCLEARDEPTHPROC)(GLdouble depth);
typedef void (GLAD_API_PTR *PFNGLCLEARDEPTHFPROC)(GLfloat d);
-typedef void (GLAD_API_PTR *PFNGLCLEARDEPTHXOESPROC)(GLfixed depth);
+typedef void (GLAD_API_PTR *PFNGLCLEARINDEXPROC)(GLfloat c);
typedef void (GLAD_API_PTR *PFNGLCLEARNAMEDBUFFERDATAPROC)(GLuint buffer, GLenum internalformat, GLenum format, GLenum type, const void * data);
typedef void (GLAD_API_PTR *PFNGLCLEARNAMEDBUFFERSUBDATAPROC)(GLuint buffer, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void * data);
typedef void (GLAD_API_PTR *PFNGLCLEARNAMEDFRAMEBUFFERFIPROC)(GLuint framebuffer, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
@@ -2459,15 +2894,50 @@ typedef void (GLAD_API_PTR *PFNGLCLEARNAMEDFRAMEBUFFERUIVPROC)(GLuint framebuffe
typedef void (GLAD_API_PTR *PFNGLCLEARSTENCILPROC)(GLint s);
typedef void (GLAD_API_PTR *PFNGLCLEARTEXIMAGEPROC)(GLuint texture, GLint level, GLenum format, GLenum type, const void * data);
typedef void (GLAD_API_PTR *PFNGLCLEARTEXSUBIMAGEPROC)(GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void * data);
+typedef void (GLAD_API_PTR *PFNGLCLIENTACTIVETEXTUREPROC)(GLenum texture);
typedef void (GLAD_API_PTR *PFNGLCLIENTACTIVETEXTUREARBPROC)(GLenum texture);
typedef GLenum (GLAD_API_PTR *PFNGLCLIENTWAITSYNCPROC)(GLsync sync, GLbitfield flags, GLuint64 timeout);
-typedef void (GLAD_API_PTR *PFNGLCLIPPLANEXOESPROC)(GLenum plane, const GLfixed * equation);
-typedef void (GLAD_API_PTR *PFNGLCOLOR3XOESPROC)(GLfixed red, GLfixed green, GLfixed blue);
-typedef void (GLAD_API_PTR *PFNGLCOLOR3XVOESPROC)(const GLfixed * components);
-typedef void (GLAD_API_PTR *PFNGLCOLOR4XOESPROC)(GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);
-typedef void (GLAD_API_PTR *PFNGLCOLOR4XVOESPROC)(const GLfixed * components);
+typedef void (GLAD_API_PTR *PFNGLCLIPPLANEPROC)(GLenum plane, const GLdouble * equation);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3BPROC)(GLbyte red, GLbyte green, GLbyte blue);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3BVPROC)(const GLbyte * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3DPROC)(GLdouble red, GLdouble green, GLdouble blue);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3FPROC)(GLfloat red, GLfloat green, GLfloat blue);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3IPROC)(GLint red, GLint green, GLint blue);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3SPROC)(GLshort red, GLshort green, GLshort blue);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3SVPROC)(const GLshort * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3UBPROC)(GLubyte red, GLubyte green, GLubyte blue);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3UBVPROC)(const GLubyte * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3UIPROC)(GLuint red, GLuint green, GLuint blue);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3UIVPROC)(const GLuint * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3USPROC)(GLushort red, GLushort green, GLushort blue);
+typedef void (GLAD_API_PTR *PFNGLCOLOR3USVPROC)(const GLushort * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4BPROC)(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4BVPROC)(const GLbyte * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4DPROC)(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4FPROC)(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4IPROC)(GLint red, GLint green, GLint blue, GLint alpha);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4SPROC)(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4SVPROC)(const GLshort * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4UBPROC)(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4UBVPROC)(const GLubyte * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4UIPROC)(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4UIVPROC)(const GLuint * v);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4USPROC)(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+typedef void (GLAD_API_PTR *PFNGLCOLOR4USVPROC)(const GLushort * v);
typedef void (GLAD_API_PTR *PFNGLCOLORMASKPROC)(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
typedef void (GLAD_API_PTR *PFNGLCOLORMASKIPROC)(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+typedef void (GLAD_API_PTR *PFNGLCOLORMATERIALPROC)(GLenum face, GLenum mode);
+typedef void (GLAD_API_PTR *PFNGLCOLORP3UIPROC)(GLenum type, GLuint color);
+typedef void (GLAD_API_PTR *PFNGLCOLORP3UIVPROC)(GLenum type, const GLuint * color);
+typedef void (GLAD_API_PTR *PFNGLCOLORP4UIPROC)(GLenum type, GLuint color);
+typedef void (GLAD_API_PTR *PFNGLCOLORP4UIVPROC)(GLenum type, const GLuint * color);
+typedef void (GLAD_API_PTR *PFNGLCOLORPOINTERPROC)(GLint size, GLenum type, GLsizei stride, const void * pointer);
typedef void (GLAD_API_PTR *PFNGLCOMPILESHADERPROC)(GLuint shader);
typedef void (GLAD_API_PTR *PFNGLCOMPILESHADERARBPROC)(GLhandleARB shaderObj);
typedef void (GLAD_API_PTR *PFNGLCOMPILESHADERINCLUDEARBPROC)(GLuint shader, GLsizei count, const GLchar *const* path, const GLint * length);
@@ -2486,11 +2956,10 @@ typedef void (GLAD_API_PTR *PFNGLCOMPRESSEDTEXSUBIMAGE3DARBPROC)(GLenum target,
typedef void (GLAD_API_PTR *PFNGLCOMPRESSEDTEXTURESUBIMAGE1DPROC)(GLuint texture, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const void * data);
typedef void (GLAD_API_PTR *PFNGLCOMPRESSEDTEXTURESUBIMAGE2DPROC)(GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void * data);
typedef void (GLAD_API_PTR *PFNGLCOMPRESSEDTEXTURESUBIMAGE3DPROC)(GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const void * data);
-typedef void (GLAD_API_PTR *PFNGLCONVOLUTIONPARAMETERXOESPROC)(GLenum target, GLenum pname, GLfixed param);
-typedef void (GLAD_API_PTR *PFNGLCONVOLUTIONPARAMETERXVOESPROC)(GLenum target, GLenum pname, const GLfixed * params);
typedef void (GLAD_API_PTR *PFNGLCOPYBUFFERSUBDATAPROC)(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
typedef void (GLAD_API_PTR *PFNGLCOPYIMAGESUBDATAPROC)(GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth);
typedef void (GLAD_API_PTR *PFNGLCOPYNAMEDBUFFERSUBDATAPROC)(GLuint readBuffer, GLuint writeBuffer, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+typedef void (GLAD_API_PTR *PFNGLCOPYPIXELSPROC)(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
typedef void (GLAD_API_PTR *PFNGLCOPYTEXIMAGE1DPROC)(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
typedef void (GLAD_API_PTR *PFNGLCOPYTEXIMAGE2DPROC)(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
typedef void (GLAD_API_PTR *PFNGLCOPYTEXSUBIMAGE1DPROC)(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
@@ -2524,6 +2993,7 @@ typedef void (GLAD_API_PTR *PFNGLDELETEBUFFERSPROC)(GLsizei n, const GLuint * bu
typedef void (GLAD_API_PTR *PFNGLDELETEBUFFERSARBPROC)(GLsizei n, const GLuint * buffers);
typedef void (GLAD_API_PTR *PFNGLDELETEFRAMEBUFFERSPROC)(GLsizei n, const GLuint * framebuffers);
typedef void (GLAD_API_PTR *PFNGLDELETEFRAMEBUFFERSEXTPROC)(GLsizei n, const GLuint * framebuffers);
+typedef void (GLAD_API_PTR *PFNGLDELETELISTSPROC)(GLuint list, GLsizei range);
typedef void (GLAD_API_PTR *PFNGLDELETENAMEDSTRINGARBPROC)(GLint namelen, const GLchar * name);
typedef void (GLAD_API_PTR *PFNGLDELETEOBJECTARBPROC)(GLhandleARB obj);
typedef void (GLAD_API_PTR *PFNGLDELETEPROGRAMPROC)(GLuint program);
@@ -2545,10 +3015,10 @@ typedef void (GLAD_API_PTR *PFNGLDEPTHRANGEPROC)(GLdouble n, GLdouble f);
typedef void (GLAD_API_PTR *PFNGLDEPTHRANGEARRAYVPROC)(GLuint first, GLsizei count, const GLdouble * v);
typedef void (GLAD_API_PTR *PFNGLDEPTHRANGEINDEXEDPROC)(GLuint index, GLdouble n, GLdouble f);
typedef void (GLAD_API_PTR *PFNGLDEPTHRANGEFPROC)(GLfloat n, GLfloat f);
-typedef void (GLAD_API_PTR *PFNGLDEPTHRANGEXOESPROC)(GLfixed n, GLfixed f);
typedef void (GLAD_API_PTR *PFNGLDETACHOBJECTARBPROC)(GLhandleARB containerObj, GLhandleARB attachedObj);
typedef void (GLAD_API_PTR *PFNGLDETACHSHADERPROC)(GLuint program, GLuint shader);
typedef void (GLAD_API_PTR *PFNGLDISABLEPROC)(GLenum cap);
+typedef void (GLAD_API_PTR *PFNGLDISABLECLIENTSTATEPROC)(GLenum array);
typedef void (GLAD_API_PTR *PFNGLDISABLEVERTEXARRAYATTRIBPROC)(GLuint vaobj, GLuint index);
typedef void (GLAD_API_PTR *PFNGLDISABLEVERTEXATTRIBARRAYPROC)(GLuint index);
typedef void (GLAD_API_PTR *PFNGLDISABLEVERTEXATTRIBARRAYARBPROC)(GLuint index);
@@ -2574,40 +3044,62 @@ typedef void (GLAD_API_PTR *PFNGLDRAWELEMENTSINSTANCEDBASEINSTANCEPROC)(GLenum m
typedef void (GLAD_API_PTR *PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXPROC)(GLenum mode, GLsizei count, GLenum type, const void * indices, GLsizei instancecount, GLint basevertex);
typedef void (GLAD_API_PTR *PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCEPROC)(GLenum mode, GLsizei count, GLenum type, const void * indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
typedef void (GLAD_API_PTR *PFNGLDRAWELEMENTSINSTANCEDEXTPROC)(GLenum mode, GLsizei count, GLenum type, const void * indices, GLsizei primcount);
+typedef void (GLAD_API_PTR *PFNGLDRAWPIXELSPROC)(GLsizei width, GLsizei height, GLenum format, GLenum type, const void * pixels);
typedef void (GLAD_API_PTR *PFNGLDRAWRANGEELEMENTSPROC)(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void * indices);
typedef void (GLAD_API_PTR *PFNGLDRAWRANGEELEMENTSBASEVERTEXPROC)(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void * indices, GLint basevertex);
typedef void (GLAD_API_PTR *PFNGLDRAWTRANSFORMFEEDBACKPROC)(GLenum mode, GLuint id);
typedef void (GLAD_API_PTR *PFNGLDRAWTRANSFORMFEEDBACKINSTANCEDPROC)(GLenum mode, GLuint id, GLsizei instancecount);
typedef void (GLAD_API_PTR *PFNGLDRAWTRANSFORMFEEDBACKSTREAMPROC)(GLenum mode, GLuint id, GLuint stream);
typedef void (GLAD_API_PTR *PFNGLDRAWTRANSFORMFEEDBACKSTREAMINSTANCEDPROC)(GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
+typedef void (GLAD_API_PTR *PFNGLEDGEFLAGPROC)(GLboolean flag);
+typedef void (GLAD_API_PTR *PFNGLEDGEFLAGPOINTERPROC)(GLsizei stride, const void * pointer);
+typedef void (GLAD_API_PTR *PFNGLEDGEFLAGVPROC)(const GLboolean * flag);
typedef void (GLAD_API_PTR *PFNGLENABLEPROC)(GLenum cap);
+typedef void (GLAD_API_PTR *PFNGLENABLECLIENTSTATEPROC)(GLenum array);
typedef void (GLAD_API_PTR *PFNGLENABLEVERTEXARRAYATTRIBPROC)(GLuint vaobj, GLuint index);
typedef void (GLAD_API_PTR *PFNGLENABLEVERTEXATTRIBARRAYPROC)(GLuint index);
typedef void (GLAD_API_PTR *PFNGLENABLEVERTEXATTRIBARRAYARBPROC)(GLuint index);
typedef void (GLAD_API_PTR *PFNGLENABLEIPROC)(GLenum target, GLuint index);
+typedef void (GLAD_API_PTR *PFNGLENDPROC)(void);
typedef void (GLAD_API_PTR *PFNGLENDCONDITIONALRENDERPROC)(void);
+typedef void (GLAD_API_PTR *PFNGLENDLISTPROC)(void);
typedef void (GLAD_API_PTR *PFNGLENDQUERYPROC)(GLenum target);
typedef void (GLAD_API_PTR *PFNGLENDQUERYARBPROC)(GLenum target);
typedef void (GLAD_API_PTR *PFNGLENDQUERYINDEXEDPROC)(GLenum target, GLuint index);
typedef void (GLAD_API_PTR *PFNGLENDTRANSFORMFEEDBACKPROC)(void);
-typedef void (GLAD_API_PTR *PFNGLEVALCOORD1XOESPROC)(GLfixed u);
-typedef void (GLAD_API_PTR *PFNGLEVALCOORD1XVOESPROC)(const GLfixed * coords);
-typedef void (GLAD_API_PTR *PFNGLEVALCOORD2XOESPROC)(GLfixed u, GLfixed v);
-typedef void (GLAD_API_PTR *PFNGLEVALCOORD2XVOESPROC)(const GLfixed * coords);
+typedef void (GLAD_API_PTR *PFNGLEVALCOORD1DPROC)(GLdouble u);
+typedef void (GLAD_API_PTR *PFNGLEVALCOORD1DVPROC)(const GLdouble * u);
+typedef void (GLAD_API_PTR *PFNGLEVALCOORD1FPROC)(GLfloat u);
+typedef void (GLAD_API_PTR *PFNGLEVALCOORD1FVPROC)(const GLfloat * u);
+typedef void (GLAD_API_PTR *PFNGLEVALCOORD2DPROC)(GLdouble u, GLdouble v);
+typedef void (GLAD_API_PTR *PFNGLEVALCOORD2DVPROC)(const GLdouble * u);
+typedef void (GLAD_API_PTR *PFNGLEVALCOORD2FPROC)(GLfloat u, GLfloat v);
+typedef void (GLAD_API_PTR *PFNGLEVALCOORD2FVPROC)(const GLfloat * u);
+typedef void (GLAD_API_PTR *PFNGLEVALMESH1PROC)(GLenum mode, GLint i1, GLint i2);
+typedef void (GLAD_API_PTR *PFNGLEVALMESH2PROC)(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+typedef void (GLAD_API_PTR *PFNGLEVALPOINT1PROC)(GLint i);
+typedef void (GLAD_API_PTR *PFNGLEVALPOINT2PROC)(GLint i, GLint j);
typedef void (GLAD_API_PTR *PFNGLEVALUATEDEPTHVALUESARBPROC)(void);
-typedef void (GLAD_API_PTR *PFNGLFEEDBACKBUFFERXOESPROC)(GLsizei n, GLenum type, const GLfixed * buffer);
+typedef void (GLAD_API_PTR *PFNGLFEEDBACKBUFFERPROC)(GLsizei size, GLenum type, GLfloat * buffer);
typedef GLsync (GLAD_API_PTR *PFNGLFENCESYNCPROC)(GLenum condition, GLbitfield flags);
typedef void (GLAD_API_PTR *PFNGLFINISHPROC)(void);
typedef void (GLAD_API_PTR *PFNGLFLUSHPROC)(void);
typedef void (GLAD_API_PTR *PFNGLFLUSHMAPPEDBUFFERRANGEPROC)(GLenum target, GLintptr offset, GLsizeiptr length);
typedef void (GLAD_API_PTR *PFNGLFLUSHMAPPEDNAMEDBUFFERRANGEPROC)(GLuint buffer, GLintptr offset, GLsizeiptr length);
+typedef void (GLAD_API_PTR *PFNGLFOGCOORDPOINTERPROC)(GLenum type, GLsizei stride, const void * pointer);
typedef void (GLAD_API_PTR *PFNGLFOGCOORDPOINTEREXTPROC)(GLenum type, GLsizei stride, const void * pointer);
+typedef void (GLAD_API_PTR *PFNGLFOGCOORDDPROC)(GLdouble coord);
typedef void (GLAD_API_PTR *PFNGLFOGCOORDDEXTPROC)(GLdouble coord);
+typedef void (GLAD_API_PTR *PFNGLFOGCOORDDVPROC)(const GLdouble * coord);
typedef void (GLAD_API_PTR *PFNGLFOGCOORDDVEXTPROC)(const GLdouble * coord);
+typedef void (GLAD_API_PTR *PFNGLFOGCOORDFPROC)(GLfloat coord);
typedef void (GLAD_API_PTR *PFNGLFOGCOORDFEXTPROC)(GLfloat coord);
+typedef void (GLAD_API_PTR *PFNGLFOGCOORDFVPROC)(const GLfloat * coord);
typedef void (GLAD_API_PTR *PFNGLFOGCOORDFVEXTPROC)(const GLfloat * coord);
-typedef void (GLAD_API_PTR *PFNGLFOGXOESPROC)(GLenum pname, GLfixed param);
-typedef void (GLAD_API_PTR *PFNGLFOGXVOESPROC)(GLenum pname, const GLfixed * param);
+typedef void (GLAD_API_PTR *PFNGLFOGFPROC)(GLenum pname, GLfloat param);
+typedef void (GLAD_API_PTR *PFNGLFOGFVPROC)(GLenum pname, const GLfloat * params);
+typedef void (GLAD_API_PTR *PFNGLFOGIPROC)(GLenum pname, GLint param);
+typedef void (GLAD_API_PTR *PFNGLFOGIVPROC)(GLenum pname, const GLint * params);
typedef void (GLAD_API_PTR *PFNGLFRAMEBUFFERPARAMETERIPROC)(GLenum target, GLenum pname, GLint param);
typedef void (GLAD_API_PTR *PFNGLFRAMEBUFFERRENDERBUFFERPROC)(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
typedef void (GLAD_API_PTR *PFNGLFRAMEBUFFERRENDERBUFFEREXTPROC)(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
@@ -2624,11 +3116,12 @@ typedef void (GLAD_API_PTR *PFNGLFRAMEBUFFERTEXTUREFACEARBPROC)(GLenum target, G
typedef void (GLAD_API_PTR *PFNGLFRAMEBUFFERTEXTURELAYERPROC)(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
typedef void (GLAD_API_PTR *PFNGLFRAMEBUFFERTEXTURELAYERARBPROC)(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
typedef void (GLAD_API_PTR *PFNGLFRONTFACEPROC)(GLenum mode);
-typedef void (GLAD_API_PTR *PFNGLFRUSTUMXOESPROC)(GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f);
+typedef void (GLAD_API_PTR *PFNGLFRUSTUMPROC)(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
typedef void (GLAD_API_PTR *PFNGLGENBUFFERSPROC)(GLsizei n, GLuint * buffers);
typedef void (GLAD_API_PTR *PFNGLGENBUFFERSARBPROC)(GLsizei n, GLuint * buffers);
typedef void (GLAD_API_PTR *PFNGLGENFRAMEBUFFERSPROC)(GLsizei n, GLuint * framebuffers);
typedef void (GLAD_API_PTR *PFNGLGENFRAMEBUFFERSEXTPROC)(GLsizei n, GLuint * framebuffers);
+typedef GLuint (GLAD_API_PTR *PFNGLGENLISTSPROC)(GLsizei range);
typedef void (GLAD_API_PTR *PFNGLGENPROGRAMPIPELINESPROC)(GLsizei n, GLuint * pipelines);
typedef void (GLAD_API_PTR *PFNGLGENPROGRAMSARBPROC)(GLsizei n, GLuint * programs);
typedef void (GLAD_API_PTR *PFNGLGENQUERIESPROC)(GLsizei n, GLuint * ids);
@@ -2667,18 +3160,16 @@ typedef void (GLAD_API_PTR *PFNGLGETBUFFERPOINTERVPROC)(GLenum target, GLenum pn
typedef void (GLAD_API_PTR *PFNGLGETBUFFERPOINTERVARBPROC)(GLenum target, GLenum pname, void ** params);
typedef void (GLAD_API_PTR *PFNGLGETBUFFERSUBDATAPROC)(GLenum target, GLintptr offset, GLsizeiptr size, void * data);
typedef void (GLAD_API_PTR *PFNGLGETBUFFERSUBDATAARBPROC)(GLenum target, GLintptrARB offset, GLsizeiptrARB size, void * data);
-typedef void (GLAD_API_PTR *PFNGLGETCLIPPLANEXOESPROC)(GLenum plane, GLfixed * equation);
+typedef void (GLAD_API_PTR *PFNGLGETCLIPPLANEPROC)(GLenum plane, GLdouble * equation);
typedef void (GLAD_API_PTR *PFNGLGETCOMPRESSEDTEXIMAGEPROC)(GLenum target, GLint level, void * img);
typedef void (GLAD_API_PTR *PFNGLGETCOMPRESSEDTEXIMAGEARBPROC)(GLenum target, GLint level, void * img);
typedef void (GLAD_API_PTR *PFNGLGETCOMPRESSEDTEXTUREIMAGEPROC)(GLuint texture, GLint level, GLsizei bufSize, void * pixels);
typedef void (GLAD_API_PTR *PFNGLGETCOMPRESSEDTEXTURESUBIMAGEPROC)(GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLsizei bufSize, void * pixels);
-typedef void (GLAD_API_PTR *PFNGLGETCONVOLUTIONPARAMETERXVOESPROC)(GLenum target, GLenum pname, GLfixed * params);
typedef GLuint (GLAD_API_PTR *PFNGLGETDEBUGMESSAGELOGPROC)(GLuint count, GLsizei bufSize, GLenum * sources, GLenum * types, GLuint * ids, GLenum * severities, GLsizei * lengths, GLchar * messageLog);
typedef GLuint (GLAD_API_PTR *PFNGLGETDEBUGMESSAGELOGARBPROC)(GLuint count, GLsizei bufSize, GLenum * sources, GLenum * types, GLuint * ids, GLenum * severities, GLsizei * lengths, GLchar * messageLog);
typedef void (GLAD_API_PTR *PFNGLGETDOUBLEI_VPROC)(GLenum target, GLuint index, GLdouble * data);
typedef void (GLAD_API_PTR *PFNGLGETDOUBLEVPROC)(GLenum pname, GLdouble * data);
typedef GLenum (GLAD_API_PTR *PFNGLGETERRORPROC)(void);
-typedef void (GLAD_API_PTR *PFNGLGETFIXEDVOESPROC)(GLenum pname, GLfixed * params);
typedef void (GLAD_API_PTR *PFNGLGETFLOATI_VPROC)(GLenum target, GLuint index, GLfloat * data);
typedef void (GLAD_API_PTR *PFNGLGETFLOATVPROC)(GLenum pname, GLfloat * data);
typedef GLint (GLAD_API_PTR *PFNGLGETFRAGDATAINDEXPROC)(GLuint program, const GLchar * name);
@@ -2687,7 +3178,6 @@ typedef void (GLAD_API_PTR *PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVPROC)(GLenum
typedef void (GLAD_API_PTR *PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVEXTPROC)(GLenum target, GLenum attachment, GLenum pname, GLint * params);
typedef void (GLAD_API_PTR *PFNGLGETFRAMEBUFFERPARAMETERIVPROC)(GLenum target, GLenum pname, GLint * params);
typedef GLhandleARB (GLAD_API_PTR *PFNGLGETHANDLEARBPROC)(GLenum pname);
-typedef void (GLAD_API_PTR *PFNGLGETHISTOGRAMPARAMETERXVOESPROC)(GLenum target, GLenum pname, GLfixed * params);
typedef void (GLAD_API_PTR *PFNGLGETINFOLOGARBPROC)(GLhandleARB obj, GLsizei maxLength, GLsizei * length, GLcharARB * infoLog);
typedef void (GLAD_API_PTR *PFNGLGETINTEGER64I_VPROC)(GLenum target, GLuint index, GLint64 * data);
typedef void (GLAD_API_PTR *PFNGLGETINTEGER64VPROC)(GLenum pname, GLint64 * data);
@@ -2695,9 +3185,13 @@ typedef void (GLAD_API_PTR *PFNGLGETINTEGERI_VPROC)(GLenum target, GLuint index,
typedef void (GLAD_API_PTR *PFNGLGETINTEGERVPROC)(GLenum pname, GLint * data);
typedef void (GLAD_API_PTR *PFNGLGETINTERNALFORMATI64VPROC)(GLenum target, GLenum internalformat, GLenum pname, GLsizei count, GLint64 * params);
typedef void (GLAD_API_PTR *PFNGLGETINTERNALFORMATIVPROC)(GLenum target, GLenum internalformat, GLenum pname, GLsizei count, GLint * params);
-typedef void (GLAD_API_PTR *PFNGLGETLIGHTXOESPROC)(GLenum light, GLenum pname, GLfixed * params);
-typedef void (GLAD_API_PTR *PFNGLGETMAPXVOESPROC)(GLenum target, GLenum query, GLfixed * v);
-typedef void (GLAD_API_PTR *PFNGLGETMATERIALXOESPROC)(GLenum face, GLenum pname, GLfixed param);
+typedef void (GLAD_API_PTR *PFNGLGETLIGHTFVPROC)(GLenum light, GLenum pname, GLfloat * params);
+typedef void (GLAD_API_PTR *PFNGLGETLIGHTIVPROC)(GLenum light, GLenum pname, GLint * params);
+typedef void (GLAD_API_PTR *PFNGLGETMAPDVPROC)(GLenum target, GLenum query, GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLGETMAPFVPROC)(GLenum target, GLenum query, GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLGETMAPIVPROC)(GLenum target, GLenum query, GLint * v);
+typedef void (GLAD_API_PTR *PFNGLGETMATERIALFVPROC)(GLenum face, GLenum pname, GLfloat * params);
+typedef void (GLAD_API_PTR *PFNGLGETMATERIALIVPROC)(GLenum face, GLenum pname, GLint * params);
typedef void (GLAD_API_PTR *PFNGLGETMULTISAMPLEFVPROC)(GLenum pname, GLuint index, GLfloat * val);
typedef void (GLAD_API_PTR *PFNGLGETNAMEDBUFFERPARAMETERI64VPROC)(GLuint buffer, GLenum pname, GLint64 * params);
typedef void (GLAD_API_PTR *PFNGLGETNAMEDBUFFERPARAMETERIVPROC)(GLuint buffer, GLenum pname, GLint * params);
@@ -2712,8 +3206,11 @@ typedef void (GLAD_API_PTR *PFNGLGETOBJECTLABELPROC)(GLenum identifier, GLuint n
typedef void (GLAD_API_PTR *PFNGLGETOBJECTPARAMETERFVARBPROC)(GLhandleARB obj, GLenum pname, GLfloat * params);
typedef void (GLAD_API_PTR *PFNGLGETOBJECTPARAMETERIVARBPROC)(GLhandleARB obj, GLenum pname, GLint * params);
typedef void (GLAD_API_PTR *PFNGLGETOBJECTPTRLABELPROC)(const void * ptr, GLsizei bufSize, GLsizei * length, GLchar * label);
-typedef void (GLAD_API_PTR *PFNGLGETPIXELMAPXVPROC)(GLenum map, GLint size, GLfixed * values);
+typedef void (GLAD_API_PTR *PFNGLGETPIXELMAPFVPROC)(GLenum map, GLfloat * values);
+typedef void (GLAD_API_PTR *PFNGLGETPIXELMAPUIVPROC)(GLenum map, GLuint * values);
+typedef void (GLAD_API_PTR *PFNGLGETPIXELMAPUSVPROC)(GLenum map, GLushort * values);
typedef void (GLAD_API_PTR *PFNGLGETPOINTERVPROC)(GLenum pname, void ** params);
+typedef void (GLAD_API_PTR *PFNGLGETPOLYGONSTIPPLEPROC)(GLubyte * mask);
typedef void (GLAD_API_PTR *PFNGLGETPROGRAMBINARYPROC)(GLuint program, GLsizei bufSize, GLsizei * length, GLenum * binaryFormat, void * binary);
typedef void (GLAD_API_PTR *PFNGLGETPROGRAMENVPARAMETERDVARBPROC)(GLenum target, GLuint index, GLdouble * params);
typedef void (GLAD_API_PTR *PFNGLGETPROGRAMENVPARAMETERFVARBPROC)(GLenum target, GLuint index, GLfloat * params);
@@ -2761,17 +3258,18 @@ typedef const GLubyte * (GLAD_API_PTR *PFNGLGETSTRINGIPROC)(GLenum name, GLuint
typedef GLuint (GLAD_API_PTR *PFNGLGETSUBROUTINEINDEXPROC)(GLuint program, GLenum shadertype, const GLchar * name);
typedef GLint (GLAD_API_PTR *PFNGLGETSUBROUTINEUNIFORMLOCATIONPROC)(GLuint program, GLenum shadertype, const GLchar * name);
typedef void (GLAD_API_PTR *PFNGLGETSYNCIVPROC)(GLsync sync, GLenum pname, GLsizei count, GLsizei * length, GLint * values);
-typedef void (GLAD_API_PTR *PFNGLGETTEXENVXVOESPROC)(GLenum target, GLenum pname, GLfixed * params);
-typedef void (GLAD_API_PTR *PFNGLGETTEXGENXVOESPROC)(GLenum coord, GLenum pname, GLfixed * params);
+typedef void (GLAD_API_PTR *PFNGLGETTEXENVFVPROC)(GLenum target, GLenum pname, GLfloat * params);
+typedef void (GLAD_API_PTR *PFNGLGETTEXENVIVPROC)(GLenum target, GLenum pname, GLint * params);
+typedef void (GLAD_API_PTR *PFNGLGETTEXGENDVPROC)(GLenum coord, GLenum pname, GLdouble * params);
+typedef void (GLAD_API_PTR *PFNGLGETTEXGENFVPROC)(GLenum coord, GLenum pname, GLfloat * params);
+typedef void (GLAD_API_PTR *PFNGLGETTEXGENIVPROC)(GLenum coord, GLenum pname, GLint * params);
typedef void (GLAD_API_PTR *PFNGLGETTEXIMAGEPROC)(GLenum target, GLint level, GLenum format, GLenum type, void * pixels);
typedef void (GLAD_API_PTR *PFNGLGETTEXLEVELPARAMETERFVPROC)(GLenum target, GLint level, GLenum pname, GLfloat * params);
typedef void (GLAD_API_PTR *PFNGLGETTEXLEVELPARAMETERIVPROC)(GLenum target, GLint level, GLenum pname, GLint * params);
-typedef void (GLAD_API_PTR *PFNGLGETTEXLEVELPARAMETERXVOESPROC)(GLenum target, GLint level, GLenum pname, GLfixed * params);
typedef void (GLAD_API_PTR *PFNGLGETTEXPARAMETERIIVPROC)(GLenum target, GLenum pname, GLint * params);
typedef void (GLAD_API_PTR *PFNGLGETTEXPARAMETERIUIVPROC)(GLenum target, GLenum pname, GLuint * params);
typedef void (GLAD_API_PTR *PFNGLGETTEXPARAMETERFVPROC)(GLenum target, GLenum pname, GLfloat * params);
typedef void (GLAD_API_PTR *PFNGLGETTEXPARAMETERIVPROC)(GLenum target, GLenum pname, GLint * params);
-typedef void (GLAD_API_PTR *PFNGLGETTEXPARAMETERXVOESPROC)(GLenum target, GLenum pname, GLfixed * params);
typedef void (GLAD_API_PTR *PFNGLGETTEXTUREIMAGEPROC)(GLuint texture, GLint level, GLenum format, GLenum type, GLsizei bufSize, void * pixels);
typedef void (GLAD_API_PTR *PFNGLGETTEXTURELEVELPARAMETERFVPROC)(GLuint texture, GLint level, GLenum pname, GLfloat * params);
typedef void (GLAD_API_PTR *PFNGLGETTEXTURELEVELPARAMETERIVPROC)(GLuint texture, GLint level, GLenum pname, GLint * params);
@@ -2814,8 +3312,20 @@ typedef void (GLAD_API_PTR *PFNGLGETVERTEXATTRIBIVARBPROC)(GLuint index, GLenum
typedef void (GLAD_API_PTR *PFNGLGETNUNIFORMI64VARBPROC)(GLuint program, GLint location, GLsizei bufSize, GLint64 * params);
typedef void (GLAD_API_PTR *PFNGLGETNUNIFORMUI64VARBPROC)(GLuint program, GLint location, GLsizei bufSize, GLuint64 * params);
typedef void (GLAD_API_PTR *PFNGLHINTPROC)(GLenum target, GLenum mode);
-typedef void (GLAD_API_PTR *PFNGLINDEXXOESPROC)(GLfixed component);
-typedef void (GLAD_API_PTR *PFNGLINDEXXVOESPROC)(const GLfixed * component);
+typedef void (GLAD_API_PTR *PFNGLINDEXMASKPROC)(GLuint mask);
+typedef void (GLAD_API_PTR *PFNGLINDEXPOINTERPROC)(GLenum type, GLsizei stride, const void * pointer);
+typedef void (GLAD_API_PTR *PFNGLINDEXDPROC)(GLdouble c);
+typedef void (GLAD_API_PTR *PFNGLINDEXDVPROC)(const GLdouble * c);
+typedef void (GLAD_API_PTR *PFNGLINDEXFPROC)(GLfloat c);
+typedef void (GLAD_API_PTR *PFNGLINDEXFVPROC)(const GLfloat * c);
+typedef void (GLAD_API_PTR *PFNGLINDEXIPROC)(GLint c);
+typedef void (GLAD_API_PTR *PFNGLINDEXIVPROC)(const GLint * c);
+typedef void (GLAD_API_PTR *PFNGLINDEXSPROC)(GLshort c);
+typedef void (GLAD_API_PTR *PFNGLINDEXSVPROC)(const GLshort * c);
+typedef void (GLAD_API_PTR *PFNGLINDEXUBPROC)(GLubyte c);
+typedef void (GLAD_API_PTR *PFNGLINDEXUBVPROC)(const GLubyte * c);
+typedef void (GLAD_API_PTR *PFNGLINITNAMESPROC)(void);
+typedef void (GLAD_API_PTR *PFNGLINTERLEAVEDARRAYSPROC)(GLenum format, GLsizei stride, const void * pointer);
typedef void (GLAD_API_PTR *PFNGLINVALIDATEBUFFERDATAPROC)(GLuint buffer);
typedef void (GLAD_API_PTR *PFNGLINVALIDATEBUFFERSUBDATAPROC)(GLuint buffer, GLintptr offset, GLsizeiptr length);
typedef void (GLAD_API_PTR *PFNGLINVALIDATEFRAMEBUFFERPROC)(GLenum target, GLsizei numAttachments, const GLenum * attachments);
@@ -2830,6 +3340,7 @@ typedef GLboolean (GLAD_API_PTR *PFNGLISENABLEDPROC)(GLenum cap);
typedef GLboolean (GLAD_API_PTR *PFNGLISENABLEDIPROC)(GLenum target, GLuint index);
typedef GLboolean (GLAD_API_PTR *PFNGLISFRAMEBUFFERPROC)(GLuint framebuffer);
typedef GLboolean (GLAD_API_PTR *PFNGLISFRAMEBUFFEREXTPROC)(GLuint framebuffer);
+typedef GLboolean (GLAD_API_PTR *PFNGLISLISTPROC)(GLuint list);
typedef GLboolean (GLAD_API_PTR *PFNGLISNAMEDSTRINGARBPROC)(GLint namelen, const GLchar * name);
typedef GLboolean (GLAD_API_PTR *PFNGLISPROGRAMPROC)(GLuint program);
typedef GLboolean (GLAD_API_PTR *PFNGLISPROGRAMARBPROC)(GLuint program);
@@ -2844,83 +3355,132 @@ typedef GLboolean (GLAD_API_PTR *PFNGLISSYNCPROC)(GLsync sync);
typedef GLboolean (GLAD_API_PTR *PFNGLISTEXTUREPROC)(GLuint texture);
typedef GLboolean (GLAD_API_PTR *PFNGLISTRANSFORMFEEDBACKPROC)(GLuint id);
typedef GLboolean (GLAD_API_PTR *PFNGLISVERTEXARRAYPROC)(GLuint array);
-typedef void (GLAD_API_PTR *PFNGLLIGHTMODELXOESPROC)(GLenum pname, GLfixed param);
-typedef void (GLAD_API_PTR *PFNGLLIGHTMODELXVOESPROC)(GLenum pname, const GLfixed * param);
-typedef void (GLAD_API_PTR *PFNGLLIGHTXOESPROC)(GLenum light, GLenum pname, GLfixed param);
-typedef void (GLAD_API_PTR *PFNGLLIGHTXVOESPROC)(GLenum light, GLenum pname, const GLfixed * params);
+typedef void (GLAD_API_PTR *PFNGLLIGHTMODELFPROC)(GLenum pname, GLfloat param);
+typedef void (GLAD_API_PTR *PFNGLLIGHTMODELFVPROC)(GLenum pname, const GLfloat * params);
+typedef void (GLAD_API_PTR *PFNGLLIGHTMODELIPROC)(GLenum pname, GLint param);
+typedef void (GLAD_API_PTR *PFNGLLIGHTMODELIVPROC)(GLenum pname, const GLint * params);
+typedef void (GLAD_API_PTR *PFNGLLIGHTFPROC)(GLenum light, GLenum pname, GLfloat param);
+typedef void (GLAD_API_PTR *PFNGLLIGHTFVPROC)(GLenum light, GLenum pname, const GLfloat * params);
+typedef void (GLAD_API_PTR *PFNGLLIGHTIPROC)(GLenum light, GLenum pname, GLint param);
+typedef void (GLAD_API_PTR *PFNGLLIGHTIVPROC)(GLenum light, GLenum pname, const GLint * params);
+typedef void (GLAD_API_PTR *PFNGLLINESTIPPLEPROC)(GLint factor, GLushort pattern);
typedef void (GLAD_API_PTR *PFNGLLINEWIDTHPROC)(GLfloat width);
-typedef void (GLAD_API_PTR *PFNGLLINEWIDTHXOESPROC)(GLfixed width);
typedef void (GLAD_API_PTR *PFNGLLINKPROGRAMPROC)(GLuint program);
typedef void (GLAD_API_PTR *PFNGLLINKPROGRAMARBPROC)(GLhandleARB programObj);
-typedef void (GLAD_API_PTR *PFNGLLOADMATRIXXOESPROC)(const GLfixed * m);
+typedef void (GLAD_API_PTR *PFNGLLISTBASEPROC)(GLuint base);
+typedef void (GLAD_API_PTR *PFNGLLOADIDENTITYPROC)(void);
+typedef void (GLAD_API_PTR *PFNGLLOADMATRIXDPROC)(const GLdouble * m);
+typedef void (GLAD_API_PTR *PFNGLLOADMATRIXFPROC)(const GLfloat * m);
+typedef void (GLAD_API_PTR *PFNGLLOADNAMEPROC)(GLuint name);
+typedef void (GLAD_API_PTR *PFNGLLOADTRANSPOSEMATRIXDPROC)(const GLdouble * m);
typedef void (GLAD_API_PTR *PFNGLLOADTRANSPOSEMATRIXDARBPROC)(const GLdouble * m);
+typedef void (GLAD_API_PTR *PFNGLLOADTRANSPOSEMATRIXFPROC)(const GLfloat * m);
typedef void (GLAD_API_PTR *PFNGLLOADTRANSPOSEMATRIXFARBPROC)(const GLfloat * m);
-typedef void (GLAD_API_PTR *PFNGLLOADTRANSPOSEMATRIXXOESPROC)(const GLfixed * m);
typedef void (GLAD_API_PTR *PFNGLLOGICOPPROC)(GLenum opcode);
-typedef void (GLAD_API_PTR *PFNGLMAP1XOESPROC)(GLenum target, GLfixed u1, GLfixed u2, GLint stride, GLint order, GLfixed points);
-typedef void (GLAD_API_PTR *PFNGLMAP2XOESPROC)(GLenum target, GLfixed u1, GLfixed u2, GLint ustride, GLint uorder, GLfixed v1, GLfixed v2, GLint vstride, GLint vorder, GLfixed points);
+typedef void (GLAD_API_PTR *PFNGLMAP1DPROC)(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble * points);
+typedef void (GLAD_API_PTR *PFNGLMAP1FPROC)(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat * points);
+typedef void (GLAD_API_PTR *PFNGLMAP2DPROC)(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble * points);
+typedef void (GLAD_API_PTR *PFNGLMAP2FPROC)(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat * points);
typedef void * (GLAD_API_PTR *PFNGLMAPBUFFERPROC)(GLenum target, GLenum access);
typedef void * (GLAD_API_PTR *PFNGLMAPBUFFERARBPROC)(GLenum target, GLenum access);
typedef void * (GLAD_API_PTR *PFNGLMAPBUFFERRANGEPROC)(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
-typedef void (GLAD_API_PTR *PFNGLMAPGRID1XOESPROC)(GLint n, GLfixed u1, GLfixed u2);
-typedef void (GLAD_API_PTR *PFNGLMAPGRID2XOESPROC)(GLint n, GLfixed u1, GLfixed u2, GLfixed v1, GLfixed v2);
+typedef void (GLAD_API_PTR *PFNGLMAPGRID1DPROC)(GLint un, GLdouble u1, GLdouble u2);
+typedef void (GLAD_API_PTR *PFNGLMAPGRID1FPROC)(GLint un, GLfloat u1, GLfloat u2);
+typedef void (GLAD_API_PTR *PFNGLMAPGRID2DPROC)(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+typedef void (GLAD_API_PTR *PFNGLMAPGRID2FPROC)(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
typedef void * (GLAD_API_PTR *PFNGLMAPNAMEDBUFFERPROC)(GLuint buffer, GLenum access);
typedef void * (GLAD_API_PTR *PFNGLMAPNAMEDBUFFERRANGEPROC)(GLuint buffer, GLintptr offset, GLsizeiptr length, GLbitfield access);
-typedef void (GLAD_API_PTR *PFNGLMATERIALXOESPROC)(GLenum face, GLenum pname, GLfixed param);
-typedef void (GLAD_API_PTR *PFNGLMATERIALXVOESPROC)(GLenum face, GLenum pname, const GLfixed * param);
+typedef void (GLAD_API_PTR *PFNGLMATERIALFPROC)(GLenum face, GLenum pname, GLfloat param);
+typedef void (GLAD_API_PTR *PFNGLMATERIALFVPROC)(GLenum face, GLenum pname, const GLfloat * params);
+typedef void (GLAD_API_PTR *PFNGLMATERIALIPROC)(GLenum face, GLenum pname, GLint param);
+typedef void (GLAD_API_PTR *PFNGLMATERIALIVPROC)(GLenum face, GLenum pname, const GLint * params);
+typedef void (GLAD_API_PTR *PFNGLMATRIXMODEPROC)(GLenum mode);
typedef void (GLAD_API_PTR *PFNGLMEMORYBARRIERPROC)(GLbitfield barriers);
-typedef void (GLAD_API_PTR *PFNGLMEMORYBARRIERBYREGIONPROC)(GLbitfield barriers);
typedef void (GLAD_API_PTR *PFNGLMINSAMPLESHADINGPROC)(GLfloat value);
typedef void (GLAD_API_PTR *PFNGLMINSAMPLESHADINGARBPROC)(GLfloat value);
-typedef void (GLAD_API_PTR *PFNGLMULTMATRIXXOESPROC)(const GLfixed * m);
+typedef void (GLAD_API_PTR *PFNGLMULTMATRIXDPROC)(const GLdouble * m);
+typedef void (GLAD_API_PTR *PFNGLMULTMATRIXFPROC)(const GLfloat * m);
+typedef void (GLAD_API_PTR *PFNGLMULTTRANSPOSEMATRIXDPROC)(const GLdouble * m);
typedef void (GLAD_API_PTR *PFNGLMULTTRANSPOSEMATRIXDARBPROC)(const GLdouble * m);
+typedef void (GLAD_API_PTR *PFNGLMULTTRANSPOSEMATRIXFPROC)(const GLfloat * m);
typedef void (GLAD_API_PTR *PFNGLMULTTRANSPOSEMATRIXFARBPROC)(const GLfloat * m);
-typedef void (GLAD_API_PTR *PFNGLMULTTRANSPOSEMATRIXXOESPROC)(const GLfixed * m);
typedef void (GLAD_API_PTR *PFNGLMULTIDRAWARRAYSPROC)(GLenum mode, const GLint * first, const GLsizei * count, GLsizei drawcount);
typedef void (GLAD_API_PTR *PFNGLMULTIDRAWARRAYSINDIRECTPROC)(GLenum mode, const void * indirect, GLsizei drawcount, GLsizei stride);
typedef void (GLAD_API_PTR *PFNGLMULTIDRAWELEMENTSPROC)(GLenum mode, const GLsizei * count, GLenum type, const void *const* indices, GLsizei drawcount);
typedef void (GLAD_API_PTR *PFNGLMULTIDRAWELEMENTSBASEVERTEXPROC)(GLenum mode, const GLsizei * count, GLenum type, const void *const* indices, GLsizei drawcount, const GLint * basevertex);
typedef void (GLAD_API_PTR *PFNGLMULTIDRAWELEMENTSINDIRECTPROC)(GLenum mode, GLenum type, const void * indirect, GLsizei drawcount, GLsizei stride);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1DPROC)(GLenum target, GLdouble s);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1DARBPROC)(GLenum target, GLdouble s);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1DVPROC)(GLenum target, const GLdouble * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1DVARBPROC)(GLenum target, const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1FPROC)(GLenum target, GLfloat s);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1FARBPROC)(GLenum target, GLfloat s);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1FVPROC)(GLenum target, const GLfloat * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1FVARBPROC)(GLenum target, const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1IPROC)(GLenum target, GLint s);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1IARBPROC)(GLenum target, GLint s);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1IVPROC)(GLenum target, const GLint * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1IVARBPROC)(GLenum target, const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1SPROC)(GLenum target, GLshort s);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1SARBPROC)(GLenum target, GLshort s);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1SVPROC)(GLenum target, const GLshort * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1SVARBPROC)(GLenum target, const GLshort * v);
-typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1XOESPROC)(GLenum texture, GLfixed s);
-typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD1XVOESPROC)(GLenum texture, const GLfixed * coords);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2DPROC)(GLenum target, GLdouble s, GLdouble t);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2DARBPROC)(GLenum target, GLdouble s, GLdouble t);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2DVPROC)(GLenum target, const GLdouble * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2DVARBPROC)(GLenum target, const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2FPROC)(GLenum target, GLfloat s, GLfloat t);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2FARBPROC)(GLenum target, GLfloat s, GLfloat t);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2FVPROC)(GLenum target, const GLfloat * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2FVARBPROC)(GLenum target, const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2IPROC)(GLenum target, GLint s, GLint t);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2IARBPROC)(GLenum target, GLint s, GLint t);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2IVPROC)(GLenum target, const GLint * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2IVARBPROC)(GLenum target, const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2SPROC)(GLenum target, GLshort s, GLshort t);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2SARBPROC)(GLenum target, GLshort s, GLshort t);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2SVPROC)(GLenum target, const GLshort * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2SVARBPROC)(GLenum target, const GLshort * v);
-typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2XOESPROC)(GLenum texture, GLfixed s, GLfixed t);
-typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD2XVOESPROC)(GLenum texture, const GLfixed * coords);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3DPROC)(GLenum target, GLdouble s, GLdouble t, GLdouble r);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3DARBPROC)(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3DVPROC)(GLenum target, const GLdouble * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3DVARBPROC)(GLenum target, const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3FPROC)(GLenum target, GLfloat s, GLfloat t, GLfloat r);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3FARBPROC)(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3FVPROC)(GLenum target, const GLfloat * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3FVARBPROC)(GLenum target, const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3IPROC)(GLenum target, GLint s, GLint t, GLint r);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3IARBPROC)(GLenum target, GLint s, GLint t, GLint r);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3IVPROC)(GLenum target, const GLint * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3IVARBPROC)(GLenum target, const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3SPROC)(GLenum target, GLshort s, GLshort t, GLshort r);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3SARBPROC)(GLenum target, GLshort s, GLshort t, GLshort r);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3SVPROC)(GLenum target, const GLshort * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3SVARBPROC)(GLenum target, const GLshort * v);
-typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3XOESPROC)(GLenum texture, GLfixed s, GLfixed t, GLfixed r);
-typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD3XVOESPROC)(GLenum texture, const GLfixed * coords);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4DPROC)(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4DARBPROC)(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4DVPROC)(GLenum target, const GLdouble * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4DVARBPROC)(GLenum target, const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4FPROC)(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4FARBPROC)(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4FVPROC)(GLenum target, const GLfloat * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4FVARBPROC)(GLenum target, const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4IPROC)(GLenum target, GLint s, GLint t, GLint r, GLint q);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4IARBPROC)(GLenum target, GLint s, GLint t, GLint r, GLint q);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4IVPROC)(GLenum target, const GLint * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4IVARBPROC)(GLenum target, const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4SPROC)(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4SARBPROC)(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4SVPROC)(GLenum target, const GLshort * v);
typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4SVARBPROC)(GLenum target, const GLshort * v);
-typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4XOESPROC)(GLenum texture, GLfixed s, GLfixed t, GLfixed r, GLfixed q);
-typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORD4XVOESPROC)(GLenum texture, const GLfixed * coords);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORDP1UIPROC)(GLenum texture, GLenum type, GLuint coords);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORDP1UIVPROC)(GLenum texture, GLenum type, const GLuint * coords);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORDP2UIPROC)(GLenum texture, GLenum type, GLuint coords);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORDP2UIVPROC)(GLenum texture, GLenum type, const GLuint * coords);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORDP3UIPROC)(GLenum texture, GLenum type, GLuint coords);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORDP3UIVPROC)(GLenum texture, GLenum type, const GLuint * coords);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORDP4UIPROC)(GLenum texture, GLenum type, GLuint coords);
+typedef void (GLAD_API_PTR *PFNGLMULTITEXCOORDP4UIVPROC)(GLenum texture, GLenum type, const GLuint * coords);
typedef void (GLAD_API_PTR *PFNGLNAMEDBUFFERDATAPROC)(GLuint buffer, GLsizeiptr size, const void * data, GLenum usage);
typedef void (GLAD_API_PTR *PFNGLNAMEDBUFFERSTORAGEPROC)(GLuint buffer, GLsizeiptr size, const void * data, GLbitfield flags);
typedef void (GLAD_API_PTR *PFNGLNAMEDBUFFERSUBDATAPROC)(GLuint buffer, GLintptr offset, GLsizeiptr size, const void * data);
@@ -2935,35 +3495,51 @@ typedef void (GLAD_API_PTR *PFNGLNAMEDFRAMEBUFFERTEXTURELAYERPROC)(GLuint frameb
typedef void (GLAD_API_PTR *PFNGLNAMEDRENDERBUFFERSTORAGEPROC)(GLuint renderbuffer, GLenum internalformat, GLsizei width, GLsizei height);
typedef void (GLAD_API_PTR *PFNGLNAMEDRENDERBUFFERSTORAGEMULTISAMPLEPROC)(GLuint renderbuffer, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
typedef void (GLAD_API_PTR *PFNGLNAMEDSTRINGARBPROC)(GLenum type, GLint namelen, const GLchar * name, GLint stringlen, const GLchar * string);
-typedef void (GLAD_API_PTR *PFNGLNORMAL3XOESPROC)(GLfixed nx, GLfixed ny, GLfixed nz);
-typedef void (GLAD_API_PTR *PFNGLNORMAL3XVOESPROC)(const GLfixed * coords);
+typedef void (GLAD_API_PTR *PFNGLNEWLISTPROC)(GLuint list, GLenum mode);
+typedef void (GLAD_API_PTR *PFNGLNORMAL3BPROC)(GLbyte nx, GLbyte ny, GLbyte nz);
+typedef void (GLAD_API_PTR *PFNGLNORMAL3BVPROC)(const GLbyte * v);
+typedef void (GLAD_API_PTR *PFNGLNORMAL3DPROC)(GLdouble nx, GLdouble ny, GLdouble nz);
+typedef void (GLAD_API_PTR *PFNGLNORMAL3DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLNORMAL3FPROC)(GLfloat nx, GLfloat ny, GLfloat nz);
+typedef void (GLAD_API_PTR *PFNGLNORMAL3FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLNORMAL3IPROC)(GLint nx, GLint ny, GLint nz);
+typedef void (GLAD_API_PTR *PFNGLNORMAL3IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLNORMAL3SPROC)(GLshort nx, GLshort ny, GLshort nz);
+typedef void (GLAD_API_PTR *PFNGLNORMAL3SVPROC)(const GLshort * v);
+typedef void (GLAD_API_PTR *PFNGLNORMALP3UIPROC)(GLenum type, GLuint coords);
+typedef void (GLAD_API_PTR *PFNGLNORMALP3UIVPROC)(GLenum type, const GLuint * coords);
+typedef void (GLAD_API_PTR *PFNGLNORMALPOINTERPROC)(GLenum type, GLsizei stride, const void * pointer);
typedef void (GLAD_API_PTR *PFNGLOBJECTLABELPROC)(GLenum identifier, GLuint name, GLsizei length, const GLchar * label);
typedef void (GLAD_API_PTR *PFNGLOBJECTPTRLABELPROC)(const void * ptr, GLsizei length, const GLchar * label);
-typedef void (GLAD_API_PTR *PFNGLORTHOXOESPROC)(GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f);
-typedef void (GLAD_API_PTR *PFNGLPASSTHROUGHXOESPROC)(GLfixed token);
+typedef void (GLAD_API_PTR *PFNGLORTHOPROC)(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+typedef void (GLAD_API_PTR *PFNGLPASSTHROUGHPROC)(GLfloat token);
typedef void (GLAD_API_PTR *PFNGLPATCHPARAMETERFVPROC)(GLenum pname, const GLfloat * values);
typedef void (GLAD_API_PTR *PFNGLPATCHPARAMETERIPROC)(GLenum pname, GLint value);
typedef void (GLAD_API_PTR *PFNGLPAUSETRANSFORMFEEDBACKPROC)(void);
-typedef void (GLAD_API_PTR *PFNGLPIXELMAPXPROC)(GLenum map, GLint size, const GLfixed * values);
+typedef void (GLAD_API_PTR *PFNGLPIXELMAPFVPROC)(GLenum map, GLsizei mapsize, const GLfloat * values);
+typedef void (GLAD_API_PTR *PFNGLPIXELMAPUIVPROC)(GLenum map, GLsizei mapsize, const GLuint * values);
+typedef void (GLAD_API_PTR *PFNGLPIXELMAPUSVPROC)(GLenum map, GLsizei mapsize, const GLushort * values);
typedef void (GLAD_API_PTR *PFNGLPIXELSTOREFPROC)(GLenum pname, GLfloat param);
typedef void (GLAD_API_PTR *PFNGLPIXELSTOREIPROC)(GLenum pname, GLint param);
-typedef void (GLAD_API_PTR *PFNGLPIXELSTOREXPROC)(GLenum pname, GLfixed param);
-typedef void (GLAD_API_PTR *PFNGLPIXELTRANSFERXOESPROC)(GLenum pname, GLfixed param);
-typedef void (GLAD_API_PTR *PFNGLPIXELZOOMXOESPROC)(GLfixed xfactor, GLfixed yfactor);
+typedef void (GLAD_API_PTR *PFNGLPIXELTRANSFERFPROC)(GLenum pname, GLfloat param);
+typedef void (GLAD_API_PTR *PFNGLPIXELTRANSFERIPROC)(GLenum pname, GLint param);
+typedef void (GLAD_API_PTR *PFNGLPIXELZOOMPROC)(GLfloat xfactor, GLfloat yfactor);
typedef void (GLAD_API_PTR *PFNGLPOINTPARAMETERFPROC)(GLenum pname, GLfloat param);
typedef void (GLAD_API_PTR *PFNGLPOINTPARAMETERFVPROC)(GLenum pname, const GLfloat * params);
typedef void (GLAD_API_PTR *PFNGLPOINTPARAMETERIPROC)(GLenum pname, GLint param);
typedef void (GLAD_API_PTR *PFNGLPOINTPARAMETERIVPROC)(GLenum pname, const GLint * params);
-typedef void (GLAD_API_PTR *PFNGLPOINTPARAMETERXVOESPROC)(GLenum pname, const GLfixed * params);
typedef void (GLAD_API_PTR *PFNGLPOINTSIZEPROC)(GLfloat size);
-typedef void (GLAD_API_PTR *PFNGLPOINTSIZEXOESPROC)(GLfixed size);
typedef void (GLAD_API_PTR *PFNGLPOLYGONMODEPROC)(GLenum face, GLenum mode);
typedef void (GLAD_API_PTR *PFNGLPOLYGONOFFSETPROC)(GLfloat factor, GLfloat units);
-typedef void (GLAD_API_PTR *PFNGLPOLYGONOFFSETXOESPROC)(GLfixed factor, GLfixed units);
+typedef void (GLAD_API_PTR *PFNGLPOLYGONSTIPPLEPROC)(const GLubyte * mask);
+typedef void (GLAD_API_PTR *PFNGLPOPATTRIBPROC)(void);
+typedef void (GLAD_API_PTR *PFNGLPOPCLIENTATTRIBPROC)(void);
typedef void (GLAD_API_PTR *PFNGLPOPDEBUGGROUPPROC)(void);
+typedef void (GLAD_API_PTR *PFNGLPOPMATRIXPROC)(void);
+typedef void (GLAD_API_PTR *PFNGLPOPNAMEPROC)(void);
typedef void (GLAD_API_PTR *PFNGLPRIMITIVEBOUNDINGBOXARBPROC)(GLfloat minX, GLfloat minY, GLfloat minZ, GLfloat minW, GLfloat maxX, GLfloat maxY, GLfloat maxZ, GLfloat maxW);
typedef void (GLAD_API_PTR *PFNGLPRIMITIVERESTARTINDEXPROC)(GLuint index);
-typedef void (GLAD_API_PTR *PFNGLPRIORITIZETEXTURESXOESPROC)(GLsizei n, const GLuint * textures, const GLfixed * priorities);
+typedef void (GLAD_API_PTR *PFNGLPRIORITIZETEXTURESPROC)(GLsizei n, const GLuint * textures, const GLfloat * priorities);
typedef void (GLAD_API_PTR *PFNGLPROGRAMBINARYPROC)(GLuint program, GLenum binaryFormat, const void * binary, GLsizei length);
typedef void (GLAD_API_PTR *PFNGLPROGRAMENVPARAMETER4DARBPROC)(GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
typedef void (GLAD_API_PTR *PFNGLPROGRAMENVPARAMETER4DVARBPROC)(GLenum target, GLuint index, const GLdouble * params);
@@ -3043,25 +3619,55 @@ typedef void (GLAD_API_PTR *PFNGLPROGRAMUNIFORMMATRIX4X2FVPROC)(GLuint program,
typedef void (GLAD_API_PTR *PFNGLPROGRAMUNIFORMMATRIX4X3DVPROC)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble * value);
typedef void (GLAD_API_PTR *PFNGLPROGRAMUNIFORMMATRIX4X3FVPROC)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat * value);
typedef void (GLAD_API_PTR *PFNGLPROVOKINGVERTEXPROC)(GLenum mode);
+typedef void (GLAD_API_PTR *PFNGLPUSHATTRIBPROC)(GLbitfield mask);
+typedef void (GLAD_API_PTR *PFNGLPUSHCLIENTATTRIBPROC)(GLbitfield mask);
typedef void (GLAD_API_PTR *PFNGLPUSHDEBUGGROUPPROC)(GLenum source, GLuint id, GLsizei length, const GLchar * message);
+typedef void (GLAD_API_PTR *PFNGLPUSHMATRIXPROC)(void);
+typedef void (GLAD_API_PTR *PFNGLPUSHNAMEPROC)(GLuint name);
typedef void (GLAD_API_PTR *PFNGLQUERYCOUNTERPROC)(GLuint id, GLenum target);
-typedef void (GLAD_API_PTR *PFNGLRASTERPOS2XOESPROC)(GLfixed x, GLfixed y);
-typedef void (GLAD_API_PTR *PFNGLRASTERPOS2XVOESPROC)(const GLfixed * coords);
-typedef void (GLAD_API_PTR *PFNGLRASTERPOS3XOESPROC)(GLfixed x, GLfixed y, GLfixed z);
-typedef void (GLAD_API_PTR *PFNGLRASTERPOS3XVOESPROC)(const GLfixed * coords);
-typedef void (GLAD_API_PTR *PFNGLRASTERPOS4XOESPROC)(GLfixed x, GLfixed y, GLfixed z, GLfixed w);
-typedef void (GLAD_API_PTR *PFNGLRASTERPOS4XVOESPROC)(const GLfixed * coords);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS2DPROC)(GLdouble x, GLdouble y);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS2DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS2FPROC)(GLfloat x, GLfloat y);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS2FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS2IPROC)(GLint x, GLint y);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS2IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS2SPROC)(GLshort x, GLshort y);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS2SVPROC)(const GLshort * v);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS3DPROC)(GLdouble x, GLdouble y, GLdouble z);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS3DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS3FPROC)(GLfloat x, GLfloat y, GLfloat z);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS3FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS3IPROC)(GLint x, GLint y, GLint z);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS3IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS3SPROC)(GLshort x, GLshort y, GLshort z);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS3SVPROC)(const GLshort * v);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS4DPROC)(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS4DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS4FPROC)(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS4FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS4IPROC)(GLint x, GLint y, GLint z, GLint w);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS4IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS4SPROC)(GLshort x, GLshort y, GLshort z, GLshort w);
+typedef void (GLAD_API_PTR *PFNGLRASTERPOS4SVPROC)(const GLshort * v);
typedef void (GLAD_API_PTR *PFNGLREADBUFFERPROC)(GLenum src);
typedef void (GLAD_API_PTR *PFNGLREADPIXELSPROC)(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, void * pixels);
-typedef void (GLAD_API_PTR *PFNGLRECTXOESPROC)(GLfixed x1, GLfixed y1, GLfixed x2, GLfixed y2);
-typedef void (GLAD_API_PTR *PFNGLRECTXVOESPROC)(const GLfixed * v1, const GLfixed * v2);
+typedef void (GLAD_API_PTR *PFNGLRECTDPROC)(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+typedef void (GLAD_API_PTR *PFNGLRECTDVPROC)(const GLdouble * v1, const GLdouble * v2);
+typedef void (GLAD_API_PTR *PFNGLRECTFPROC)(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+typedef void (GLAD_API_PTR *PFNGLRECTFVPROC)(const GLfloat * v1, const GLfloat * v2);
+typedef void (GLAD_API_PTR *PFNGLRECTIPROC)(GLint x1, GLint y1, GLint x2, GLint y2);
+typedef void (GLAD_API_PTR *PFNGLRECTIVPROC)(const GLint * v1, const GLint * v2);
+typedef void (GLAD_API_PTR *PFNGLRECTSPROC)(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+typedef void (GLAD_API_PTR *PFNGLRECTSVPROC)(const GLshort * v1, const GLshort * v2);
typedef void (GLAD_API_PTR *PFNGLRELEASESHADERCOMPILERPROC)(void);
+typedef GLint (GLAD_API_PTR *PFNGLRENDERMODEPROC)(GLenum mode);
typedef void (GLAD_API_PTR *PFNGLRENDERBUFFERSTORAGEPROC)(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
typedef void (GLAD_API_PTR *PFNGLRENDERBUFFERSTORAGEEXTPROC)(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
typedef void (GLAD_API_PTR *PFNGLRENDERBUFFERSTORAGEMULTISAMPLEPROC)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
typedef void (GLAD_API_PTR *PFNGLRENDERBUFFERSTORAGEMULTISAMPLEEXTPROC)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
typedef void (GLAD_API_PTR *PFNGLRESUMETRANSFORMFEEDBACKPROC)(void);
-typedef void (GLAD_API_PTR *PFNGLROTATEXOESPROC)(GLfixed angle, GLfixed x, GLfixed y, GLfixed z);
+typedef void (GLAD_API_PTR *PFNGLROTATEDPROC)(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+typedef void (GLAD_API_PTR *PFNGLROTATEFPROC)(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
typedef void (GLAD_API_PTR *PFNGLSAMPLECOVERAGEPROC)(GLfloat value, GLboolean invert);
typedef void (GLAD_API_PTR *PFNGLSAMPLECOVERAGEARBPROC)(GLfloat value, GLboolean invert);
typedef void (GLAD_API_PTR *PFNGLSAMPLEMASKIPROC)(GLuint maskNumber, GLbitfield mask);
@@ -3071,11 +3677,33 @@ typedef void (GLAD_API_PTR *PFNGLSAMPLERPARAMETERFPROC)(GLuint sampler, GLenum p
typedef void (GLAD_API_PTR *PFNGLSAMPLERPARAMETERFVPROC)(GLuint sampler, GLenum pname, const GLfloat * param);
typedef void (GLAD_API_PTR *PFNGLSAMPLERPARAMETERIPROC)(GLuint sampler, GLenum pname, GLint param);
typedef void (GLAD_API_PTR *PFNGLSAMPLERPARAMETERIVPROC)(GLuint sampler, GLenum pname, const GLint * param);
-typedef void (GLAD_API_PTR *PFNGLSCALEXOESPROC)(GLfixed x, GLfixed y, GLfixed z);
+typedef void (GLAD_API_PTR *PFNGLSCALEDPROC)(GLdouble x, GLdouble y, GLdouble z);
+typedef void (GLAD_API_PTR *PFNGLSCALEFPROC)(GLfloat x, GLfloat y, GLfloat z);
typedef void (GLAD_API_PTR *PFNGLSCISSORPROC)(GLint x, GLint y, GLsizei width, GLsizei height);
typedef void (GLAD_API_PTR *PFNGLSCISSORARRAYVPROC)(GLuint first, GLsizei count, const GLint * v);
typedef void (GLAD_API_PTR *PFNGLSCISSORINDEXEDPROC)(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
typedef void (GLAD_API_PTR *PFNGLSCISSORINDEXEDVPROC)(GLuint index, const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3BPROC)(GLbyte red, GLbyte green, GLbyte blue);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3BVPROC)(const GLbyte * v);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3DPROC)(GLdouble red, GLdouble green, GLdouble blue);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3FPROC)(GLfloat red, GLfloat green, GLfloat blue);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3IPROC)(GLint red, GLint green, GLint blue);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3SPROC)(GLshort red, GLshort green, GLshort blue);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3SVPROC)(const GLshort * v);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3UBPROC)(GLubyte red, GLubyte green, GLubyte blue);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3UBVPROC)(const GLubyte * v);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3UIPROC)(GLuint red, GLuint green, GLuint blue);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3UIVPROC)(const GLuint * v);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3USPROC)(GLushort red, GLushort green, GLushort blue);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLOR3USVPROC)(const GLushort * v);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLORP3UIPROC)(GLenum type, GLuint color);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLORP3UIVPROC)(GLenum type, const GLuint * color);
+typedef void (GLAD_API_PTR *PFNGLSECONDARYCOLORPOINTERPROC)(GLint size, GLenum type, GLsizei stride, const void * pointer);
+typedef void (GLAD_API_PTR *PFNGLSELECTBUFFERPROC)(GLsizei size, GLuint * buffer);
+typedef void (GLAD_API_PTR *PFNGLSHADEMODELPROC)(GLenum mode);
typedef void (GLAD_API_PTR *PFNGLSHADERBINARYPROC)(GLsizei count, const GLuint * shaders, GLenum binaryFormat, const void * binary, GLsizei length);
typedef void (GLAD_API_PTR *PFNGLSHADERSOURCEPROC)(GLuint shader, GLsizei count, const GLchar *const* string, const GLint * length);
typedef void (GLAD_API_PTR *PFNGLSHADERSOURCEARBPROC)(GLhandleARB shaderObj, GLsizei count, const GLcharARB ** string, const GLint * length);
@@ -3089,18 +3717,57 @@ typedef void (GLAD_API_PTR *PFNGLSTENCILOPPROC)(GLenum fail, GLenum zfail, GLenu
typedef void (GLAD_API_PTR *PFNGLSTENCILOPSEPARATEPROC)(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
typedef void (GLAD_API_PTR *PFNGLTEXBUFFERPROC)(GLenum target, GLenum internalformat, GLuint buffer);
typedef void (GLAD_API_PTR *PFNGLTEXBUFFERRANGEPROC)(GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
-typedef void (GLAD_API_PTR *PFNGLTEXCOORD1XOESPROC)(GLfixed s);
-typedef void (GLAD_API_PTR *PFNGLTEXCOORD1XVOESPROC)(const GLfixed * coords);
-typedef void (GLAD_API_PTR *PFNGLTEXCOORD2XOESPROC)(GLfixed s, GLfixed t);
-typedef void (GLAD_API_PTR *PFNGLTEXCOORD2XVOESPROC)(const GLfixed * coords);
-typedef void (GLAD_API_PTR *PFNGLTEXCOORD3XOESPROC)(GLfixed s, GLfixed t, GLfixed r);
-typedef void (GLAD_API_PTR *PFNGLTEXCOORD3XVOESPROC)(const GLfixed * coords);
-typedef void (GLAD_API_PTR *PFNGLTEXCOORD4XOESPROC)(GLfixed s, GLfixed t, GLfixed r, GLfixed q);
-typedef void (GLAD_API_PTR *PFNGLTEXCOORD4XVOESPROC)(const GLfixed * coords);
-typedef void (GLAD_API_PTR *PFNGLTEXENVXOESPROC)(GLenum target, GLenum pname, GLfixed param);
-typedef void (GLAD_API_PTR *PFNGLTEXENVXVOESPROC)(GLenum target, GLenum pname, const GLfixed * params);
-typedef void (GLAD_API_PTR *PFNGLTEXGENXOESPROC)(GLenum coord, GLenum pname, GLfixed param);
-typedef void (GLAD_API_PTR *PFNGLTEXGENXVOESPROC)(GLenum coord, GLenum pname, const GLfixed * params);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD1DPROC)(GLdouble s);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD1DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD1FPROC)(GLfloat s);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD1FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD1IPROC)(GLint s);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD1IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD1SPROC)(GLshort s);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD1SVPROC)(const GLshort * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD2DPROC)(GLdouble s, GLdouble t);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD2DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD2FPROC)(GLfloat s, GLfloat t);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD2FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD2IPROC)(GLint s, GLint t);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD2IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD2SPROC)(GLshort s, GLshort t);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD2SVPROC)(const GLshort * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD3DPROC)(GLdouble s, GLdouble t, GLdouble r);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD3DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD3FPROC)(GLfloat s, GLfloat t, GLfloat r);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD3FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD3IPROC)(GLint s, GLint t, GLint r);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD3IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD3SPROC)(GLshort s, GLshort t, GLshort r);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD3SVPROC)(const GLshort * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD4DPROC)(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD4DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD4FPROC)(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD4FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD4IPROC)(GLint s, GLint t, GLint r, GLint q);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD4IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD4SPROC)(GLshort s, GLshort t, GLshort r, GLshort q);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORD4SVPROC)(const GLshort * v);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORDP1UIPROC)(GLenum type, GLuint coords);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORDP1UIVPROC)(GLenum type, const GLuint * coords);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORDP2UIPROC)(GLenum type, GLuint coords);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORDP2UIVPROC)(GLenum type, const GLuint * coords);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORDP3UIPROC)(GLenum type, GLuint coords);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORDP3UIVPROC)(GLenum type, const GLuint * coords);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORDP4UIPROC)(GLenum type, GLuint coords);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORDP4UIVPROC)(GLenum type, const GLuint * coords);
+typedef void (GLAD_API_PTR *PFNGLTEXCOORDPOINTERPROC)(GLint size, GLenum type, GLsizei stride, const void * pointer);
+typedef void (GLAD_API_PTR *PFNGLTEXENVFPROC)(GLenum target, GLenum pname, GLfloat param);
+typedef void (GLAD_API_PTR *PFNGLTEXENVFVPROC)(GLenum target, GLenum pname, const GLfloat * params);
+typedef void (GLAD_API_PTR *PFNGLTEXENVIPROC)(GLenum target, GLenum pname, GLint param);
+typedef void (GLAD_API_PTR *PFNGLTEXENVIVPROC)(GLenum target, GLenum pname, const GLint * params);
+typedef void (GLAD_API_PTR *PFNGLTEXGENDPROC)(GLenum coord, GLenum pname, GLdouble param);
+typedef void (GLAD_API_PTR *PFNGLTEXGENDVPROC)(GLenum coord, GLenum pname, const GLdouble * params);
+typedef void (GLAD_API_PTR *PFNGLTEXGENFPROC)(GLenum coord, GLenum pname, GLfloat param);
+typedef void (GLAD_API_PTR *PFNGLTEXGENFVPROC)(GLenum coord, GLenum pname, const GLfloat * params);
+typedef void (GLAD_API_PTR *PFNGLTEXGENIPROC)(GLenum coord, GLenum pname, GLint param);
+typedef void (GLAD_API_PTR *PFNGLTEXGENIVPROC)(GLenum coord, GLenum pname, const GLint * params);
typedef void (GLAD_API_PTR *PFNGLTEXIMAGE1DPROC)(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const void * pixels);
typedef void (GLAD_API_PTR *PFNGLTEXIMAGE2DPROC)(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const void * pixels);
typedef void (GLAD_API_PTR *PFNGLTEXIMAGE2DMULTISAMPLEPROC)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
@@ -3112,8 +3779,6 @@ typedef void (GLAD_API_PTR *PFNGLTEXPARAMETERFPROC)(GLenum target, GLenum pname,
typedef void (GLAD_API_PTR *PFNGLTEXPARAMETERFVPROC)(GLenum target, GLenum pname, const GLfloat * params);
typedef void (GLAD_API_PTR *PFNGLTEXPARAMETERIPROC)(GLenum target, GLenum pname, GLint param);
typedef void (GLAD_API_PTR *PFNGLTEXPARAMETERIVPROC)(GLenum target, GLenum pname, const GLint * params);
-typedef void (GLAD_API_PTR *PFNGLTEXPARAMETERXOESPROC)(GLenum target, GLenum pname, GLfixed param);
-typedef void (GLAD_API_PTR *PFNGLTEXPARAMETERXVOESPROC)(GLenum target, GLenum pname, const GLfixed * params);
typedef void (GLAD_API_PTR *PFNGLTEXSTORAGE1DPROC)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
typedef void (GLAD_API_PTR *PFNGLTEXSTORAGE2DPROC)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
typedef void (GLAD_API_PTR *PFNGLTEXSTORAGE2DMULTISAMPLEPROC)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
@@ -3142,7 +3807,8 @@ typedef void (GLAD_API_PTR *PFNGLTEXTUREVIEWPROC)(GLuint texture, GLenum target,
typedef void (GLAD_API_PTR *PFNGLTRANSFORMFEEDBACKBUFFERBASEPROC)(GLuint xfb, GLuint index, GLuint buffer);
typedef void (GLAD_API_PTR *PFNGLTRANSFORMFEEDBACKBUFFERRANGEPROC)(GLuint xfb, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
typedef void (GLAD_API_PTR *PFNGLTRANSFORMFEEDBACKVARYINGSPROC)(GLuint program, GLsizei count, const GLchar *const* varyings, GLenum bufferMode);
-typedef void (GLAD_API_PTR *PFNGLTRANSLATEXOESPROC)(GLfixed x, GLfixed y, GLfixed z);
+typedef void (GLAD_API_PTR *PFNGLTRANSLATEDPROC)(GLdouble x, GLdouble y, GLdouble z);
+typedef void (GLAD_API_PTR *PFNGLTRANSLATEFPROC)(GLfloat x, GLfloat y, GLfloat z);
typedef void (GLAD_API_PTR *PFNGLUNIFORM1DPROC)(GLint location, GLdouble x);
typedef void (GLAD_API_PTR *PFNGLUNIFORM1DVPROC)(GLint location, GLsizei count, const GLdouble * value);
typedef void (GLAD_API_PTR *PFNGLUNIFORM1FPROC)(GLint location, GLfloat v0);
@@ -3239,12 +3905,30 @@ typedef void (GLAD_API_PTR *PFNGLUSEPROGRAMSTAGESPROC)(GLuint pipeline, GLbitfie
typedef void (GLAD_API_PTR *PFNGLVALIDATEPROGRAMPROC)(GLuint program);
typedef void (GLAD_API_PTR *PFNGLVALIDATEPROGRAMARBPROC)(GLhandleARB programObj);
typedef void (GLAD_API_PTR *PFNGLVALIDATEPROGRAMPIPELINEPROC)(GLuint pipeline);
-typedef void (GLAD_API_PTR *PFNGLVERTEX2XOESPROC)(GLfixed x);
-typedef void (GLAD_API_PTR *PFNGLVERTEX2XVOESPROC)(const GLfixed * coords);
-typedef void (GLAD_API_PTR *PFNGLVERTEX3XOESPROC)(GLfixed x, GLfixed y);
-typedef void (GLAD_API_PTR *PFNGLVERTEX3XVOESPROC)(const GLfixed * coords);
-typedef void (GLAD_API_PTR *PFNGLVERTEX4XOESPROC)(GLfixed x, GLfixed y, GLfixed z);
-typedef void (GLAD_API_PTR *PFNGLVERTEX4XVOESPROC)(const GLfixed * coords);
+typedef void (GLAD_API_PTR *PFNGLVERTEX2DPROC)(GLdouble x, GLdouble y);
+typedef void (GLAD_API_PTR *PFNGLVERTEX2DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLVERTEX2FPROC)(GLfloat x, GLfloat y);
+typedef void (GLAD_API_PTR *PFNGLVERTEX2FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLVERTEX2IPROC)(GLint x, GLint y);
+typedef void (GLAD_API_PTR *PFNGLVERTEX2IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLVERTEX2SPROC)(GLshort x, GLshort y);
+typedef void (GLAD_API_PTR *PFNGLVERTEX2SVPROC)(const GLshort * v);
+typedef void (GLAD_API_PTR *PFNGLVERTEX3DPROC)(GLdouble x, GLdouble y, GLdouble z);
+typedef void (GLAD_API_PTR *PFNGLVERTEX3DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLVERTEX3FPROC)(GLfloat x, GLfloat y, GLfloat z);
+typedef void (GLAD_API_PTR *PFNGLVERTEX3FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLVERTEX3IPROC)(GLint x, GLint y, GLint z);
+typedef void (GLAD_API_PTR *PFNGLVERTEX3IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLVERTEX3SPROC)(GLshort x, GLshort y, GLshort z);
+typedef void (GLAD_API_PTR *PFNGLVERTEX3SVPROC)(const GLshort * v);
+typedef void (GLAD_API_PTR *PFNGLVERTEX4DPROC)(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+typedef void (GLAD_API_PTR *PFNGLVERTEX4DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLVERTEX4FPROC)(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+typedef void (GLAD_API_PTR *PFNGLVERTEX4FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLVERTEX4IPROC)(GLint x, GLint y, GLint z, GLint w);
+typedef void (GLAD_API_PTR *PFNGLVERTEX4IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLVERTEX4SPROC)(GLshort x, GLshort y, GLshort z, GLshort w);
+typedef void (GLAD_API_PTR *PFNGLVERTEX4SVPROC)(const GLshort * v);
typedef void (GLAD_API_PTR *PFNGLVERTEXARRAYATTRIBBINDINGPROC)(GLuint vaobj, GLuint attribindex, GLuint bindingindex);
typedef void (GLAD_API_PTR *PFNGLVERTEXARRAYATTRIBFORMATPROC)(GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset);
typedef void (GLAD_API_PTR *PFNGLVERTEXARRAYATTRIBIFORMATPROC)(GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
@@ -3372,15 +4056,38 @@ typedef void (GLAD_API_PTR *PFNGLVERTEXATTRIBP4UIVPROC)(GLuint index, GLenum typ
typedef void (GLAD_API_PTR *PFNGLVERTEXATTRIBPOINTERPROC)(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void * pointer);
typedef void (GLAD_API_PTR *PFNGLVERTEXATTRIBPOINTERARBPROC)(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void * pointer);
typedef void (GLAD_API_PTR *PFNGLVERTEXBINDINGDIVISORPROC)(GLuint bindingindex, GLuint divisor);
+typedef void (GLAD_API_PTR *PFNGLVERTEXP2UIPROC)(GLenum type, GLuint value);
+typedef void (GLAD_API_PTR *PFNGLVERTEXP2UIVPROC)(GLenum type, const GLuint * value);
+typedef void (GLAD_API_PTR *PFNGLVERTEXP3UIPROC)(GLenum type, GLuint value);
+typedef void (GLAD_API_PTR *PFNGLVERTEXP3UIVPROC)(GLenum type, const GLuint * value);
+typedef void (GLAD_API_PTR *PFNGLVERTEXP4UIPROC)(GLenum type, GLuint value);
+typedef void (GLAD_API_PTR *PFNGLVERTEXP4UIVPROC)(GLenum type, const GLuint * value);
+typedef void (GLAD_API_PTR *PFNGLVERTEXPOINTERPROC)(GLint size, GLenum type, GLsizei stride, const void * pointer);
typedef void (GLAD_API_PTR *PFNGLVIEWPORTPROC)(GLint x, GLint y, GLsizei width, GLsizei height);
typedef void (GLAD_API_PTR *PFNGLVIEWPORTARRAYVPROC)(GLuint first, GLsizei count, const GLfloat * v);
typedef void (GLAD_API_PTR *PFNGLVIEWPORTINDEXEDFPROC)(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
typedef void (GLAD_API_PTR *PFNGLVIEWPORTINDEXEDFVPROC)(GLuint index, const GLfloat * v);
typedef void (GLAD_API_PTR *PFNGLWAITSYNCPROC)(GLsync sync, GLbitfield flags, GLuint64 timeout);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS2DPROC)(GLdouble x, GLdouble y);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS2DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS2FPROC)(GLfloat x, GLfloat y);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS2FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS2IPROC)(GLint x, GLint y);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS2IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS2SPROC)(GLshort x, GLshort y);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS2SVPROC)(const GLshort * v);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS3DPROC)(GLdouble x, GLdouble y, GLdouble z);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS3DVPROC)(const GLdouble * v);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS3FPROC)(GLfloat x, GLfloat y, GLfloat z);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS3FVPROC)(const GLfloat * v);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS3IPROC)(GLint x, GLint y, GLint z);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS3IVPROC)(const GLint * v);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS3SPROC)(GLshort x, GLshort y, GLshort z);
+typedef void (GLAD_API_PTR *PFNGLWINDOWPOS3SVPROC)(const GLshort * v);
-GLAD_API_CALL PFNGLACCUMXOESPROC glad_glAccumxOES;
-GLAD_API_CALL PFNGLACCUMXOESPROC glad_debug_glAccumxOES;
-#define glAccumxOES glad_debug_glAccumxOES
+GLAD_API_CALL PFNGLACCUMPROC glad_glAccum;
+GLAD_API_CALL PFNGLACCUMPROC glad_debug_glAccum;
+#define glAccum glad_debug_glAccum
GLAD_API_CALL PFNGLACTIVESHADERPROGRAMPROC glad_glActiveShaderProgram;
GLAD_API_CALL PFNGLACTIVESHADERPROGRAMPROC glad_debug_glActiveShaderProgram;
#define glActiveShaderProgram glad_debug_glActiveShaderProgram
@@ -3390,15 +4097,24 @@ GLAD_API_CALL PFNGLACTIVETEXTUREPROC glad_debug_glActiveTexture;
GLAD_API_CALL PFNGLACTIVETEXTUREARBPROC glad_glActiveTextureARB;
GLAD_API_CALL PFNGLACTIVETEXTUREARBPROC glad_debug_glActiveTextureARB;
#define glActiveTextureARB glad_debug_glActiveTextureARB
-GLAD_API_CALL PFNGLALPHAFUNCXOESPROC glad_glAlphaFuncxOES;
-GLAD_API_CALL PFNGLALPHAFUNCXOESPROC glad_debug_glAlphaFuncxOES;
-#define glAlphaFuncxOES glad_debug_glAlphaFuncxOES
+GLAD_API_CALL PFNGLALPHAFUNCPROC glad_glAlphaFunc;
+GLAD_API_CALL PFNGLALPHAFUNCPROC glad_debug_glAlphaFunc;
+#define glAlphaFunc glad_debug_glAlphaFunc
+GLAD_API_CALL PFNGLARETEXTURESRESIDENTPROC glad_glAreTexturesResident;
+GLAD_API_CALL PFNGLARETEXTURESRESIDENTPROC glad_debug_glAreTexturesResident;
+#define glAreTexturesResident glad_debug_glAreTexturesResident
+GLAD_API_CALL PFNGLARRAYELEMENTPROC glad_glArrayElement;
+GLAD_API_CALL PFNGLARRAYELEMENTPROC glad_debug_glArrayElement;
+#define glArrayElement glad_debug_glArrayElement
GLAD_API_CALL PFNGLATTACHOBJECTARBPROC glad_glAttachObjectARB;
GLAD_API_CALL PFNGLATTACHOBJECTARBPROC glad_debug_glAttachObjectARB;
#define glAttachObjectARB glad_debug_glAttachObjectARB
GLAD_API_CALL PFNGLATTACHSHADERPROC glad_glAttachShader;
GLAD_API_CALL PFNGLATTACHSHADERPROC glad_debug_glAttachShader;
#define glAttachShader glad_debug_glAttachShader
+GLAD_API_CALL PFNGLBEGINPROC glad_glBegin;
+GLAD_API_CALL PFNGLBEGINPROC glad_debug_glBegin;
+#define glBegin glad_debug_glBegin
GLAD_API_CALL PFNGLBEGINCONDITIONALRENDERPROC glad_glBeginConditionalRender;
GLAD_API_CALL PFNGLBEGINCONDITIONALRENDERPROC glad_debug_glBeginConditionalRender;
#define glBeginConditionalRender glad_debug_glBeginConditionalRender
@@ -3495,15 +4211,15 @@ GLAD_API_CALL PFNGLBINDVERTEXBUFFERPROC glad_debug_glBindVertexBuffer;
GLAD_API_CALL PFNGLBINDVERTEXBUFFERSPROC glad_glBindVertexBuffers;
GLAD_API_CALL PFNGLBINDVERTEXBUFFERSPROC glad_debug_glBindVertexBuffers;
#define glBindVertexBuffers glad_debug_glBindVertexBuffers
-GLAD_API_CALL PFNGLBITMAPXOESPROC glad_glBitmapxOES;
-GLAD_API_CALL PFNGLBITMAPXOESPROC glad_debug_glBitmapxOES;
-#define glBitmapxOES glad_debug_glBitmapxOES
+GLAD_API_CALL PFNGLBITMAPPROC glad_glBitmap;
+GLAD_API_CALL PFNGLBITMAPPROC glad_debug_glBitmap;
+#define glBitmap glad_debug_glBitmap
+GLAD_API_CALL PFNGLBLENDBARRIERKHRPROC glad_glBlendBarrierKHR;
+GLAD_API_CALL PFNGLBLENDBARRIERKHRPROC glad_debug_glBlendBarrierKHR;
+#define glBlendBarrierKHR glad_debug_glBlendBarrierKHR
GLAD_API_CALL PFNGLBLENDCOLORPROC glad_glBlendColor;
GLAD_API_CALL PFNGLBLENDCOLORPROC glad_debug_glBlendColor;
#define glBlendColor glad_debug_glBlendColor
-GLAD_API_CALL PFNGLBLENDCOLORXOESPROC glad_glBlendColorxOES;
-GLAD_API_CALL PFNGLBLENDCOLORXOESPROC glad_debug_glBlendColorxOES;
-#define glBlendColorxOES glad_debug_glBlendColorxOES
GLAD_API_CALL PFNGLBLENDEQUATIONPROC glad_glBlendEquation;
GLAD_API_CALL PFNGLBLENDEQUATIONPROC glad_debug_glBlendEquation;
#define glBlendEquation glad_debug_glBlendEquation
@@ -3564,6 +4280,12 @@ GLAD_API_CALL PFNGLBUFFERSUBDATAPROC glad_debug_glBufferSubData;
GLAD_API_CALL PFNGLBUFFERSUBDATAARBPROC glad_glBufferSubDataARB;
GLAD_API_CALL PFNGLBUFFERSUBDATAARBPROC glad_debug_glBufferSubDataARB;
#define glBufferSubDataARB glad_debug_glBufferSubDataARB
+GLAD_API_CALL PFNGLCALLLISTPROC glad_glCallList;
+GLAD_API_CALL PFNGLCALLLISTPROC glad_debug_glCallList;
+#define glCallList glad_debug_glCallList
+GLAD_API_CALL PFNGLCALLLISTSPROC glad_glCallLists;
+GLAD_API_CALL PFNGLCALLLISTSPROC glad_debug_glCallLists;
+#define glCallLists glad_debug_glCallLists
GLAD_API_CALL PFNGLCHECKFRAMEBUFFERSTATUSPROC glad_glCheckFramebufferStatus;
GLAD_API_CALL PFNGLCHECKFRAMEBUFFERSTATUSPROC glad_debug_glCheckFramebufferStatus;
#define glCheckFramebufferStatus glad_debug_glCheckFramebufferStatus
@@ -3582,9 +4304,9 @@ GLAD_API_CALL PFNGLCLAMPCOLORARBPROC glad_debug_glClampColorARB;
GLAD_API_CALL PFNGLCLEARPROC glad_glClear;
GLAD_API_CALL PFNGLCLEARPROC glad_debug_glClear;
#define glClear glad_debug_glClear
-GLAD_API_CALL PFNGLCLEARACCUMXOESPROC glad_glClearAccumxOES;
-GLAD_API_CALL PFNGLCLEARACCUMXOESPROC glad_debug_glClearAccumxOES;
-#define glClearAccumxOES glad_debug_glClearAccumxOES
+GLAD_API_CALL PFNGLCLEARACCUMPROC glad_glClearAccum;
+GLAD_API_CALL PFNGLCLEARACCUMPROC glad_debug_glClearAccum;
+#define glClearAccum glad_debug_glClearAccum
GLAD_API_CALL PFNGLCLEARBUFFERDATAPROC glad_glClearBufferData;
GLAD_API_CALL PFNGLCLEARBUFFERDATAPROC glad_debug_glClearBufferData;
#define glClearBufferData glad_debug_glClearBufferData
@@ -3606,18 +4328,15 @@ GLAD_API_CALL PFNGLCLEARBUFFERUIVPROC glad_debug_glClearBufferuiv;
GLAD_API_CALL PFNGLCLEARCOLORPROC glad_glClearColor;
GLAD_API_CALL PFNGLCLEARCOLORPROC glad_debug_glClearColor;
#define glClearColor glad_debug_glClearColor
-GLAD_API_CALL PFNGLCLEARCOLORXOESPROC glad_glClearColorxOES;
-GLAD_API_CALL PFNGLCLEARCOLORXOESPROC glad_debug_glClearColorxOES;
-#define glClearColorxOES glad_debug_glClearColorxOES
GLAD_API_CALL PFNGLCLEARDEPTHPROC glad_glClearDepth;
GLAD_API_CALL PFNGLCLEARDEPTHPROC glad_debug_glClearDepth;
#define glClearDepth glad_debug_glClearDepth
GLAD_API_CALL PFNGLCLEARDEPTHFPROC glad_glClearDepthf;
GLAD_API_CALL PFNGLCLEARDEPTHFPROC glad_debug_glClearDepthf;
#define glClearDepthf glad_debug_glClearDepthf
-GLAD_API_CALL PFNGLCLEARDEPTHXOESPROC glad_glClearDepthxOES;
-GLAD_API_CALL PFNGLCLEARDEPTHXOESPROC glad_debug_glClearDepthxOES;
-#define glClearDepthxOES glad_debug_glClearDepthxOES
+GLAD_API_CALL PFNGLCLEARINDEXPROC glad_glClearIndex;
+GLAD_API_CALL PFNGLCLEARINDEXPROC glad_debug_glClearIndex;
+#define glClearIndex glad_debug_glClearIndex
GLAD_API_CALL PFNGLCLEARNAMEDBUFFERDATAPROC glad_glClearNamedBufferData;
GLAD_API_CALL PFNGLCLEARNAMEDBUFFERDATAPROC glad_debug_glClearNamedBufferData;
#define glClearNamedBufferData glad_debug_glClearNamedBufferData
@@ -3645,33 +4364,138 @@ GLAD_API_CALL PFNGLCLEARTEXIMAGEPROC glad_debug_glClearTexImage;
GLAD_API_CALL PFNGLCLEARTEXSUBIMAGEPROC glad_glClearTexSubImage;
GLAD_API_CALL PFNGLCLEARTEXSUBIMAGEPROC glad_debug_glClearTexSubImage;
#define glClearTexSubImage glad_debug_glClearTexSubImage
+GLAD_API_CALL PFNGLCLIENTACTIVETEXTUREPROC glad_glClientActiveTexture;
+GLAD_API_CALL PFNGLCLIENTACTIVETEXTUREPROC glad_debug_glClientActiveTexture;
+#define glClientActiveTexture glad_debug_glClientActiveTexture
GLAD_API_CALL PFNGLCLIENTACTIVETEXTUREARBPROC glad_glClientActiveTextureARB;
GLAD_API_CALL PFNGLCLIENTACTIVETEXTUREARBPROC glad_debug_glClientActiveTextureARB;
#define glClientActiveTextureARB glad_debug_glClientActiveTextureARB
GLAD_API_CALL PFNGLCLIENTWAITSYNCPROC glad_glClientWaitSync;
GLAD_API_CALL PFNGLCLIENTWAITSYNCPROC glad_debug_glClientWaitSync;
#define glClientWaitSync glad_debug_glClientWaitSync
-GLAD_API_CALL PFNGLCLIPPLANEXOESPROC glad_glClipPlanexOES;
-GLAD_API_CALL PFNGLCLIPPLANEXOESPROC glad_debug_glClipPlanexOES;
-#define glClipPlanexOES glad_debug_glClipPlanexOES
-GLAD_API_CALL PFNGLCOLOR3XOESPROC glad_glColor3xOES;
-GLAD_API_CALL PFNGLCOLOR3XOESPROC glad_debug_glColor3xOES;
-#define glColor3xOES glad_debug_glColor3xOES
-GLAD_API_CALL PFNGLCOLOR3XVOESPROC glad_glColor3xvOES;
-GLAD_API_CALL PFNGLCOLOR3XVOESPROC glad_debug_glColor3xvOES;
-#define glColor3xvOES glad_debug_glColor3xvOES
-GLAD_API_CALL PFNGLCOLOR4XOESPROC glad_glColor4xOES;
-GLAD_API_CALL PFNGLCOLOR4XOESPROC glad_debug_glColor4xOES;
-#define glColor4xOES glad_debug_glColor4xOES
-GLAD_API_CALL PFNGLCOLOR4XVOESPROC glad_glColor4xvOES;
-GLAD_API_CALL PFNGLCOLOR4XVOESPROC glad_debug_glColor4xvOES;
-#define glColor4xvOES glad_debug_glColor4xvOES
+GLAD_API_CALL PFNGLCLIPPLANEPROC glad_glClipPlane;
+GLAD_API_CALL PFNGLCLIPPLANEPROC glad_debug_glClipPlane;
+#define glClipPlane glad_debug_glClipPlane
+GLAD_API_CALL PFNGLCOLOR3BPROC glad_glColor3b;
+GLAD_API_CALL PFNGLCOLOR3BPROC glad_debug_glColor3b;
+#define glColor3b glad_debug_glColor3b
+GLAD_API_CALL PFNGLCOLOR3BVPROC glad_glColor3bv;
+GLAD_API_CALL PFNGLCOLOR3BVPROC glad_debug_glColor3bv;
+#define glColor3bv glad_debug_glColor3bv
+GLAD_API_CALL PFNGLCOLOR3DPROC glad_glColor3d;
+GLAD_API_CALL PFNGLCOLOR3DPROC glad_debug_glColor3d;
+#define glColor3d glad_debug_glColor3d
+GLAD_API_CALL PFNGLCOLOR3DVPROC glad_glColor3dv;
+GLAD_API_CALL PFNGLCOLOR3DVPROC glad_debug_glColor3dv;
+#define glColor3dv glad_debug_glColor3dv
+GLAD_API_CALL PFNGLCOLOR3FPROC glad_glColor3f;
+GLAD_API_CALL PFNGLCOLOR3FPROC glad_debug_glColor3f;
+#define glColor3f glad_debug_glColor3f
+GLAD_API_CALL PFNGLCOLOR3FVPROC glad_glColor3fv;
+GLAD_API_CALL PFNGLCOLOR3FVPROC glad_debug_glColor3fv;
+#define glColor3fv glad_debug_glColor3fv
+GLAD_API_CALL PFNGLCOLOR3IPROC glad_glColor3i;
+GLAD_API_CALL PFNGLCOLOR3IPROC glad_debug_glColor3i;
+#define glColor3i glad_debug_glColor3i
+GLAD_API_CALL PFNGLCOLOR3IVPROC glad_glColor3iv;
+GLAD_API_CALL PFNGLCOLOR3IVPROC glad_debug_glColor3iv;
+#define glColor3iv glad_debug_glColor3iv
+GLAD_API_CALL PFNGLCOLOR3SPROC glad_glColor3s;
+GLAD_API_CALL PFNGLCOLOR3SPROC glad_debug_glColor3s;
+#define glColor3s glad_debug_glColor3s
+GLAD_API_CALL PFNGLCOLOR3SVPROC glad_glColor3sv;
+GLAD_API_CALL PFNGLCOLOR3SVPROC glad_debug_glColor3sv;
+#define glColor3sv glad_debug_glColor3sv
+GLAD_API_CALL PFNGLCOLOR3UBPROC glad_glColor3ub;
+GLAD_API_CALL PFNGLCOLOR3UBPROC glad_debug_glColor3ub;
+#define glColor3ub glad_debug_glColor3ub
+GLAD_API_CALL PFNGLCOLOR3UBVPROC glad_glColor3ubv;
+GLAD_API_CALL PFNGLCOLOR3UBVPROC glad_debug_glColor3ubv;
+#define glColor3ubv glad_debug_glColor3ubv
+GLAD_API_CALL PFNGLCOLOR3UIPROC glad_glColor3ui;
+GLAD_API_CALL PFNGLCOLOR3UIPROC glad_debug_glColor3ui;
+#define glColor3ui glad_debug_glColor3ui
+GLAD_API_CALL PFNGLCOLOR3UIVPROC glad_glColor3uiv;
+GLAD_API_CALL PFNGLCOLOR3UIVPROC glad_debug_glColor3uiv;
+#define glColor3uiv glad_debug_glColor3uiv
+GLAD_API_CALL PFNGLCOLOR3USPROC glad_glColor3us;
+GLAD_API_CALL PFNGLCOLOR3USPROC glad_debug_glColor3us;
+#define glColor3us glad_debug_glColor3us
+GLAD_API_CALL PFNGLCOLOR3USVPROC glad_glColor3usv;
+GLAD_API_CALL PFNGLCOLOR3USVPROC glad_debug_glColor3usv;
+#define glColor3usv glad_debug_glColor3usv
+GLAD_API_CALL PFNGLCOLOR4BPROC glad_glColor4b;
+GLAD_API_CALL PFNGLCOLOR4BPROC glad_debug_glColor4b;
+#define glColor4b glad_debug_glColor4b
+GLAD_API_CALL PFNGLCOLOR4BVPROC glad_glColor4bv;
+GLAD_API_CALL PFNGLCOLOR4BVPROC glad_debug_glColor4bv;
+#define glColor4bv glad_debug_glColor4bv
+GLAD_API_CALL PFNGLCOLOR4DPROC glad_glColor4d;
+GLAD_API_CALL PFNGLCOLOR4DPROC glad_debug_glColor4d;
+#define glColor4d glad_debug_glColor4d
+GLAD_API_CALL PFNGLCOLOR4DVPROC glad_glColor4dv;
+GLAD_API_CALL PFNGLCOLOR4DVPROC glad_debug_glColor4dv;
+#define glColor4dv glad_debug_glColor4dv
+GLAD_API_CALL PFNGLCOLOR4FPROC glad_glColor4f;
+GLAD_API_CALL PFNGLCOLOR4FPROC glad_debug_glColor4f;
+#define glColor4f glad_debug_glColor4f
+GLAD_API_CALL PFNGLCOLOR4FVPROC glad_glColor4fv;
+GLAD_API_CALL PFNGLCOLOR4FVPROC glad_debug_glColor4fv;
+#define glColor4fv glad_debug_glColor4fv
+GLAD_API_CALL PFNGLCOLOR4IPROC glad_glColor4i;
+GLAD_API_CALL PFNGLCOLOR4IPROC glad_debug_glColor4i;
+#define glColor4i glad_debug_glColor4i
+GLAD_API_CALL PFNGLCOLOR4IVPROC glad_glColor4iv;
+GLAD_API_CALL PFNGLCOLOR4IVPROC glad_debug_glColor4iv;
+#define glColor4iv glad_debug_glColor4iv
+GLAD_API_CALL PFNGLCOLOR4SPROC glad_glColor4s;
+GLAD_API_CALL PFNGLCOLOR4SPROC glad_debug_glColor4s;
+#define glColor4s glad_debug_glColor4s
+GLAD_API_CALL PFNGLCOLOR4SVPROC glad_glColor4sv;
+GLAD_API_CALL PFNGLCOLOR4SVPROC glad_debug_glColor4sv;
+#define glColor4sv glad_debug_glColor4sv
+GLAD_API_CALL PFNGLCOLOR4UBPROC glad_glColor4ub;
+GLAD_API_CALL PFNGLCOLOR4UBPROC glad_debug_glColor4ub;
+#define glColor4ub glad_debug_glColor4ub
+GLAD_API_CALL PFNGLCOLOR4UBVPROC glad_glColor4ubv;
+GLAD_API_CALL PFNGLCOLOR4UBVPROC glad_debug_glColor4ubv;
+#define glColor4ubv glad_debug_glColor4ubv
+GLAD_API_CALL PFNGLCOLOR4UIPROC glad_glColor4ui;
+GLAD_API_CALL PFNGLCOLOR4UIPROC glad_debug_glColor4ui;
+#define glColor4ui glad_debug_glColor4ui
+GLAD_API_CALL PFNGLCOLOR4UIVPROC glad_glColor4uiv;
+GLAD_API_CALL PFNGLCOLOR4UIVPROC glad_debug_glColor4uiv;
+#define glColor4uiv glad_debug_glColor4uiv
+GLAD_API_CALL PFNGLCOLOR4USPROC glad_glColor4us;
+GLAD_API_CALL PFNGLCOLOR4USPROC glad_debug_glColor4us;
+#define glColor4us glad_debug_glColor4us
+GLAD_API_CALL PFNGLCOLOR4USVPROC glad_glColor4usv;
+GLAD_API_CALL PFNGLCOLOR4USVPROC glad_debug_glColor4usv;
+#define glColor4usv glad_debug_glColor4usv
GLAD_API_CALL PFNGLCOLORMASKPROC glad_glColorMask;
GLAD_API_CALL PFNGLCOLORMASKPROC glad_debug_glColorMask;
#define glColorMask glad_debug_glColorMask
GLAD_API_CALL PFNGLCOLORMASKIPROC glad_glColorMaski;
GLAD_API_CALL PFNGLCOLORMASKIPROC glad_debug_glColorMaski;
#define glColorMaski glad_debug_glColorMaski
+GLAD_API_CALL PFNGLCOLORMATERIALPROC glad_glColorMaterial;
+GLAD_API_CALL PFNGLCOLORMATERIALPROC glad_debug_glColorMaterial;
+#define glColorMaterial glad_debug_glColorMaterial
+GLAD_API_CALL PFNGLCOLORP3UIPROC glad_glColorP3ui;
+GLAD_API_CALL PFNGLCOLORP3UIPROC glad_debug_glColorP3ui;
+#define glColorP3ui glad_debug_glColorP3ui
+GLAD_API_CALL PFNGLCOLORP3UIVPROC glad_glColorP3uiv;
+GLAD_API_CALL PFNGLCOLORP3UIVPROC glad_debug_glColorP3uiv;
+#define glColorP3uiv glad_debug_glColorP3uiv
+GLAD_API_CALL PFNGLCOLORP4UIPROC glad_glColorP4ui;
+GLAD_API_CALL PFNGLCOLORP4UIPROC glad_debug_glColorP4ui;
+#define glColorP4ui glad_debug_glColorP4ui
+GLAD_API_CALL PFNGLCOLORP4UIVPROC glad_glColorP4uiv;
+GLAD_API_CALL PFNGLCOLORP4UIVPROC glad_debug_glColorP4uiv;
+#define glColorP4uiv glad_debug_glColorP4uiv
+GLAD_API_CALL PFNGLCOLORPOINTERPROC glad_glColorPointer;
+GLAD_API_CALL PFNGLCOLORPOINTERPROC glad_debug_glColorPointer;
+#define glColorPointer glad_debug_glColorPointer
GLAD_API_CALL PFNGLCOMPILESHADERPROC glad_glCompileShader;
GLAD_API_CALL PFNGLCOMPILESHADERPROC glad_debug_glCompileShader;
#define glCompileShader glad_debug_glCompileShader
@@ -3726,12 +4550,6 @@ GLAD_API_CALL PFNGLCOMPRESSEDTEXTURESUBIMAGE2DPROC glad_debug_glCompressedTextur
GLAD_API_CALL PFNGLCOMPRESSEDTEXTURESUBIMAGE3DPROC glad_glCompressedTextureSubImage3D;
GLAD_API_CALL PFNGLCOMPRESSEDTEXTURESUBIMAGE3DPROC glad_debug_glCompressedTextureSubImage3D;
#define glCompressedTextureSubImage3D glad_debug_glCompressedTextureSubImage3D
-GLAD_API_CALL PFNGLCONVOLUTIONPARAMETERXOESPROC glad_glConvolutionParameterxOES;
-GLAD_API_CALL PFNGLCONVOLUTIONPARAMETERXOESPROC glad_debug_glConvolutionParameterxOES;
-#define glConvolutionParameterxOES glad_debug_glConvolutionParameterxOES
-GLAD_API_CALL PFNGLCONVOLUTIONPARAMETERXVOESPROC glad_glConvolutionParameterxvOES;
-GLAD_API_CALL PFNGLCONVOLUTIONPARAMETERXVOESPROC glad_debug_glConvolutionParameterxvOES;
-#define glConvolutionParameterxvOES glad_debug_glConvolutionParameterxvOES
GLAD_API_CALL PFNGLCOPYBUFFERSUBDATAPROC glad_glCopyBufferSubData;
GLAD_API_CALL PFNGLCOPYBUFFERSUBDATAPROC glad_debug_glCopyBufferSubData;
#define glCopyBufferSubData glad_debug_glCopyBufferSubData
@@ -3741,6 +4559,9 @@ GLAD_API_CALL PFNGLCOPYIMAGESUBDATAPROC glad_debug_glCopyImageSubData;
GLAD_API_CALL PFNGLCOPYNAMEDBUFFERSUBDATAPROC glad_glCopyNamedBufferSubData;
GLAD_API_CALL PFNGLCOPYNAMEDBUFFERSUBDATAPROC glad_debug_glCopyNamedBufferSubData;
#define glCopyNamedBufferSubData glad_debug_glCopyNamedBufferSubData
+GLAD_API_CALL PFNGLCOPYPIXELSPROC glad_glCopyPixels;
+GLAD_API_CALL PFNGLCOPYPIXELSPROC glad_debug_glCopyPixels;
+#define glCopyPixels glad_debug_glCopyPixels
GLAD_API_CALL PFNGLCOPYTEXIMAGE1DPROC glad_glCopyTexImage1D;
GLAD_API_CALL PFNGLCOPYTEXIMAGE1DPROC glad_debug_glCopyTexImage1D;
#define glCopyTexImage1D glad_debug_glCopyTexImage1D
@@ -3840,6 +4661,9 @@ GLAD_API_CALL PFNGLDELETEFRAMEBUFFERSPROC glad_debug_glDeleteFramebuffers;
GLAD_API_CALL PFNGLDELETEFRAMEBUFFERSEXTPROC glad_glDeleteFramebuffersEXT;
GLAD_API_CALL PFNGLDELETEFRAMEBUFFERSEXTPROC glad_debug_glDeleteFramebuffersEXT;
#define glDeleteFramebuffersEXT glad_debug_glDeleteFramebuffersEXT
+GLAD_API_CALL PFNGLDELETELISTSPROC glad_glDeleteLists;
+GLAD_API_CALL PFNGLDELETELISTSPROC glad_debug_glDeleteLists;
+#define glDeleteLists glad_debug_glDeleteLists
GLAD_API_CALL PFNGLDELETENAMEDSTRINGARBPROC glad_glDeleteNamedStringARB;
GLAD_API_CALL PFNGLDELETENAMEDSTRINGARBPROC glad_debug_glDeleteNamedStringARB;
#define glDeleteNamedStringARB glad_debug_glDeleteNamedStringARB
@@ -3903,9 +4727,6 @@ GLAD_API_CALL PFNGLDEPTHRANGEINDEXEDPROC glad_debug_glDepthRangeIndexed;
GLAD_API_CALL PFNGLDEPTHRANGEFPROC glad_glDepthRangef;
GLAD_API_CALL PFNGLDEPTHRANGEFPROC glad_debug_glDepthRangef;
#define glDepthRangef glad_debug_glDepthRangef
-GLAD_API_CALL PFNGLDEPTHRANGEXOESPROC glad_glDepthRangexOES;
-GLAD_API_CALL PFNGLDEPTHRANGEXOESPROC glad_debug_glDepthRangexOES;
-#define glDepthRangexOES glad_debug_glDepthRangexOES
GLAD_API_CALL PFNGLDETACHOBJECTARBPROC glad_glDetachObjectARB;
GLAD_API_CALL PFNGLDETACHOBJECTARBPROC glad_debug_glDetachObjectARB;
#define glDetachObjectARB glad_debug_glDetachObjectARB
@@ -3915,6 +4736,9 @@ GLAD_API_CALL PFNGLDETACHSHADERPROC glad_debug_glDetachShader;
GLAD_API_CALL PFNGLDISABLEPROC glad_glDisable;
GLAD_API_CALL PFNGLDISABLEPROC glad_debug_glDisable;
#define glDisable glad_debug_glDisable
+GLAD_API_CALL PFNGLDISABLECLIENTSTATEPROC glad_glDisableClientState;
+GLAD_API_CALL PFNGLDISABLECLIENTSTATEPROC glad_debug_glDisableClientState;
+#define glDisableClientState glad_debug_glDisableClientState
GLAD_API_CALL PFNGLDISABLEVERTEXARRAYATTRIBPROC glad_glDisableVertexArrayAttrib;
GLAD_API_CALL PFNGLDISABLEVERTEXARRAYATTRIBPROC glad_debug_glDisableVertexArrayAttrib;
#define glDisableVertexArrayAttrib glad_debug_glDisableVertexArrayAttrib
@@ -3990,6 +4814,9 @@ GLAD_API_CALL PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCEPROC glad_debug_gl
GLAD_API_CALL PFNGLDRAWELEMENTSINSTANCEDEXTPROC glad_glDrawElementsInstancedEXT;
GLAD_API_CALL PFNGLDRAWELEMENTSINSTANCEDEXTPROC glad_debug_glDrawElementsInstancedEXT;
#define glDrawElementsInstancedEXT glad_debug_glDrawElementsInstancedEXT
+GLAD_API_CALL PFNGLDRAWPIXELSPROC glad_glDrawPixels;
+GLAD_API_CALL PFNGLDRAWPIXELSPROC glad_debug_glDrawPixels;
+#define glDrawPixels glad_debug_glDrawPixels
GLAD_API_CALL PFNGLDRAWRANGEELEMENTSPROC glad_glDrawRangeElements;
GLAD_API_CALL PFNGLDRAWRANGEELEMENTSPROC glad_debug_glDrawRangeElements;
#define glDrawRangeElements glad_debug_glDrawRangeElements
@@ -4008,9 +4835,21 @@ GLAD_API_CALL PFNGLDRAWTRANSFORMFEEDBACKSTREAMPROC glad_debug_glDrawTransformFee
GLAD_API_CALL PFNGLDRAWTRANSFORMFEEDBACKSTREAMINSTANCEDPROC glad_glDrawTransformFeedbackStreamInstanced;
GLAD_API_CALL PFNGLDRAWTRANSFORMFEEDBACKSTREAMINSTANCEDPROC glad_debug_glDrawTransformFeedbackStreamInstanced;
#define glDrawTransformFeedbackStreamInstanced glad_debug_glDrawTransformFeedbackStreamInstanced
+GLAD_API_CALL PFNGLEDGEFLAGPROC glad_glEdgeFlag;
+GLAD_API_CALL PFNGLEDGEFLAGPROC glad_debug_glEdgeFlag;
+#define glEdgeFlag glad_debug_glEdgeFlag
+GLAD_API_CALL PFNGLEDGEFLAGPOINTERPROC glad_glEdgeFlagPointer;
+GLAD_API_CALL PFNGLEDGEFLAGPOINTERPROC glad_debug_glEdgeFlagPointer;
+#define glEdgeFlagPointer glad_debug_glEdgeFlagPointer
+GLAD_API_CALL PFNGLEDGEFLAGVPROC glad_glEdgeFlagv;
+GLAD_API_CALL PFNGLEDGEFLAGVPROC glad_debug_glEdgeFlagv;
+#define glEdgeFlagv glad_debug_glEdgeFlagv
GLAD_API_CALL PFNGLENABLEPROC glad_glEnable;
GLAD_API_CALL PFNGLENABLEPROC glad_debug_glEnable;
#define glEnable glad_debug_glEnable
+GLAD_API_CALL PFNGLENABLECLIENTSTATEPROC glad_glEnableClientState;
+GLAD_API_CALL PFNGLENABLECLIENTSTATEPROC glad_debug_glEnableClientState;
+#define glEnableClientState glad_debug_glEnableClientState
GLAD_API_CALL PFNGLENABLEVERTEXARRAYATTRIBPROC glad_glEnableVertexArrayAttrib;
GLAD_API_CALL PFNGLENABLEVERTEXARRAYATTRIBPROC glad_debug_glEnableVertexArrayAttrib;
#define glEnableVertexArrayAttrib glad_debug_glEnableVertexArrayAttrib
@@ -4023,9 +4862,15 @@ GLAD_API_CALL PFNGLENABLEVERTEXATTRIBARRAYARBPROC glad_debug_glEnableVertexAttri
GLAD_API_CALL PFNGLENABLEIPROC glad_glEnablei;
GLAD_API_CALL PFNGLENABLEIPROC glad_debug_glEnablei;
#define glEnablei glad_debug_glEnablei
+GLAD_API_CALL PFNGLENDPROC glad_glEnd;
+GLAD_API_CALL PFNGLENDPROC glad_debug_glEnd;
+#define glEnd glad_debug_glEnd
GLAD_API_CALL PFNGLENDCONDITIONALRENDERPROC glad_glEndConditionalRender;
GLAD_API_CALL PFNGLENDCONDITIONALRENDERPROC glad_debug_glEndConditionalRender;
#define glEndConditionalRender glad_debug_glEndConditionalRender
+GLAD_API_CALL PFNGLENDLISTPROC glad_glEndList;
+GLAD_API_CALL PFNGLENDLISTPROC glad_debug_glEndList;
+#define glEndList glad_debug_glEndList
GLAD_API_CALL PFNGLENDQUERYPROC glad_glEndQuery;
GLAD_API_CALL PFNGLENDQUERYPROC glad_debug_glEndQuery;
#define glEndQuery glad_debug_glEndQuery
@@ -4038,24 +4883,48 @@ GLAD_API_CALL PFNGLENDQUERYINDEXEDPROC glad_debug_glEndQueryIndexed;
GLAD_API_CALL PFNGLENDTRANSFORMFEEDBACKPROC glad_glEndTransformFeedback;
GLAD_API_CALL PFNGLENDTRANSFORMFEEDBACKPROC glad_debug_glEndTransformFeedback;
#define glEndTransformFeedback glad_debug_glEndTransformFeedback
-GLAD_API_CALL PFNGLEVALCOORD1XOESPROC glad_glEvalCoord1xOES;
-GLAD_API_CALL PFNGLEVALCOORD1XOESPROC glad_debug_glEvalCoord1xOES;
-#define glEvalCoord1xOES glad_debug_glEvalCoord1xOES
-GLAD_API_CALL PFNGLEVALCOORD1XVOESPROC glad_glEvalCoord1xvOES;
-GLAD_API_CALL PFNGLEVALCOORD1XVOESPROC glad_debug_glEvalCoord1xvOES;
-#define glEvalCoord1xvOES glad_debug_glEvalCoord1xvOES
-GLAD_API_CALL PFNGLEVALCOORD2XOESPROC glad_glEvalCoord2xOES;
-GLAD_API_CALL PFNGLEVALCOORD2XOESPROC glad_debug_glEvalCoord2xOES;
-#define glEvalCoord2xOES glad_debug_glEvalCoord2xOES
-GLAD_API_CALL PFNGLEVALCOORD2XVOESPROC glad_glEvalCoord2xvOES;
-GLAD_API_CALL PFNGLEVALCOORD2XVOESPROC glad_debug_glEvalCoord2xvOES;
-#define glEvalCoord2xvOES glad_debug_glEvalCoord2xvOES
+GLAD_API_CALL PFNGLEVALCOORD1DPROC glad_glEvalCoord1d;
+GLAD_API_CALL PFNGLEVALCOORD1DPROC glad_debug_glEvalCoord1d;
+#define glEvalCoord1d glad_debug_glEvalCoord1d
+GLAD_API_CALL PFNGLEVALCOORD1DVPROC glad_glEvalCoord1dv;
+GLAD_API_CALL PFNGLEVALCOORD1DVPROC glad_debug_glEvalCoord1dv;
+#define glEvalCoord1dv glad_debug_glEvalCoord1dv
+GLAD_API_CALL PFNGLEVALCOORD1FPROC glad_glEvalCoord1f;
+GLAD_API_CALL PFNGLEVALCOORD1FPROC glad_debug_glEvalCoord1f;
+#define glEvalCoord1f glad_debug_glEvalCoord1f
+GLAD_API_CALL PFNGLEVALCOORD1FVPROC glad_glEvalCoord1fv;
+GLAD_API_CALL PFNGLEVALCOORD1FVPROC glad_debug_glEvalCoord1fv;
+#define glEvalCoord1fv glad_debug_glEvalCoord1fv
+GLAD_API_CALL PFNGLEVALCOORD2DPROC glad_glEvalCoord2d;
+GLAD_API_CALL PFNGLEVALCOORD2DPROC glad_debug_glEvalCoord2d;
+#define glEvalCoord2d glad_debug_glEvalCoord2d
+GLAD_API_CALL PFNGLEVALCOORD2DVPROC glad_glEvalCoord2dv;
+GLAD_API_CALL PFNGLEVALCOORD2DVPROC glad_debug_glEvalCoord2dv;
+#define glEvalCoord2dv glad_debug_glEvalCoord2dv
+GLAD_API_CALL PFNGLEVALCOORD2FPROC glad_glEvalCoord2f;
+GLAD_API_CALL PFNGLEVALCOORD2FPROC glad_debug_glEvalCoord2f;
+#define glEvalCoord2f glad_debug_glEvalCoord2f
+GLAD_API_CALL PFNGLEVALCOORD2FVPROC glad_glEvalCoord2fv;
+GLAD_API_CALL PFNGLEVALCOORD2FVPROC glad_debug_glEvalCoord2fv;
+#define glEvalCoord2fv glad_debug_glEvalCoord2fv
+GLAD_API_CALL PFNGLEVALMESH1PROC glad_glEvalMesh1;
+GLAD_API_CALL PFNGLEVALMESH1PROC glad_debug_glEvalMesh1;
+#define glEvalMesh1 glad_debug_glEvalMesh1
+GLAD_API_CALL PFNGLEVALMESH2PROC glad_glEvalMesh2;
+GLAD_API_CALL PFNGLEVALMESH2PROC glad_debug_glEvalMesh2;
+#define glEvalMesh2 glad_debug_glEvalMesh2
+GLAD_API_CALL PFNGLEVALPOINT1PROC glad_glEvalPoint1;
+GLAD_API_CALL PFNGLEVALPOINT1PROC glad_debug_glEvalPoint1;
+#define glEvalPoint1 glad_debug_glEvalPoint1
+GLAD_API_CALL PFNGLEVALPOINT2PROC glad_glEvalPoint2;
+GLAD_API_CALL PFNGLEVALPOINT2PROC glad_debug_glEvalPoint2;
+#define glEvalPoint2 glad_debug_glEvalPoint2
GLAD_API_CALL PFNGLEVALUATEDEPTHVALUESARBPROC glad_glEvaluateDepthValuesARB;
GLAD_API_CALL PFNGLEVALUATEDEPTHVALUESARBPROC glad_debug_glEvaluateDepthValuesARB;
#define glEvaluateDepthValuesARB glad_debug_glEvaluateDepthValuesARB
-GLAD_API_CALL PFNGLFEEDBACKBUFFERXOESPROC glad_glFeedbackBufferxOES;
-GLAD_API_CALL PFNGLFEEDBACKBUFFERXOESPROC glad_debug_glFeedbackBufferxOES;
-#define glFeedbackBufferxOES glad_debug_glFeedbackBufferxOES
+GLAD_API_CALL PFNGLFEEDBACKBUFFERPROC glad_glFeedbackBuffer;
+GLAD_API_CALL PFNGLFEEDBACKBUFFERPROC glad_debug_glFeedbackBuffer;
+#define glFeedbackBuffer glad_debug_glFeedbackBuffer
GLAD_API_CALL PFNGLFENCESYNCPROC glad_glFenceSync;
GLAD_API_CALL PFNGLFENCESYNCPROC glad_debug_glFenceSync;
#define glFenceSync glad_debug_glFenceSync
@@ -4071,27 +4940,48 @@ GLAD_API_CALL PFNGLFLUSHMAPPEDBUFFERRANGEPROC glad_debug_glFlushMappedBufferRang
GLAD_API_CALL PFNGLFLUSHMAPPEDNAMEDBUFFERRANGEPROC glad_glFlushMappedNamedBufferRange;
GLAD_API_CALL PFNGLFLUSHMAPPEDNAMEDBUFFERRANGEPROC glad_debug_glFlushMappedNamedBufferRange;
#define glFlushMappedNamedBufferRange glad_debug_glFlushMappedNamedBufferRange
+GLAD_API_CALL PFNGLFOGCOORDPOINTERPROC glad_glFogCoordPointer;
+GLAD_API_CALL PFNGLFOGCOORDPOINTERPROC glad_debug_glFogCoordPointer;
+#define glFogCoordPointer glad_debug_glFogCoordPointer
GLAD_API_CALL PFNGLFOGCOORDPOINTEREXTPROC glad_glFogCoordPointerEXT;
GLAD_API_CALL PFNGLFOGCOORDPOINTEREXTPROC glad_debug_glFogCoordPointerEXT;
#define glFogCoordPointerEXT glad_debug_glFogCoordPointerEXT
+GLAD_API_CALL PFNGLFOGCOORDDPROC glad_glFogCoordd;
+GLAD_API_CALL PFNGLFOGCOORDDPROC glad_debug_glFogCoordd;
+#define glFogCoordd glad_debug_glFogCoordd
GLAD_API_CALL PFNGLFOGCOORDDEXTPROC glad_glFogCoorddEXT;
GLAD_API_CALL PFNGLFOGCOORDDEXTPROC glad_debug_glFogCoorddEXT;
#define glFogCoorddEXT glad_debug_glFogCoorddEXT
+GLAD_API_CALL PFNGLFOGCOORDDVPROC glad_glFogCoorddv;
+GLAD_API_CALL PFNGLFOGCOORDDVPROC glad_debug_glFogCoorddv;
+#define glFogCoorddv glad_debug_glFogCoorddv
GLAD_API_CALL PFNGLFOGCOORDDVEXTPROC glad_glFogCoorddvEXT;
GLAD_API_CALL PFNGLFOGCOORDDVEXTPROC glad_debug_glFogCoorddvEXT;
#define glFogCoorddvEXT glad_debug_glFogCoorddvEXT
+GLAD_API_CALL PFNGLFOGCOORDFPROC glad_glFogCoordf;
+GLAD_API_CALL PFNGLFOGCOORDFPROC glad_debug_glFogCoordf;
+#define glFogCoordf glad_debug_glFogCoordf
GLAD_API_CALL PFNGLFOGCOORDFEXTPROC glad_glFogCoordfEXT;
GLAD_API_CALL PFNGLFOGCOORDFEXTPROC glad_debug_glFogCoordfEXT;
#define glFogCoordfEXT glad_debug_glFogCoordfEXT
+GLAD_API_CALL PFNGLFOGCOORDFVPROC glad_glFogCoordfv;
+GLAD_API_CALL PFNGLFOGCOORDFVPROC glad_debug_glFogCoordfv;
+#define glFogCoordfv glad_debug_glFogCoordfv
GLAD_API_CALL PFNGLFOGCOORDFVEXTPROC glad_glFogCoordfvEXT;
GLAD_API_CALL PFNGLFOGCOORDFVEXTPROC glad_debug_glFogCoordfvEXT;
#define glFogCoordfvEXT glad_debug_glFogCoordfvEXT
-GLAD_API_CALL PFNGLFOGXOESPROC glad_glFogxOES;
-GLAD_API_CALL PFNGLFOGXOESPROC glad_debug_glFogxOES;
-#define glFogxOES glad_debug_glFogxOES
-GLAD_API_CALL PFNGLFOGXVOESPROC glad_glFogxvOES;
-GLAD_API_CALL PFNGLFOGXVOESPROC glad_debug_glFogxvOES;
-#define glFogxvOES glad_debug_glFogxvOES
+GLAD_API_CALL PFNGLFOGFPROC glad_glFogf;
+GLAD_API_CALL PFNGLFOGFPROC glad_debug_glFogf;
+#define glFogf glad_debug_glFogf
+GLAD_API_CALL PFNGLFOGFVPROC glad_glFogfv;
+GLAD_API_CALL PFNGLFOGFVPROC glad_debug_glFogfv;
+#define glFogfv glad_debug_glFogfv
+GLAD_API_CALL PFNGLFOGIPROC glad_glFogi;
+GLAD_API_CALL PFNGLFOGIPROC glad_debug_glFogi;
+#define glFogi glad_debug_glFogi
+GLAD_API_CALL PFNGLFOGIVPROC glad_glFogiv;
+GLAD_API_CALL PFNGLFOGIVPROC glad_debug_glFogiv;
+#define glFogiv glad_debug_glFogiv
GLAD_API_CALL PFNGLFRAMEBUFFERPARAMETERIPROC glad_glFramebufferParameteri;
GLAD_API_CALL PFNGLFRAMEBUFFERPARAMETERIPROC glad_debug_glFramebufferParameteri;
#define glFramebufferParameteri glad_debug_glFramebufferParameteri
@@ -4140,9 +5030,9 @@ GLAD_API_CALL PFNGLFRAMEBUFFERTEXTURELAYERARBPROC glad_debug_glFramebufferTextur
GLAD_API_CALL PFNGLFRONTFACEPROC glad_glFrontFace;
GLAD_API_CALL PFNGLFRONTFACEPROC glad_debug_glFrontFace;
#define glFrontFace glad_debug_glFrontFace
-GLAD_API_CALL PFNGLFRUSTUMXOESPROC glad_glFrustumxOES;
-GLAD_API_CALL PFNGLFRUSTUMXOESPROC glad_debug_glFrustumxOES;
-#define glFrustumxOES glad_debug_glFrustumxOES
+GLAD_API_CALL PFNGLFRUSTUMPROC glad_glFrustum;
+GLAD_API_CALL PFNGLFRUSTUMPROC glad_debug_glFrustum;
+#define glFrustum glad_debug_glFrustum
GLAD_API_CALL PFNGLGENBUFFERSPROC glad_glGenBuffers;
GLAD_API_CALL PFNGLGENBUFFERSPROC glad_debug_glGenBuffers;
#define glGenBuffers glad_debug_glGenBuffers
@@ -4155,6 +5045,9 @@ GLAD_API_CALL PFNGLGENFRAMEBUFFERSPROC glad_debug_glGenFramebuffers;
GLAD_API_CALL PFNGLGENFRAMEBUFFERSEXTPROC glad_glGenFramebuffersEXT;
GLAD_API_CALL PFNGLGENFRAMEBUFFERSEXTPROC glad_debug_glGenFramebuffersEXT;
#define glGenFramebuffersEXT glad_debug_glGenFramebuffersEXT
+GLAD_API_CALL PFNGLGENLISTSPROC glad_glGenLists;
+GLAD_API_CALL PFNGLGENLISTSPROC glad_debug_glGenLists;
+#define glGenLists glad_debug_glGenLists
GLAD_API_CALL PFNGLGENPROGRAMPIPELINESPROC glad_glGenProgramPipelines;
GLAD_API_CALL PFNGLGENPROGRAMPIPELINESPROC glad_debug_glGenProgramPipelines;
#define glGenProgramPipelines glad_debug_glGenProgramPipelines
@@ -4269,9 +5162,9 @@ GLAD_API_CALL PFNGLGETBUFFERSUBDATAPROC glad_debug_glGetBufferSubData;
GLAD_API_CALL PFNGLGETBUFFERSUBDATAARBPROC glad_glGetBufferSubDataARB;
GLAD_API_CALL PFNGLGETBUFFERSUBDATAARBPROC glad_debug_glGetBufferSubDataARB;
#define glGetBufferSubDataARB glad_debug_glGetBufferSubDataARB
-GLAD_API_CALL PFNGLGETCLIPPLANEXOESPROC glad_glGetClipPlanexOES;
-GLAD_API_CALL PFNGLGETCLIPPLANEXOESPROC glad_debug_glGetClipPlanexOES;
-#define glGetClipPlanexOES glad_debug_glGetClipPlanexOES
+GLAD_API_CALL PFNGLGETCLIPPLANEPROC glad_glGetClipPlane;
+GLAD_API_CALL PFNGLGETCLIPPLANEPROC glad_debug_glGetClipPlane;
+#define glGetClipPlane glad_debug_glGetClipPlane
GLAD_API_CALL PFNGLGETCOMPRESSEDTEXIMAGEPROC glad_glGetCompressedTexImage;
GLAD_API_CALL PFNGLGETCOMPRESSEDTEXIMAGEPROC glad_debug_glGetCompressedTexImage;
#define glGetCompressedTexImage glad_debug_glGetCompressedTexImage
@@ -4284,9 +5177,6 @@ GLAD_API_CALL PFNGLGETCOMPRESSEDTEXTUREIMAGEPROC glad_debug_glGetCompressedTextu
GLAD_API_CALL PFNGLGETCOMPRESSEDTEXTURESUBIMAGEPROC glad_glGetCompressedTextureSubImage;
GLAD_API_CALL PFNGLGETCOMPRESSEDTEXTURESUBIMAGEPROC glad_debug_glGetCompressedTextureSubImage;
#define glGetCompressedTextureSubImage glad_debug_glGetCompressedTextureSubImage
-GLAD_API_CALL PFNGLGETCONVOLUTIONPARAMETERXVOESPROC glad_glGetConvolutionParameterxvOES;
-GLAD_API_CALL PFNGLGETCONVOLUTIONPARAMETERXVOESPROC glad_debug_glGetConvolutionParameterxvOES;
-#define glGetConvolutionParameterxvOES glad_debug_glGetConvolutionParameterxvOES
GLAD_API_CALL PFNGLGETDEBUGMESSAGELOGPROC glad_glGetDebugMessageLog;
GLAD_API_CALL PFNGLGETDEBUGMESSAGELOGPROC glad_debug_glGetDebugMessageLog;
#define glGetDebugMessageLog glad_debug_glGetDebugMessageLog
@@ -4302,9 +5192,6 @@ GLAD_API_CALL PFNGLGETDOUBLEVPROC glad_debug_glGetDoublev;
GLAD_API_CALL PFNGLGETERRORPROC glad_glGetError;
GLAD_API_CALL PFNGLGETERRORPROC glad_debug_glGetError;
#define glGetError glad_debug_glGetError
-GLAD_API_CALL PFNGLGETFIXEDVOESPROC glad_glGetFixedvOES;
-GLAD_API_CALL PFNGLGETFIXEDVOESPROC glad_debug_glGetFixedvOES;
-#define glGetFixedvOES glad_debug_glGetFixedvOES
GLAD_API_CALL PFNGLGETFLOATI_VPROC glad_glGetFloati_v;
GLAD_API_CALL PFNGLGETFLOATI_VPROC glad_debug_glGetFloati_v;
#define glGetFloati_v glad_debug_glGetFloati_v
@@ -4329,9 +5216,6 @@ GLAD_API_CALL PFNGLGETFRAMEBUFFERPARAMETERIVPROC glad_debug_glGetFramebufferPara
GLAD_API_CALL PFNGLGETHANDLEARBPROC glad_glGetHandleARB;
GLAD_API_CALL PFNGLGETHANDLEARBPROC glad_debug_glGetHandleARB;
#define glGetHandleARB glad_debug_glGetHandleARB
-GLAD_API_CALL PFNGLGETHISTOGRAMPARAMETERXVOESPROC glad_glGetHistogramParameterxvOES;
-GLAD_API_CALL PFNGLGETHISTOGRAMPARAMETERXVOESPROC glad_debug_glGetHistogramParameterxvOES;
-#define glGetHistogramParameterxvOES glad_debug_glGetHistogramParameterxvOES
GLAD_API_CALL PFNGLGETINFOLOGARBPROC glad_glGetInfoLogARB;
GLAD_API_CALL PFNGLGETINFOLOGARBPROC glad_debug_glGetInfoLogARB;
#define glGetInfoLogARB glad_debug_glGetInfoLogARB
@@ -4353,15 +5237,27 @@ GLAD_API_CALL PFNGLGETINTERNALFORMATI64VPROC glad_debug_glGetInternalformati64v;
GLAD_API_CALL PFNGLGETINTERNALFORMATIVPROC glad_glGetInternalformativ;
GLAD_API_CALL PFNGLGETINTERNALFORMATIVPROC glad_debug_glGetInternalformativ;
#define glGetInternalformativ glad_debug_glGetInternalformativ
-GLAD_API_CALL PFNGLGETLIGHTXOESPROC glad_glGetLightxOES;
-GLAD_API_CALL PFNGLGETLIGHTXOESPROC glad_debug_glGetLightxOES;
-#define glGetLightxOES glad_debug_glGetLightxOES
-GLAD_API_CALL PFNGLGETMAPXVOESPROC glad_glGetMapxvOES;
-GLAD_API_CALL PFNGLGETMAPXVOESPROC glad_debug_glGetMapxvOES;
-#define glGetMapxvOES glad_debug_glGetMapxvOES
-GLAD_API_CALL PFNGLGETMATERIALXOESPROC glad_glGetMaterialxOES;
-GLAD_API_CALL PFNGLGETMATERIALXOESPROC glad_debug_glGetMaterialxOES;
-#define glGetMaterialxOES glad_debug_glGetMaterialxOES
+GLAD_API_CALL PFNGLGETLIGHTFVPROC glad_glGetLightfv;
+GLAD_API_CALL PFNGLGETLIGHTFVPROC glad_debug_glGetLightfv;
+#define glGetLightfv glad_debug_glGetLightfv
+GLAD_API_CALL PFNGLGETLIGHTIVPROC glad_glGetLightiv;
+GLAD_API_CALL PFNGLGETLIGHTIVPROC glad_debug_glGetLightiv;
+#define glGetLightiv glad_debug_glGetLightiv
+GLAD_API_CALL PFNGLGETMAPDVPROC glad_glGetMapdv;
+GLAD_API_CALL PFNGLGETMAPDVPROC glad_debug_glGetMapdv;
+#define glGetMapdv glad_debug_glGetMapdv
+GLAD_API_CALL PFNGLGETMAPFVPROC glad_glGetMapfv;
+GLAD_API_CALL PFNGLGETMAPFVPROC glad_debug_glGetMapfv;
+#define glGetMapfv glad_debug_glGetMapfv
+GLAD_API_CALL PFNGLGETMAPIVPROC glad_glGetMapiv;
+GLAD_API_CALL PFNGLGETMAPIVPROC glad_debug_glGetMapiv;
+#define glGetMapiv glad_debug_glGetMapiv
+GLAD_API_CALL PFNGLGETMATERIALFVPROC glad_glGetMaterialfv;
+GLAD_API_CALL PFNGLGETMATERIALFVPROC glad_debug_glGetMaterialfv;
+#define glGetMaterialfv glad_debug_glGetMaterialfv
+GLAD_API_CALL PFNGLGETMATERIALIVPROC glad_glGetMaterialiv;
+GLAD_API_CALL PFNGLGETMATERIALIVPROC glad_debug_glGetMaterialiv;
+#define glGetMaterialiv glad_debug_glGetMaterialiv
GLAD_API_CALL PFNGLGETMULTISAMPLEFVPROC glad_glGetMultisamplefv;
GLAD_API_CALL PFNGLGETMULTISAMPLEFVPROC glad_debug_glGetMultisamplefv;
#define glGetMultisamplefv glad_debug_glGetMultisamplefv
@@ -4404,12 +5300,21 @@ GLAD_API_CALL PFNGLGETOBJECTPARAMETERIVARBPROC glad_debug_glGetObjectParameteriv
GLAD_API_CALL PFNGLGETOBJECTPTRLABELPROC glad_glGetObjectPtrLabel;
GLAD_API_CALL PFNGLGETOBJECTPTRLABELPROC glad_debug_glGetObjectPtrLabel;
#define glGetObjectPtrLabel glad_debug_glGetObjectPtrLabel
-GLAD_API_CALL PFNGLGETPIXELMAPXVPROC glad_glGetPixelMapxv;
-GLAD_API_CALL PFNGLGETPIXELMAPXVPROC glad_debug_glGetPixelMapxv;
-#define glGetPixelMapxv glad_debug_glGetPixelMapxv
+GLAD_API_CALL PFNGLGETPIXELMAPFVPROC glad_glGetPixelMapfv;
+GLAD_API_CALL PFNGLGETPIXELMAPFVPROC glad_debug_glGetPixelMapfv;
+#define glGetPixelMapfv glad_debug_glGetPixelMapfv
+GLAD_API_CALL PFNGLGETPIXELMAPUIVPROC glad_glGetPixelMapuiv;
+GLAD_API_CALL PFNGLGETPIXELMAPUIVPROC glad_debug_glGetPixelMapuiv;
+#define glGetPixelMapuiv glad_debug_glGetPixelMapuiv
+GLAD_API_CALL PFNGLGETPIXELMAPUSVPROC glad_glGetPixelMapusv;
+GLAD_API_CALL PFNGLGETPIXELMAPUSVPROC glad_debug_glGetPixelMapusv;
+#define glGetPixelMapusv glad_debug_glGetPixelMapusv
GLAD_API_CALL PFNGLGETPOINTERVPROC glad_glGetPointerv;
GLAD_API_CALL PFNGLGETPOINTERVPROC glad_debug_glGetPointerv;
#define glGetPointerv glad_debug_glGetPointerv
+GLAD_API_CALL PFNGLGETPOLYGONSTIPPLEPROC glad_glGetPolygonStipple;
+GLAD_API_CALL PFNGLGETPOLYGONSTIPPLEPROC glad_debug_glGetPolygonStipple;
+#define glGetPolygonStipple glad_debug_glGetPolygonStipple
GLAD_API_CALL PFNGLGETPROGRAMBINARYPROC glad_glGetProgramBinary;
GLAD_API_CALL PFNGLGETPROGRAMBINARYPROC glad_debug_glGetProgramBinary;
#define glGetProgramBinary glad_debug_glGetProgramBinary
@@ -4551,12 +5456,21 @@ GLAD_API_CALL PFNGLGETSUBROUTINEUNIFORMLOCATIONPROC glad_debug_glGetSubroutineUn
GLAD_API_CALL PFNGLGETSYNCIVPROC glad_glGetSynciv;
GLAD_API_CALL PFNGLGETSYNCIVPROC glad_debug_glGetSynciv;
#define glGetSynciv glad_debug_glGetSynciv
-GLAD_API_CALL PFNGLGETTEXENVXVOESPROC glad_glGetTexEnvxvOES;
-GLAD_API_CALL PFNGLGETTEXENVXVOESPROC glad_debug_glGetTexEnvxvOES;
-#define glGetTexEnvxvOES glad_debug_glGetTexEnvxvOES
-GLAD_API_CALL PFNGLGETTEXGENXVOESPROC glad_glGetTexGenxvOES;
-GLAD_API_CALL PFNGLGETTEXGENXVOESPROC glad_debug_glGetTexGenxvOES;
-#define glGetTexGenxvOES glad_debug_glGetTexGenxvOES
+GLAD_API_CALL PFNGLGETTEXENVFVPROC glad_glGetTexEnvfv;
+GLAD_API_CALL PFNGLGETTEXENVFVPROC glad_debug_glGetTexEnvfv;
+#define glGetTexEnvfv glad_debug_glGetTexEnvfv
+GLAD_API_CALL PFNGLGETTEXENVIVPROC glad_glGetTexEnviv;
+GLAD_API_CALL PFNGLGETTEXENVIVPROC glad_debug_glGetTexEnviv;
+#define glGetTexEnviv glad_debug_glGetTexEnviv
+GLAD_API_CALL PFNGLGETTEXGENDVPROC glad_glGetTexGendv;
+GLAD_API_CALL PFNGLGETTEXGENDVPROC glad_debug_glGetTexGendv;
+#define glGetTexGendv glad_debug_glGetTexGendv
+GLAD_API_CALL PFNGLGETTEXGENFVPROC glad_glGetTexGenfv;
+GLAD_API_CALL PFNGLGETTEXGENFVPROC glad_debug_glGetTexGenfv;
+#define glGetTexGenfv glad_debug_glGetTexGenfv
+GLAD_API_CALL PFNGLGETTEXGENIVPROC glad_glGetTexGeniv;
+GLAD_API_CALL PFNGLGETTEXGENIVPROC glad_debug_glGetTexGeniv;
+#define glGetTexGeniv glad_debug_glGetTexGeniv
GLAD_API_CALL PFNGLGETTEXIMAGEPROC glad_glGetTexImage;
GLAD_API_CALL PFNGLGETTEXIMAGEPROC glad_debug_glGetTexImage;
#define glGetTexImage glad_debug_glGetTexImage
@@ -4566,9 +5480,6 @@ GLAD_API_CALL PFNGLGETTEXLEVELPARAMETERFVPROC glad_debug_glGetTexLevelParameterf
GLAD_API_CALL PFNGLGETTEXLEVELPARAMETERIVPROC glad_glGetTexLevelParameteriv;
GLAD_API_CALL PFNGLGETTEXLEVELPARAMETERIVPROC glad_debug_glGetTexLevelParameteriv;
#define glGetTexLevelParameteriv glad_debug_glGetTexLevelParameteriv
-GLAD_API_CALL PFNGLGETTEXLEVELPARAMETERXVOESPROC glad_glGetTexLevelParameterxvOES;
-GLAD_API_CALL PFNGLGETTEXLEVELPARAMETERXVOESPROC glad_debug_glGetTexLevelParameterxvOES;
-#define glGetTexLevelParameterxvOES glad_debug_glGetTexLevelParameterxvOES
GLAD_API_CALL PFNGLGETTEXPARAMETERIIVPROC glad_glGetTexParameterIiv;
GLAD_API_CALL PFNGLGETTEXPARAMETERIIVPROC glad_debug_glGetTexParameterIiv;
#define glGetTexParameterIiv glad_debug_glGetTexParameterIiv
@@ -4581,9 +5492,6 @@ GLAD_API_CALL PFNGLGETTEXPARAMETERFVPROC glad_debug_glGetTexParameterfv;
GLAD_API_CALL PFNGLGETTEXPARAMETERIVPROC glad_glGetTexParameteriv;
GLAD_API_CALL PFNGLGETTEXPARAMETERIVPROC glad_debug_glGetTexParameteriv;
#define glGetTexParameteriv glad_debug_glGetTexParameteriv
-GLAD_API_CALL PFNGLGETTEXPARAMETERXVOESPROC glad_glGetTexParameterxvOES;
-GLAD_API_CALL PFNGLGETTEXPARAMETERXVOESPROC glad_debug_glGetTexParameterxvOES;
-#define glGetTexParameterxvOES glad_debug_glGetTexParameterxvOES
GLAD_API_CALL PFNGLGETTEXTUREIMAGEPROC glad_glGetTextureImage;
GLAD_API_CALL PFNGLGETTEXTUREIMAGEPROC glad_debug_glGetTextureImage;
#define glGetTextureImage glad_debug_glGetTextureImage
@@ -4710,12 +5618,48 @@ GLAD_API_CALL PFNGLGETNUNIFORMUI64VARBPROC glad_debug_glGetnUniformui64vARB;
GLAD_API_CALL PFNGLHINTPROC glad_glHint;
GLAD_API_CALL PFNGLHINTPROC glad_debug_glHint;
#define glHint glad_debug_glHint
-GLAD_API_CALL PFNGLINDEXXOESPROC glad_glIndexxOES;
-GLAD_API_CALL PFNGLINDEXXOESPROC glad_debug_glIndexxOES;
-#define glIndexxOES glad_debug_glIndexxOES
-GLAD_API_CALL PFNGLINDEXXVOESPROC glad_glIndexxvOES;
-GLAD_API_CALL PFNGLINDEXXVOESPROC glad_debug_glIndexxvOES;
-#define glIndexxvOES glad_debug_glIndexxvOES
+GLAD_API_CALL PFNGLINDEXMASKPROC glad_glIndexMask;
+GLAD_API_CALL PFNGLINDEXMASKPROC glad_debug_glIndexMask;
+#define glIndexMask glad_debug_glIndexMask
+GLAD_API_CALL PFNGLINDEXPOINTERPROC glad_glIndexPointer;
+GLAD_API_CALL PFNGLINDEXPOINTERPROC glad_debug_glIndexPointer;
+#define glIndexPointer glad_debug_glIndexPointer
+GLAD_API_CALL PFNGLINDEXDPROC glad_glIndexd;
+GLAD_API_CALL PFNGLINDEXDPROC glad_debug_glIndexd;
+#define glIndexd glad_debug_glIndexd
+GLAD_API_CALL PFNGLINDEXDVPROC glad_glIndexdv;
+GLAD_API_CALL PFNGLINDEXDVPROC glad_debug_glIndexdv;
+#define glIndexdv glad_debug_glIndexdv
+GLAD_API_CALL PFNGLINDEXFPROC glad_glIndexf;
+GLAD_API_CALL PFNGLINDEXFPROC glad_debug_glIndexf;
+#define glIndexf glad_debug_glIndexf
+GLAD_API_CALL PFNGLINDEXFVPROC glad_glIndexfv;
+GLAD_API_CALL PFNGLINDEXFVPROC glad_debug_glIndexfv;
+#define glIndexfv glad_debug_glIndexfv
+GLAD_API_CALL PFNGLINDEXIPROC glad_glIndexi;
+GLAD_API_CALL PFNGLINDEXIPROC glad_debug_glIndexi;
+#define glIndexi glad_debug_glIndexi
+GLAD_API_CALL PFNGLINDEXIVPROC glad_glIndexiv;
+GLAD_API_CALL PFNGLINDEXIVPROC glad_debug_glIndexiv;
+#define glIndexiv glad_debug_glIndexiv
+GLAD_API_CALL PFNGLINDEXSPROC glad_glIndexs;
+GLAD_API_CALL PFNGLINDEXSPROC glad_debug_glIndexs;
+#define glIndexs glad_debug_glIndexs
+GLAD_API_CALL PFNGLINDEXSVPROC glad_glIndexsv;
+GLAD_API_CALL PFNGLINDEXSVPROC glad_debug_glIndexsv;
+#define glIndexsv glad_debug_glIndexsv
+GLAD_API_CALL PFNGLINDEXUBPROC glad_glIndexub;
+GLAD_API_CALL PFNGLINDEXUBPROC glad_debug_glIndexub;
+#define glIndexub glad_debug_glIndexub
+GLAD_API_CALL PFNGLINDEXUBVPROC glad_glIndexubv;
+GLAD_API_CALL PFNGLINDEXUBVPROC glad_debug_glIndexubv;
+#define glIndexubv glad_debug_glIndexubv
+GLAD_API_CALL PFNGLINITNAMESPROC glad_glInitNames;
+GLAD_API_CALL PFNGLINITNAMESPROC glad_debug_glInitNames;
+#define glInitNames glad_debug_glInitNames
+GLAD_API_CALL PFNGLINTERLEAVEDARRAYSPROC glad_glInterleavedArrays;
+GLAD_API_CALL PFNGLINTERLEAVEDARRAYSPROC glad_debug_glInterleavedArrays;
+#define glInterleavedArrays glad_debug_glInterleavedArrays
GLAD_API_CALL PFNGLINVALIDATEBUFFERDATAPROC glad_glInvalidateBufferData;
GLAD_API_CALL PFNGLINVALIDATEBUFFERDATAPROC glad_debug_glInvalidateBufferData;
#define glInvalidateBufferData glad_debug_glInvalidateBufferData
@@ -4758,6 +5702,9 @@ GLAD_API_CALL PFNGLISFRAMEBUFFERPROC glad_debug_glIsFramebuffer;
GLAD_API_CALL PFNGLISFRAMEBUFFEREXTPROC glad_glIsFramebufferEXT;
GLAD_API_CALL PFNGLISFRAMEBUFFEREXTPROC glad_debug_glIsFramebufferEXT;
#define glIsFramebufferEXT glad_debug_glIsFramebufferEXT
+GLAD_API_CALL PFNGLISLISTPROC glad_glIsList;
+GLAD_API_CALL PFNGLISLISTPROC glad_debug_glIsList;
+#define glIsList glad_debug_glIsList
GLAD_API_CALL PFNGLISNAMEDSTRINGARBPROC glad_glIsNamedStringARB;
GLAD_API_CALL PFNGLISNAMEDSTRINGARBPROC glad_debug_glIsNamedStringARB;
#define glIsNamedStringARB glad_debug_glIsNamedStringARB
@@ -4800,51 +5747,84 @@ GLAD_API_CALL PFNGLISTRANSFORMFEEDBACKPROC glad_debug_glIsTransformFeedback;
GLAD_API_CALL PFNGLISVERTEXARRAYPROC glad_glIsVertexArray;
GLAD_API_CALL PFNGLISVERTEXARRAYPROC glad_debug_glIsVertexArray;
#define glIsVertexArray glad_debug_glIsVertexArray
-GLAD_API_CALL PFNGLLIGHTMODELXOESPROC glad_glLightModelxOES;
-GLAD_API_CALL PFNGLLIGHTMODELXOESPROC glad_debug_glLightModelxOES;
-#define glLightModelxOES glad_debug_glLightModelxOES
-GLAD_API_CALL PFNGLLIGHTMODELXVOESPROC glad_glLightModelxvOES;
-GLAD_API_CALL PFNGLLIGHTMODELXVOESPROC glad_debug_glLightModelxvOES;
-#define glLightModelxvOES glad_debug_glLightModelxvOES
-GLAD_API_CALL PFNGLLIGHTXOESPROC glad_glLightxOES;
-GLAD_API_CALL PFNGLLIGHTXOESPROC glad_debug_glLightxOES;
-#define glLightxOES glad_debug_glLightxOES
-GLAD_API_CALL PFNGLLIGHTXVOESPROC glad_glLightxvOES;
-GLAD_API_CALL PFNGLLIGHTXVOESPROC glad_debug_glLightxvOES;
-#define glLightxvOES glad_debug_glLightxvOES
+GLAD_API_CALL PFNGLLIGHTMODELFPROC glad_glLightModelf;
+GLAD_API_CALL PFNGLLIGHTMODELFPROC glad_debug_glLightModelf;
+#define glLightModelf glad_debug_glLightModelf
+GLAD_API_CALL PFNGLLIGHTMODELFVPROC glad_glLightModelfv;
+GLAD_API_CALL PFNGLLIGHTMODELFVPROC glad_debug_glLightModelfv;
+#define glLightModelfv glad_debug_glLightModelfv
+GLAD_API_CALL PFNGLLIGHTMODELIPROC glad_glLightModeli;
+GLAD_API_CALL PFNGLLIGHTMODELIPROC glad_debug_glLightModeli;
+#define glLightModeli glad_debug_glLightModeli
+GLAD_API_CALL PFNGLLIGHTMODELIVPROC glad_glLightModeliv;
+GLAD_API_CALL PFNGLLIGHTMODELIVPROC glad_debug_glLightModeliv;
+#define glLightModeliv glad_debug_glLightModeliv
+GLAD_API_CALL PFNGLLIGHTFPROC glad_glLightf;
+GLAD_API_CALL PFNGLLIGHTFPROC glad_debug_glLightf;
+#define glLightf glad_debug_glLightf
+GLAD_API_CALL PFNGLLIGHTFVPROC glad_glLightfv;
+GLAD_API_CALL PFNGLLIGHTFVPROC glad_debug_glLightfv;
+#define glLightfv glad_debug_glLightfv
+GLAD_API_CALL PFNGLLIGHTIPROC glad_glLighti;
+GLAD_API_CALL PFNGLLIGHTIPROC glad_debug_glLighti;
+#define glLighti glad_debug_glLighti
+GLAD_API_CALL PFNGLLIGHTIVPROC glad_glLightiv;
+GLAD_API_CALL PFNGLLIGHTIVPROC glad_debug_glLightiv;
+#define glLightiv glad_debug_glLightiv
+GLAD_API_CALL PFNGLLINESTIPPLEPROC glad_glLineStipple;
+GLAD_API_CALL PFNGLLINESTIPPLEPROC glad_debug_glLineStipple;
+#define glLineStipple glad_debug_glLineStipple
GLAD_API_CALL PFNGLLINEWIDTHPROC glad_glLineWidth;
GLAD_API_CALL PFNGLLINEWIDTHPROC glad_debug_glLineWidth;
#define glLineWidth glad_debug_glLineWidth
-GLAD_API_CALL PFNGLLINEWIDTHXOESPROC glad_glLineWidthxOES;
-GLAD_API_CALL PFNGLLINEWIDTHXOESPROC glad_debug_glLineWidthxOES;
-#define glLineWidthxOES glad_debug_glLineWidthxOES
GLAD_API_CALL PFNGLLINKPROGRAMPROC glad_glLinkProgram;
GLAD_API_CALL PFNGLLINKPROGRAMPROC glad_debug_glLinkProgram;
#define glLinkProgram glad_debug_glLinkProgram
GLAD_API_CALL PFNGLLINKPROGRAMARBPROC glad_glLinkProgramARB;
GLAD_API_CALL PFNGLLINKPROGRAMARBPROC glad_debug_glLinkProgramARB;
#define glLinkProgramARB glad_debug_glLinkProgramARB
-GLAD_API_CALL PFNGLLOADMATRIXXOESPROC glad_glLoadMatrixxOES;
-GLAD_API_CALL PFNGLLOADMATRIXXOESPROC glad_debug_glLoadMatrixxOES;
-#define glLoadMatrixxOES glad_debug_glLoadMatrixxOES
+GLAD_API_CALL PFNGLLISTBASEPROC glad_glListBase;
+GLAD_API_CALL PFNGLLISTBASEPROC glad_debug_glListBase;
+#define glListBase glad_debug_glListBase
+GLAD_API_CALL PFNGLLOADIDENTITYPROC glad_glLoadIdentity;
+GLAD_API_CALL PFNGLLOADIDENTITYPROC glad_debug_glLoadIdentity;
+#define glLoadIdentity glad_debug_glLoadIdentity
+GLAD_API_CALL PFNGLLOADMATRIXDPROC glad_glLoadMatrixd;
+GLAD_API_CALL PFNGLLOADMATRIXDPROC glad_debug_glLoadMatrixd;
+#define glLoadMatrixd glad_debug_glLoadMatrixd
+GLAD_API_CALL PFNGLLOADMATRIXFPROC glad_glLoadMatrixf;
+GLAD_API_CALL PFNGLLOADMATRIXFPROC glad_debug_glLoadMatrixf;
+#define glLoadMatrixf glad_debug_glLoadMatrixf
+GLAD_API_CALL PFNGLLOADNAMEPROC glad_glLoadName;
+GLAD_API_CALL PFNGLLOADNAMEPROC glad_debug_glLoadName;
+#define glLoadName glad_debug_glLoadName
+GLAD_API_CALL PFNGLLOADTRANSPOSEMATRIXDPROC glad_glLoadTransposeMatrixd;
+GLAD_API_CALL PFNGLLOADTRANSPOSEMATRIXDPROC glad_debug_glLoadTransposeMatrixd;
+#define glLoadTransposeMatrixd glad_debug_glLoadTransposeMatrixd
GLAD_API_CALL PFNGLLOADTRANSPOSEMATRIXDARBPROC glad_glLoadTransposeMatrixdARB;
GLAD_API_CALL PFNGLLOADTRANSPOSEMATRIXDARBPROC glad_debug_glLoadTransposeMatrixdARB;
#define glLoadTransposeMatrixdARB glad_debug_glLoadTransposeMatrixdARB
+GLAD_API_CALL PFNGLLOADTRANSPOSEMATRIXFPROC glad_glLoadTransposeMatrixf;
+GLAD_API_CALL PFNGLLOADTRANSPOSEMATRIXFPROC glad_debug_glLoadTransposeMatrixf;
+#define glLoadTransposeMatrixf glad_debug_glLoadTransposeMatrixf
GLAD_API_CALL PFNGLLOADTRANSPOSEMATRIXFARBPROC glad_glLoadTransposeMatrixfARB;
GLAD_API_CALL PFNGLLOADTRANSPOSEMATRIXFARBPROC glad_debug_glLoadTransposeMatrixfARB;
#define glLoadTransposeMatrixfARB glad_debug_glLoadTransposeMatrixfARB
-GLAD_API_CALL PFNGLLOADTRANSPOSEMATRIXXOESPROC glad_glLoadTransposeMatrixxOES;
-GLAD_API_CALL PFNGLLOADTRANSPOSEMATRIXXOESPROC glad_debug_glLoadTransposeMatrixxOES;
-#define glLoadTransposeMatrixxOES glad_debug_glLoadTransposeMatrixxOES
GLAD_API_CALL PFNGLLOGICOPPROC glad_glLogicOp;
GLAD_API_CALL PFNGLLOGICOPPROC glad_debug_glLogicOp;
#define glLogicOp glad_debug_glLogicOp
-GLAD_API_CALL PFNGLMAP1XOESPROC glad_glMap1xOES;
-GLAD_API_CALL PFNGLMAP1XOESPROC glad_debug_glMap1xOES;
-#define glMap1xOES glad_debug_glMap1xOES
-GLAD_API_CALL PFNGLMAP2XOESPROC glad_glMap2xOES;
-GLAD_API_CALL PFNGLMAP2XOESPROC glad_debug_glMap2xOES;
-#define glMap2xOES glad_debug_glMap2xOES
+GLAD_API_CALL PFNGLMAP1DPROC glad_glMap1d;
+GLAD_API_CALL PFNGLMAP1DPROC glad_debug_glMap1d;
+#define glMap1d glad_debug_glMap1d
+GLAD_API_CALL PFNGLMAP1FPROC glad_glMap1f;
+GLAD_API_CALL PFNGLMAP1FPROC glad_debug_glMap1f;
+#define glMap1f glad_debug_glMap1f
+GLAD_API_CALL PFNGLMAP2DPROC glad_glMap2d;
+GLAD_API_CALL PFNGLMAP2DPROC glad_debug_glMap2d;
+#define glMap2d glad_debug_glMap2d
+GLAD_API_CALL PFNGLMAP2FPROC glad_glMap2f;
+GLAD_API_CALL PFNGLMAP2FPROC glad_debug_glMap2f;
+#define glMap2f glad_debug_glMap2f
GLAD_API_CALL PFNGLMAPBUFFERPROC glad_glMapBuffer;
GLAD_API_CALL PFNGLMAPBUFFERPROC glad_debug_glMapBuffer;
#define glMapBuffer glad_debug_glMapBuffer
@@ -4854,48 +5834,66 @@ GLAD_API_CALL PFNGLMAPBUFFERARBPROC glad_debug_glMapBufferARB;
GLAD_API_CALL PFNGLMAPBUFFERRANGEPROC glad_glMapBufferRange;
GLAD_API_CALL PFNGLMAPBUFFERRANGEPROC glad_debug_glMapBufferRange;
#define glMapBufferRange glad_debug_glMapBufferRange
-GLAD_API_CALL PFNGLMAPGRID1XOESPROC glad_glMapGrid1xOES;
-GLAD_API_CALL PFNGLMAPGRID1XOESPROC glad_debug_glMapGrid1xOES;
-#define glMapGrid1xOES glad_debug_glMapGrid1xOES
-GLAD_API_CALL PFNGLMAPGRID2XOESPROC glad_glMapGrid2xOES;
-GLAD_API_CALL PFNGLMAPGRID2XOESPROC glad_debug_glMapGrid2xOES;
-#define glMapGrid2xOES glad_debug_glMapGrid2xOES
+GLAD_API_CALL PFNGLMAPGRID1DPROC glad_glMapGrid1d;
+GLAD_API_CALL PFNGLMAPGRID1DPROC glad_debug_glMapGrid1d;
+#define glMapGrid1d glad_debug_glMapGrid1d
+GLAD_API_CALL PFNGLMAPGRID1FPROC glad_glMapGrid1f;
+GLAD_API_CALL PFNGLMAPGRID1FPROC glad_debug_glMapGrid1f;
+#define glMapGrid1f glad_debug_glMapGrid1f
+GLAD_API_CALL PFNGLMAPGRID2DPROC glad_glMapGrid2d;
+GLAD_API_CALL PFNGLMAPGRID2DPROC glad_debug_glMapGrid2d;
+#define glMapGrid2d glad_debug_glMapGrid2d
+GLAD_API_CALL PFNGLMAPGRID2FPROC glad_glMapGrid2f;
+GLAD_API_CALL PFNGLMAPGRID2FPROC glad_debug_glMapGrid2f;
+#define glMapGrid2f glad_debug_glMapGrid2f
GLAD_API_CALL PFNGLMAPNAMEDBUFFERPROC glad_glMapNamedBuffer;
GLAD_API_CALL PFNGLMAPNAMEDBUFFERPROC glad_debug_glMapNamedBuffer;
#define glMapNamedBuffer glad_debug_glMapNamedBuffer
GLAD_API_CALL PFNGLMAPNAMEDBUFFERRANGEPROC glad_glMapNamedBufferRange;
GLAD_API_CALL PFNGLMAPNAMEDBUFFERRANGEPROC glad_debug_glMapNamedBufferRange;
#define glMapNamedBufferRange glad_debug_glMapNamedBufferRange
-GLAD_API_CALL PFNGLMATERIALXOESPROC glad_glMaterialxOES;
-GLAD_API_CALL PFNGLMATERIALXOESPROC glad_debug_glMaterialxOES;
-#define glMaterialxOES glad_debug_glMaterialxOES
-GLAD_API_CALL PFNGLMATERIALXVOESPROC glad_glMaterialxvOES;
-GLAD_API_CALL PFNGLMATERIALXVOESPROC glad_debug_glMaterialxvOES;
-#define glMaterialxvOES glad_debug_glMaterialxvOES
+GLAD_API_CALL PFNGLMATERIALFPROC glad_glMaterialf;
+GLAD_API_CALL PFNGLMATERIALFPROC glad_debug_glMaterialf;
+#define glMaterialf glad_debug_glMaterialf
+GLAD_API_CALL PFNGLMATERIALFVPROC glad_glMaterialfv;
+GLAD_API_CALL PFNGLMATERIALFVPROC glad_debug_glMaterialfv;
+#define glMaterialfv glad_debug_glMaterialfv
+GLAD_API_CALL PFNGLMATERIALIPROC glad_glMateriali;
+GLAD_API_CALL PFNGLMATERIALIPROC glad_debug_glMateriali;
+#define glMateriali glad_debug_glMateriali
+GLAD_API_CALL PFNGLMATERIALIVPROC glad_glMaterialiv;
+GLAD_API_CALL PFNGLMATERIALIVPROC glad_debug_glMaterialiv;
+#define glMaterialiv glad_debug_glMaterialiv
+GLAD_API_CALL PFNGLMATRIXMODEPROC glad_glMatrixMode;
+GLAD_API_CALL PFNGLMATRIXMODEPROC glad_debug_glMatrixMode;
+#define glMatrixMode glad_debug_glMatrixMode
GLAD_API_CALL PFNGLMEMORYBARRIERPROC glad_glMemoryBarrier;
GLAD_API_CALL PFNGLMEMORYBARRIERPROC glad_debug_glMemoryBarrier;
#define glMemoryBarrier glad_debug_glMemoryBarrier
-GLAD_API_CALL PFNGLMEMORYBARRIERBYREGIONPROC glad_glMemoryBarrierByRegion;
-GLAD_API_CALL PFNGLMEMORYBARRIERBYREGIONPROC glad_debug_glMemoryBarrierByRegion;
-#define glMemoryBarrierByRegion glad_debug_glMemoryBarrierByRegion
GLAD_API_CALL PFNGLMINSAMPLESHADINGPROC glad_glMinSampleShading;
GLAD_API_CALL PFNGLMINSAMPLESHADINGPROC glad_debug_glMinSampleShading;
#define glMinSampleShading glad_debug_glMinSampleShading
GLAD_API_CALL PFNGLMINSAMPLESHADINGARBPROC glad_glMinSampleShadingARB;
GLAD_API_CALL PFNGLMINSAMPLESHADINGARBPROC glad_debug_glMinSampleShadingARB;
#define glMinSampleShadingARB glad_debug_glMinSampleShadingARB
-GLAD_API_CALL PFNGLMULTMATRIXXOESPROC glad_glMultMatrixxOES;
-GLAD_API_CALL PFNGLMULTMATRIXXOESPROC glad_debug_glMultMatrixxOES;
-#define glMultMatrixxOES glad_debug_glMultMatrixxOES
+GLAD_API_CALL PFNGLMULTMATRIXDPROC glad_glMultMatrixd;
+GLAD_API_CALL PFNGLMULTMATRIXDPROC glad_debug_glMultMatrixd;
+#define glMultMatrixd glad_debug_glMultMatrixd
+GLAD_API_CALL PFNGLMULTMATRIXFPROC glad_glMultMatrixf;
+GLAD_API_CALL PFNGLMULTMATRIXFPROC glad_debug_glMultMatrixf;
+#define glMultMatrixf glad_debug_glMultMatrixf
+GLAD_API_CALL PFNGLMULTTRANSPOSEMATRIXDPROC glad_glMultTransposeMatrixd;
+GLAD_API_CALL PFNGLMULTTRANSPOSEMATRIXDPROC glad_debug_glMultTransposeMatrixd;
+#define glMultTransposeMatrixd glad_debug_glMultTransposeMatrixd
GLAD_API_CALL PFNGLMULTTRANSPOSEMATRIXDARBPROC glad_glMultTransposeMatrixdARB;
GLAD_API_CALL PFNGLMULTTRANSPOSEMATRIXDARBPROC glad_debug_glMultTransposeMatrixdARB;
#define glMultTransposeMatrixdARB glad_debug_glMultTransposeMatrixdARB
+GLAD_API_CALL PFNGLMULTTRANSPOSEMATRIXFPROC glad_glMultTransposeMatrixf;
+GLAD_API_CALL PFNGLMULTTRANSPOSEMATRIXFPROC glad_debug_glMultTransposeMatrixf;
+#define glMultTransposeMatrixf glad_debug_glMultTransposeMatrixf
GLAD_API_CALL PFNGLMULTTRANSPOSEMATRIXFARBPROC glad_glMultTransposeMatrixfARB;
GLAD_API_CALL PFNGLMULTTRANSPOSEMATRIXFARBPROC glad_debug_glMultTransposeMatrixfARB;
#define glMultTransposeMatrixfARB glad_debug_glMultTransposeMatrixfARB
-GLAD_API_CALL PFNGLMULTTRANSPOSEMATRIXXOESPROC glad_glMultTransposeMatrixxOES;
-GLAD_API_CALL PFNGLMULTTRANSPOSEMATRIXXOESPROC glad_debug_glMultTransposeMatrixxOES;
-#define glMultTransposeMatrixxOES glad_debug_glMultTransposeMatrixxOES
GLAD_API_CALL PFNGLMULTIDRAWARRAYSPROC glad_glMultiDrawArrays;
GLAD_API_CALL PFNGLMULTIDRAWARRAYSPROC glad_debug_glMultiDrawArrays;
#define glMultiDrawArrays glad_debug_glMultiDrawArrays
@@ -4911,126 +5909,222 @@ GLAD_API_CALL PFNGLMULTIDRAWELEMENTSBASEVERTEXPROC glad_debug_glMultiDrawElement
GLAD_API_CALL PFNGLMULTIDRAWELEMENTSINDIRECTPROC glad_glMultiDrawElementsIndirect;
GLAD_API_CALL PFNGLMULTIDRAWELEMENTSINDIRECTPROC glad_debug_glMultiDrawElementsIndirect;
#define glMultiDrawElementsIndirect glad_debug_glMultiDrawElementsIndirect
+GLAD_API_CALL PFNGLMULTITEXCOORD1DPROC glad_glMultiTexCoord1d;
+GLAD_API_CALL PFNGLMULTITEXCOORD1DPROC glad_debug_glMultiTexCoord1d;
+#define glMultiTexCoord1d glad_debug_glMultiTexCoord1d
GLAD_API_CALL PFNGLMULTITEXCOORD1DARBPROC glad_glMultiTexCoord1dARB;
GLAD_API_CALL PFNGLMULTITEXCOORD1DARBPROC glad_debug_glMultiTexCoord1dARB;
#define glMultiTexCoord1dARB glad_debug_glMultiTexCoord1dARB
+GLAD_API_CALL PFNGLMULTITEXCOORD1DVPROC glad_glMultiTexCoord1dv;
+GLAD_API_CALL PFNGLMULTITEXCOORD1DVPROC glad_debug_glMultiTexCoord1dv;
+#define glMultiTexCoord1dv glad_debug_glMultiTexCoord1dv
GLAD_API_CALL PFNGLMULTITEXCOORD1DVARBPROC glad_glMultiTexCoord1dvARB;
GLAD_API_CALL PFNGLMULTITEXCOORD1DVARBPROC glad_debug_glMultiTexCoord1dvARB;
#define glMultiTexCoord1dvARB glad_debug_glMultiTexCoord1dvARB
+GLAD_API_CALL PFNGLMULTITEXCOORD1FPROC glad_glMultiTexCoord1f;
+GLAD_API_CALL PFNGLMULTITEXCOORD1FPROC glad_debug_glMultiTexCoord1f;
+#define glMultiTexCoord1f glad_debug_glMultiTexCoord1f
GLAD_API_CALL PFNGLMULTITEXCOORD1FARBPROC glad_glMultiTexCoord1fARB;
GLAD_API_CALL PFNGLMULTITEXCOORD1FARBPROC glad_debug_glMultiTexCoord1fARB;
#define glMultiTexCoord1fARB glad_debug_glMultiTexCoord1fARB
+GLAD_API_CALL PFNGLMULTITEXCOORD1FVPROC glad_glMultiTexCoord1fv;
+GLAD_API_CALL PFNGLMULTITEXCOORD1FVPROC glad_debug_glMultiTexCoord1fv;
+#define glMultiTexCoord1fv glad_debug_glMultiTexCoord1fv
GLAD_API_CALL PFNGLMULTITEXCOORD1FVARBPROC glad_glMultiTexCoord1fvARB;
GLAD_API_CALL PFNGLMULTITEXCOORD1FVARBPROC glad_debug_glMultiTexCoord1fvARB;
#define glMultiTexCoord1fvARB glad_debug_glMultiTexCoord1fvARB
+GLAD_API_CALL PFNGLMULTITEXCOORD1IPROC glad_glMultiTexCoord1i;
+GLAD_API_CALL PFNGLMULTITEXCOORD1IPROC glad_debug_glMultiTexCoord1i;
+#define glMultiTexCoord1i glad_debug_glMultiTexCoord1i
GLAD_API_CALL PFNGLMULTITEXCOORD1IARBPROC glad_glMultiTexCoord1iARB;
GLAD_API_CALL PFNGLMULTITEXCOORD1IARBPROC glad_debug_glMultiTexCoord1iARB;
#define glMultiTexCoord1iARB glad_debug_glMultiTexCoord1iARB
+GLAD_API_CALL PFNGLMULTITEXCOORD1IVPROC glad_glMultiTexCoord1iv;
+GLAD_API_CALL PFNGLMULTITEXCOORD1IVPROC glad_debug_glMultiTexCoord1iv;
+#define glMultiTexCoord1iv glad_debug_glMultiTexCoord1iv
GLAD_API_CALL PFNGLMULTITEXCOORD1IVARBPROC glad_glMultiTexCoord1ivARB;
GLAD_API_CALL PFNGLMULTITEXCOORD1IVARBPROC glad_debug_glMultiTexCoord1ivARB;
#define glMultiTexCoord1ivARB glad_debug_glMultiTexCoord1ivARB
+GLAD_API_CALL PFNGLMULTITEXCOORD1SPROC glad_glMultiTexCoord1s;
+GLAD_API_CALL PFNGLMULTITEXCOORD1SPROC glad_debug_glMultiTexCoord1s;
+#define glMultiTexCoord1s glad_debug_glMultiTexCoord1s
GLAD_API_CALL PFNGLMULTITEXCOORD1SARBPROC glad_glMultiTexCoord1sARB;
GLAD_API_CALL PFNGLMULTITEXCOORD1SARBPROC glad_debug_glMultiTexCoord1sARB;
#define glMultiTexCoord1sARB glad_debug_glMultiTexCoord1sARB
+GLAD_API_CALL PFNGLMULTITEXCOORD1SVPROC glad_glMultiTexCoord1sv;
+GLAD_API_CALL PFNGLMULTITEXCOORD1SVPROC glad_debug_glMultiTexCoord1sv;
+#define glMultiTexCoord1sv glad_debug_glMultiTexCoord1sv
GLAD_API_CALL PFNGLMULTITEXCOORD1SVARBPROC glad_glMultiTexCoord1svARB;
GLAD_API_CALL PFNGLMULTITEXCOORD1SVARBPROC glad_debug_glMultiTexCoord1svARB;
#define glMultiTexCoord1svARB glad_debug_glMultiTexCoord1svARB
-GLAD_API_CALL PFNGLMULTITEXCOORD1XOESPROC glad_glMultiTexCoord1xOES;
-GLAD_API_CALL PFNGLMULTITEXCOORD1XOESPROC glad_debug_glMultiTexCoord1xOES;
-#define glMultiTexCoord1xOES glad_debug_glMultiTexCoord1xOES
-GLAD_API_CALL PFNGLMULTITEXCOORD1XVOESPROC glad_glMultiTexCoord1xvOES;
-GLAD_API_CALL PFNGLMULTITEXCOORD1XVOESPROC glad_debug_glMultiTexCoord1xvOES;
-#define glMultiTexCoord1xvOES glad_debug_glMultiTexCoord1xvOES
+GLAD_API_CALL PFNGLMULTITEXCOORD2DPROC glad_glMultiTexCoord2d;
+GLAD_API_CALL PFNGLMULTITEXCOORD2DPROC glad_debug_glMultiTexCoord2d;
+#define glMultiTexCoord2d glad_debug_glMultiTexCoord2d
GLAD_API_CALL PFNGLMULTITEXCOORD2DARBPROC glad_glMultiTexCoord2dARB;
GLAD_API_CALL PFNGLMULTITEXCOORD2DARBPROC glad_debug_glMultiTexCoord2dARB;
#define glMultiTexCoord2dARB glad_debug_glMultiTexCoord2dARB
+GLAD_API_CALL PFNGLMULTITEXCOORD2DVPROC glad_glMultiTexCoord2dv;
+GLAD_API_CALL PFNGLMULTITEXCOORD2DVPROC glad_debug_glMultiTexCoord2dv;
+#define glMultiTexCoord2dv glad_debug_glMultiTexCoord2dv
GLAD_API_CALL PFNGLMULTITEXCOORD2DVARBPROC glad_glMultiTexCoord2dvARB;
GLAD_API_CALL PFNGLMULTITEXCOORD2DVARBPROC glad_debug_glMultiTexCoord2dvARB;
#define glMultiTexCoord2dvARB glad_debug_glMultiTexCoord2dvARB
+GLAD_API_CALL PFNGLMULTITEXCOORD2FPROC glad_glMultiTexCoord2f;
+GLAD_API_CALL PFNGLMULTITEXCOORD2FPROC glad_debug_glMultiTexCoord2f;
+#define glMultiTexCoord2f glad_debug_glMultiTexCoord2f
GLAD_API_CALL PFNGLMULTITEXCOORD2FARBPROC glad_glMultiTexCoord2fARB;
GLAD_API_CALL PFNGLMULTITEXCOORD2FARBPROC glad_debug_glMultiTexCoord2fARB;
#define glMultiTexCoord2fARB glad_debug_glMultiTexCoord2fARB
+GLAD_API_CALL PFNGLMULTITEXCOORD2FVPROC glad_glMultiTexCoord2fv;
+GLAD_API_CALL PFNGLMULTITEXCOORD2FVPROC glad_debug_glMultiTexCoord2fv;
+#define glMultiTexCoord2fv glad_debug_glMultiTexCoord2fv
GLAD_API_CALL PFNGLMULTITEXCOORD2FVARBPROC glad_glMultiTexCoord2fvARB;
GLAD_API_CALL PFNGLMULTITEXCOORD2FVARBPROC glad_debug_glMultiTexCoord2fvARB;
#define glMultiTexCoord2fvARB glad_debug_glMultiTexCoord2fvARB
+GLAD_API_CALL PFNGLMULTITEXCOORD2IPROC glad_glMultiTexCoord2i;
+GLAD_API_CALL PFNGLMULTITEXCOORD2IPROC glad_debug_glMultiTexCoord2i;
+#define glMultiTexCoord2i glad_debug_glMultiTexCoord2i
GLAD_API_CALL PFNGLMULTITEXCOORD2IARBPROC glad_glMultiTexCoord2iARB;
GLAD_API_CALL PFNGLMULTITEXCOORD2IARBPROC glad_debug_glMultiTexCoord2iARB;
#define glMultiTexCoord2iARB glad_debug_glMultiTexCoord2iARB
+GLAD_API_CALL PFNGLMULTITEXCOORD2IVPROC glad_glMultiTexCoord2iv;
+GLAD_API_CALL PFNGLMULTITEXCOORD2IVPROC glad_debug_glMultiTexCoord2iv;
+#define glMultiTexCoord2iv glad_debug_glMultiTexCoord2iv
GLAD_API_CALL PFNGLMULTITEXCOORD2IVARBPROC glad_glMultiTexCoord2ivARB;
GLAD_API_CALL PFNGLMULTITEXCOORD2IVARBPROC glad_debug_glMultiTexCoord2ivARB;
#define glMultiTexCoord2ivARB glad_debug_glMultiTexCoord2ivARB
+GLAD_API_CALL PFNGLMULTITEXCOORD2SPROC glad_glMultiTexCoord2s;
+GLAD_API_CALL PFNGLMULTITEXCOORD2SPROC glad_debug_glMultiTexCoord2s;
+#define glMultiTexCoord2s glad_debug_glMultiTexCoord2s
GLAD_API_CALL PFNGLMULTITEXCOORD2SARBPROC glad_glMultiTexCoord2sARB;
GLAD_API_CALL PFNGLMULTITEXCOORD2SARBPROC glad_debug_glMultiTexCoord2sARB;
#define glMultiTexCoord2sARB glad_debug_glMultiTexCoord2sARB
+GLAD_API_CALL PFNGLMULTITEXCOORD2SVPROC glad_glMultiTexCoord2sv;
+GLAD_API_CALL PFNGLMULTITEXCOORD2SVPROC glad_debug_glMultiTexCoord2sv;
+#define glMultiTexCoord2sv glad_debug_glMultiTexCoord2sv
GLAD_API_CALL PFNGLMULTITEXCOORD2SVARBPROC glad_glMultiTexCoord2svARB;
GLAD_API_CALL PFNGLMULTITEXCOORD2SVARBPROC glad_debug_glMultiTexCoord2svARB;
#define glMultiTexCoord2svARB glad_debug_glMultiTexCoord2svARB
-GLAD_API_CALL PFNGLMULTITEXCOORD2XOESPROC glad_glMultiTexCoord2xOES;
-GLAD_API_CALL PFNGLMULTITEXCOORD2XOESPROC glad_debug_glMultiTexCoord2xOES;
-#define glMultiTexCoord2xOES glad_debug_glMultiTexCoord2xOES
-GLAD_API_CALL PFNGLMULTITEXCOORD2XVOESPROC glad_glMultiTexCoord2xvOES;
-GLAD_API_CALL PFNGLMULTITEXCOORD2XVOESPROC glad_debug_glMultiTexCoord2xvOES;
-#define glMultiTexCoord2xvOES glad_debug_glMultiTexCoord2xvOES
+GLAD_API_CALL PFNGLMULTITEXCOORD3DPROC glad_glMultiTexCoord3d;
+GLAD_API_CALL PFNGLMULTITEXCOORD3DPROC glad_debug_glMultiTexCoord3d;
+#define glMultiTexCoord3d glad_debug_glMultiTexCoord3d
GLAD_API_CALL PFNGLMULTITEXCOORD3DARBPROC glad_glMultiTexCoord3dARB;
GLAD_API_CALL PFNGLMULTITEXCOORD3DARBPROC glad_debug_glMultiTexCoord3dARB;
#define glMultiTexCoord3dARB glad_debug_glMultiTexCoord3dARB
+GLAD_API_CALL PFNGLMULTITEXCOORD3DVPROC glad_glMultiTexCoord3dv;
+GLAD_API_CALL PFNGLMULTITEXCOORD3DVPROC glad_debug_glMultiTexCoord3dv;
+#define glMultiTexCoord3dv glad_debug_glMultiTexCoord3dv
GLAD_API_CALL PFNGLMULTITEXCOORD3DVARBPROC glad_glMultiTexCoord3dvARB;
GLAD_API_CALL PFNGLMULTITEXCOORD3DVARBPROC glad_debug_glMultiTexCoord3dvARB;
#define glMultiTexCoord3dvARB glad_debug_glMultiTexCoord3dvARB
+GLAD_API_CALL PFNGLMULTITEXCOORD3FPROC glad_glMultiTexCoord3f;
+GLAD_API_CALL PFNGLMULTITEXCOORD3FPROC glad_debug_glMultiTexCoord3f;
+#define glMultiTexCoord3f glad_debug_glMultiTexCoord3f
GLAD_API_CALL PFNGLMULTITEXCOORD3FARBPROC glad_glMultiTexCoord3fARB;
GLAD_API_CALL PFNGLMULTITEXCOORD3FARBPROC glad_debug_glMultiTexCoord3fARB;
#define glMultiTexCoord3fARB glad_debug_glMultiTexCoord3fARB
+GLAD_API_CALL PFNGLMULTITEXCOORD3FVPROC glad_glMultiTexCoord3fv;
+GLAD_API_CALL PFNGLMULTITEXCOORD3FVPROC glad_debug_glMultiTexCoord3fv;
+#define glMultiTexCoord3fv glad_debug_glMultiTexCoord3fv
GLAD_API_CALL PFNGLMULTITEXCOORD3FVARBPROC glad_glMultiTexCoord3fvARB;
GLAD_API_CALL PFNGLMULTITEXCOORD3FVARBPROC glad_debug_glMultiTexCoord3fvARB;
#define glMultiTexCoord3fvARB glad_debug_glMultiTexCoord3fvARB
+GLAD_API_CALL PFNGLMULTITEXCOORD3IPROC glad_glMultiTexCoord3i;
+GLAD_API_CALL PFNGLMULTITEXCOORD3IPROC glad_debug_glMultiTexCoord3i;
+#define glMultiTexCoord3i glad_debug_glMultiTexCoord3i
GLAD_API_CALL PFNGLMULTITEXCOORD3IARBPROC glad_glMultiTexCoord3iARB;
GLAD_API_CALL PFNGLMULTITEXCOORD3IARBPROC glad_debug_glMultiTexCoord3iARB;
#define glMultiTexCoord3iARB glad_debug_glMultiTexCoord3iARB
+GLAD_API_CALL PFNGLMULTITEXCOORD3IVPROC glad_glMultiTexCoord3iv;
+GLAD_API_CALL PFNGLMULTITEXCOORD3IVPROC glad_debug_glMultiTexCoord3iv;
+#define glMultiTexCoord3iv glad_debug_glMultiTexCoord3iv
GLAD_API_CALL PFNGLMULTITEXCOORD3IVARBPROC glad_glMultiTexCoord3ivARB;
GLAD_API_CALL PFNGLMULTITEXCOORD3IVARBPROC glad_debug_glMultiTexCoord3ivARB;
#define glMultiTexCoord3ivARB glad_debug_glMultiTexCoord3ivARB
+GLAD_API_CALL PFNGLMULTITEXCOORD3SPROC glad_glMultiTexCoord3s;
+GLAD_API_CALL PFNGLMULTITEXCOORD3SPROC glad_debug_glMultiTexCoord3s;
+#define glMultiTexCoord3s glad_debug_glMultiTexCoord3s
GLAD_API_CALL PFNGLMULTITEXCOORD3SARBPROC glad_glMultiTexCoord3sARB;
GLAD_API_CALL PFNGLMULTITEXCOORD3SARBPROC glad_debug_glMultiTexCoord3sARB;
#define glMultiTexCoord3sARB glad_debug_glMultiTexCoord3sARB
+GLAD_API_CALL PFNGLMULTITEXCOORD3SVPROC glad_glMultiTexCoord3sv;
+GLAD_API_CALL PFNGLMULTITEXCOORD3SVPROC glad_debug_glMultiTexCoord3sv;
+#define glMultiTexCoord3sv glad_debug_glMultiTexCoord3sv
GLAD_API_CALL PFNGLMULTITEXCOORD3SVARBPROC glad_glMultiTexCoord3svARB;
GLAD_API_CALL PFNGLMULTITEXCOORD3SVARBPROC glad_debug_glMultiTexCoord3svARB;
#define glMultiTexCoord3svARB glad_debug_glMultiTexCoord3svARB
-GLAD_API_CALL PFNGLMULTITEXCOORD3XOESPROC glad_glMultiTexCoord3xOES;
-GLAD_API_CALL PFNGLMULTITEXCOORD3XOESPROC glad_debug_glMultiTexCoord3xOES;
-#define glMultiTexCoord3xOES glad_debug_glMultiTexCoord3xOES
-GLAD_API_CALL PFNGLMULTITEXCOORD3XVOESPROC glad_glMultiTexCoord3xvOES;
-GLAD_API_CALL PFNGLMULTITEXCOORD3XVOESPROC glad_debug_glMultiTexCoord3xvOES;
-#define glMultiTexCoord3xvOES glad_debug_glMultiTexCoord3xvOES
+GLAD_API_CALL PFNGLMULTITEXCOORD4DPROC glad_glMultiTexCoord4d;
+GLAD_API_CALL PFNGLMULTITEXCOORD4DPROC glad_debug_glMultiTexCoord4d;
+#define glMultiTexCoord4d glad_debug_glMultiTexCoord4d
GLAD_API_CALL PFNGLMULTITEXCOORD4DARBPROC glad_glMultiTexCoord4dARB;
GLAD_API_CALL PFNGLMULTITEXCOORD4DARBPROC glad_debug_glMultiTexCoord4dARB;
#define glMultiTexCoord4dARB glad_debug_glMultiTexCoord4dARB
+GLAD_API_CALL PFNGLMULTITEXCOORD4DVPROC glad_glMultiTexCoord4dv;
+GLAD_API_CALL PFNGLMULTITEXCOORD4DVPROC glad_debug_glMultiTexCoord4dv;
+#define glMultiTexCoord4dv glad_debug_glMultiTexCoord4dv
GLAD_API_CALL PFNGLMULTITEXCOORD4DVARBPROC glad_glMultiTexCoord4dvARB;
GLAD_API_CALL PFNGLMULTITEXCOORD4DVARBPROC glad_debug_glMultiTexCoord4dvARB;
#define glMultiTexCoord4dvARB glad_debug_glMultiTexCoord4dvARB
+GLAD_API_CALL PFNGLMULTITEXCOORD4FPROC glad_glMultiTexCoord4f;
+GLAD_API_CALL PFNGLMULTITEXCOORD4FPROC glad_debug_glMultiTexCoord4f;
+#define glMultiTexCoord4f glad_debug_glMultiTexCoord4f
GLAD_API_CALL PFNGLMULTITEXCOORD4FARBPROC glad_glMultiTexCoord4fARB;
GLAD_API_CALL PFNGLMULTITEXCOORD4FARBPROC glad_debug_glMultiTexCoord4fARB;
#define glMultiTexCoord4fARB glad_debug_glMultiTexCoord4fARB
+GLAD_API_CALL PFNGLMULTITEXCOORD4FVPROC glad_glMultiTexCoord4fv;
+GLAD_API_CALL PFNGLMULTITEXCOORD4FVPROC glad_debug_glMultiTexCoord4fv;
+#define glMultiTexCoord4fv glad_debug_glMultiTexCoord4fv
GLAD_API_CALL PFNGLMULTITEXCOORD4FVARBPROC glad_glMultiTexCoord4fvARB;
GLAD_API_CALL PFNGLMULTITEXCOORD4FVARBPROC glad_debug_glMultiTexCoord4fvARB;
#define glMultiTexCoord4fvARB glad_debug_glMultiTexCoord4fvARB
+GLAD_API_CALL PFNGLMULTITEXCOORD4IPROC glad_glMultiTexCoord4i;
+GLAD_API_CALL PFNGLMULTITEXCOORD4IPROC glad_debug_glMultiTexCoord4i;
+#define glMultiTexCoord4i glad_debug_glMultiTexCoord4i
GLAD_API_CALL PFNGLMULTITEXCOORD4IARBPROC glad_glMultiTexCoord4iARB;
GLAD_API_CALL PFNGLMULTITEXCOORD4IARBPROC glad_debug_glMultiTexCoord4iARB;
#define glMultiTexCoord4iARB glad_debug_glMultiTexCoord4iARB
+GLAD_API_CALL PFNGLMULTITEXCOORD4IVPROC glad_glMultiTexCoord4iv;
+GLAD_API_CALL PFNGLMULTITEXCOORD4IVPROC glad_debug_glMultiTexCoord4iv;
+#define glMultiTexCoord4iv glad_debug_glMultiTexCoord4iv
GLAD_API_CALL PFNGLMULTITEXCOORD4IVARBPROC glad_glMultiTexCoord4ivARB;
GLAD_API_CALL PFNGLMULTITEXCOORD4IVARBPROC glad_debug_glMultiTexCoord4ivARB;
#define glMultiTexCoord4ivARB glad_debug_glMultiTexCoord4ivARB
+GLAD_API_CALL PFNGLMULTITEXCOORD4SPROC glad_glMultiTexCoord4s;
+GLAD_API_CALL PFNGLMULTITEXCOORD4SPROC glad_debug_glMultiTexCoord4s;
+#define glMultiTexCoord4s glad_debug_glMultiTexCoord4s
GLAD_API_CALL PFNGLMULTITEXCOORD4SARBPROC glad_glMultiTexCoord4sARB;
GLAD_API_CALL PFNGLMULTITEXCOORD4SARBPROC glad_debug_glMultiTexCoord4sARB;
#define glMultiTexCoord4sARB glad_debug_glMultiTexCoord4sARB
+GLAD_API_CALL PFNGLMULTITEXCOORD4SVPROC glad_glMultiTexCoord4sv;
+GLAD_API_CALL PFNGLMULTITEXCOORD4SVPROC glad_debug_glMultiTexCoord4sv;
+#define glMultiTexCoord4sv glad_debug_glMultiTexCoord4sv
GLAD_API_CALL PFNGLMULTITEXCOORD4SVARBPROC glad_glMultiTexCoord4svARB;
GLAD_API_CALL PFNGLMULTITEXCOORD4SVARBPROC glad_debug_glMultiTexCoord4svARB;
#define glMultiTexCoord4svARB glad_debug_glMultiTexCoord4svARB
-GLAD_API_CALL PFNGLMULTITEXCOORD4XOESPROC glad_glMultiTexCoord4xOES;
-GLAD_API_CALL PFNGLMULTITEXCOORD4XOESPROC glad_debug_glMultiTexCoord4xOES;
-#define glMultiTexCoord4xOES glad_debug_glMultiTexCoord4xOES
-GLAD_API_CALL PFNGLMULTITEXCOORD4XVOESPROC glad_glMultiTexCoord4xvOES;
-GLAD_API_CALL PFNGLMULTITEXCOORD4XVOESPROC glad_debug_glMultiTexCoord4xvOES;
-#define glMultiTexCoord4xvOES glad_debug_glMultiTexCoord4xvOES
+GLAD_API_CALL PFNGLMULTITEXCOORDP1UIPROC glad_glMultiTexCoordP1ui;
+GLAD_API_CALL PFNGLMULTITEXCOORDP1UIPROC glad_debug_glMultiTexCoordP1ui;
+#define glMultiTexCoordP1ui glad_debug_glMultiTexCoordP1ui
+GLAD_API_CALL PFNGLMULTITEXCOORDP1UIVPROC glad_glMultiTexCoordP1uiv;
+GLAD_API_CALL PFNGLMULTITEXCOORDP1UIVPROC glad_debug_glMultiTexCoordP1uiv;
+#define glMultiTexCoordP1uiv glad_debug_glMultiTexCoordP1uiv
+GLAD_API_CALL PFNGLMULTITEXCOORDP2UIPROC glad_glMultiTexCoordP2ui;
+GLAD_API_CALL PFNGLMULTITEXCOORDP2UIPROC glad_debug_glMultiTexCoordP2ui;
+#define glMultiTexCoordP2ui glad_debug_glMultiTexCoordP2ui
+GLAD_API_CALL PFNGLMULTITEXCOORDP2UIVPROC glad_glMultiTexCoordP2uiv;
+GLAD_API_CALL PFNGLMULTITEXCOORDP2UIVPROC glad_debug_glMultiTexCoordP2uiv;
+#define glMultiTexCoordP2uiv glad_debug_glMultiTexCoordP2uiv
+GLAD_API_CALL PFNGLMULTITEXCOORDP3UIPROC glad_glMultiTexCoordP3ui;
+GLAD_API_CALL PFNGLMULTITEXCOORDP3UIPROC glad_debug_glMultiTexCoordP3ui;
+#define glMultiTexCoordP3ui glad_debug_glMultiTexCoordP3ui
+GLAD_API_CALL PFNGLMULTITEXCOORDP3UIVPROC glad_glMultiTexCoordP3uiv;
+GLAD_API_CALL PFNGLMULTITEXCOORDP3UIVPROC glad_debug_glMultiTexCoordP3uiv;
+#define glMultiTexCoordP3uiv glad_debug_glMultiTexCoordP3uiv
+GLAD_API_CALL PFNGLMULTITEXCOORDP4UIPROC glad_glMultiTexCoordP4ui;
+GLAD_API_CALL PFNGLMULTITEXCOORDP4UIPROC glad_debug_glMultiTexCoordP4ui;
+#define glMultiTexCoordP4ui glad_debug_glMultiTexCoordP4ui
+GLAD_API_CALL PFNGLMULTITEXCOORDP4UIVPROC glad_glMultiTexCoordP4uiv;
+GLAD_API_CALL PFNGLMULTITEXCOORDP4UIVPROC glad_debug_glMultiTexCoordP4uiv;
+#define glMultiTexCoordP4uiv glad_debug_glMultiTexCoordP4uiv
GLAD_API_CALL PFNGLNAMEDBUFFERDATAPROC glad_glNamedBufferData;
GLAD_API_CALL PFNGLNAMEDBUFFERDATAPROC glad_debug_glNamedBufferData;
#define glNamedBufferData glad_debug_glNamedBufferData
@@ -5073,24 +6167,60 @@ GLAD_API_CALL PFNGLNAMEDRENDERBUFFERSTORAGEMULTISAMPLEPROC glad_debug_glNamedRen
GLAD_API_CALL PFNGLNAMEDSTRINGARBPROC glad_glNamedStringARB;
GLAD_API_CALL PFNGLNAMEDSTRINGARBPROC glad_debug_glNamedStringARB;
#define glNamedStringARB glad_debug_glNamedStringARB
-GLAD_API_CALL PFNGLNORMAL3XOESPROC glad_glNormal3xOES;
-GLAD_API_CALL PFNGLNORMAL3XOESPROC glad_debug_glNormal3xOES;
-#define glNormal3xOES glad_debug_glNormal3xOES
-GLAD_API_CALL PFNGLNORMAL3XVOESPROC glad_glNormal3xvOES;
-GLAD_API_CALL PFNGLNORMAL3XVOESPROC glad_debug_glNormal3xvOES;
-#define glNormal3xvOES glad_debug_glNormal3xvOES
+GLAD_API_CALL PFNGLNEWLISTPROC glad_glNewList;
+GLAD_API_CALL PFNGLNEWLISTPROC glad_debug_glNewList;
+#define glNewList glad_debug_glNewList
+GLAD_API_CALL PFNGLNORMAL3BPROC glad_glNormal3b;
+GLAD_API_CALL PFNGLNORMAL3BPROC glad_debug_glNormal3b;
+#define glNormal3b glad_debug_glNormal3b
+GLAD_API_CALL PFNGLNORMAL3BVPROC glad_glNormal3bv;
+GLAD_API_CALL PFNGLNORMAL3BVPROC glad_debug_glNormal3bv;
+#define glNormal3bv glad_debug_glNormal3bv
+GLAD_API_CALL PFNGLNORMAL3DPROC glad_glNormal3d;
+GLAD_API_CALL PFNGLNORMAL3DPROC glad_debug_glNormal3d;
+#define glNormal3d glad_debug_glNormal3d
+GLAD_API_CALL PFNGLNORMAL3DVPROC glad_glNormal3dv;
+GLAD_API_CALL PFNGLNORMAL3DVPROC glad_debug_glNormal3dv;
+#define glNormal3dv glad_debug_glNormal3dv
+GLAD_API_CALL PFNGLNORMAL3FPROC glad_glNormal3f;
+GLAD_API_CALL PFNGLNORMAL3FPROC glad_debug_glNormal3f;
+#define glNormal3f glad_debug_glNormal3f
+GLAD_API_CALL PFNGLNORMAL3FVPROC glad_glNormal3fv;
+GLAD_API_CALL PFNGLNORMAL3FVPROC glad_debug_glNormal3fv;
+#define glNormal3fv glad_debug_glNormal3fv
+GLAD_API_CALL PFNGLNORMAL3IPROC glad_glNormal3i;
+GLAD_API_CALL PFNGLNORMAL3IPROC glad_debug_glNormal3i;
+#define glNormal3i glad_debug_glNormal3i
+GLAD_API_CALL PFNGLNORMAL3IVPROC glad_glNormal3iv;
+GLAD_API_CALL PFNGLNORMAL3IVPROC glad_debug_glNormal3iv;
+#define glNormal3iv glad_debug_glNormal3iv
+GLAD_API_CALL PFNGLNORMAL3SPROC glad_glNormal3s;
+GLAD_API_CALL PFNGLNORMAL3SPROC glad_debug_glNormal3s;
+#define glNormal3s glad_debug_glNormal3s
+GLAD_API_CALL PFNGLNORMAL3SVPROC glad_glNormal3sv;
+GLAD_API_CALL PFNGLNORMAL3SVPROC glad_debug_glNormal3sv;
+#define glNormal3sv glad_debug_glNormal3sv
+GLAD_API_CALL PFNGLNORMALP3UIPROC glad_glNormalP3ui;
+GLAD_API_CALL PFNGLNORMALP3UIPROC glad_debug_glNormalP3ui;
+#define glNormalP3ui glad_debug_glNormalP3ui
+GLAD_API_CALL PFNGLNORMALP3UIVPROC glad_glNormalP3uiv;
+GLAD_API_CALL PFNGLNORMALP3UIVPROC glad_debug_glNormalP3uiv;
+#define glNormalP3uiv glad_debug_glNormalP3uiv
+GLAD_API_CALL PFNGLNORMALPOINTERPROC glad_glNormalPointer;
+GLAD_API_CALL PFNGLNORMALPOINTERPROC glad_debug_glNormalPointer;
+#define glNormalPointer glad_debug_glNormalPointer
GLAD_API_CALL PFNGLOBJECTLABELPROC glad_glObjectLabel;
GLAD_API_CALL PFNGLOBJECTLABELPROC glad_debug_glObjectLabel;
#define glObjectLabel glad_debug_glObjectLabel
GLAD_API_CALL PFNGLOBJECTPTRLABELPROC glad_glObjectPtrLabel;
GLAD_API_CALL PFNGLOBJECTPTRLABELPROC glad_debug_glObjectPtrLabel;
#define glObjectPtrLabel glad_debug_glObjectPtrLabel
-GLAD_API_CALL PFNGLORTHOXOESPROC glad_glOrthoxOES;
-GLAD_API_CALL PFNGLORTHOXOESPROC glad_debug_glOrthoxOES;
-#define glOrthoxOES glad_debug_glOrthoxOES
-GLAD_API_CALL PFNGLPASSTHROUGHXOESPROC glad_glPassThroughxOES;
-GLAD_API_CALL PFNGLPASSTHROUGHXOESPROC glad_debug_glPassThroughxOES;
-#define glPassThroughxOES glad_debug_glPassThroughxOES
+GLAD_API_CALL PFNGLORTHOPROC glad_glOrtho;
+GLAD_API_CALL PFNGLORTHOPROC glad_debug_glOrtho;
+#define glOrtho glad_debug_glOrtho
+GLAD_API_CALL PFNGLPASSTHROUGHPROC glad_glPassThrough;
+GLAD_API_CALL PFNGLPASSTHROUGHPROC glad_debug_glPassThrough;
+#define glPassThrough glad_debug_glPassThrough
GLAD_API_CALL PFNGLPATCHPARAMETERFVPROC glad_glPatchParameterfv;
GLAD_API_CALL PFNGLPATCHPARAMETERFVPROC glad_debug_glPatchParameterfv;
#define glPatchParameterfv glad_debug_glPatchParameterfv
@@ -5100,24 +6230,30 @@ GLAD_API_CALL PFNGLPATCHPARAMETERIPROC glad_debug_glPatchParameteri;
GLAD_API_CALL PFNGLPAUSETRANSFORMFEEDBACKPROC glad_glPauseTransformFeedback;
GLAD_API_CALL PFNGLPAUSETRANSFORMFEEDBACKPROC glad_debug_glPauseTransformFeedback;
#define glPauseTransformFeedback glad_debug_glPauseTransformFeedback
-GLAD_API_CALL PFNGLPIXELMAPXPROC glad_glPixelMapx;
-GLAD_API_CALL PFNGLPIXELMAPXPROC glad_debug_glPixelMapx;
-#define glPixelMapx glad_debug_glPixelMapx
+GLAD_API_CALL PFNGLPIXELMAPFVPROC glad_glPixelMapfv;
+GLAD_API_CALL PFNGLPIXELMAPFVPROC glad_debug_glPixelMapfv;
+#define glPixelMapfv glad_debug_glPixelMapfv
+GLAD_API_CALL PFNGLPIXELMAPUIVPROC glad_glPixelMapuiv;
+GLAD_API_CALL PFNGLPIXELMAPUIVPROC glad_debug_glPixelMapuiv;
+#define glPixelMapuiv glad_debug_glPixelMapuiv
+GLAD_API_CALL PFNGLPIXELMAPUSVPROC glad_glPixelMapusv;
+GLAD_API_CALL PFNGLPIXELMAPUSVPROC glad_debug_glPixelMapusv;
+#define glPixelMapusv glad_debug_glPixelMapusv
GLAD_API_CALL PFNGLPIXELSTOREFPROC glad_glPixelStoref;
GLAD_API_CALL PFNGLPIXELSTOREFPROC glad_debug_glPixelStoref;
#define glPixelStoref glad_debug_glPixelStoref
GLAD_API_CALL PFNGLPIXELSTOREIPROC glad_glPixelStorei;
GLAD_API_CALL PFNGLPIXELSTOREIPROC glad_debug_glPixelStorei;
#define glPixelStorei glad_debug_glPixelStorei
-GLAD_API_CALL PFNGLPIXELSTOREXPROC glad_glPixelStorex;
-GLAD_API_CALL PFNGLPIXELSTOREXPROC glad_debug_glPixelStorex;
-#define glPixelStorex glad_debug_glPixelStorex
-GLAD_API_CALL PFNGLPIXELTRANSFERXOESPROC glad_glPixelTransferxOES;
-GLAD_API_CALL PFNGLPIXELTRANSFERXOESPROC glad_debug_glPixelTransferxOES;
-#define glPixelTransferxOES glad_debug_glPixelTransferxOES
-GLAD_API_CALL PFNGLPIXELZOOMXOESPROC glad_glPixelZoomxOES;
-GLAD_API_CALL PFNGLPIXELZOOMXOESPROC glad_debug_glPixelZoomxOES;
-#define glPixelZoomxOES glad_debug_glPixelZoomxOES
+GLAD_API_CALL PFNGLPIXELTRANSFERFPROC glad_glPixelTransferf;
+GLAD_API_CALL PFNGLPIXELTRANSFERFPROC glad_debug_glPixelTransferf;
+#define glPixelTransferf glad_debug_glPixelTransferf
+GLAD_API_CALL PFNGLPIXELTRANSFERIPROC glad_glPixelTransferi;
+GLAD_API_CALL PFNGLPIXELTRANSFERIPROC glad_debug_glPixelTransferi;
+#define glPixelTransferi glad_debug_glPixelTransferi
+GLAD_API_CALL PFNGLPIXELZOOMPROC glad_glPixelZoom;
+GLAD_API_CALL PFNGLPIXELZOOMPROC glad_debug_glPixelZoom;
+#define glPixelZoom glad_debug_glPixelZoom
GLAD_API_CALL PFNGLPOINTPARAMETERFPROC glad_glPointParameterf;
GLAD_API_CALL PFNGLPOINTPARAMETERFPROC glad_debug_glPointParameterf;
#define glPointParameterf glad_debug_glPointParameterf
@@ -5130,36 +6266,42 @@ GLAD_API_CALL PFNGLPOINTPARAMETERIPROC glad_debug_glPointParameteri;
GLAD_API_CALL PFNGLPOINTPARAMETERIVPROC glad_glPointParameteriv;
GLAD_API_CALL PFNGLPOINTPARAMETERIVPROC glad_debug_glPointParameteriv;
#define glPointParameteriv glad_debug_glPointParameteriv
-GLAD_API_CALL PFNGLPOINTPARAMETERXVOESPROC glad_glPointParameterxvOES;
-GLAD_API_CALL PFNGLPOINTPARAMETERXVOESPROC glad_debug_glPointParameterxvOES;
-#define glPointParameterxvOES glad_debug_glPointParameterxvOES
GLAD_API_CALL PFNGLPOINTSIZEPROC glad_glPointSize;
GLAD_API_CALL PFNGLPOINTSIZEPROC glad_debug_glPointSize;
#define glPointSize glad_debug_glPointSize
-GLAD_API_CALL PFNGLPOINTSIZEXOESPROC glad_glPointSizexOES;
-GLAD_API_CALL PFNGLPOINTSIZEXOESPROC glad_debug_glPointSizexOES;
-#define glPointSizexOES glad_debug_glPointSizexOES
GLAD_API_CALL PFNGLPOLYGONMODEPROC glad_glPolygonMode;
GLAD_API_CALL PFNGLPOLYGONMODEPROC glad_debug_glPolygonMode;
#define glPolygonMode glad_debug_glPolygonMode
GLAD_API_CALL PFNGLPOLYGONOFFSETPROC glad_glPolygonOffset;
GLAD_API_CALL PFNGLPOLYGONOFFSETPROC glad_debug_glPolygonOffset;
#define glPolygonOffset glad_debug_glPolygonOffset
-GLAD_API_CALL PFNGLPOLYGONOFFSETXOESPROC glad_glPolygonOffsetxOES;
-GLAD_API_CALL PFNGLPOLYGONOFFSETXOESPROC glad_debug_glPolygonOffsetxOES;
-#define glPolygonOffsetxOES glad_debug_glPolygonOffsetxOES
+GLAD_API_CALL PFNGLPOLYGONSTIPPLEPROC glad_glPolygonStipple;
+GLAD_API_CALL PFNGLPOLYGONSTIPPLEPROC glad_debug_glPolygonStipple;
+#define glPolygonStipple glad_debug_glPolygonStipple
+GLAD_API_CALL PFNGLPOPATTRIBPROC glad_glPopAttrib;
+GLAD_API_CALL PFNGLPOPATTRIBPROC glad_debug_glPopAttrib;
+#define glPopAttrib glad_debug_glPopAttrib
+GLAD_API_CALL PFNGLPOPCLIENTATTRIBPROC glad_glPopClientAttrib;
+GLAD_API_CALL PFNGLPOPCLIENTATTRIBPROC glad_debug_glPopClientAttrib;
+#define glPopClientAttrib glad_debug_glPopClientAttrib
GLAD_API_CALL PFNGLPOPDEBUGGROUPPROC glad_glPopDebugGroup;
GLAD_API_CALL PFNGLPOPDEBUGGROUPPROC glad_debug_glPopDebugGroup;
#define glPopDebugGroup glad_debug_glPopDebugGroup
+GLAD_API_CALL PFNGLPOPMATRIXPROC glad_glPopMatrix;
+GLAD_API_CALL PFNGLPOPMATRIXPROC glad_debug_glPopMatrix;
+#define glPopMatrix glad_debug_glPopMatrix
+GLAD_API_CALL PFNGLPOPNAMEPROC glad_glPopName;
+GLAD_API_CALL PFNGLPOPNAMEPROC glad_debug_glPopName;
+#define glPopName glad_debug_glPopName
GLAD_API_CALL PFNGLPRIMITIVEBOUNDINGBOXARBPROC glad_glPrimitiveBoundingBoxARB;
GLAD_API_CALL PFNGLPRIMITIVEBOUNDINGBOXARBPROC glad_debug_glPrimitiveBoundingBoxARB;
#define glPrimitiveBoundingBoxARB glad_debug_glPrimitiveBoundingBoxARB
GLAD_API_CALL PFNGLPRIMITIVERESTARTINDEXPROC glad_glPrimitiveRestartIndex;
GLAD_API_CALL PFNGLPRIMITIVERESTARTINDEXPROC glad_debug_glPrimitiveRestartIndex;
#define glPrimitiveRestartIndex glad_debug_glPrimitiveRestartIndex
-GLAD_API_CALL PFNGLPRIORITIZETEXTURESXOESPROC glad_glPrioritizeTexturesxOES;
-GLAD_API_CALL PFNGLPRIORITIZETEXTURESXOESPROC glad_debug_glPrioritizeTexturesxOES;
-#define glPrioritizeTexturesxOES glad_debug_glPrioritizeTexturesxOES
+GLAD_API_CALL PFNGLPRIORITIZETEXTURESPROC glad_glPrioritizeTextures;
+GLAD_API_CALL PFNGLPRIORITIZETEXTURESPROC glad_debug_glPrioritizeTextures;
+#define glPrioritizeTextures glad_debug_glPrioritizeTextures
GLAD_API_CALL PFNGLPROGRAMBINARYPROC glad_glProgramBinary;
GLAD_API_CALL PFNGLPROGRAMBINARYPROC glad_debug_glProgramBinary;
#define glProgramBinary glad_debug_glProgramBinary
@@ -5397,45 +6539,132 @@ GLAD_API_CALL PFNGLPROGRAMUNIFORMMATRIX4X3FVPROC glad_debug_glProgramUniformMatr
GLAD_API_CALL PFNGLPROVOKINGVERTEXPROC glad_glProvokingVertex;
GLAD_API_CALL PFNGLPROVOKINGVERTEXPROC glad_debug_glProvokingVertex;
#define glProvokingVertex glad_debug_glProvokingVertex
+GLAD_API_CALL PFNGLPUSHATTRIBPROC glad_glPushAttrib;
+GLAD_API_CALL PFNGLPUSHATTRIBPROC glad_debug_glPushAttrib;
+#define glPushAttrib glad_debug_glPushAttrib
+GLAD_API_CALL PFNGLPUSHCLIENTATTRIBPROC glad_glPushClientAttrib;
+GLAD_API_CALL PFNGLPUSHCLIENTATTRIBPROC glad_debug_glPushClientAttrib;
+#define glPushClientAttrib glad_debug_glPushClientAttrib
GLAD_API_CALL PFNGLPUSHDEBUGGROUPPROC glad_glPushDebugGroup;
GLAD_API_CALL PFNGLPUSHDEBUGGROUPPROC glad_debug_glPushDebugGroup;
#define glPushDebugGroup glad_debug_glPushDebugGroup
+GLAD_API_CALL PFNGLPUSHMATRIXPROC glad_glPushMatrix;
+GLAD_API_CALL PFNGLPUSHMATRIXPROC glad_debug_glPushMatrix;
+#define glPushMatrix glad_debug_glPushMatrix
+GLAD_API_CALL PFNGLPUSHNAMEPROC glad_glPushName;
+GLAD_API_CALL PFNGLPUSHNAMEPROC glad_debug_glPushName;
+#define glPushName glad_debug_glPushName
GLAD_API_CALL PFNGLQUERYCOUNTERPROC glad_glQueryCounter;
GLAD_API_CALL PFNGLQUERYCOUNTERPROC glad_debug_glQueryCounter;
#define glQueryCounter glad_debug_glQueryCounter
-GLAD_API_CALL PFNGLRASTERPOS2XOESPROC glad_glRasterPos2xOES;
-GLAD_API_CALL PFNGLRASTERPOS2XOESPROC glad_debug_glRasterPos2xOES;
-#define glRasterPos2xOES glad_debug_glRasterPos2xOES
-GLAD_API_CALL PFNGLRASTERPOS2XVOESPROC glad_glRasterPos2xvOES;
-GLAD_API_CALL PFNGLRASTERPOS2XVOESPROC glad_debug_glRasterPos2xvOES;
-#define glRasterPos2xvOES glad_debug_glRasterPos2xvOES
-GLAD_API_CALL PFNGLRASTERPOS3XOESPROC glad_glRasterPos3xOES;
-GLAD_API_CALL PFNGLRASTERPOS3XOESPROC glad_debug_glRasterPos3xOES;
-#define glRasterPos3xOES glad_debug_glRasterPos3xOES
-GLAD_API_CALL PFNGLRASTERPOS3XVOESPROC glad_glRasterPos3xvOES;
-GLAD_API_CALL PFNGLRASTERPOS3XVOESPROC glad_debug_glRasterPos3xvOES;
-#define glRasterPos3xvOES glad_debug_glRasterPos3xvOES
-GLAD_API_CALL PFNGLRASTERPOS4XOESPROC glad_glRasterPos4xOES;
-GLAD_API_CALL PFNGLRASTERPOS4XOESPROC glad_debug_glRasterPos4xOES;
-#define glRasterPos4xOES glad_debug_glRasterPos4xOES
-GLAD_API_CALL PFNGLRASTERPOS4XVOESPROC glad_glRasterPos4xvOES;
-GLAD_API_CALL PFNGLRASTERPOS4XVOESPROC glad_debug_glRasterPos4xvOES;
-#define glRasterPos4xvOES glad_debug_glRasterPos4xvOES
+GLAD_API_CALL PFNGLRASTERPOS2DPROC glad_glRasterPos2d;
+GLAD_API_CALL PFNGLRASTERPOS2DPROC glad_debug_glRasterPos2d;
+#define glRasterPos2d glad_debug_glRasterPos2d
+GLAD_API_CALL PFNGLRASTERPOS2DVPROC glad_glRasterPos2dv;
+GLAD_API_CALL PFNGLRASTERPOS2DVPROC glad_debug_glRasterPos2dv;
+#define glRasterPos2dv glad_debug_glRasterPos2dv
+GLAD_API_CALL PFNGLRASTERPOS2FPROC glad_glRasterPos2f;
+GLAD_API_CALL PFNGLRASTERPOS2FPROC glad_debug_glRasterPos2f;
+#define glRasterPos2f glad_debug_glRasterPos2f
+GLAD_API_CALL PFNGLRASTERPOS2FVPROC glad_glRasterPos2fv;
+GLAD_API_CALL PFNGLRASTERPOS2FVPROC glad_debug_glRasterPos2fv;
+#define glRasterPos2fv glad_debug_glRasterPos2fv
+GLAD_API_CALL PFNGLRASTERPOS2IPROC glad_glRasterPos2i;
+GLAD_API_CALL PFNGLRASTERPOS2IPROC glad_debug_glRasterPos2i;
+#define glRasterPos2i glad_debug_glRasterPos2i
+GLAD_API_CALL PFNGLRASTERPOS2IVPROC glad_glRasterPos2iv;
+GLAD_API_CALL PFNGLRASTERPOS2IVPROC glad_debug_glRasterPos2iv;
+#define glRasterPos2iv glad_debug_glRasterPos2iv
+GLAD_API_CALL PFNGLRASTERPOS2SPROC glad_glRasterPos2s;
+GLAD_API_CALL PFNGLRASTERPOS2SPROC glad_debug_glRasterPos2s;
+#define glRasterPos2s glad_debug_glRasterPos2s
+GLAD_API_CALL PFNGLRASTERPOS2SVPROC glad_glRasterPos2sv;
+GLAD_API_CALL PFNGLRASTERPOS2SVPROC glad_debug_glRasterPos2sv;
+#define glRasterPos2sv glad_debug_glRasterPos2sv
+GLAD_API_CALL PFNGLRASTERPOS3DPROC glad_glRasterPos3d;
+GLAD_API_CALL PFNGLRASTERPOS3DPROC glad_debug_glRasterPos3d;
+#define glRasterPos3d glad_debug_glRasterPos3d
+GLAD_API_CALL PFNGLRASTERPOS3DVPROC glad_glRasterPos3dv;
+GLAD_API_CALL PFNGLRASTERPOS3DVPROC glad_debug_glRasterPos3dv;
+#define glRasterPos3dv glad_debug_glRasterPos3dv
+GLAD_API_CALL PFNGLRASTERPOS3FPROC glad_glRasterPos3f;
+GLAD_API_CALL PFNGLRASTERPOS3FPROC glad_debug_glRasterPos3f;
+#define glRasterPos3f glad_debug_glRasterPos3f
+GLAD_API_CALL PFNGLRASTERPOS3FVPROC glad_glRasterPos3fv;
+GLAD_API_CALL PFNGLRASTERPOS3FVPROC glad_debug_glRasterPos3fv;
+#define glRasterPos3fv glad_debug_glRasterPos3fv
+GLAD_API_CALL PFNGLRASTERPOS3IPROC glad_glRasterPos3i;
+GLAD_API_CALL PFNGLRASTERPOS3IPROC glad_debug_glRasterPos3i;
+#define glRasterPos3i glad_debug_glRasterPos3i
+GLAD_API_CALL PFNGLRASTERPOS3IVPROC glad_glRasterPos3iv;
+GLAD_API_CALL PFNGLRASTERPOS3IVPROC glad_debug_glRasterPos3iv;
+#define glRasterPos3iv glad_debug_glRasterPos3iv
+GLAD_API_CALL PFNGLRASTERPOS3SPROC glad_glRasterPos3s;
+GLAD_API_CALL PFNGLRASTERPOS3SPROC glad_debug_glRasterPos3s;
+#define glRasterPos3s glad_debug_glRasterPos3s
+GLAD_API_CALL PFNGLRASTERPOS3SVPROC glad_glRasterPos3sv;
+GLAD_API_CALL PFNGLRASTERPOS3SVPROC glad_debug_glRasterPos3sv;
+#define glRasterPos3sv glad_debug_glRasterPos3sv
+GLAD_API_CALL PFNGLRASTERPOS4DPROC glad_glRasterPos4d;
+GLAD_API_CALL PFNGLRASTERPOS4DPROC glad_debug_glRasterPos4d;
+#define glRasterPos4d glad_debug_glRasterPos4d
+GLAD_API_CALL PFNGLRASTERPOS4DVPROC glad_glRasterPos4dv;
+GLAD_API_CALL PFNGLRASTERPOS4DVPROC glad_debug_glRasterPos4dv;
+#define glRasterPos4dv glad_debug_glRasterPos4dv
+GLAD_API_CALL PFNGLRASTERPOS4FPROC glad_glRasterPos4f;
+GLAD_API_CALL PFNGLRASTERPOS4FPROC glad_debug_glRasterPos4f;
+#define glRasterPos4f glad_debug_glRasterPos4f
+GLAD_API_CALL PFNGLRASTERPOS4FVPROC glad_glRasterPos4fv;
+GLAD_API_CALL PFNGLRASTERPOS4FVPROC glad_debug_glRasterPos4fv;
+#define glRasterPos4fv glad_debug_glRasterPos4fv
+GLAD_API_CALL PFNGLRASTERPOS4IPROC glad_glRasterPos4i;
+GLAD_API_CALL PFNGLRASTERPOS4IPROC glad_debug_glRasterPos4i;
+#define glRasterPos4i glad_debug_glRasterPos4i
+GLAD_API_CALL PFNGLRASTERPOS4IVPROC glad_glRasterPos4iv;
+GLAD_API_CALL PFNGLRASTERPOS4IVPROC glad_debug_glRasterPos4iv;
+#define glRasterPos4iv glad_debug_glRasterPos4iv
+GLAD_API_CALL PFNGLRASTERPOS4SPROC glad_glRasterPos4s;
+GLAD_API_CALL PFNGLRASTERPOS4SPROC glad_debug_glRasterPos4s;
+#define glRasterPos4s glad_debug_glRasterPos4s
+GLAD_API_CALL PFNGLRASTERPOS4SVPROC glad_glRasterPos4sv;
+GLAD_API_CALL PFNGLRASTERPOS4SVPROC glad_debug_glRasterPos4sv;
+#define glRasterPos4sv glad_debug_glRasterPos4sv
GLAD_API_CALL PFNGLREADBUFFERPROC glad_glReadBuffer;
GLAD_API_CALL PFNGLREADBUFFERPROC glad_debug_glReadBuffer;
#define glReadBuffer glad_debug_glReadBuffer
GLAD_API_CALL PFNGLREADPIXELSPROC glad_glReadPixels;
GLAD_API_CALL PFNGLREADPIXELSPROC glad_debug_glReadPixels;
#define glReadPixels glad_debug_glReadPixels
-GLAD_API_CALL PFNGLRECTXOESPROC glad_glRectxOES;
-GLAD_API_CALL PFNGLRECTXOESPROC glad_debug_glRectxOES;
-#define glRectxOES glad_debug_glRectxOES
-GLAD_API_CALL PFNGLRECTXVOESPROC glad_glRectxvOES;
-GLAD_API_CALL PFNGLRECTXVOESPROC glad_debug_glRectxvOES;
-#define glRectxvOES glad_debug_glRectxvOES
+GLAD_API_CALL PFNGLRECTDPROC glad_glRectd;
+GLAD_API_CALL PFNGLRECTDPROC glad_debug_glRectd;
+#define glRectd glad_debug_glRectd
+GLAD_API_CALL PFNGLRECTDVPROC glad_glRectdv;
+GLAD_API_CALL PFNGLRECTDVPROC glad_debug_glRectdv;
+#define glRectdv glad_debug_glRectdv
+GLAD_API_CALL PFNGLRECTFPROC glad_glRectf;
+GLAD_API_CALL PFNGLRECTFPROC glad_debug_glRectf;
+#define glRectf glad_debug_glRectf
+GLAD_API_CALL PFNGLRECTFVPROC glad_glRectfv;
+GLAD_API_CALL PFNGLRECTFVPROC glad_debug_glRectfv;
+#define glRectfv glad_debug_glRectfv
+GLAD_API_CALL PFNGLRECTIPROC glad_glRecti;
+GLAD_API_CALL PFNGLRECTIPROC glad_debug_glRecti;
+#define glRecti glad_debug_glRecti
+GLAD_API_CALL PFNGLRECTIVPROC glad_glRectiv;
+GLAD_API_CALL PFNGLRECTIVPROC glad_debug_glRectiv;
+#define glRectiv glad_debug_glRectiv
+GLAD_API_CALL PFNGLRECTSPROC glad_glRects;
+GLAD_API_CALL PFNGLRECTSPROC glad_debug_glRects;
+#define glRects glad_debug_glRects
+GLAD_API_CALL PFNGLRECTSVPROC glad_glRectsv;
+GLAD_API_CALL PFNGLRECTSVPROC glad_debug_glRectsv;
+#define glRectsv glad_debug_glRectsv
GLAD_API_CALL PFNGLRELEASESHADERCOMPILERPROC glad_glReleaseShaderCompiler;
GLAD_API_CALL PFNGLRELEASESHADERCOMPILERPROC glad_debug_glReleaseShaderCompiler;
#define glReleaseShaderCompiler glad_debug_glReleaseShaderCompiler
+GLAD_API_CALL PFNGLRENDERMODEPROC glad_glRenderMode;
+GLAD_API_CALL PFNGLRENDERMODEPROC glad_debug_glRenderMode;
+#define glRenderMode glad_debug_glRenderMode
GLAD_API_CALL PFNGLRENDERBUFFERSTORAGEPROC glad_glRenderbufferStorage;
GLAD_API_CALL PFNGLRENDERBUFFERSTORAGEPROC glad_debug_glRenderbufferStorage;
#define glRenderbufferStorage glad_debug_glRenderbufferStorage
@@ -5451,9 +6680,12 @@ GLAD_API_CALL PFNGLRENDERBUFFERSTORAGEMULTISAMPLEEXTPROC glad_debug_glRenderbuff
GLAD_API_CALL PFNGLRESUMETRANSFORMFEEDBACKPROC glad_glResumeTransformFeedback;
GLAD_API_CALL PFNGLRESUMETRANSFORMFEEDBACKPROC glad_debug_glResumeTransformFeedback;
#define glResumeTransformFeedback glad_debug_glResumeTransformFeedback
-GLAD_API_CALL PFNGLROTATEXOESPROC glad_glRotatexOES;
-GLAD_API_CALL PFNGLROTATEXOESPROC glad_debug_glRotatexOES;
-#define glRotatexOES glad_debug_glRotatexOES
+GLAD_API_CALL PFNGLROTATEDPROC glad_glRotated;
+GLAD_API_CALL PFNGLROTATEDPROC glad_debug_glRotated;
+#define glRotated glad_debug_glRotated
+GLAD_API_CALL PFNGLROTATEFPROC glad_glRotatef;
+GLAD_API_CALL PFNGLROTATEFPROC glad_debug_glRotatef;
+#define glRotatef glad_debug_glRotatef
GLAD_API_CALL PFNGLSAMPLECOVERAGEPROC glad_glSampleCoverage;
GLAD_API_CALL PFNGLSAMPLECOVERAGEPROC glad_debug_glSampleCoverage;
#define glSampleCoverage glad_debug_glSampleCoverage
@@ -5481,9 +6713,12 @@ GLAD_API_CALL PFNGLSAMPLERPARAMETERIPROC glad_debug_glSamplerParameteri;
GLAD_API_CALL PFNGLSAMPLERPARAMETERIVPROC glad_glSamplerParameteriv;
GLAD_API_CALL PFNGLSAMPLERPARAMETERIVPROC glad_debug_glSamplerParameteriv;
#define glSamplerParameteriv glad_debug_glSamplerParameteriv
-GLAD_API_CALL PFNGLSCALEXOESPROC glad_glScalexOES;
-GLAD_API_CALL PFNGLSCALEXOESPROC glad_debug_glScalexOES;
-#define glScalexOES glad_debug_glScalexOES
+GLAD_API_CALL PFNGLSCALEDPROC glad_glScaled;
+GLAD_API_CALL PFNGLSCALEDPROC glad_debug_glScaled;
+#define glScaled glad_debug_glScaled
+GLAD_API_CALL PFNGLSCALEFPROC glad_glScalef;
+GLAD_API_CALL PFNGLSCALEFPROC glad_debug_glScalef;
+#define glScalef glad_debug_glScalef
GLAD_API_CALL PFNGLSCISSORPROC glad_glScissor;
GLAD_API_CALL PFNGLSCISSORPROC glad_debug_glScissor;
#define glScissor glad_debug_glScissor
@@ -5496,6 +6731,69 @@ GLAD_API_CALL PFNGLSCISSORINDEXEDPROC glad_debug_glScissorIndexed;
GLAD_API_CALL PFNGLSCISSORINDEXEDVPROC glad_glScissorIndexedv;
GLAD_API_CALL PFNGLSCISSORINDEXEDVPROC glad_debug_glScissorIndexedv;
#define glScissorIndexedv glad_debug_glScissorIndexedv
+GLAD_API_CALL PFNGLSECONDARYCOLOR3BPROC glad_glSecondaryColor3b;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3BPROC glad_debug_glSecondaryColor3b;
+#define glSecondaryColor3b glad_debug_glSecondaryColor3b
+GLAD_API_CALL PFNGLSECONDARYCOLOR3BVPROC glad_glSecondaryColor3bv;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3BVPROC glad_debug_glSecondaryColor3bv;
+#define glSecondaryColor3bv glad_debug_glSecondaryColor3bv
+GLAD_API_CALL PFNGLSECONDARYCOLOR3DPROC glad_glSecondaryColor3d;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3DPROC glad_debug_glSecondaryColor3d;
+#define glSecondaryColor3d glad_debug_glSecondaryColor3d
+GLAD_API_CALL PFNGLSECONDARYCOLOR3DVPROC glad_glSecondaryColor3dv;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3DVPROC glad_debug_glSecondaryColor3dv;
+#define glSecondaryColor3dv glad_debug_glSecondaryColor3dv
+GLAD_API_CALL PFNGLSECONDARYCOLOR3FPROC glad_glSecondaryColor3f;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3FPROC glad_debug_glSecondaryColor3f;
+#define glSecondaryColor3f glad_debug_glSecondaryColor3f
+GLAD_API_CALL PFNGLSECONDARYCOLOR3FVPROC glad_glSecondaryColor3fv;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3FVPROC glad_debug_glSecondaryColor3fv;
+#define glSecondaryColor3fv glad_debug_glSecondaryColor3fv
+GLAD_API_CALL PFNGLSECONDARYCOLOR3IPROC glad_glSecondaryColor3i;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3IPROC glad_debug_glSecondaryColor3i;
+#define glSecondaryColor3i glad_debug_glSecondaryColor3i
+GLAD_API_CALL PFNGLSECONDARYCOLOR3IVPROC glad_glSecondaryColor3iv;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3IVPROC glad_debug_glSecondaryColor3iv;
+#define glSecondaryColor3iv glad_debug_glSecondaryColor3iv
+GLAD_API_CALL PFNGLSECONDARYCOLOR3SPROC glad_glSecondaryColor3s;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3SPROC glad_debug_glSecondaryColor3s;
+#define glSecondaryColor3s glad_debug_glSecondaryColor3s
+GLAD_API_CALL PFNGLSECONDARYCOLOR3SVPROC glad_glSecondaryColor3sv;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3SVPROC glad_debug_glSecondaryColor3sv;
+#define glSecondaryColor3sv glad_debug_glSecondaryColor3sv
+GLAD_API_CALL PFNGLSECONDARYCOLOR3UBPROC glad_glSecondaryColor3ub;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3UBPROC glad_debug_glSecondaryColor3ub;
+#define glSecondaryColor3ub glad_debug_glSecondaryColor3ub
+GLAD_API_CALL PFNGLSECONDARYCOLOR3UBVPROC glad_glSecondaryColor3ubv;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3UBVPROC glad_debug_glSecondaryColor3ubv;
+#define glSecondaryColor3ubv glad_debug_glSecondaryColor3ubv
+GLAD_API_CALL PFNGLSECONDARYCOLOR3UIPROC glad_glSecondaryColor3ui;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3UIPROC glad_debug_glSecondaryColor3ui;
+#define glSecondaryColor3ui glad_debug_glSecondaryColor3ui
+GLAD_API_CALL PFNGLSECONDARYCOLOR3UIVPROC glad_glSecondaryColor3uiv;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3UIVPROC glad_debug_glSecondaryColor3uiv;
+#define glSecondaryColor3uiv glad_debug_glSecondaryColor3uiv
+GLAD_API_CALL PFNGLSECONDARYCOLOR3USPROC glad_glSecondaryColor3us;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3USPROC glad_debug_glSecondaryColor3us;
+#define glSecondaryColor3us glad_debug_glSecondaryColor3us
+GLAD_API_CALL PFNGLSECONDARYCOLOR3USVPROC glad_glSecondaryColor3usv;
+GLAD_API_CALL PFNGLSECONDARYCOLOR3USVPROC glad_debug_glSecondaryColor3usv;
+#define glSecondaryColor3usv glad_debug_glSecondaryColor3usv
+GLAD_API_CALL PFNGLSECONDARYCOLORP3UIPROC glad_glSecondaryColorP3ui;
+GLAD_API_CALL PFNGLSECONDARYCOLORP3UIPROC glad_debug_glSecondaryColorP3ui;
+#define glSecondaryColorP3ui glad_debug_glSecondaryColorP3ui
+GLAD_API_CALL PFNGLSECONDARYCOLORP3UIVPROC glad_glSecondaryColorP3uiv;
+GLAD_API_CALL PFNGLSECONDARYCOLORP3UIVPROC glad_debug_glSecondaryColorP3uiv;
+#define glSecondaryColorP3uiv glad_debug_glSecondaryColorP3uiv
+GLAD_API_CALL PFNGLSECONDARYCOLORPOINTERPROC glad_glSecondaryColorPointer;
+GLAD_API_CALL PFNGLSECONDARYCOLORPOINTERPROC glad_debug_glSecondaryColorPointer;
+#define glSecondaryColorPointer glad_debug_glSecondaryColorPointer
+GLAD_API_CALL PFNGLSELECTBUFFERPROC glad_glSelectBuffer;
+GLAD_API_CALL PFNGLSELECTBUFFERPROC glad_debug_glSelectBuffer;
+#define glSelectBuffer glad_debug_glSelectBuffer
+GLAD_API_CALL PFNGLSHADEMODELPROC glad_glShadeModel;
+GLAD_API_CALL PFNGLSHADEMODELPROC glad_debug_glShadeModel;
+#define glShadeModel glad_debug_glShadeModel
GLAD_API_CALL PFNGLSHADERBINARYPROC glad_glShaderBinary;
GLAD_API_CALL PFNGLSHADERBINARYPROC glad_debug_glShaderBinary;
#define glShaderBinary glad_debug_glShaderBinary
@@ -5535,42 +6833,159 @@ GLAD_API_CALL PFNGLTEXBUFFERPROC glad_debug_glTexBuffer;
GLAD_API_CALL PFNGLTEXBUFFERRANGEPROC glad_glTexBufferRange;
GLAD_API_CALL PFNGLTEXBUFFERRANGEPROC glad_debug_glTexBufferRange;
#define glTexBufferRange glad_debug_glTexBufferRange
-GLAD_API_CALL PFNGLTEXCOORD1XOESPROC glad_glTexCoord1xOES;
-GLAD_API_CALL PFNGLTEXCOORD1XOESPROC glad_debug_glTexCoord1xOES;
-#define glTexCoord1xOES glad_debug_glTexCoord1xOES
-GLAD_API_CALL PFNGLTEXCOORD1XVOESPROC glad_glTexCoord1xvOES;
-GLAD_API_CALL PFNGLTEXCOORD1XVOESPROC glad_debug_glTexCoord1xvOES;
-#define glTexCoord1xvOES glad_debug_glTexCoord1xvOES
-GLAD_API_CALL PFNGLTEXCOORD2XOESPROC glad_glTexCoord2xOES;
-GLAD_API_CALL PFNGLTEXCOORD2XOESPROC glad_debug_glTexCoord2xOES;
-#define glTexCoord2xOES glad_debug_glTexCoord2xOES
-GLAD_API_CALL PFNGLTEXCOORD2XVOESPROC glad_glTexCoord2xvOES;
-GLAD_API_CALL PFNGLTEXCOORD2XVOESPROC glad_debug_glTexCoord2xvOES;
-#define glTexCoord2xvOES glad_debug_glTexCoord2xvOES
-GLAD_API_CALL PFNGLTEXCOORD3XOESPROC glad_glTexCoord3xOES;
-GLAD_API_CALL PFNGLTEXCOORD3XOESPROC glad_debug_glTexCoord3xOES;
-#define glTexCoord3xOES glad_debug_glTexCoord3xOES
-GLAD_API_CALL PFNGLTEXCOORD3XVOESPROC glad_glTexCoord3xvOES;
-GLAD_API_CALL PFNGLTEXCOORD3XVOESPROC glad_debug_glTexCoord3xvOES;
-#define glTexCoord3xvOES glad_debug_glTexCoord3xvOES
-GLAD_API_CALL PFNGLTEXCOORD4XOESPROC glad_glTexCoord4xOES;
-GLAD_API_CALL PFNGLTEXCOORD4XOESPROC glad_debug_glTexCoord4xOES;
-#define glTexCoord4xOES glad_debug_glTexCoord4xOES
-GLAD_API_CALL PFNGLTEXCOORD4XVOESPROC glad_glTexCoord4xvOES;
-GLAD_API_CALL PFNGLTEXCOORD4XVOESPROC glad_debug_glTexCoord4xvOES;
-#define glTexCoord4xvOES glad_debug_glTexCoord4xvOES
-GLAD_API_CALL PFNGLTEXENVXOESPROC glad_glTexEnvxOES;
-GLAD_API_CALL PFNGLTEXENVXOESPROC glad_debug_glTexEnvxOES;
-#define glTexEnvxOES glad_debug_glTexEnvxOES
-GLAD_API_CALL PFNGLTEXENVXVOESPROC glad_glTexEnvxvOES;
-GLAD_API_CALL PFNGLTEXENVXVOESPROC glad_debug_glTexEnvxvOES;
-#define glTexEnvxvOES glad_debug_glTexEnvxvOES
-GLAD_API_CALL PFNGLTEXGENXOESPROC glad_glTexGenxOES;
-GLAD_API_CALL PFNGLTEXGENXOESPROC glad_debug_glTexGenxOES;
-#define glTexGenxOES glad_debug_glTexGenxOES
-GLAD_API_CALL PFNGLTEXGENXVOESPROC glad_glTexGenxvOES;
-GLAD_API_CALL PFNGLTEXGENXVOESPROC glad_debug_glTexGenxvOES;
-#define glTexGenxvOES glad_debug_glTexGenxvOES
+GLAD_API_CALL PFNGLTEXCOORD1DPROC glad_glTexCoord1d;
+GLAD_API_CALL PFNGLTEXCOORD1DPROC glad_debug_glTexCoord1d;
+#define glTexCoord1d glad_debug_glTexCoord1d
+GLAD_API_CALL PFNGLTEXCOORD1DVPROC glad_glTexCoord1dv;
+GLAD_API_CALL PFNGLTEXCOORD1DVPROC glad_debug_glTexCoord1dv;
+#define glTexCoord1dv glad_debug_glTexCoord1dv
+GLAD_API_CALL PFNGLTEXCOORD1FPROC glad_glTexCoord1f;
+GLAD_API_CALL PFNGLTEXCOORD1FPROC glad_debug_glTexCoord1f;
+#define glTexCoord1f glad_debug_glTexCoord1f
+GLAD_API_CALL PFNGLTEXCOORD1FVPROC glad_glTexCoord1fv;
+GLAD_API_CALL PFNGLTEXCOORD1FVPROC glad_debug_glTexCoord1fv;
+#define glTexCoord1fv glad_debug_glTexCoord1fv
+GLAD_API_CALL PFNGLTEXCOORD1IPROC glad_glTexCoord1i;
+GLAD_API_CALL PFNGLTEXCOORD1IPROC glad_debug_glTexCoord1i;
+#define glTexCoord1i glad_debug_glTexCoord1i
+GLAD_API_CALL PFNGLTEXCOORD1IVPROC glad_glTexCoord1iv;
+GLAD_API_CALL PFNGLTEXCOORD1IVPROC glad_debug_glTexCoord1iv;
+#define glTexCoord1iv glad_debug_glTexCoord1iv
+GLAD_API_CALL PFNGLTEXCOORD1SPROC glad_glTexCoord1s;
+GLAD_API_CALL PFNGLTEXCOORD1SPROC glad_debug_glTexCoord1s;
+#define glTexCoord1s glad_debug_glTexCoord1s
+GLAD_API_CALL PFNGLTEXCOORD1SVPROC glad_glTexCoord1sv;
+GLAD_API_CALL PFNGLTEXCOORD1SVPROC glad_debug_glTexCoord1sv;
+#define glTexCoord1sv glad_debug_glTexCoord1sv
+GLAD_API_CALL PFNGLTEXCOORD2DPROC glad_glTexCoord2d;
+GLAD_API_CALL PFNGLTEXCOORD2DPROC glad_debug_glTexCoord2d;
+#define glTexCoord2d glad_debug_glTexCoord2d
+GLAD_API_CALL PFNGLTEXCOORD2DVPROC glad_glTexCoord2dv;
+GLAD_API_CALL PFNGLTEXCOORD2DVPROC glad_debug_glTexCoord2dv;
+#define glTexCoord2dv glad_debug_glTexCoord2dv
+GLAD_API_CALL PFNGLTEXCOORD2FPROC glad_glTexCoord2f;
+GLAD_API_CALL PFNGLTEXCOORD2FPROC glad_debug_glTexCoord2f;
+#define glTexCoord2f glad_debug_glTexCoord2f
+GLAD_API_CALL PFNGLTEXCOORD2FVPROC glad_glTexCoord2fv;
+GLAD_API_CALL PFNGLTEXCOORD2FVPROC glad_debug_glTexCoord2fv;
+#define glTexCoord2fv glad_debug_glTexCoord2fv
+GLAD_API_CALL PFNGLTEXCOORD2IPROC glad_glTexCoord2i;
+GLAD_API_CALL PFNGLTEXCOORD2IPROC glad_debug_glTexCoord2i;
+#define glTexCoord2i glad_debug_glTexCoord2i
+GLAD_API_CALL PFNGLTEXCOORD2IVPROC glad_glTexCoord2iv;
+GLAD_API_CALL PFNGLTEXCOORD2IVPROC glad_debug_glTexCoord2iv;
+#define glTexCoord2iv glad_debug_glTexCoord2iv
+GLAD_API_CALL PFNGLTEXCOORD2SPROC glad_glTexCoord2s;
+GLAD_API_CALL PFNGLTEXCOORD2SPROC glad_debug_glTexCoord2s;
+#define glTexCoord2s glad_debug_glTexCoord2s
+GLAD_API_CALL PFNGLTEXCOORD2SVPROC glad_glTexCoord2sv;
+GLAD_API_CALL PFNGLTEXCOORD2SVPROC glad_debug_glTexCoord2sv;
+#define glTexCoord2sv glad_debug_glTexCoord2sv
+GLAD_API_CALL PFNGLTEXCOORD3DPROC glad_glTexCoord3d;
+GLAD_API_CALL PFNGLTEXCOORD3DPROC glad_debug_glTexCoord3d;
+#define glTexCoord3d glad_debug_glTexCoord3d
+GLAD_API_CALL PFNGLTEXCOORD3DVPROC glad_glTexCoord3dv;
+GLAD_API_CALL PFNGLTEXCOORD3DVPROC glad_debug_glTexCoord3dv;
+#define glTexCoord3dv glad_debug_glTexCoord3dv
+GLAD_API_CALL PFNGLTEXCOORD3FPROC glad_glTexCoord3f;
+GLAD_API_CALL PFNGLTEXCOORD3FPROC glad_debug_glTexCoord3f;
+#define glTexCoord3f glad_debug_glTexCoord3f
+GLAD_API_CALL PFNGLTEXCOORD3FVPROC glad_glTexCoord3fv;
+GLAD_API_CALL PFNGLTEXCOORD3FVPROC glad_debug_glTexCoord3fv;
+#define glTexCoord3fv glad_debug_glTexCoord3fv
+GLAD_API_CALL PFNGLTEXCOORD3IPROC glad_glTexCoord3i;
+GLAD_API_CALL PFNGLTEXCOORD3IPROC glad_debug_glTexCoord3i;
+#define glTexCoord3i glad_debug_glTexCoord3i
+GLAD_API_CALL PFNGLTEXCOORD3IVPROC glad_glTexCoord3iv;
+GLAD_API_CALL PFNGLTEXCOORD3IVPROC glad_debug_glTexCoord3iv;
+#define glTexCoord3iv glad_debug_glTexCoord3iv
+GLAD_API_CALL PFNGLTEXCOORD3SPROC glad_glTexCoord3s;
+GLAD_API_CALL PFNGLTEXCOORD3SPROC glad_debug_glTexCoord3s;
+#define glTexCoord3s glad_debug_glTexCoord3s
+GLAD_API_CALL PFNGLTEXCOORD3SVPROC glad_glTexCoord3sv;
+GLAD_API_CALL PFNGLTEXCOORD3SVPROC glad_debug_glTexCoord3sv;
+#define glTexCoord3sv glad_debug_glTexCoord3sv
+GLAD_API_CALL PFNGLTEXCOORD4DPROC glad_glTexCoord4d;
+GLAD_API_CALL PFNGLTEXCOORD4DPROC glad_debug_glTexCoord4d;
+#define glTexCoord4d glad_debug_glTexCoord4d
+GLAD_API_CALL PFNGLTEXCOORD4DVPROC glad_glTexCoord4dv;
+GLAD_API_CALL PFNGLTEXCOORD4DVPROC glad_debug_glTexCoord4dv;
+#define glTexCoord4dv glad_debug_glTexCoord4dv
+GLAD_API_CALL PFNGLTEXCOORD4FPROC glad_glTexCoord4f;
+GLAD_API_CALL PFNGLTEXCOORD4FPROC glad_debug_glTexCoord4f;
+#define glTexCoord4f glad_debug_glTexCoord4f
+GLAD_API_CALL PFNGLTEXCOORD4FVPROC glad_glTexCoord4fv;
+GLAD_API_CALL PFNGLTEXCOORD4FVPROC glad_debug_glTexCoord4fv;
+#define glTexCoord4fv glad_debug_glTexCoord4fv
+GLAD_API_CALL PFNGLTEXCOORD4IPROC glad_glTexCoord4i;
+GLAD_API_CALL PFNGLTEXCOORD4IPROC glad_debug_glTexCoord4i;
+#define glTexCoord4i glad_debug_glTexCoord4i
+GLAD_API_CALL PFNGLTEXCOORD4IVPROC glad_glTexCoord4iv;
+GLAD_API_CALL PFNGLTEXCOORD4IVPROC glad_debug_glTexCoord4iv;
+#define glTexCoord4iv glad_debug_glTexCoord4iv
+GLAD_API_CALL PFNGLTEXCOORD4SPROC glad_glTexCoord4s;
+GLAD_API_CALL PFNGLTEXCOORD4SPROC glad_debug_glTexCoord4s;
+#define glTexCoord4s glad_debug_glTexCoord4s
+GLAD_API_CALL PFNGLTEXCOORD4SVPROC glad_glTexCoord4sv;
+GLAD_API_CALL PFNGLTEXCOORD4SVPROC glad_debug_glTexCoord4sv;
+#define glTexCoord4sv glad_debug_glTexCoord4sv
+GLAD_API_CALL PFNGLTEXCOORDP1UIPROC glad_glTexCoordP1ui;
+GLAD_API_CALL PFNGLTEXCOORDP1UIPROC glad_debug_glTexCoordP1ui;
+#define glTexCoordP1ui glad_debug_glTexCoordP1ui
+GLAD_API_CALL PFNGLTEXCOORDP1UIVPROC glad_glTexCoordP1uiv;
+GLAD_API_CALL PFNGLTEXCOORDP1UIVPROC glad_debug_glTexCoordP1uiv;
+#define glTexCoordP1uiv glad_debug_glTexCoordP1uiv
+GLAD_API_CALL PFNGLTEXCOORDP2UIPROC glad_glTexCoordP2ui;
+GLAD_API_CALL PFNGLTEXCOORDP2UIPROC glad_debug_glTexCoordP2ui;
+#define glTexCoordP2ui glad_debug_glTexCoordP2ui
+GLAD_API_CALL PFNGLTEXCOORDP2UIVPROC glad_glTexCoordP2uiv;
+GLAD_API_CALL PFNGLTEXCOORDP2UIVPROC glad_debug_glTexCoordP2uiv;
+#define glTexCoordP2uiv glad_debug_glTexCoordP2uiv
+GLAD_API_CALL PFNGLTEXCOORDP3UIPROC glad_glTexCoordP3ui;
+GLAD_API_CALL PFNGLTEXCOORDP3UIPROC glad_debug_glTexCoordP3ui;
+#define glTexCoordP3ui glad_debug_glTexCoordP3ui
+GLAD_API_CALL PFNGLTEXCOORDP3UIVPROC glad_glTexCoordP3uiv;
+GLAD_API_CALL PFNGLTEXCOORDP3UIVPROC glad_debug_glTexCoordP3uiv;
+#define glTexCoordP3uiv glad_debug_glTexCoordP3uiv
+GLAD_API_CALL PFNGLTEXCOORDP4UIPROC glad_glTexCoordP4ui;
+GLAD_API_CALL PFNGLTEXCOORDP4UIPROC glad_debug_glTexCoordP4ui;
+#define glTexCoordP4ui glad_debug_glTexCoordP4ui
+GLAD_API_CALL PFNGLTEXCOORDP4UIVPROC glad_glTexCoordP4uiv;
+GLAD_API_CALL PFNGLTEXCOORDP4UIVPROC glad_debug_glTexCoordP4uiv;
+#define glTexCoordP4uiv glad_debug_glTexCoordP4uiv
+GLAD_API_CALL PFNGLTEXCOORDPOINTERPROC glad_glTexCoordPointer;
+GLAD_API_CALL PFNGLTEXCOORDPOINTERPROC glad_debug_glTexCoordPointer;
+#define glTexCoordPointer glad_debug_glTexCoordPointer
+GLAD_API_CALL PFNGLTEXENVFPROC glad_glTexEnvf;
+GLAD_API_CALL PFNGLTEXENVFPROC glad_debug_glTexEnvf;
+#define glTexEnvf glad_debug_glTexEnvf
+GLAD_API_CALL PFNGLTEXENVFVPROC glad_glTexEnvfv;
+GLAD_API_CALL PFNGLTEXENVFVPROC glad_debug_glTexEnvfv;
+#define glTexEnvfv glad_debug_glTexEnvfv
+GLAD_API_CALL PFNGLTEXENVIPROC glad_glTexEnvi;
+GLAD_API_CALL PFNGLTEXENVIPROC glad_debug_glTexEnvi;
+#define glTexEnvi glad_debug_glTexEnvi
+GLAD_API_CALL PFNGLTEXENVIVPROC glad_glTexEnviv;
+GLAD_API_CALL PFNGLTEXENVIVPROC glad_debug_glTexEnviv;
+#define glTexEnviv glad_debug_glTexEnviv
+GLAD_API_CALL PFNGLTEXGENDPROC glad_glTexGend;
+GLAD_API_CALL PFNGLTEXGENDPROC glad_debug_glTexGend;
+#define glTexGend glad_debug_glTexGend
+GLAD_API_CALL PFNGLTEXGENDVPROC glad_glTexGendv;
+GLAD_API_CALL PFNGLTEXGENDVPROC glad_debug_glTexGendv;
+#define glTexGendv glad_debug_glTexGendv
+GLAD_API_CALL PFNGLTEXGENFPROC glad_glTexGenf;
+GLAD_API_CALL PFNGLTEXGENFPROC glad_debug_glTexGenf;
+#define glTexGenf glad_debug_glTexGenf
+GLAD_API_CALL PFNGLTEXGENFVPROC glad_glTexGenfv;
+GLAD_API_CALL PFNGLTEXGENFVPROC glad_debug_glTexGenfv;
+#define glTexGenfv glad_debug_glTexGenfv
+GLAD_API_CALL PFNGLTEXGENIPROC glad_glTexGeni;
+GLAD_API_CALL PFNGLTEXGENIPROC glad_debug_glTexGeni;
+#define glTexGeni glad_debug_glTexGeni
+GLAD_API_CALL PFNGLTEXGENIVPROC glad_glTexGeniv;
+GLAD_API_CALL PFNGLTEXGENIVPROC glad_debug_glTexGeniv;
+#define glTexGeniv glad_debug_glTexGeniv
GLAD_API_CALL PFNGLTEXIMAGE1DPROC glad_glTexImage1D;
GLAD_API_CALL PFNGLTEXIMAGE1DPROC glad_debug_glTexImage1D;
#define glTexImage1D glad_debug_glTexImage1D
@@ -5604,12 +7019,6 @@ GLAD_API_CALL PFNGLTEXPARAMETERIPROC glad_debug_glTexParameteri;
GLAD_API_CALL PFNGLTEXPARAMETERIVPROC glad_glTexParameteriv;
GLAD_API_CALL PFNGLTEXPARAMETERIVPROC glad_debug_glTexParameteriv;
#define glTexParameteriv glad_debug_glTexParameteriv
-GLAD_API_CALL PFNGLTEXPARAMETERXOESPROC glad_glTexParameterxOES;
-GLAD_API_CALL PFNGLTEXPARAMETERXOESPROC glad_debug_glTexParameterxOES;
-#define glTexParameterxOES glad_debug_glTexParameterxOES
-GLAD_API_CALL PFNGLTEXPARAMETERXVOESPROC glad_glTexParameterxvOES;
-GLAD_API_CALL PFNGLTEXPARAMETERXVOESPROC glad_debug_glTexParameterxvOES;
-#define glTexParameterxvOES glad_debug_glTexParameterxvOES
GLAD_API_CALL PFNGLTEXSTORAGE1DPROC glad_glTexStorage1D;
GLAD_API_CALL PFNGLTEXSTORAGE1DPROC glad_debug_glTexStorage1D;
#define glTexStorage1D glad_debug_glTexStorage1D
@@ -5694,9 +7103,12 @@ GLAD_API_CALL PFNGLTRANSFORMFEEDBACKBUFFERRANGEPROC glad_debug_glTransformFeedba
GLAD_API_CALL PFNGLTRANSFORMFEEDBACKVARYINGSPROC glad_glTransformFeedbackVaryings;
GLAD_API_CALL PFNGLTRANSFORMFEEDBACKVARYINGSPROC glad_debug_glTransformFeedbackVaryings;
#define glTransformFeedbackVaryings glad_debug_glTransformFeedbackVaryings
-GLAD_API_CALL PFNGLTRANSLATEXOESPROC glad_glTranslatexOES;
-GLAD_API_CALL PFNGLTRANSLATEXOESPROC glad_debug_glTranslatexOES;
-#define glTranslatexOES glad_debug_glTranslatexOES
+GLAD_API_CALL PFNGLTRANSLATEDPROC glad_glTranslated;
+GLAD_API_CALL PFNGLTRANSLATEDPROC glad_debug_glTranslated;
+#define glTranslated glad_debug_glTranslated
+GLAD_API_CALL PFNGLTRANSLATEFPROC glad_glTranslatef;
+GLAD_API_CALL PFNGLTRANSLATEFPROC glad_debug_glTranslatef;
+#define glTranslatef glad_debug_glTranslatef
GLAD_API_CALL PFNGLUNIFORM1DPROC glad_glUniform1d;
GLAD_API_CALL PFNGLUNIFORM1DPROC glad_debug_glUniform1d;
#define glUniform1d glad_debug_glUniform1d
@@ -5985,24 +7397,78 @@ GLAD_API_CALL PFNGLVALIDATEPROGRAMARBPROC glad_debug_glValidateProgramARB;
GLAD_API_CALL PFNGLVALIDATEPROGRAMPIPELINEPROC glad_glValidateProgramPipeline;
GLAD_API_CALL PFNGLVALIDATEPROGRAMPIPELINEPROC glad_debug_glValidateProgramPipeline;
#define glValidateProgramPipeline glad_debug_glValidateProgramPipeline
-GLAD_API_CALL PFNGLVERTEX2XOESPROC glad_glVertex2xOES;
-GLAD_API_CALL PFNGLVERTEX2XOESPROC glad_debug_glVertex2xOES;
-#define glVertex2xOES glad_debug_glVertex2xOES
-GLAD_API_CALL PFNGLVERTEX2XVOESPROC glad_glVertex2xvOES;
-GLAD_API_CALL PFNGLVERTEX2XVOESPROC glad_debug_glVertex2xvOES;
-#define glVertex2xvOES glad_debug_glVertex2xvOES
-GLAD_API_CALL PFNGLVERTEX3XOESPROC glad_glVertex3xOES;
-GLAD_API_CALL PFNGLVERTEX3XOESPROC glad_debug_glVertex3xOES;
-#define glVertex3xOES glad_debug_glVertex3xOES
-GLAD_API_CALL PFNGLVERTEX3XVOESPROC glad_glVertex3xvOES;
-GLAD_API_CALL PFNGLVERTEX3XVOESPROC glad_debug_glVertex3xvOES;
-#define glVertex3xvOES glad_debug_glVertex3xvOES
-GLAD_API_CALL PFNGLVERTEX4XOESPROC glad_glVertex4xOES;
-GLAD_API_CALL PFNGLVERTEX4XOESPROC glad_debug_glVertex4xOES;
-#define glVertex4xOES glad_debug_glVertex4xOES
-GLAD_API_CALL PFNGLVERTEX4XVOESPROC glad_glVertex4xvOES;
-GLAD_API_CALL PFNGLVERTEX4XVOESPROC glad_debug_glVertex4xvOES;
-#define glVertex4xvOES glad_debug_glVertex4xvOES
+GLAD_API_CALL PFNGLVERTEX2DPROC glad_glVertex2d;
+GLAD_API_CALL PFNGLVERTEX2DPROC glad_debug_glVertex2d;
+#define glVertex2d glad_debug_glVertex2d
+GLAD_API_CALL PFNGLVERTEX2DVPROC glad_glVertex2dv;
+GLAD_API_CALL PFNGLVERTEX2DVPROC glad_debug_glVertex2dv;
+#define glVertex2dv glad_debug_glVertex2dv
+GLAD_API_CALL PFNGLVERTEX2FPROC glad_glVertex2f;
+GLAD_API_CALL PFNGLVERTEX2FPROC glad_debug_glVertex2f;
+#define glVertex2f glad_debug_glVertex2f
+GLAD_API_CALL PFNGLVERTEX2FVPROC glad_glVertex2fv;
+GLAD_API_CALL PFNGLVERTEX2FVPROC glad_debug_glVertex2fv;
+#define glVertex2fv glad_debug_glVertex2fv
+GLAD_API_CALL PFNGLVERTEX2IPROC glad_glVertex2i;
+GLAD_API_CALL PFNGLVERTEX2IPROC glad_debug_glVertex2i;
+#define glVertex2i glad_debug_glVertex2i
+GLAD_API_CALL PFNGLVERTEX2IVPROC glad_glVertex2iv;
+GLAD_API_CALL PFNGLVERTEX2IVPROC glad_debug_glVertex2iv;
+#define glVertex2iv glad_debug_glVertex2iv
+GLAD_API_CALL PFNGLVERTEX2SPROC glad_glVertex2s;
+GLAD_API_CALL PFNGLVERTEX2SPROC glad_debug_glVertex2s;
+#define glVertex2s glad_debug_glVertex2s
+GLAD_API_CALL PFNGLVERTEX2SVPROC glad_glVertex2sv;
+GLAD_API_CALL PFNGLVERTEX2SVPROC glad_debug_glVertex2sv;
+#define glVertex2sv glad_debug_glVertex2sv
+GLAD_API_CALL PFNGLVERTEX3DPROC glad_glVertex3d;
+GLAD_API_CALL PFNGLVERTEX3DPROC glad_debug_glVertex3d;
+#define glVertex3d glad_debug_glVertex3d
+GLAD_API_CALL PFNGLVERTEX3DVPROC glad_glVertex3dv;
+GLAD_API_CALL PFNGLVERTEX3DVPROC glad_debug_glVertex3dv;
+#define glVertex3dv glad_debug_glVertex3dv
+GLAD_API_CALL PFNGLVERTEX3FPROC glad_glVertex3f;
+GLAD_API_CALL PFNGLVERTEX3FPROC glad_debug_glVertex3f;
+#define glVertex3f glad_debug_glVertex3f
+GLAD_API_CALL PFNGLVERTEX3FVPROC glad_glVertex3fv;
+GLAD_API_CALL PFNGLVERTEX3FVPROC glad_debug_glVertex3fv;
+#define glVertex3fv glad_debug_glVertex3fv
+GLAD_API_CALL PFNGLVERTEX3IPROC glad_glVertex3i;
+GLAD_API_CALL PFNGLVERTEX3IPROC glad_debug_glVertex3i;
+#define glVertex3i glad_debug_glVertex3i
+GLAD_API_CALL PFNGLVERTEX3IVPROC glad_glVertex3iv;
+GLAD_API_CALL PFNGLVERTEX3IVPROC glad_debug_glVertex3iv;
+#define glVertex3iv glad_debug_glVertex3iv
+GLAD_API_CALL PFNGLVERTEX3SPROC glad_glVertex3s;
+GLAD_API_CALL PFNGLVERTEX3SPROC glad_debug_glVertex3s;
+#define glVertex3s glad_debug_glVertex3s
+GLAD_API_CALL PFNGLVERTEX3SVPROC glad_glVertex3sv;
+GLAD_API_CALL PFNGLVERTEX3SVPROC glad_debug_glVertex3sv;
+#define glVertex3sv glad_debug_glVertex3sv
+GLAD_API_CALL PFNGLVERTEX4DPROC glad_glVertex4d;
+GLAD_API_CALL PFNGLVERTEX4DPROC glad_debug_glVertex4d;
+#define glVertex4d glad_debug_glVertex4d
+GLAD_API_CALL PFNGLVERTEX4DVPROC glad_glVertex4dv;
+GLAD_API_CALL PFNGLVERTEX4DVPROC glad_debug_glVertex4dv;
+#define glVertex4dv glad_debug_glVertex4dv
+GLAD_API_CALL PFNGLVERTEX4FPROC glad_glVertex4f;
+GLAD_API_CALL PFNGLVERTEX4FPROC glad_debug_glVertex4f;
+#define glVertex4f glad_debug_glVertex4f
+GLAD_API_CALL PFNGLVERTEX4FVPROC glad_glVertex4fv;
+GLAD_API_CALL PFNGLVERTEX4FVPROC glad_debug_glVertex4fv;
+#define glVertex4fv glad_debug_glVertex4fv
+GLAD_API_CALL PFNGLVERTEX4IPROC glad_glVertex4i;
+GLAD_API_CALL PFNGLVERTEX4IPROC glad_debug_glVertex4i;
+#define glVertex4i glad_debug_glVertex4i
+GLAD_API_CALL PFNGLVERTEX4IVPROC glad_glVertex4iv;
+GLAD_API_CALL PFNGLVERTEX4IVPROC glad_debug_glVertex4iv;
+#define glVertex4iv glad_debug_glVertex4iv
+GLAD_API_CALL PFNGLVERTEX4SPROC glad_glVertex4s;
+GLAD_API_CALL PFNGLVERTEX4SPROC glad_debug_glVertex4s;
+#define glVertex4s glad_debug_glVertex4s
+GLAD_API_CALL PFNGLVERTEX4SVPROC glad_glVertex4sv;
+GLAD_API_CALL PFNGLVERTEX4SVPROC glad_debug_glVertex4sv;
+#define glVertex4sv glad_debug_glVertex4sv
GLAD_API_CALL PFNGLVERTEXARRAYATTRIBBINDINGPROC glad_glVertexArrayAttribBinding;
GLAD_API_CALL PFNGLVERTEXARRAYATTRIBBINDINGPROC glad_debug_glVertexArrayAttribBinding;
#define glVertexArrayAttribBinding glad_debug_glVertexArrayAttribBinding
@@ -6384,6 +7850,27 @@ GLAD_API_CALL PFNGLVERTEXATTRIBPOINTERARBPROC glad_debug_glVertexAttribPointerAR
GLAD_API_CALL PFNGLVERTEXBINDINGDIVISORPROC glad_glVertexBindingDivisor;
GLAD_API_CALL PFNGLVERTEXBINDINGDIVISORPROC glad_debug_glVertexBindingDivisor;
#define glVertexBindingDivisor glad_debug_glVertexBindingDivisor
+GLAD_API_CALL PFNGLVERTEXP2UIPROC glad_glVertexP2ui;
+GLAD_API_CALL PFNGLVERTEXP2UIPROC glad_debug_glVertexP2ui;
+#define glVertexP2ui glad_debug_glVertexP2ui
+GLAD_API_CALL PFNGLVERTEXP2UIVPROC glad_glVertexP2uiv;
+GLAD_API_CALL PFNGLVERTEXP2UIVPROC glad_debug_glVertexP2uiv;
+#define glVertexP2uiv glad_debug_glVertexP2uiv
+GLAD_API_CALL PFNGLVERTEXP3UIPROC glad_glVertexP3ui;
+GLAD_API_CALL PFNGLVERTEXP3UIPROC glad_debug_glVertexP3ui;
+#define glVertexP3ui glad_debug_glVertexP3ui
+GLAD_API_CALL PFNGLVERTEXP3UIVPROC glad_glVertexP3uiv;
+GLAD_API_CALL PFNGLVERTEXP3UIVPROC glad_debug_glVertexP3uiv;
+#define glVertexP3uiv glad_debug_glVertexP3uiv
+GLAD_API_CALL PFNGLVERTEXP4UIPROC glad_glVertexP4ui;
+GLAD_API_CALL PFNGLVERTEXP4UIPROC glad_debug_glVertexP4ui;
+#define glVertexP4ui glad_debug_glVertexP4ui
+GLAD_API_CALL PFNGLVERTEXP4UIVPROC glad_glVertexP4uiv;
+GLAD_API_CALL PFNGLVERTEXP4UIVPROC glad_debug_glVertexP4uiv;
+#define glVertexP4uiv glad_debug_glVertexP4uiv
+GLAD_API_CALL PFNGLVERTEXPOINTERPROC glad_glVertexPointer;
+GLAD_API_CALL PFNGLVERTEXPOINTERPROC glad_debug_glVertexPointer;
+#define glVertexPointer glad_debug_glVertexPointer
GLAD_API_CALL PFNGLVIEWPORTPROC glad_glViewport;
GLAD_API_CALL PFNGLVIEWPORTPROC glad_debug_glViewport;
#define glViewport glad_debug_glViewport
@@ -6399,6 +7886,54 @@ GLAD_API_CALL PFNGLVIEWPORTINDEXEDFVPROC glad_debug_glViewportIndexedfv;
GLAD_API_CALL PFNGLWAITSYNCPROC glad_glWaitSync;
GLAD_API_CALL PFNGLWAITSYNCPROC glad_debug_glWaitSync;
#define glWaitSync glad_debug_glWaitSync
+GLAD_API_CALL PFNGLWINDOWPOS2DPROC glad_glWindowPos2d;
+GLAD_API_CALL PFNGLWINDOWPOS2DPROC glad_debug_glWindowPos2d;
+#define glWindowPos2d glad_debug_glWindowPos2d
+GLAD_API_CALL PFNGLWINDOWPOS2DVPROC glad_glWindowPos2dv;
+GLAD_API_CALL PFNGLWINDOWPOS2DVPROC glad_debug_glWindowPos2dv;
+#define glWindowPos2dv glad_debug_glWindowPos2dv
+GLAD_API_CALL PFNGLWINDOWPOS2FPROC glad_glWindowPos2f;
+GLAD_API_CALL PFNGLWINDOWPOS2FPROC glad_debug_glWindowPos2f;
+#define glWindowPos2f glad_debug_glWindowPos2f
+GLAD_API_CALL PFNGLWINDOWPOS2FVPROC glad_glWindowPos2fv;
+GLAD_API_CALL PFNGLWINDOWPOS2FVPROC glad_debug_glWindowPos2fv;
+#define glWindowPos2fv glad_debug_glWindowPos2fv
+GLAD_API_CALL PFNGLWINDOWPOS2IPROC glad_glWindowPos2i;
+GLAD_API_CALL PFNGLWINDOWPOS2IPROC glad_debug_glWindowPos2i;
+#define glWindowPos2i glad_debug_glWindowPos2i
+GLAD_API_CALL PFNGLWINDOWPOS2IVPROC glad_glWindowPos2iv;
+GLAD_API_CALL PFNGLWINDOWPOS2IVPROC glad_debug_glWindowPos2iv;
+#define glWindowPos2iv glad_debug_glWindowPos2iv
+GLAD_API_CALL PFNGLWINDOWPOS2SPROC glad_glWindowPos2s;
+GLAD_API_CALL PFNGLWINDOWPOS2SPROC glad_debug_glWindowPos2s;
+#define glWindowPos2s glad_debug_glWindowPos2s
+GLAD_API_CALL PFNGLWINDOWPOS2SVPROC glad_glWindowPos2sv;
+GLAD_API_CALL PFNGLWINDOWPOS2SVPROC glad_debug_glWindowPos2sv;
+#define glWindowPos2sv glad_debug_glWindowPos2sv
+GLAD_API_CALL PFNGLWINDOWPOS3DPROC glad_glWindowPos3d;
+GLAD_API_CALL PFNGLWINDOWPOS3DPROC glad_debug_glWindowPos3d;
+#define glWindowPos3d glad_debug_glWindowPos3d
+GLAD_API_CALL PFNGLWINDOWPOS3DVPROC glad_glWindowPos3dv;
+GLAD_API_CALL PFNGLWINDOWPOS3DVPROC glad_debug_glWindowPos3dv;
+#define glWindowPos3dv glad_debug_glWindowPos3dv
+GLAD_API_CALL PFNGLWINDOWPOS3FPROC glad_glWindowPos3f;
+GLAD_API_CALL PFNGLWINDOWPOS3FPROC glad_debug_glWindowPos3f;
+#define glWindowPos3f glad_debug_glWindowPos3f
+GLAD_API_CALL PFNGLWINDOWPOS3FVPROC glad_glWindowPos3fv;
+GLAD_API_CALL PFNGLWINDOWPOS3FVPROC glad_debug_glWindowPos3fv;
+#define glWindowPos3fv glad_debug_glWindowPos3fv
+GLAD_API_CALL PFNGLWINDOWPOS3IPROC glad_glWindowPos3i;
+GLAD_API_CALL PFNGLWINDOWPOS3IPROC glad_debug_glWindowPos3i;
+#define glWindowPos3i glad_debug_glWindowPos3i
+GLAD_API_CALL PFNGLWINDOWPOS3IVPROC glad_glWindowPos3iv;
+GLAD_API_CALL PFNGLWINDOWPOS3IVPROC glad_debug_glWindowPos3iv;
+#define glWindowPos3iv glad_debug_glWindowPos3iv
+GLAD_API_CALL PFNGLWINDOWPOS3SPROC glad_glWindowPos3s;
+GLAD_API_CALL PFNGLWINDOWPOS3SPROC glad_debug_glWindowPos3s;
+#define glWindowPos3s glad_debug_glWindowPos3s
+GLAD_API_CALL PFNGLWINDOWPOS3SVPROC glad_glWindowPos3sv;
+GLAD_API_CALL PFNGLWINDOWPOS3SVPROC glad_debug_glWindowPos3sv;
+#define glWindowPos3sv glad_debug_glWindowPos3sv
diff --git a/external/sources/allegro 4.4.3.1-custom/addons/loadpng/savepng.c b/external/sources/allegro 4.4.3.1-custom/addons/loadpng/savepng.c
index 527494474b..4529233c8d 100644
--- a/external/sources/allegro 4.4.3.1-custom/addons/loadpng/savepng.c
+++ b/external/sources/allegro 4.4.3.1-custom/addons/loadpng/savepng.c
@@ -233,9 +233,9 @@ static int really_save_png(PACKFILE *fp, BITMAP *bmp, AL_CONST RGB *pal)
int i;
for (i = 0; i < 256; i++) {
- palette[i].red = _rgb_scale_6[pal[i].r]; /* 64 -> 256 */
- palette[i].green = _rgb_scale_6[pal[i].g];
- palette[i].blue = _rgb_scale_6[pal[i].b];
+ palette[i].red = pal[i].r; /* 64 -> 256 */
+ palette[i].green = pal[i].g;
+ palette[i].blue = pal[i].b;
}
/* Set palette colors. */
diff --git a/external/sources/allegro 4.4.3.1-custom/include/allegro/inline/draw.inl b/external/sources/allegro 4.4.3.1-custom/include/allegro/inline/draw.inl
index ec829e9d04..b09d85af19 100644
--- a/external/sources/allegro 4.4.3.1-custom/include/allegro/inline/draw.inl
+++ b/external/sources/allegro 4.4.3.1-custom/include/allegro/inline/draw.inl
@@ -239,6 +239,7 @@ AL_INLINE(void, draw_sprite, (BITMAP *bmp, BITMAP *sprite, int x, int y),
{
ASSERT(bmp);
ASSERT(sprite);
+ TracyCZone(draw, 1);
if (sprite->vtable->color_depth == 8) {
bmp->vtable->draw_256_sprite(bmp, sprite, x, y);
@@ -247,6 +248,7 @@ AL_INLINE(void, draw_sprite, (BITMAP *bmp, BITMAP *sprite, int x, int y),
ASSERT(bmp->vtable->color_depth == sprite->vtable->color_depth);
bmp->vtable->draw_sprite(bmp, sprite, x, y);
}
+ TracyCZoneEnd(draw);
})
AL_INLINE(void, draw_sprite_ex, (BITMAP *bmp, BITMAP *sprite, int x, int y,
@@ -254,6 +256,7 @@ AL_INLINE(void, draw_sprite_ex, (BITMAP *bmp, BITMAP *sprite, int x, int y,
{
ASSERT(bmp);
ASSERT(sprite);
+ TracyCZone(ctx, 1);
if (mode == DRAW_SPRITE_TRANS) {
ASSERT((bmp->vtable->color_depth == sprite->vtable->color_depth) ||
@@ -266,36 +269,44 @@ AL_INLINE(void, draw_sprite_ex, (BITMAP *bmp, BITMAP *sprite, int x, int y,
ASSERT(bmp->vtable->color_depth == sprite->vtable->color_depth);
bmp->vtable->draw_sprite_ex(bmp, sprite, x, y, mode, flip);
}
+ TracyCZoneEnd(ctx);
})
AL_INLINE(void, draw_sprite_v_flip, (BITMAP *bmp, BITMAP *sprite, int x, int y),{
+ TracyCZone(ctx, 1);
ASSERT(bmp);
ASSERT(sprite);
ASSERT(bmp->vtable->color_depth == sprite->vtable->color_depth);
bmp->vtable->draw_sprite_v_flip(bmp, sprite, x, y);
+ TracyCZoneEnd(ctx);
})
AL_INLINE(void, draw_sprite_h_flip, (BITMAP *bmp, BITMAP *sprite, int x, int y),{
+ TracyCZone(ctx, 1);
ASSERT(bmp);
ASSERT(sprite);
ASSERT(bmp->vtable->color_depth == sprite->vtable->color_depth);
bmp->vtable->draw_sprite_h_flip(bmp, sprite, x, y);
+ TracyCZoneEnd(ctx);
})
AL_INLINE(void, draw_sprite_vh_flip, (BITMAP *bmp, BITMAP *sprite, int x, int y),
{
+ TracyCZone(ctx, 1);
ASSERT(bmp);
ASSERT(sprite);
ASSERT(bmp->vtable->color_depth == sprite->vtable->color_depth);
bmp->vtable->draw_sprite_vh_flip(bmp, sprite, x, y);
+ TracyCZoneEnd(ctx);
})
AL_INLINE(void, draw_trans_sprite, (BITMAP *bmp, BITMAP *sprite, int x, int y),
{
+ TracyCZone(ctx, 1);
ASSERT(bmp);
ASSERT(sprite);
diff --git a/external/sources/allegro 4.4.3.1-custom/include/allegro/inline/gfx.inl b/external/sources/allegro 4.4.3.1-custom/include/allegro/inline/gfx.inl
index b72db6a37f..22d8a27cdd 100644
--- a/external/sources/allegro 4.4.3.1-custom/include/allegro/inline/gfx.inl
+++ b/external/sources/allegro 4.4.3.1-custom/include/allegro/inline/gfx.inl
@@ -20,6 +20,7 @@
#define ALLEGRO_GFX_INL
#include "allegro/debug.h"
+#include "tracy/TracyC.h"
#define ALLEGRO_IMPORT_GFX_ASM
#include "asm.inl"
@@ -95,9 +96,11 @@ AL_INLINE(int, is_windowed_mode, (void),
AL_INLINE(void, clear_to_color, (BITMAP *bitmap, int color),
{
+ TracyCZone(clear, 1);
ASSERT(bitmap);
bitmap->vtable->clear_to_color(bitmap, color);
+ TracyCZoneEnd(clear);
})
diff --git a/external/sources/allegro 4.4.3.1-custom/meson.build b/external/sources/allegro 4.4.3.1-custom/meson.build
index d999797479..5c5a4e6454 100644
--- a/external/sources/allegro 4.4.3.1-custom/meson.build
+++ b/external/sources/allegro 4.4.3.1-custom/meson.build
@@ -72,7 +72,7 @@ subdir('src')
allegro_include = include_directories('include')
loadpng_include = include_directories('addons/loadpng')
-loadpng_dependencies = [dependency('libpng')]
+loadpng_dependencies = [dependency('libpng'), dependency('tracy')]
loadpng_sources = []
subdir('addons/loadpng')
@@ -80,7 +80,7 @@ subdir('addons/loadpng')
compiler = meson.get_compiler('c')
if compiler.get_argument_syntax() == 'gcc'
- c_args = ['-Wno-deprecated-declarations']
+ c_args = ['-Wno-deprecated-declarations', '-DTRACY_ENABLE']
else
endif
allegro_args = ['-DALLEGRO_NO_COMPATIBILITY']
@@ -88,8 +88,9 @@ allegro_lib = []
loadpng_lib = []
if not get_option('use_prebuilt_libraries') or host_machine.system() in ['darwin', 'linux']
- allegro = static_library('allegro', sources: allegro_sources, include_directories: allegro_include, c_args: [c_args, allegro_defines])
- loadpng = static_library('loadpng', sources: loadpng_sources, dependencies: loadpng_dependencies, include_directories: allegro_include)
+ tracy = dependency('tracy')
+ allegro = static_library('allegro', sources: allegro_sources, dependencies: tracy, include_directories: allegro_include, c_args: [c_args, allegro_defines])
+ loadpng = static_library('loadpng', sources: loadpng_sources, dependencies: loadpng_dependencies, include_directories: allegro_include)
else
allegro = []
loadpng = []
diff --git a/external/sources/allegro 4.4.3.1-custom/src/bmp.c b/external/sources/allegro 4.4.3.1-custom/src/bmp.c
index c456a72eb1..35349f9878 100644
--- a/external/sources/allegro 4.4.3.1-custom/src/bmp.c
+++ b/external/sources/allegro 4.4.3.1-custom/src/bmp.c
@@ -827,9 +827,9 @@ int save_bmp_pf(PACKFILE *f, BITMAP *bmp, AL_CONST RGB *pal)
/* palette */
for (i=0; i<256; i++) {
- pack_putc(_rgb_scale_6[pal[i].b], f);
- pack_putc(_rgb_scale_6[pal[i].g], f);
- pack_putc(_rgb_scale_6[pal[i].r], f);
+ pack_putc(pal[i].b, f);
+ pack_putc(pal[i].g, f);
+ pack_putc(pal[i].r, f);
pack_putc(0, f);
}
}
diff --git a/external/sources/allegro 4.4.3.1-custom/src/c/cblit.h b/external/sources/allegro 4.4.3.1-custom/src/c/cblit.h
index 912f009c8b..5f9205c5d6 100644
--- a/external/sources/allegro 4.4.3.1-custom/src/c/cblit.h
+++ b/external/sources/allegro 4.4.3.1-custom/src/c/cblit.h
@@ -33,6 +33,7 @@
#include
#endif
+#include "tracy/TracyC.h"
/* _linear_clear_to_color:
@@ -40,12 +41,21 @@
*/
void FUNC_LINEAR_CLEAR_TO_COLOR(BITMAP *dst, int color)
{
+ TracyCZone(clear, 1);
int x, y;
- int w;
+ int w, h;
ASSERT(dst);
+
w = dst->cr - dst->cl;
+ h = dst->cb - dst->ct;
+
+ if (!is_sub_bitmap(dst) && (color == 0 || PP_DEPTH == 8) && w == dst->w && h == dst->h) {
+ memset(dst->dat, color, dst->w * dst->h * PP_DEPTH / 8);
+ TracyCZoneEnd(clear);
+ return;
+ }
bmp_select(dst);
@@ -53,11 +63,12 @@ void FUNC_LINEAR_CLEAR_TO_COLOR(BITMAP *dst, int color)
PIXEL_PTR d = OFFSET_PIXEL_PTR(bmp_write_line(dst, y), dst->cl);
for (x = w - 1; x >= 0; INC_PIXEL_PTR(d), x--) {
- PUT_PIXEL(d, color);
+ PUT_PIXEL(d, color);
}
}
bmp_unwrite_line(dst);
+ TracyCZoneEnd(clear);
}