POV-Ray : Newsgroups : povray.general : Can intensity of light be returned in Pov-Ray? Server Time
29 Jul 2024 22:31:00 EDT (-0400)
  Can intensity of light be returned in Pov-Ray? (Message 1 to 8 of 8)  
From: TC
Subject: Can intensity of light be returned in Pov-Ray?
Date: 31 May 2010 15:25:01
Message: <4c040d0d$1@news.povray.org>
Well, subject says it all. Is there a way to return the intensity of light 
in Pov-Ray?

I mean like the trace-function, but return a light-intensity I(x,y,z)?

I realize that one first has to compute the scene, so I suppose there is no 
easy way to do this. Is there a complicated way?


Post a reply to this message

From: Warp
Subject: Re: Can intensity of light be returned in Pov-Ray?
Date: 31 May 2010 15:35:17
Message: <4c040f75@news.povray.org>
TC <do-not-reply@i-do get-enough-spam-already-2498.com> wrote:
> Is there a complicated way? 

  Patch the source code?

-- 
                                                          - Warp


Post a reply to this message

From: TC
Subject: Re: Can intensity of light be returned in Pov-Ray?
Date: 31 May 2010 21:27:48
Message: <4c046214@news.povray.org>
>  Patch the source code?

I did not really want to spend the next few years studying the pov-ray 
source... but probably the only solution.

Changing some of the source-code might be interesting, though. I always 
thought a built-in physics-engine would have been nice, but I fear 
implementing it would probably be the work of a lifetime and very probably 
beyond my skills.

To know the amount of light at a certain point in space would allow to 
simulate heliotropic behaviour of plants. Ivy not just creeping up a wall 
but climbing towards the light. Yes, it can be achieved by using trace and 
common sense and lots of trials, too, but to have a mechanism for it would 
have been nice.


Post a reply to this message

From: Darren New
Subject: Re: Can intensity of light be returned in Pov-Ray?
Date: 31 May 2010 21:52:47
Message: <4c0467ef$1@news.povray.org>
TC wrote:
>>  Patch the source code?
> 
> I did not really want to spend the next few years studying the pov-ray 
> source... but probably the only solution.

Or, trace the image without the ivy, then use it as a pigment to guide the 
movement of the ivy in a second trace.

-- 
Darren New, San Diego CA, USA (PST)
    Ada - the programming language trying to avoid
    you literally shooting yourself in the foot.


Post a reply to this message

From: SharkD
Subject: Re: Can intensity of light be returned in Pov-Ray?
Date: 1 Jun 2010 11:50:48
Message: <4c052c58$1@news.povray.org>
Given direct lighting and a small number of light sources the 
calculations shouldn't be that difficult, or should they?


Mike


On 5/31/2010 3:35 PM, Warp wrote:
> TC<do-not-reply@i-do get-enough-spam-already-2498.com>  wrote:
>> Is there a complicated way?
>
>    Patch the source code?
>


Post a reply to this message

From: Christian Froeschlin
Subject: Re: Can intensity of light be returned in Pov-Ray?
Date: 1 Jun 2010 14:07:24
Message: <4c054c5c$1@news.povray.org>
TC wrote:

> I always thought a built-in physics-engine would have been nice

MegaPOV has a patch for mechanical simulations, in case this
is of interest to you.

> To know the amount of light at a certain point in space would allow
> to simulate heliotropic behaviour of plants. Ivy not just creeping up
> a wall but climbing towards the light.

Getting the light intensity at a point would not seem the
best choice for that even if possible. At least I don't think
heliotropic plants look for bright surfaces, they probably
target the light sources directly and you know where
those are in the scene anyway.

Actually I think the term heliotropic is reservered for plants
which actually turn towards the light actively, as opposed
to just growing towards the light.


Post a reply to this message

From: TC
Subject: Re: Can intensity of light be returned in Pov-Ray?
Date: 1 Jun 2010 14:44:30
Message: <4c05550e$1@news.povray.org>
"Christian Froeschlin" <chr### [at] chrfrde> schrieb im Newsbeitrag 
news:4c054c5c$1@news.povray.org...
> MegaPOV has a patch for mechanical simulations, in case this
> is of interest to you.

Thank you for this suggestion. Megapov seems to have come quite a long way 
ahead in the last few years.


Post a reply to this message

From: Reactor
Subject: Re: Can intensity of light be returned in Pov-Ray?
Date: 1 Jun 2010 16:25:01
Message: <web.4c056bbc869f17a7e6ccfb210@news.povray.org>
Darren New <dne### [at] sanrrcom> wrote:
> TC wrote:
> >>  Patch the source code?
> >
> > I did not really want to spend the next few years studying the pov-ray
> > source... but probably the only solution.
>
> Or, trace the image without the ivy, then use it as a pigment to guide the
> movement of the ivy in a second trace.
>
> --
> Darren New, San Diego CA, USA (PST)
>     Ada - the programming language trying to avoid
>     you literally shooting yourself in the foot.


Personally, I favor this choice - a grayscale light mapping of the surfaces
could be produced and used as a function to determine whether or not an area is
light or dark.  It is labor intensive, for sure, but it can be done.  Using
Megapov's proximity pattern also allows one to produce an ambient occlusion
pigment.  I have not tried this with a function, but if it works it will not
require the production of separate images (internal or external).

There was someone else's fastprox macro that used averaged object pigments to
produce a form of feature detection - corner detection for structures and large
objects could be drawn from this without much difficulty.  Of course, this would
again be a form of ambient occlusion, which may not always be accurate in a
given setup.  However, the nice thing about this is that you can introduce
objects into your ao/light map that do not have an actual scene presence.  These
objects can be used to make your light map more accurate, or manipulate it for
dramatic effect, etc.


-Reactor


Post a reply to this message

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