The Persistence of Vision Raytracer (POV-Ray).
This is the legacy Bug Tracking System for the POV-Ray project. Bugs listed here are being migrated to our github issue tracker. Please refer to that for new reports or updates to existing ones on this system.
Opened by Christoph Lipka - 2010-05-14
Last edited by Christoph Lipka - 2010-08-21
FS#113 - Multi-layered reflections broken
Reflections in multi-layered textures are broken in 3.7 betas, as can be demonstrated with the following scene showing two reflective hemispheres on a checkered plane:
camera { location <1.0, 0.5, -4.0> direction 1.5*z right x*image_width/image_height look_at <0.0, 0.0, 0.0> } sky_sphere { pigment { gradient y color_map { [0.0 rgb <0.6,0.7,1.0>] [0.7 rgb <0.0,0.1,0.8>] } } } light_source { <0, 0, 0> // light's position (translated below) color rgb <1, 1, 1> // light's color translate <-30, 30, -30> } default { finish { diffuse 0 ambient 0 specular 0 } } // ---------------------------------------- plane { // checkered floor y, -1 texture { pigment { checker color rgb 1 color blue 1 } finish{ diffuse 0.8 ambient 0.1 } } } // left hemisphere intersection { sphere { 0, 1 } plane { x, -0.002 } texture { pigment { color rgb 1 } finish{ reflection { 0.5 } } } texture { pigment { color rgbt 1 } finish{ reflection { 0.4 } } } texture { pigment { color rgbt 1 } finish{ reflection { 0.1 } } } } // right hemisphere intersection { sphere { 0, 1 } plane { -x, -0.002 } texture { pigment { color rgb 1 } finish{ reflection { 1.0 } } } }
Note that the reflection parameters of the left, multi-layered hemisphere sum up to 1.0, i.e. the same value as used in the single layer in the right hemisphere.
The first attached file (test_3.6.2.png), rendered with POV-Ray 3.6.2, shows the expected output: Both hemispheres appear to have the same reflectivity.
The second attached file (test_3.7.0.beta37a.png), rendered with POV-Ray 3.7.0.beta.37a, shows a much brighter left (multi-layered) sphere.
As it turns out, in order to get the expected result with POV-Ray 3.7.0.beta.37a, the reflectivity of each layer must be divided by 3, 2 and 1, respectively (which obviously does not sum up to 1.0):
... texture { pigment { color rgb 1 } finish{ reflection { 0.5 / 3 } } } texture { pigment { color rgbt 1 } finish{ reflection { 0.4 / 2 } } } texture { pigment { color rgbt 1 } finish{ reflection { 0.1 / 1 } } } ...
fixed with change #4983
Tested with beta 38 source, original scene looks now fine.