POV-Ray : Newsgroups : povray.general : solution for shadow line artifact Server Time
5 Aug 2024 10:21:14 EDT (-0400)
  solution for shadow line artifact (Message 1 to 1 of 1)  
From: Sascha Ledinsky
Subject: solution for shadow line artifact
Date: 16 Oct 2002 05:39:14
Message: <3dad33c2$1@news.povray.org>
Here's something that might be a solution for the shadow line artifact
problem seen in normal modified patterns (see Pov-Ray documentation chapter
9.8)
The only solution I can think of is to somhow disable self-shadowing.
Here's what I've found out...
-Using 'no_shadow' is inacceptable because this not only stops self
shadowing but turns off shadows of the object completely.
-Using a 'shadowless' lightsource is also inacceptable because it doesn't
produce highlights (?!)
-Light groups don't control the shadows (?!)
Well, here's a strange solution that seems to work...

/*-----------------------------------*/
#default
{
    pigment { color rgb <1,1,1> }
    finish { ambient 0.1 diffuse 0.9}
}

camera
{
    location <0,1,-2>
    look_at <0,0.7,0>
}

light_source
{
    <-100,100,0>
    color rgb <1,1,1>
}

#declare tx = texture
{
    normal { bumps 1 scale 0.05 }
    finish
    {
        ambient 0.1
        diffuse 0.9
        specular 0.3 roughness 0.1
    }
}

#declare ob = union
{
    sphere { <0,1,0>,0.5 }
    cylinder { <0,1,0>,<0,0,0>,0.3 }
    torus { 0.5,0.05 translate <0,1,0> }
}

plane { y,0 }

object { ob texture{ tx } no_shadow }

object
{
    ob
    no_image
    pigment { transmit 1 }
    interior { fade_power 10000 fade_distance 0.0001 }
}

/*-----------------------------------*/

It uses the same object twice, one for the image and one for the shadow.
Without the 'transmit 1' and fading it would still cast a shadow on the
visible object.
I don't know how 'stable' this method is, I haven't tested it with more
complex object yet.
Turning off light-buffers (-UL) messes up the shadows completely (don't know
why)

what do you think?


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.