ShaderTool
0.1
Live tool for developing OpenGL shaders interactively
|
Macros | |
#define | UNUSED(a) (void)a |
Functions | |
GLFWwindow * | initialize_window (int width, int height) |
Initialize GLFW and OpenGL, and create a window. More... | |
unsigned int | initialize_vertices () |
Initialize the vertex array. More... | |
unsigned int | initialize_framebuffer (unsigned int *framebuffer, unsigned int *texture_color_buffer, unsigned int texture_width, unsigned int texture_height) |
Initialize a framebuffer and the associated texture. More... | |
void | framebuffer_size_callback (GLFWwindow *window, int width, int height) |
Callback to adjust the size of the viewport when the window is resized. More... | |
#define UNUSED | ( | a | ) | (void)a |
void framebuffer_size_callback | ( | GLFWwindow * | window, |
int | width, | ||
int | height | ||
) |
Callback to adjust the size of the viewport when the window is resized.
window | The current window. |
width | The new width. |
height | The new height. |
unsigned int initialize_framebuffer | ( | unsigned int * | framebuffer, |
unsigned int * | texture_color_buffer, | ||
unsigned int | texture_width, | ||
unsigned int | texture_height | ||
) |
Initialize a framebuffer and the associated texture.
framebuffer | The framebuffer ID to be initialized. |
texture_color_buffer | The texture ID to be initialized. |
texture_width | The width of the desired texture image. |
texture_height | The height of the desired texture image. |
unsigned int initialize_vertices | ( | ) |
Initialize the vertex array.
This functions defines a simple rectangle containing the whole viewport.
GLFWwindow* initialize_window | ( | int | width, |
int | height | ||
) |
Initialize GLFW and OpenGL, and create a window.
width | The width of the window to create. |
height | The height of the window to create. |
NULL
on error.