|
atomes 1.2.1
atomes: an atomic scale modeling tool box
|
Functions to create the OpenGL parameters edition window. More...
#include "global.h"#include "interface.h"#include "preferences.h"#include "glview.h"#include "glwindow.h"
Include dependency graph for w_advance.c:Go to the source code of this file.
Functions | |
| void | set_quality (int q, glwin *view) |
| set OpenGL quality | |
| GtkWidget * | adv_box (GtkWidget *box, char *lab, int vspace, int size, float xalign) |
| create a box with markup label | |
| GtkWidget * | bdv_box (GtkWidget *box, char *lab, int size, float xalign) |
| create a box with markup label | |
| G_MODULE_EXPORT void | toggled_delete_ligth (GtkToggleButton *but, gpointer data) |
| toggle delete light callback GTK3 | |
| G_MODULE_EXPORT void | run_light_source_to_be_removed (GtkDialog *win, gint response_id, gpointer data) |
| remove light source(s) - running the dialog | |
| int * | light_source_to_be_removed (int val, Lightning *ogl_lightning, opengl_edition *ogl_edit) |
| remove light source(s) - creating the dialog | |
| void | print_light_source (Light source, int i) |
| print light source data | |
| Light | init_light_source (int type, float size, float depth) |
| initialize a light source | |
| Light | copy_light_source (Light old_sp) |
| create a copy of a light source | |
| Light * | copy_light_sources (int dima, int dimb, Light *old_sp) |
| create a copy of a list of light sources | |
| void | show_active_light_data (opengl_edition *ogl_win, int lid, int tid) |
| show active light data | |
| void | update_light_data (int li, opengl_edition *ogl_win) |
| update light data | |
| G_MODULE_EXPORT void | show_light_param (GtkComboBox *box, gpointer data) |
| update light parameters based on light id in combo box | |
| void | create_lights_combo (int num_lights, opengl_edition *ogl_win) |
| create light combo box | |
| void | add_remove_lights (int val, gpointer data) |
| add or remove lights | |
| G_MODULE_EXPORT void | set_nlights_spin (GtkSpinButton *res, gpointer data) |
| change the number of light(s) - spin button | |
| G_MODULE_EXPORT void | set_nlights (GtkEntry *res, gpointer data) |
| change the number of light(s) - entry | |
| G_MODULE_EXPORT void | update_light_param (GtkEntry *res, gpointer data) |
| update light parameter | |
| void | set_data_pos (vec3_t *vect, int pos, double v) |
| modify a vector component | |
| G_MODULE_EXPORT void | set_object_pos (GtkEntry *res, gpointer data) |
| set object position | |
| G_MODULE_EXPORT void | set_light_type (GtkComboBox *box, gpointer data) |
| set light type callback | |
| G_MODULE_EXPORT void | set_light_fix (GtkComboBox *box, gpointer data) |
| set light fix callback | |
| G_MODULE_EXPORT void | show_this_light (GtkToggleButton *but, gpointer data) |
| show / hide this light callback GTK3 | |
| GtkWidget * | create_setting_pos (gchar *lab, int size, float xalign, int pid, int lid, float *values, opengl_edition *ogl_win) |
| create OpenGL setting entries table | |
| GtkWidget * | lights_tab (glwin *view, opengl_edition *ogl_edit, Lightning *ogl_lightning) |
| OpenGL light(s) parameters tab. | |
| G_MODULE_EXPORT void | set_use_template_toggle (GtkToggleButton *but, gpointer data) |
| use or not OpenGL material template callback GTK3 | |
| G_MODULE_EXPORT void | set_template (GtkComboBox *box, gpointer data) |
| change the OpenGL material template | |
| G_MODULE_EXPORT void | set_l_model (GtkComboBox *box, gpointer data) |
| change OpenGL lightning model | |
| void | param_has_changed (gpointer data, double val) |
| update OpenGL material parameter | |
| G_MODULE_EXPORT void | update_mat_param (GtkEntry *res, gpointer data) |
| update OpenGL material parameter - entry | |
| G_MODULE_EXPORT gboolean | scroll_scale_param (GtkRange *range, GtkScrollType scroll, gdouble value, gpointer data) |
| update OpenGL material parameter - scroll callback | |
| G_MODULE_EXPORT void | scale_param (GtkRange *range, gpointer data) |
| update OpenGL material parameter - range callback | |
| G_MODULE_EXPORT gboolean | scroll_scale_quality (GtkRange *range, GtkScrollType scroll, gdouble value, gpointer data) |
| update OpenGL quality - scroll callback | |
| G_MODULE_EXPORT void | scale_quality (GtkRange *range, gpointer data) |
| update OpenGL quality - range callback | |
| GtkWidget * | lightning_fix (glwin *view, Material *this_material) |
| GtkWidget * | materials_tab (glwin *view, opengl_edition *ogl_edit, Material *the_mat) |
| OpenGL material parameters tab. | |
| void | fog_param_changed (gpointer data, GLfloat u, GtkRange *range) |
| update OpenGL fog parameter | |
| G_MODULE_EXPORT gboolean | scroll_set_fog_param (GtkRange *range, GtkScrollType scroll, gdouble value, gpointer data) |
| update OpenGL fog parameter - scroll callback | |
| G_MODULE_EXPORT void | set_fog_param (GtkRange *range, gpointer data) |
| update OpenGL fog parameter - range callback | |
| G_MODULE_EXPORT void | set_fog_type (GtkWidget *widg, gpointer data) |
| set OpenGL fog type | |
| void | setup_fog_dialogs (opengl_edition *ogl_edit, int fid) |
| update OpenGL fog tab based of fog type | |
| G_MODULE_EXPORT void | set_fog_mode (GtkWidget *widg, gpointer data) |
| set fog mode callback | |
| GtkWidget * | fog_tab (glwin *view, opengl_edition *ogl_edit, Fog *the_fog) |
| OpenGL fog parameters tab. | |
| void | close_advanced_opengl (gpointer data) |
| close OpenGL rendering window free data | |
| G_MODULE_EXPORT gboolean | close_advanced (GtkWidget *widg, GdkEvent *event, gpointer data) |
| close OpenGL rendering advanced window callback GTK3 | |
| G_MODULE_EXPORT void | opengl_advanced (GtkWidget *widg, gpointer data) |
| create OpenGL rendering advanced window | |
Variables | |
| gchar * | material_template [TEMPLATES] |
| GLfloat | template_parameters [TEMPLATES][5] |
| float | mat_min_max [5][2] |
| gchar * | ogl_settings [3][10] |
| gchar * | lpos [3] = {"x", "y", "z"} |
| gchar * | cpos [3] = {"r", "g", "b"} |
| GtkWidget * | d_close |
| int | status |
| int * | light_list |
| GtkWidget ** | light_but |
Functions to create the OpenGL parameters edition window.
Definition in file w_advance.c.
| void add_remove_lights | ( | int | val, |
| gpointer | data ) |
add or remove lights
| val | total number of light(s) |
| data | the associated data pointer |
Definition at line 555 of file w_advance.c.
| GtkWidget * adv_box | ( | GtkWidget * | box, |
| char * | lab, | ||
| int | vspace, | ||
| int | size, | ||
| float | xalign ) |
create a box with markup label
| box | the box to insert the widget in |
| lab | label |
| vspace | vertical space |
| size | size |
| xalign | x alignement |
Definition at line 151 of file w_advance.c.
| GtkWidget * bdv_box | ( | GtkWidget * | box, |
| char * | lab, | ||
| int | size, | ||
| float | xalign ) |
create a box with markup label
| box | the GtkWidget sending the signal |
| lab | label |
| size | size |
| xalign | x alignement |
Definition at line 169 of file w_advance.c.
| G_MODULE_EXPORT gboolean close_advanced | ( | GtkWidget * | widg, |
| GdkEvent * | event, | ||
| gpointer | data ) |
close OpenGL rendering advanced window callback GTK3
| widg | the GtkWidget sending the signal |
| event | the GdkEvent triggering the signal |
| data | the associated data pointer |
Definition at line 1655 of file w_advance.c.
| void close_advanced_opengl | ( | gpointer | data | ) |
close OpenGL rendering window free data
| data | the associated data pointer |
Definition at line 1627 of file w_advance.c.
create a copy of a light source
| old_sp | the light source to copy |
Definition at line 379 of file w_advance.c.
create a copy of a list of light sources
| dima | new list size |
| dimb | old list size to duplicate |
| old_sp | old light sources |
Definition at line 402 of file w_advance.c.
| void create_lights_combo | ( | int | num_lights, |
| opengl_edition * | ogl_win ) |
create light combo box
| num_lights | the target number of lights |
| ogl_win | the target OpenGL edition window |
Definition at line 531 of file w_advance.c.
| GtkWidget * create_setting_pos | ( | gchar * | lab, |
| int | size, | ||
| float | xalign, | ||
| int | pid, | ||
| int | lid, | ||
| float * | values, | ||
| opengl_edition * | ogl_win ) |
create OpenGL setting entries table
| lab | label to display |
| size | size of the label |
| xalign | x alignement |
| pid | parameter id (0 = material, 1 = light direction, 2 = light position, 3 = light intensity, 4 = fog) |
| lid | parameter label id |
| values | target parameter values |
| ogl_win | the target OpenGL edition window |
Definition at line 899 of file w_advance.c.
| void fog_param_changed | ( | gpointer | data, |
| GLfloat | u, | ||
| GtkRange * | range ) |
update OpenGL fog parameter
| data | the associated data pointer |
| u | the new value |
| range | the GtkRange to udapte if needed |
Definition at line 1397 of file w_advance.c.
| GtkWidget * fog_tab | ( | glwin * | view, |
| opengl_edition * | ogl_edit, | ||
| Fog * | the_fog ) |
OpenGL fog parameters tab.
| view | the target glwin |
| ogl_edit | the target OpenGL edition window |
| the_fog | the target fog data structure |
Definition at line 1566 of file w_advance.c.
| Light init_light_source | ( | int | type, |
| float | size, | ||
| float | depth ) |
initialize a light source
| type | the type of light |
| size | depth or max (a,b,c) |
| depth | field depth |
| intens |
Definition at line 337 of file w_advance.c.
| int * light_source_to_be_removed | ( | int | val, |
| Lightning * | ogl_lightning, | ||
| opengl_edition * | ogl_edit ) |
remove light source(s) - creating the dialog
| val | number of light(s) to remove |
| ogl_lightning | the target lightning data structure |
| ogl_edit | the target OpenGL edition window |
Definition at line 257 of file w_advance.c.
Definition at line 1296 of file w_advance.c.
| GtkWidget * lights_tab | ( | glwin * | view, |
| opengl_edition * | ogl_edit, | ||
| Lightning * | ogl_lightning ) |
OpenGL light(s) parameters tab.
| view | the target glwin |
| ogl_edit | the target OpenGL edition window |
| ogl_lightning | the target lightning data structure |
Definition at line 938 of file w_advance.c.
| GtkWidget * materials_tab | ( | glwin * | view, |
| opengl_edition * | ogl_edit, | ||
| Material * | the_mat ) |
OpenGL material parameters tab.
| view | the target glwin |
| ogl_edit | the target OpenGL edition window |
| the_mat | the target material data structure |
Definition at line 1323 of file w_advance.c.
| G_MODULE_EXPORT void opengl_advanced | ( | GtkWidget * | widg, |
| gpointer | data ) |
create OpenGL rendering advanced window
| widg | the GtkWidget sending the signal |
| data | the associated data pointer |
Definition at line 1670 of file w_advance.c.
| void param_has_changed | ( | gpointer | data, |
| double | val ) |
update OpenGL material parameter
| data | the associated data pointer |
| val | the new value |
Definition at line 1183 of file w_advance.c.
| void print_light_source | ( | Light | source, |
| int | i ) |
print light source data
| source | the light source |
| i | the light source id |
Definition at line 297 of file w_advance.c.
| G_MODULE_EXPORT void run_light_source_to_be_removed | ( | GtkDialog * | win, |
| gint | response_id, | ||
| gpointer | data ) |
remove light source(s) - running the dialog
| win | the GtkDialog sending the signal |
| response_id | the response id |
| data | the associated data pointer |
Definition at line 232 of file w_advance.c.
| G_MODULE_EXPORT void scale_param | ( | GtkRange * | range, |
| gpointer | data ) |
update OpenGL material parameter - range callback
| range | the GtkRange sending the signal |
| data | the associated data pointer |
Definition at line 1248 of file w_advance.c.
| G_MODULE_EXPORT void scale_quality | ( | GtkRange * | range, |
| gpointer | data ) |
update OpenGL quality - range callback
| range | the GtkRange sending the signal |
| data | the associated data pointer |
Definition at line 1280 of file w_advance.c.
| G_MODULE_EXPORT gboolean scroll_scale_param | ( | GtkRange * | range, |
| GtkScrollType | scroll, | ||
| gdouble | value, | ||
| gpointer | data ) |
update OpenGL material parameter - scroll callback
| range | the GtkRange sending the signal |
| scroll | the associated scroll type |
| value | the range value |
| data | the associated data pointer |
Definition at line 1234 of file w_advance.c.
| G_MODULE_EXPORT gboolean scroll_scale_quality | ( | GtkRange * | range, |
| GtkScrollType | scroll, | ||
| gdouble | value, | ||
| gpointer | data ) |
update OpenGL quality - scroll callback
| range | the GtkRange sending the signal |
| scroll | the associated scroll type |
| value | the range value |
| data | the associated data pointer |
Definition at line 1263 of file w_advance.c.
| G_MODULE_EXPORT gboolean scroll_set_fog_param | ( | GtkRange * | range, |
| GtkScrollType | scroll, | ||
| gdouble | value, | ||
| gpointer | data ) |
update OpenGL fog parameter - scroll callback
| range | the GtkRange sending the signal |
| scroll | the associated scroll type |
| value | the range value |
| data | the associated data pointer |
Definition at line 1456 of file w_advance.c.
| void set_data_pos | ( | vec3_t * | vect, |
| int | pos, | ||
| double | v ) |
modify a vector component
| vect | vector to adjust |
| pos | position to adjust |
| v | new value |
Definition at line 731 of file w_advance.c.
| G_MODULE_EXPORT void set_fog_mode | ( | GtkWidget * | widg, |
| gpointer | data ) |
set fog mode callback
| widg | the GtkWidget sending the signal |
| data | the associated data pointer |
Definition at line 1552 of file w_advance.c.
| G_MODULE_EXPORT void set_fog_param | ( | GtkRange * | range, |
| gpointer | data ) |
update OpenGL fog parameter - range callback
| range | the GtkRange sending the signal |
| data | the associated data pointer |
Definition at line 1470 of file w_advance.c.
| G_MODULE_EXPORT void set_fog_type | ( | GtkWidget * | widg, |
| gpointer | data ) |
set OpenGL fog type
| widg | the GtkWidget sending the signal |
| data | the associated data pointer |
Definition at line 1483 of file w_advance.c.
| G_MODULE_EXPORT void set_l_model | ( | GtkComboBox * | box, |
| gpointer | data ) |
change OpenGL lightning model
| box | the GtkComboBox sending the signal |
| data | the associated data pointer |
Definition at line 1161 of file w_advance.c.
| G_MODULE_EXPORT void set_light_fix | ( | GtkComboBox * | box, |
| gpointer | data ) |
set light fix callback
| box | the GtkComboBox sending the signal |
| data | the associated data pointer |
Definition at line 833 of file w_advance.c.
| G_MODULE_EXPORT void set_light_type | ( | GtkComboBox * | box, |
| gpointer | data ) |
set light type callback
| box | the GtkComboBox sending the signal |
| data | the associated data pointer |
Definition at line 817 of file w_advance.c.
| G_MODULE_EXPORT void set_nlights | ( | GtkEntry * | res, |
| gpointer | data ) |
change the number of light(s) - entry
| res | the GtkEntry sending the signal |
| data | the associated data pointer |
Definition at line 667 of file w_advance.c.
| G_MODULE_EXPORT void set_nlights_spin | ( | GtkSpinButton * | res, |
| gpointer | data ) |
change the number of light(s) - spin button
| res | the GtkSpinButton sending the signal |
| data | the associated data pointer |
Definition at line 654 of file w_advance.c.
| G_MODULE_EXPORT void set_object_pos | ( | GtkEntry * | res, |
| gpointer | data ) |
set object position
| res | the GtkEntry sending the signal |
| data | the associated data pointer |
Definition at line 755 of file w_advance.c.
|
extern |
set OpenGL quality
| q | new OpenGL quality |
| view | the target glwin |
Definition at line 60 of file m_quality.c.
| G_MODULE_EXPORT void set_template | ( | GtkComboBox * | box, |
| gpointer | data ) |
change the OpenGL material template
| box | the GtkComboBox sending the signal |
| data | the associated data pointer |
Definition at line 1113 of file w_advance.c.
| G_MODULE_EXPORT void set_use_template_toggle | ( | GtkToggleButton * | but, |
| gpointer | data ) |
use or not OpenGL material template callback GTK3
| but | the GtkToggleButton sending the signal |
| data | the associated data pointer |
Definition at line 1049 of file w_advance.c.
| void setup_fog_dialogs | ( | opengl_edition * | ogl_edit, |
| int | fid ) |
update OpenGL fog tab based of fog type
| ogl_edit | the target opengl_edition |
| fid | the fog mode |
Definition at line 1509 of file w_advance.c.
| void show_active_light_data | ( | opengl_edition * | ogl_win, |
| int | lid, | ||
| int | tid ) |
show active light data
| ogl_win | the target OpenGL edition window |
| lid | the light id |
| tid | the light type |
Definition at line 432 of file w_advance.c.
| G_MODULE_EXPORT void show_light_param | ( | GtkComboBox * | box, |
| gpointer | data ) |
update light parameters based on light id in combo box
| box | the GtkComboBox sending the signal |
| data | the associated data pointer |
Definition at line 517 of file w_advance.c.
| G_MODULE_EXPORT void show_this_light | ( | GtkToggleButton * | but, |
| gpointer | data ) |
show / hide this light callback GTK3
| but | the GtkToggleButton sending the signal |
| data | the associated data pointer |
Definition at line 875 of file w_advance.c.
| G_MODULE_EXPORT void toggled_delete_ligth | ( | GtkToggleButton * | but, |
| gpointer | data ) |
toggle delete light callback GTK3
| but | the GtkToggleButton sending the signal |
| data | the associated data pointer |
Definition at line 199 of file w_advance.c.
| void update_light_data | ( | int | li, |
| opengl_edition * | ogl_win ) |
update light data
| li | the light id |
| ogl_win | the target OpenGL edition window |
Definition at line 474 of file w_advance.c.
| G_MODULE_EXPORT void update_light_param | ( | GtkEntry * | res, |
| gpointer | data ) |
update light parameter
| res | the GtkEntry sending the signal |
| data | the associated data pointer |
Definition at line 684 of file w_advance.c.
| G_MODULE_EXPORT void update_mat_param | ( | GtkEntry * | res, |
| gpointer | data ) |
update OpenGL material parameter - entry
| res | the GtkEntry sending the signal |
| data | the associated data pointer |
Definition at line 1217 of file w_advance.c.
| gchar* cpos[3] = {"r", "g", "b"} |
Definition at line 138 of file w_advance.c.
| GtkWidget* d_close |
Definition at line 177 of file w_advance.c.
| GtkWidget** light_but |
Definition at line 221 of file w_advance.c.
| int* light_list |
Definition at line 220 of file w_advance.c.
| gchar* lpos[3] = {"x", "y", "z"} |
Definition at line 137 of file w_advance.c.
| float mat_min_max[5][2] |
Definition at line 113 of file w_advance.c.
| gchar* material_template[TEMPLATES] |
Definition at line 97 of file w_advance.c.
| gchar* ogl_settings[3][10] |
Definition at line 119 of file w_advance.c.
| int status |
Definition at line 178 of file w_advance.c.
| GLfloat template_parameters[TEMPLATES][5] |
Definition at line 105 of file w_advance.c.