From 8a1097a2243a9829d5d7e61ef10133f8096aa5e2 Mon Sep 17 00:00:00 2001 From: Juan Linietsky Date: Fri, 2 Jun 2017 22:08:41 -0300 Subject: many fixes to image loader, voxel cone tracing, etc. --- scene/3d/gi_probe.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'scene/3d') diff --git a/scene/3d/gi_probe.cpp b/scene/3d/gi_probe.cpp index 3542b8b876..2acbed3b4e 100644 --- a/scene/3d/gi_probe.cpp +++ b/scene/3d/gi_probe.cpp @@ -909,10 +909,11 @@ Vector GIProbe::_get_bake_texture(Ref p_image, const Color &p_colo for (int i = 0; i < bake_texture_size * bake_texture_size; i++) { Color c; - c.r = r[i * 4 + 0] / 255.0; - c.g = r[i * 4 + 1] / 255.0; - c.b = r[i * 4 + 2] / 255.0; + c.r = (r[i * 4 + 0] / 255.0) * p_color.r; + c.g = (r[i * 4 + 1] / 255.0) * p_color.g; + c.b = (r[i * 4 + 2] / 255.0) * p_color.b; c.a = r[i * 4 + 3] / 255.0; + ret[i] = c; } -- cgit v1.2.3