44#ifndef __NILOREA_GUI_COLORWHEEL__
45#define __NILOREA_GUI_COLORWHEEL__
static void on_change(const float rgba[4], void *user_data)
the picker's callback
The top-level GUI context that holds all windows.
ALLEGRO_COLOR(* N_GUI_COLORWHEEL_COLOUR)(float u, float v, void *user_data)
The colour the disc shows for a point.
ALLEGRO_COLOR n_gui_colorwheel_hue(float u, float v, void *user_data)
The default disc colour: HSV, hue by angle with red to the right and going counter clockwise,...
int n_gui_colorwheel_get(N_GUI_CTX *ctx, int widget_id, float *u, float *v)
Read the point.
int n_gui_colorwheel_new(N_GUI_CTX *ctx, int window_id, float x, float y, float w, float h, N_GUI_COLORWHEEL_CHANGE on_change, void *user_data)
Add a colour wheel, its point in the centre.
void(* N_GUI_COLORWHEEL_CHANGE)(int widget_id, int dragging, void *user_data)
Called when the point moves.
void n_gui_colorwheel_set_colour(N_GUI_CTX *ctx, int widget_id, N_GUI_COLORWHEEL_COLOUR colour, void *user_data)
Paint the disc with the caller's colours.
int n_gui_colorwheel_set(N_GUI_CTX *ctx, int widget_id, float u, float v)
Set the point.
GUI system: buttons, sliders, text areas, checkboxes, scrollbars, dropdown menus, windows.