Gamma correction corrected....
This commit is contained in:
@@ -228,7 +228,9 @@ generate_member_ui_imgui :: (type: *Type_Info_Struct, builder: *String_Builder,
|
||||
} else if info_struct.name == "Vector3" {
|
||||
print_to_builder(builder, "\tImGui.DragFloat3(tprint_c(\"%\"), *e.%.component);\n", new_path, new_path);
|
||||
} else if info_struct.name == "Color" || info_struct.name == "Vector4" {
|
||||
print_to_builder(builder, "\tImGui.ColorEdit4(tprint_c(\"%\"), *e.%.component);\n", new_path, new_path);
|
||||
print_to_builder(builder, "\tsrgb_color := linear_to_srgb(e.%);\n", new_path);
|
||||
print_to_builder(builder, "\tImGui.ColorEdit4(tprint_c(\"%\"), *srgb_color.component);\n", new_path);
|
||||
print_to_builder(builder, "\te.% = srgb_to_linear(srgb_color);\n", new_path);
|
||||
} else {
|
||||
generate_member_ui_imgui(info_struct, builder, new_path);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user