From b6d6b32a6f02965e1d088adaa6a0e051d620b878 Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Tue, 12 Apr 2011 14:09:46 -0400 Subject: Fix up translucency semantics and API. --- libdimension/sky_sphere.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'libdimension/sky_sphere.c') diff --git a/libdimension/sky_sphere.c b/libdimension/sky_sphere.c index 9643feb..0ea5fa3 100644 --- a/libdimension/sky_sphere.c +++ b/libdimension/sky_sphere.c @@ -58,14 +58,13 @@ dmnsn_initialize_sky_sphere(dmnsn_sky_sphere *sky_sphere) dmnsn_color dmnsn_sky_sphere_color(const dmnsn_sky_sphere *sky_sphere, dmnsn_vector d) { - dmnsn_color color = dmnsn_black; - color.trans = 1.0; + dmnsn_color color = dmnsn_clear; DMNSN_ARRAY_FOREACH (const dmnsn_pigment **, pigment, sky_sphere->pigments) { dmnsn_pigment_fn *pigment_fn = (*pigment)->pigment_fn; if (pigment_fn) { dmnsn_color sky = pigment_fn(*pigment, d); - color = dmnsn_color_add(dmnsn_color_filter(color, sky), sky); + color = dmnsn_apply_filter(color, sky); } } -- cgit v1.2.3