POV-Ray : Newsgroups : povray.general : Lotsa Photons (Literally!) Server Time
6 Nov 2024 16:31:49 EST (-0500)
  Lotsa Photons (Literally!) (Message 1 to 7 of 7)  
From: nomail
Subject: Lotsa Photons (Literally!)
Date: 21 May 2004 10:30:01
Message: <web.40ae1177d70920a7945ad0900@news.povray.org>
Hello

Here is the problem in it's briefest form.
I set POV-Ray rendering on a scene with photons and left it for about 7
hours.
When I came back I saw that it hadn't even started rendering yet, it was
just building photon maps.
Now this is the problem: It had built a photon map of about 1,500,000,000
photons. I stopped it at this point and looked through the code but I
couldn't see anything wrong. I tried running it again, but watched it this
time. After about 10 seconds it started rendering, but I hadn't changed any
code at all.

Why did this happen? Please tell me.

Thanks in advance!


Post a reply to this message

From: Ross
Subject: Re: Lotsa Photons (Literally!)
Date: 21 May 2004 13:40:21
Message: <40ae3f05$1@news.povray.org>
<nomail@nomail> wrote in message
news:web.40ae1177d70920a7945ad0900@news.povray.org...
> Hello
>
> Here is the problem in it's briefest form.
> I set POV-Ray rendering on a scene with photons and left it for about 7
> hours.
> When I came back I saw that it hadn't even started rendering yet, it was
> just building photon maps.
> Now this is the problem: It had built a photon map of about 1,500,000,000
> photons. I stopped it at this point and looked through the code but I
> couldn't see anything wrong. I tried running it again, but watched it this
> time. After about 10 seconds it started rendering, but I hadn't changed
any
> code at all.
>
> Why did this happen? Please tell me.
>
> Thanks in advance!
>
>

are you explicitly using "count" in photon global settings, or are you using
"spacing"? count will limit the number of photons, and spacing will use as
many as it needs(?). that's my naive understanding. i always use count.

http://www.povray.org/documentation/view/209/


Post a reply to this message

From: Ross
Subject: Re: Lotsa Photons (Literally!)
Date: 21 May 2004 13:44:34
Message: <40ae4002@news.povray.org>
>>I tried running it again, but watched it this
> > time. After about 10 seconds it started rendering, but I hadn't changed
> any
> > code at all.
> >

hah. glossed over this part of your message. nevermind my "count versus
spacing" message. though it might somehow be related, indirectly... or
something ;)


Post a reply to this message

From: Warp
Subject: Re: Lotsa Photons (Literally!)
Date: 21 May 2004 18:53:14
Message: <40ae885a@news.povray.org>
nomail@nomail wrote:
> Why did this happen? Please tell me.

  You have to specify "photons { target }" only in those objects which
are reflecting/refracting (and which you want to have caustics) and these
objects must not be infinite (such as planes).

  You do not specify "photons { target }" for objects which are not
reflecting/refracting nor those which are infinite. (If you *really*
need photons to be directly shot at an infinite object, you'll have
to make it finite by manually specifying a bounding box for it.)

  Having an infinite object being the target for photons is one reason
for the photon calculations to take forever.

-- 
#macro N(D)#if(D>99)cylinder{M()#local D=div(D,104);M().5,2pigment{rgb M()}}
N(D)#end#end#macro M()<mod(D,13)-6mod(div(D,13)8)-3,10>#end blob{
N(11117333955)N(4254934330)N(3900569407)N(7382340)N(3358)N(970)}//  - Warp -


Post a reply to this message

From: Christopher James Huff
Subject: Re: Lotsa Photons (Literally!)
Date: 23 May 2004 13:55:48
Message: <cjameshuff-286B3F.12561123052004@news.povray.org>
In article <40ae885a@news.povray.org>, Warp <war### [at] tagpovrayorg> 
wrote:

>   Having an infinite object being the target for photons is one reason
> for the photon calculations to take forever.

But note in this case that it is an intermittent problem...not a problem 
with the scene, but a bug somewhere. Something's either uninitialized or 
getting written over. Unfortunately, finding it is likely to be very 
difficult...the problem can be literally anywhere, and will behave 
differently on different machines. It might even be a bad piece of RAM 
in the affected system...but I think other people have reported similar 
things.

-- 
Christopher James Huff <cja### [at] earthlinknet>
http://home.earthlink.net/~cjameshuff/
POV-Ray TAG: <chr### [at] tagpovrayorg>
http://tag.povray.org/


Post a reply to this message

From: Warp
Subject: Re: Lotsa Photons (Literally!)
Date: 24 May 2004 09:08:35
Message: <40b1f3d3@news.povray.org>
Christopher James Huff <cja### [at] earthlinknet> wrote:
> But note in this case that it is an intermittent problem...not a problem 
> with the scene, but a bug somewhere.

  What do you mean?

  Certainly the photon code could be *improved* (eg. by adding a code
which refuses to take an infinite object as a target), but I don't
understand how it is buggy or system-dependant.

-- 
#macro N(D)#if(D>99)cylinder{M()#local D=div(D,104);M().5,2pigment{rgb M()}}
N(D)#end#end#macro M()<mod(D,13)-6mod(div(D,13)8)-3,10>#end blob{
N(11117333955)N(4254934330)N(3900569407)N(7382340)N(3358)N(970)}//  - Warp -


Post a reply to this message

From: Christopher James Huff
Subject: Re: Lotsa Photons (Literally!)
Date: 24 May 2004 13:22:22
Message: <cjameshuff-D69584.12224824052004@news.povray.org>
In article <40b1f3d3@news.povray.org>, Warp <war### [at] tagpovrayorg> 
wrote:

>   Certainly the photon code could be *improved* (eg. by adding a code
> which refuses to take an infinite object as a target), but I don't
> understand how it is buggy or system-dependant.

From the original message:
"I tried running it again, but watched it this time. After about 10 
seconds it started rendering, but I hadn't changed any code at all."

It spent over 7 hours collecting over a billion photons before being 
canceled. The next time, it spent a few seconds and rendered as it 
should have. That sort of nondeterministic behavior is almost always a 
sign of a bug.

And it shouldn't disallow infinite objects as photon targets...finite 
objects can take just as long, if their bounding box contains the light 
source. However, a warning may be in order for both these cases.

-- 
Christopher James Huff <cja### [at] earthlinknet>
http://home.earthlink.net/~cjameshuff/
POV-Ray TAG: <chr### [at] tagpovrayorg>
http://tag.povray.org/


Post a reply to this message

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