POV-Ray : Newsgroups : povray.advanced-users : Spotlight and media Server Time
28 Jul 2024 20:25:22 EDT (-0400)
  Spotlight and media (Message 4 to 13 of 13)  
<<< Previous 3 Messages Goto Initial 10 Messages
From: Carl
Subject: Re: Spotlight and media
Date: 18 Nov 2004 12:25:00
Message: <web.419cda9e3c6e7b27a54c62600@news.povray.org>
I think I've found something according to:

    3.6.2.2  Sampling Parameters & Methods

For media types which interact with spotlights or cylinder lights, the
intervals which are not illuminated by these light types are weighted
differently than the illuminated intervals when distributing samples.

So it looks like media treats spotlights differently the normal lights.  I'm
now playing with some of the media settings talked about in this section to
see if they fix the problem.  So far I've been using the defaults for these
settings.

Carl


Post a reply to this message

From: Slime
Subject: Re: Spotlight and media
Date: 18 Nov 2004 13:09:39
Message: <419ce563$1@news.povray.org>
> So it looks like media treats spotlights differently the normal lights.

That's true, but the effects of that are different than what you're seeing
here. The graininess should not be appearing.

I would make sure that your media container object doesn't coincide with the
spotlight's cone of light, and also as Mike said, make sure your light
source isn't on the surface of an object.

 - Slime
 [ http://www.slimeland.com/ ]


Post a reply to this message

From: Reactor
Subject: Re: Spotlight and media
Date: 18 Nov 2004 14:59:05
Message: <419cff09$1@news.povray.org>
"Slime" <fak### [at] emailaddress> wrote in message
news:419ce563$1@news.povray.org...
> > So it looks like media treats spotlights differently the normal lights.
>
> That's true, but the effects of that are different than what you're seeing
> here. The graininess should not be appearing.
>
> I would make sure that your media container object doesn't coincide with
the
> spotlight's cone of light, and also as Mike said, make sure your light
> source isn't on the surface of an object.

It really does look like a coincident surface issue, but the coincident
surface need not be with the light source.  You mentioned that the light
source is inside of a CSG cut out, does the shape that forms the cutout
extend beyond the shape you are cutting?

Reactor


Post a reply to this message

From: Carl
Subject: Re: Spotlight and media
Date: 18 Nov 2004 15:05:01
Message: <web.419d00373c6e7b27a54c62600@news.povray.org>
> That's true, but the effects of that are different than what you're seeing
> here. The graininess should not be appearing.

Well that is good to know.  Now I just have to track down what I'm doing
wrong.

> I would make sure that your media container object doesn't coincide with the
> spotlight's cone of light, and also as Mike said, make sure your light
> source isn't on the surface of an object.

Well I just removed the object the spotlights were inside of and I still see
the graininess.

http://www.wwwmwww.com/TRON/tanktest4.jpg

This is 7 spot_lights.  3 sets of 2 pointing in opposite directions and one
by itself pointing forward.  The media container is a scaled sphere
centered on the light source.  Actually it's 4 spheres merged together that
look about like this at the moment:

sphere {<0,0,0>,1 scale <100,35,35> translate
<cannon_width/2,532-54*(Tx5-(Tx3-20))/232,cannon_height/2> hollow pigment
{color rgbf 1}
      interior {
        media {
          aa_level     5
          aa_threshold 0.05
          confidence   0.95
          intervals    1
          method       3
          ratio        0.9
          samples      10, 10
          variance     1/256
          scattering {
            1
            color rgb .5
            extinction 0.001
          }
          density {
            spherical
            color_map {
               [0 color rgb 0]
               [1 color rgb 1]
            }
            scale <100,35,35> translate
<cannon_width/2,532-54*(Tx5-(Tx3-20))/232,cannon_height/2>
          }
        }
      }
    }

I'll strip down my file and see if I can get some simple code to post that
shows the same effect.

Carl


Post a reply to this message

From: Carl
Subject: Re: Spotlight and media
Date: 18 Nov 2004 16:05:00
Message: <web.419d0e333c6e7b27a54c62600@news.povray.org>
Here is a bare bones file which shows the problem:

  #include "colors.inc"

  light_source {<10,10,10> color <252/255,96/255,12/255>
                spotlight point_at <10,20,10> radius 0 falloff 90 tightness
10}

  sphere {<0,0,0>,1 scale <3,10,3> translate <10,10,10> hollow pigment
{color rgbf 1}
      interior {
        media {
          aa_level     5
          aa_threshold 0.05
          confidence   0.95
          intervals    1
          method       3
          ratio        0.9
          samples      10, 10
          variance     1/256
          scattering {
            1
            color rgb .5
            extinction 0.001
          }
          density {
            spherical
            color_map {
               [0 color rgb 0]
               [1 color rgb 1]
            }
            scale <3,10,3> translate <10,10,10>
          }
        }
      }
    }

    camera {location <0,0,100> look_at <10,15,10> angle 10}

It produces this image:
http://www.wwwmwww.com/TRON/error.jpg

I'm using POV-Ray 3.6, no AA, and +FN.  If you use:
light_source {<10,10,10> color <252/255,96/255,12/255>}
instead of the above spotlight things look much better.

Carl


Post a reply to this message

From: Mike Raiford
Subject: Re: Spotlight and media
Date: 18 Nov 2004 16:36:08
Message: <419d15c8$1@news.povray.org>
Carl wrote:

> spotlight point_at <10,20,10> radius 0 falloff 90 tightness



-- 
~Mike


Post a reply to this message

From: Slime
Subject: Re: Spotlight and media
Date: 18 Nov 2004 16:41:07
Message: <419d16f3@news.povray.org>
> falloff 90

That's what's doing it. Use falloff 89.999 and it works right. There's
probably some angle-related calculation going on internally which doesn't
have good results with 90 degree angles.

By the way,

>           confidence   0.95
>           variance     1/256

You can remove those lines. Confidence and variance are only used for
sampling method 1.

 - Slime
 [ http://www.slimeland.com/ ]


Post a reply to this message

From: Slime
Subject: Re: Spotlight and media
Date: 18 Nov 2004 16:42:02
Message: <419d172a$1@news.povray.org>
Heh, Mike beat me. =)

 - Slime
 [ http://www.slimeland.com/ ]


Post a reply to this message

From: Carl
Subject: Re: Spotlight and media
Date: 18 Nov 2004 18:05:00
Message: <web.419d29893c6e7b27a54c62600@news.povray.org>
Thanks guys.  It would have taken me forever to figure that one out on my
own.

Carl


Post a reply to this message

From: Carl
Subject: Re: Spotlight and media
Date: 18 Nov 2004 21:00:00
Message: <web.419d53373c6e7b27a54c62600@news.povray.org>
Looking much better...

http://www.wwwmwww.com/TRON/tanktest5.jpg

Thanks again,
Carl


Post a reply to this message

<<< Previous 3 Messages Goto Initial 10 Messages

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