POV-Ray : Newsgroups : povray.unofficial.patches : Bugs in UVPov 6.1 Server Time
2 Sep 2024 18:15:29 EDT (-0400)
  Bugs in UVPov 6.1 (Message 1 to 3 of 3)  
From: Mark Wagner
Subject: Bugs in UVPov 6.1
Date: 10 Nov 1999 00:11:15
Message: <3828fe73@news.povray.org>
The following scene demonstrates several bugs in UVPov 6.1

As is, only 7 photons are shot while rendering the image, and none are
stored.  If you add the line "falloff 1" to the cylinder light and increase
the
radius of the media sphere to 50, only 7 photons are shot, and none are
stored.  If you increase the radius of the media-containing sphere to 50,
so that it encloses both the camera and the light source, plenty of photons
are shot, but no photons are stored in the scattering media, even though
I specified that UVPov should do so.  Removing the ground plane causes
photons to be stored in the media.

Mark

/////////////////////////////////////////////////////////
plane{y, 0 pigment{ checker color rgb 1, color rgb .5} }

camera{location 11 look_at 0}

#declare phd = 1;
global_settings{
max_trace_level 20
photons{
  gather 20, 100
  radius .1*phd, 2, .1*phd
  autostop 0
  jitter .2
  expand_thresholds 0.2, 40
  max_trace_level 20
  max_media_steps 100
}
}

light_source{ 
x*50 rgb <1,0,0>
cylinder
radius .1
point_at <0,0,0>
}

box{<-2,0,-.1>,<2,1,0>
pigment{rgb 1}
finish{ambient 0 diffuse 0 reflection 1}
rotate y*-45
photons{
  separation 0.005*phd
  refraction off
  reflection on
}
}

difference{
cylinder{0, y*2, 10}
cylinder{y*-.1, y*2.1, 9.9}
box{<10.01, -.001, -1>,<9.5, 2.02, 1>}
pigment{rgb 1}
finish{
  ambient .1
  diffuse 1
}
}

sphere{ //Media to scatter light
0, 11
pigment{rgbt 1}
finish{ambient 0 diffuse 0}
hollow
interior{
  ior 1
  media{
   scattering{ 1, 1 extinction 0}
   method 3   
   intervals 1
   samples 1, 10
  }
}
}


Post a reply to this message

From: Nathan Kopp
Subject: Re: Bugs in UVPov 6.1
Date: 10 Nov 1999 23:11:54
Message: <382a420a@news.povray.org>
There is a bug in UVPov, but it's probably not exactly what you'd expect.
I'll paste in a modified version of your code that does show photons in
media.  The problem is that UVPov incorrectly handles cylinder lights.  It
does not shoot parallel rays, so the photons coming out of cylinder lights
act more like photons coming out of a spot light.  I thought I documented
this, but I guess I didn't.  The moral of the story is to use spot lights,
not cylinder lights.  I'll eventually fix cylinder lights.  Someday.

-Nathan

Ok, here's the changed scene, with comments:

// First, I added
plane{-y, 0 pigment{ checker color rgb 1, color rgb .5}}

camera{location 11 look_at 0}

#declare phd = 1;

global_settings{
max_trace_level 20
photons{
  gather 20, 100
  radius .1*phd, 2, .1*phd
  autostop 0
  jitter .2
  expand_thresholds 0.2, 40
  max_trace_level 20
  max_media_steps 100
}
}

/* VERY IMPORTANT:
I moved the light source up a bit so it is not exactly on the
surface of the plane.  It kept thinking that it was inside the
plane (which was non-hollow) and thus put no photons in
media.
*/
light_source{ 
x*50+.01*y rgb <1,0,0>
cylinder
radius .1
point_at <0,0,0>
}

box{<-2,0,-.1>,<2,1,0>
pigment{rgb 1}
finish{ambient 0 diffuse 0 reflection 1}
rotate y*-45
photons{
  separation 0.05*phd  // changed to a more reasonable number
  refraction off
  reflection on
}
}

difference{
cylinder{0, y*2, 10}
cylinder{y*-.1, y*2.1, 9.9}
box{<10.01, -.001, -1>,<9.5, 2.02, 1>}
pigment{rgb 1}
finish{
  ambient .1
  diffuse 1
}
}

sphere{ // Media to scatter light
0, 11
pigment{rgbt 1}
finish{ambient 0 diffuse 0}
hollow
interior{
  ior 1
  media{
   scattering{ 1, 1 extinction 0}
   method 3   
   intervals 1
   samples 20,20
/* increased the samples.  One sample and one interval just don't
cut it.  You'll miss everything interesting that way.  Don't forget that
method 3 _ignores_ the max_samples number and only pays attention
to min_samples */
  }
}
photons{photo
ns_pass_through}
/* photons_pass_through was added so that photons go through this
media-containing object on their way to the mirror.  Otherwise, when they
don't hit the target object (they hit this instead) they are discarded */
}


Post a reply to this message

From: Mark Wagner
Subject: Re: Bugs in UVPov 6.1
Date: 11 Nov 1999 00:16:48
Message: <382a5140@news.povray.org>
Nathan Kopp wrote in message <382a420a@news.povray.org>...
>There is a bug in UVPov, but it's probably not exactly what you'd expect.
>I'll paste in a modified version of your code that does show photons in
>media.  The problem is that UVPov incorrectly handles cylinder lights.  It
>does not shoot parallel rays, so the photons coming out of cylinder lights
>act more like photons coming out of a spot light.  I thought I documented
>this, but I guess I didn't.  The moral of the story is to use spot lights,
>not cylinder lights.  I'll eventually fix cylinder lights.  Someday.
>


Thanks

Mark


Post a reply to this message

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