aboutsummaryrefslogtreecommitdiff
path: root/src/model.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/model.c')
-rw-r--r--src/model.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/model.c b/src/model.c
index 1432f62..bf5512e 100644
--- a/src/model.c
+++ b/src/model.c
@@ -72,9 +72,9 @@ static Model *model_new(const char *name) {
}
-static Primitive *model_add_primitive(Model *model, GLenum type, GLfloat *vertices, GLfloat *normals, GLfloat *texcoords,
- int n, PrimitiveAttrib attribs, GLfloat r, GLfloat g, GLfloat b, char *texture,
- GLfloat radius, GLfloat shininess, int vbos) {
+static Primitive *model_add_primitive(Model *model, GLenum type, GLfloat *vertices, GLfloat *normals,
+ GLfloat *texcoords, int n, PrimitiveAttrib attribs, GLfloat r, GLfloat g,
+ GLfloat b, char *texture, GLfloat radius, GLfloat shininess, int vbos) {
Primitive *p;
@@ -153,7 +153,8 @@ static Primitive *model_add_primitive(Model *model, GLenum type, GLfloat *vertic
}
-static void model_calculate_normals(GLfloat *vertices, GLfloat *normals, int first, int last, int centre, int v1, int v2) {
+static void model_calculate_normals(GLfloat *vertices, GLfloat *normals, int first, int last, int centre,
+ int v1, int v2) {
GLfloat ax, ay, az;
GLfloat bx, by, bz;
@@ -238,7 +239,8 @@ static int model_load(ModelContext *ctx, const char *name, RenderContext *render
if ( line[0] == '\n' ) {
if ( num_vertices > 0 ) {
model_add_primitive(model, type, vertices, normals, texcoords, num_vertices,
- attribs, col_r, col_g, col_b, texture, radius, shininess, render->vbos);
+ attribs, col_r, col_g, col_b, texture, radius, shininess,
+ render->vbos);
num_vertices = 0;
type = PRIMITIVE_TRIANGLES;
attribs = ATTRIB_NONE;