|
LibGame
v0.4.0
The LG Game Engine - Copyright (C) 2024-2025 ETMSoftware
|
6 #ifndef LG_SHADER_PROGS_H
7 #define LG_SHADER_PROGS_H
9 #define LG_INVALID_SHADER_PROG_ID 500000
22 int model_view_proj_m;
34 const char *attrib_name;
35 uint32_t num_components;
37 zboolean do_normalize;
39 void *first_component_offset;
42 #define VAP_END {-1, NULL, 0, 0, 0, 0, NULL}
44 #define CHECK_GL_E lg_check_gl_errors(lg_log_time(), __FILE__ , __LINE__, __func__)
46 #define CHECK_GL_E_2 {if (lg_check_gl_errors(lg_log_time(), __FILE__, __LINE__, __func__) != LG_OK) exit(-1);}
48 #define STH_WRONG_HERE \
52 INFO_OUT("VARO TÄSSÄ\n%s [%s: %d] %s(): jotain pitää korjata\n", UTF8_RW_ROUNDED_ARROW, __FILE__, __LINE__, __func__) \
Definition: lg_shader_progs.h:32
int lg_check_gl_errors(long long log_time, const char *file, int line, const char *func)
Definition: lg_shader_progs.c:286
Definition: lg_shader_progs.h:11
Definition: lg_shader_progs.h:16
int LG_ShaderProg_get_attrib_loc(LG_ShaderProg *shader_prog, const char *attrib_name)
Definition: lg_shader_progs.c:209
int LG_ShaderProg_get_uniform_loc(LG_ShaderProg *shader_prog, const char *uniform_name)
Definition: lg_shader_progs.c:237
void lg_shader_info_log(uint32_t shader)
Definition: lg_shader_progs.c:320
LG_ShaderProg LG_ShaderProg_create(const char **vertex_shader_code, const char **fragment_shader_code, LG_VAP_params *params)
Definition: lg_shader_progs.c:63
void LG_ShaderProg_use(LG_ShaderProg *shader_prog, zboolean gl_checking)
Definition: lg_shader_progs.c:182
uint32_t lg_load_shader(int type, const char **shader_code)
Definition: lg_shader_progs.c:256
void LG_ShaderProg_delete(LG_ShaderProg *shader_prog)
Definition: lg_shader_progs.c:167