src/graphics/init.c File Referencesrc/graphics/init.cgraphics - initialization and graphic stack management #include "../../include/graphics.h"#include "../../include/parse.h"#include "../../include/util.h"Macros #define TEST 0Functions int graphics_init (void *error_buffer)Initializes graphical stack. bool graphics_shutdown (const int id, void *error_buffer)Shutdowns a gl_area. void graphics_model_setup (const int stack_id)TODO #pragma omp parallel schedule(static, 12) void attribute((optimize("no-unroll-loops"))) main_test_graphics (void) {}. void graphics_init_buffers (const int stack_id)Initializes the buffer of a gl_area Calls according to the user preferences. bool graphics_init_shaders (const int stack_id)Initializes the shaders of a gl_area and link them to a program. Variables struct graphics_stack_t * graphics_stack = NULLphantom documentation used to test the functioning of doxygen size_t graphics_stack_size = 0int * free_stack_slot = NULLsize_t free_stack_slot_size = 0Detailed Descriptiongraphics - initialization and graphic stack management This file is part of Gem-graph. Function Documentationgraphics_init()graphics_initinit.cinit.cgraphics_initint graphics_init (void * error_buffer)Initializes graphical stack. Initializes a gl_area.
Parameters
gl_area, ptrto the gl_area widget
Returnsid if initialized graphics_init_buffers()graphics_init_buffersinit.cinit.cgraphics_init_buffersvoid graphics_init_buffers (const int stack_id)Initializes the buffer of a gl_area Calls according to the user preferences.
Parameters
gl_area, ptrto the gl_area widget
Returnsvoid graphics_init_shaders()graphics_init_shadersinit.cinit.cgraphics_init_shadersbool graphics_init_shaders (const int stack_id)Initializes the shaders of a gl_area and link them to a program.
Parameters
gl_area, ptrto the gl_area widget
Returnstrue if initialized graphics_model_setup()graphics_model_setupinit.cinit.cgraphics_model_setupvoid graphics_model_setup (const int stack_id)TODO #pragma omp parallel schedule(static, 12) void attribute((optimize("no-unroll-loops"))) main_test_graphics (void) {}. assert : space dimensions (x,y,z) > 0 assert : arrows localization within space and sites assert : no more than one arrow per address notify : weights are replaced, NOT added (could be !)Init space and arrows (= initial state) and allows ulterior creations, suppressions or modifications of the arrows[] arraydraws the space() triggers graphics_set_arrows() that modifies the list () and draws arrowsInitialisation du générateur pseudo-aléatoire Attention, les vertex centraux de chaque unité d'espace (cube) peuvent être redondants (max 6) graphics_shutdown()graphics_shutdowninit.cinit.cgraphics_shutdownbool graphics_shutdown (const int id, void * error_buffer)Shutdowns a gl_area. Draws the current buffer to a gl_area.
Parameters
gl_area, ptrto the gl_area widget
Returnstrue if success Variable Documentationgraphics_stackgraphics_stackinit.cinit.cgraphics_stackstruct graphics_stack_t* graphics_stack = NULLphantom documentation used to test the functioning of doxygen Dynamic array of ptrs to dynamically allocated gl_area_entry.