POV-Ray : Newsgroups : povray.advanced-users : Shadow Shape Server Time
23 Dec 2024 03:07:22 EST (-0500)
  Shadow Shape (Message 1 to 4 of 4)  
From: Sereib
Subject: Shadow Shape
Date: 4 Jun 2012 11:05:00
Message: <web.4fcccdec18f6f84dabedaac80@news.povray.org>
Hello,

I work on a scene with an asteroid (isosurface) close to the earth (the
atmosphere and clouds are two separate scattering media). Both, the asteroid and
the clouds are very detailed, but render sufficiently fast if either the
asteroid or (!) the clouds are part of the scene, or the asteroid does not cast
its shadow over the clouds.

However, the rendering extremely slows down if the light source position moves
and the shadow of the asteroid hits the clouds. I assume the combination of
scattering media and isosurfaces casting their shadow on the scattering media
causes lots of extra calculations ...

Adding "no_shadow" to the asteroid object is no option, this deteriorates the
3D-appearance of the asteroid.

I could also switch from "scattering" to "emission" for the cloud media, but
this also looks less real.

Since the shadow on the clouds is almost invisible in this scene, it would be
more than enough if - for calculating the shadow on the clouds - the asteroid is
assumed to be just a sphere, or any other simple shape.

So it would be a great idea, to have a term like this:

object { ... shadow_lookslike{sphere{<x,y,z>,r}}}

which only holds for the calculation of shadows cast on any other object of the
scene, not for the object itself. The shadow it casts over itself should not be
affected.

I assume such a feature does not exist yet, what do you think about it?

Thank you in advance for your comments!


Post a reply to this message

From: Le Forgeron
Subject: Re: Shadow Shape
Date: 4 Jun 2012 12:06:05
Message: <4fccdced$1@news.povray.org>
Le 04/06/2012 17:02, Sereib nous fit lire :
> Hello,
> 
> I work on a scene with an asteroid (isosurface) close to the earth (the
> atmosphere and clouds are two separate scattering media). Both, the asteroid and
> the clouds are very detailed, but render sufficiently fast if either the
> asteroid or (!) the clouds are part of the scene, or the asteroid does not cast
> its shadow over the clouds.
> 
> However, the rendering extremely slows down if the light source position moves
> and the shadow of the asteroid hits the clouds. I assume the combination of
> scattering media and isosurfaces casting their shadow on the scattering media
> causes lots of extra calculations ...
> 
> Adding "no_shadow" to the asteroid object is no option, this deteriorates the
> 3D-appearance of the asteroid.
> 
> I could also switch from "scattering" to "emission" for the cloud media, but
> this also looks less real.
> 
> Since the shadow on the clouds is almost invisible in this scene, it would be
> more than enough if - for calculating the shadow on the clouds - the asteroid is
> assumed to be just a sphere, or any other simple shape.
> 
> So it would be a great idea, to have a term like this:
> 
> object { ... shadow_lookslike{sphere{<x,y,z>,r}}}
> 
> which only holds for the calculation of shadows cast on any other object of the
> scene, not for the object itself. The shadow it casts over itself should not be
> affected.
> 
> I assume such a feature does not exist yet, what do you think about it?
> 
> Thank you in advance for your comments!
> 
> 

You should dive a bit in lightgroup and play with no_image. (for the
light source, cloud & sphere)
It might means a duplicated light source...


Post a reply to this message

From: Alain
Subject: Re: Shadow Shape
Date: 4 Jun 2012 15:18:55
Message: <4fcd0a1f$1@news.povray.org>

> Hello,
>
> I work on a scene with an asteroid (isosurface) close to the earth (the
> atmosphere and clouds are two separate scattering media). Both, the asteroid and
> the clouds are very detailed, but render sufficiently fast if either the
> asteroid or (!) the clouds are part of the scene, or the asteroid does not cast
> its shadow over the clouds.
>
> However, the rendering extremely slows down if the light source position moves
> and the shadow of the asteroid hits the clouds. I assume the combination of
> scattering media and isosurfaces casting their shadow on the scattering media
> causes lots of extra calculations ...
>
> Adding "no_shadow" to the asteroid object is no option, this deteriorates the
> 3D-appearance of the asteroid.
>
> I could also switch from "scattering" to "emission" for the cloud media, but
> this also looks less real.
>
> Since the shadow on the clouds is almost invisible in this scene, it would be
> more than enough if - for calculating the shadow on the clouds - the asteroid is
> assumed to be just a sphere, or any other simple shape.
>
> So it would be a great idea, to have a term like this:
>
> object { ... shadow_lookslike{sphere{<x,y,z>,r}}}
>
> which only holds for the calculation of shadows cast on any other object of the
> scene, not for the object itself. The shadow it casts over itself should not be
> affected.
>
> I assume such a feature does not exist yet, what do you think about it?
>
> Thank you in advance for your comments!
>
>

My take would be to use a light_group.
The light is in the same DIRECTION for both but not at the same distance.

You keep the asteroid unchanged.

The planet's light would be slightly closer to the planet than the 
asteroid and have a shadow caster disk with no_image. That disk will 
have a spherical pattern fading to transparency to compensate the fact 
that the distances involved are MUCH shorter. Alternatively, you can use 
a broad circular area_light. The goal is to have a penumbrae similar to 
the one you have now. The light of the light_group need to be closer 
than the asteroid to prevent it from casting any shadow.

BOTH lights should be made parallel with identical location to point_at 
vectors.

That way, the light going to the asteroid is ignored for the planet.




Alain


Post a reply to this message

From: Sereib
Subject: Re: Shadow Shape
Date: 5 Jun 2012 08:55:01
Message: <web.4fce00e27b47b6c23fdf9f0b0@news.povray.org>
Hello,

thanks for your valuable comments, now it works - fast and with a shadow (in the
2nd light group with the light source responsible for the shadow on the clouds,
the asteroid is nothing but a sphere)! I already worked with light groups in the
past, but for any reason I did not associate it with my shadow-problem ...


Post a reply to this message

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