30 lines
751 B
C
30 lines
751 B
C
#pragma once
|
|
|
|
#include <stdint.h>
|
|
#include "include/glad/gl.h"
|
|
|
|
struct cw_vertex_array {
|
|
GLuint id;
|
|
};
|
|
|
|
struct cw_vertex_buffer {
|
|
GLuint id;
|
|
};
|
|
|
|
struct cw_index_buffer {
|
|
GLuint id;
|
|
};
|
|
|
|
// Vertex Array
|
|
void cw_vertex_array_init(struct cw_vertex_array *self);
|
|
void cw_vertex_array_deinit(struct cw_vertex_array *self);
|
|
void cw_vertex_array_bind(struct cw_vertex_array *self);
|
|
void cw_vertex_array_unbind(struct cw_vertex_array *self);
|
|
|
|
// Vertex Buffer
|
|
void cw_vertex_buffer_init(struct cw_vertex_buffer *self);
|
|
void cw_vertex_buffer_deinit(struct cw_vertex_buffer *self);
|
|
|
|
// Index Buffer
|
|
void cw_index_buffer_init(struct cw_index_buffer *self, uint32_t* indices, uint32_t count);
|
|
void cw_index_buffer_deinit(struct cw_index_buffer *self);
|