1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-07 12:30:27 +00:00

Add Linear SRGB and OKLab color spaces to Gradient.

This commit is contained in:
JoNax97
2023-04-23 22:22:45 -03:00
committed by Joaquin Muñiz
parent 2210111eb5
commit c07b2fcf4d
5 changed files with 142 additions and 20 deletions

View File

@@ -45,6 +45,7 @@ class GradientEditor : public Control {
int grabbed = -1;
Vector<Gradient::Point> points;
Gradient::InterpolationMode interpolation_mode = Gradient::GRADIENT_INTERPOLATE_LINEAR;
Gradient::ColorSpace interpolation_color_space = Gradient::GRADIENT_COLOR_SPACE_SRGB;
bool editing = false;
Ref<Gradient> gradient;
@@ -84,6 +85,9 @@ public:
void set_interpolation_mode(Gradient::InterpolationMode p_interp_mode);
Gradient::InterpolationMode get_interpolation_mode();
void set_interpolation_color_space(Gradient::ColorSpace p_color_space);
Gradient::ColorSpace get_interpolation_color_space();
ColorPicker *get_picker();
PopupPanel *get_popup();