Skip to content

Commit

Permalink
typedef ushort and define gl fallbacks in gltfloader
Browse files Browse the repository at this point in the history
  • Loading branch information
no-lex committed Jan 26, 2024
1 parent 3d5334e commit 5291fe3
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/engine/model/gltfloader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,26 @@
#include <cstdint>

typedef unsigned int uint;
typedef unsigned short ushort;

#include "gltfloader.h"

//for GL types (GL_FLOAT, GL_UNSIGNED_INT, etc.)
#include <GL/gl.h>

//these values should be loaded by gl.h, fallback if not defined
#ifndef GL_UNSIGNED_INT
#define GL_UNSIGNED_INT 5125
#endif
#ifndef GL_UNSIGNED_SHORT
#define GL_UNSIGNED_SHORT 5123
#endif
#ifndef GL_UNSIGNED_BYTE
#define GL_UNSIGNED_SHORT 5121
#endif
#ifndef GL_FLOAT
#define GL_FLOAT 5126
#endif

//populates the object vectors with the data in the gltf file
GLTFModelInfo::GLTFModelInfo(std::string_view path)
Expand Down

0 comments on commit 5291fe3

Please sign in to comment.