Further apply type aliases and cleanup includes

master
outfrost 2019-01-15 14:51:59 +01:00
parent 5b1f7e35a0
commit ba8e13fea6
5 changed files with 10 additions and 14 deletions

View File

@ -1,10 +1,10 @@
#include <GL/gl.h>
#include <assimp/scene.h>
#include <string.h>
#include <stdlib.h>
#include <stdio.h>
#include "assimp_types.h"
char* getGlInfoString() {
const char* glVersion = (const char*) glGetString(GL_VERSION);
const char* glslVersion = (const char*) glGetString(GL_SHADING_LANGUAGE_VERSION);
@ -25,7 +25,7 @@ char* getGlInfoString() {
return glInfoString;
}
void dumpScene(FILE* stream, const struct aiScene* scene) {
void dumpScene(FILE* stream, const AiScene* scene) {
if (scene == NULL) {
fprintf(stream, "NULL");
return;
@ -45,7 +45,7 @@ void dumpScene(FILE* stream, const struct aiScene* scene) {
(void*) (*scene).mLights);
}
void dumpNode(FILE* stream, const struct aiNode* node) {
void dumpNode(FILE* stream, const AiNode* node) {
if (node == NULL) {
fprintf(stream, "NULL");
return;

View File

@ -1,12 +1,12 @@
#ifndef DEBUGUTIL_H_
#define DEBUGUTIL_H_
#include <assimp/scene.h>
#include <stdio.h>
#include "assimp_types.h"
char* getGlInfoString();
void dumpScene(FILE* stream, const struct aiScene* scene);
void dumpNode(FILE* stream, const struct aiNode* node);
void dumpScene(FILE* stream, const AiScene* scene);
void dumpNode(FILE* stream, const AiNode* node);
#endif

View File

@ -24,7 +24,7 @@ void setImage(TgaImage* image) {
}
const AiScene* importScene(const char* path) {
const struct aiScene* scene = aiImportFile(path, 0u);
const AiScene* scene = aiImportFile(path, 0u);
if (scene == NULL) {
fprintf(stderr, "Asset import failed at file %s\n", path); // TODO factor logging the heck outta here
}

View File

@ -1,11 +1,9 @@
#include <GL/glut.h>
#include "assimp_types.h"
#include "level.h"
#include "render.h"
#include "typedefs.h"
#include "performance.h"
#include "render.h"
const float AXIS_RADIUS = 5.0f;

2
tga.c
View File

@ -1,5 +1,3 @@
#include <GL/gl.h>
#include <stdlib.h>
#include <stdio.h>