aboutsummaryrefslogtreecommitdiff
path: root/src/raylib.h
diff options
context:
space:
mode:
authorJoshua Reisenauer <kd7tck@msn.com>2016-05-11 18:15:46 -0700
committerJoshua Reisenauer <kd7tck@msn.com>2016-05-11 18:15:46 -0700
commit529d20ee6a29528a0da456be4f08eb7caa56df21 (patch)
tree8dc4d3a0ca894390ab018f961342d5fbc5d570d7 /src/raylib.h
parentad3d270c429844462f3fd62fa12257760fac24b5 (diff)
parent6acfda599e5353b1c90bb11329ce50632851b1f5 (diff)
downloadraylib-529d20ee6a29528a0da456be4f08eb7caa56df21.tar.gz
raylib-529d20ee6a29528a0da456be4f08eb7caa56df21.zip
Merge remote-tracking branch 'refs/remotes/raysan5/develop' into newaudio
Diffstat (limited to 'src/raylib.h')
-rw-r--r--src/raylib.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/raylib.h b/src/raylib.h
index b9390d31..a6507906 100644
--- a/src/raylib.h
+++ b/src/raylib.h
@@ -368,18 +368,20 @@ typedef struct BoundingBox {
// Vertex data definning a mesh
typedef struct Mesh {
- int vertexCount; // num vertices
+ int vertexCount; // number of vertices stored in arrays
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 *texcoords2; // vertex second texture coordinates (useful for lightmaps) (shader-location = 5)
float *normals; // vertex normals (XYZ - 3 components per vertex) (shader-location = 2)
float *tangents; // vertex tangents (XYZ - 3 components per vertex) (shader-location = 4)
unsigned char *colors; // vertex colors (RGBA - 4 components per vertex) (shader-location = 3)
+ unsigned short *indices; // vertex indices (in case vertex data comes indexed)
+ int triangleCount; // number of triangles to draw
BoundingBox bounds; // mesh limits defined by min and max points
unsigned int vaoId; // OpenGL Vertex Array Object id
- unsigned int vboId[6]; // OpenGL Vertex Buffer Objects id (6 types of vertex data)
+ unsigned int vboId[7]; // OpenGL Vertex Buffer Objects id (7 types of vertex data)
} Mesh;
// Shader type (generic shader)
@@ -813,6 +815,7 @@ void SetModelTexture(Model *model, Texture2D texture); // Link a textur
Material LoadMaterial(const char *fileName); // Load material data (from file)
Material LoadDefaultMaterial(void); // Load default material (uses default models shader)
+void UnloadMaterial(Material material); // Unload material textures from VRAM
void DrawModel(Model model, Vector3 position, float scale, Color tint); // Draw a model (with texture if set)
void DrawModelEx(Model model, Vector3 position, Vector3 rotationAxis, float rotationAngle, Vector3 scale, Color tint); // Draw a model with extended parameters