POV-Ray : Newsgroups : povray.general : Another light groups bug Server Time
5 Nov 2024 01:26:09 EST (-0500)
  Another light groups bug (Message 1 to 7 of 7)  
From: Mark Weyer
Subject: Another light groups bug
Date: 26 Aug 2003 06:28:07
Message: <3F4B3703.9020101@informatik.uni-freiburg.de>
It causes a segfault. I would be happy to know a workaround.
The following seemed essential in minimalizing the scene:
  - multiple light sources (not necessarily at the same place)
  - some of them spotlights with nonzero point_at (not necessarily location 0)
  - light_group

Minimal scene:
==============

camera {
   translate -3*z
}

light_group {
   #local i=0;
   #while (i<18)
     light_source {
       0 1
       spotlight radius 30 falloff 60 point_at 1
     }
     #local i=i+1;
   #end
   sphere {0 1
     pigment {transmit 1}
     hollow
     interior {
       media {
         scattering {1 1}
       }
     }
   }
}


Povray output:
==============

Persistence of Vision(tm) Ray Tracer Version 3.5 Unix (.Linux.gcc)
   This is an official version prepared by the POV-Ray Team. See the
    documentation on how to contact the authors or visit us on the
    internet at http://www.povray.org/.
Copyright 1991-2002 POV-Ray Team(tm)
Parsing Options
   Input file: bug.pov (compatible to version 3.5)
   Remove bounds........On  Split unions........Off
   Library paths: /usr/local/share/povray-3.5
     /usr/local/share/povray-3.5/include
Output Options
   Image resolution 320 by 240 (rows 1 to 240, columns 1 to 320).
   Output file: bug.png, 24 bpp PNG
   Graphic display......On  (type: 0, palette: 3, gamma:  2.2)
   Mosaic preview......Off
   CPU usage histogram.Off
   Continued trace.....Off  Allow interruption..Off  Pause when done.....Off
   Verbose messages.....On
Tracing Options
   Quality:  9
   Bounding boxes.......On  Bounding threshold: 3
   Light Buffer.........On  Vista Buffer.........On  Draw Vista Buffer...Off
   Antialiasing........Off
Animation Options
   Clock value....   0.000  (Animation off)
Redirecting Options
   All Streams to console.........Off
   Debug Stream to console.........On
   Fatal Stream to console.........On
   Render Stream to console........On
   Statistics Stream to console....On
   Warning Stream to console.......On


Parsing...

Creating bounding slabs.
Scene contains 1 frame level objects; 0 infinite.

Displaying...
Using 16 bit TrueColor visual...
   -:--:-- Rendering line   36 of  240. Segmentation fault



-- 
merge{#local i=-11;#while(i<11)#local
i=i+.1;sphere{<i*(i*i*(.05-i*i*(4e-7*i*i+3e-4))-3)10*sin(i)30>.5}#end
pigment{rgbt 1}interior{media{emission x}}hollow}//  Mark Weyer


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: Another light groups bug
Date: 26 Aug 2003 12:29:16
Message: <3f4b8adc$1@news.povray.org>
In article <3F4### [at] informatikuni-freiburgde> , Mark Weyer 
<wey### [at] informatikuni-freiburgde>  wrote:

> It causes a segfault. I would be happy to know a workaround.
> The following seemed essential in minimalizing the scene:
>   - multiple light sources (not necessarily at the same place)
>   - some of them spotlights with nonzero point_at (not necessarily location 0)
>   - light_group

As far as I can tell lightgroups simply make an otherwise existing problem
visible in the given scene.  For me the crash happens when freeing memory in
non-lightgroup related code because memory below something allocated has
been overwritten...

    Thorsten

____________________________________________________
Thorsten Froehlich, Duisburg, Germany
e-mail: tho### [at] trfde

Visit POV-Ray on the web: http://mac.povray.org


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: Another light groups bug
Date: 26 Aug 2003 14:41:36
Message: <3f4ba9e0$1@news.povray.org>
BTW, your subject line says "Another light groups bug", would you care to 
explain which other lightgroup bug you are referring to?  I am not aware of
any other...

    Thorsten

____________________________________________________
Thorsten Froehlich, Duisburg, Germany
e-mail: tho### [at] trfde

Visit POV-Ray on the web: http://mac.povray.org


Post a reply to this message

From: Mark Weyer
Subject: Re: Another light groups bug
Date: 29 Aug 2003 03:53:56
Message: <3F4F0767.70605@informatik.uni-freiburg.de>
> BTW, your subject line says "Another light groups bug", would you care to 
> explain which other lightgroup bug you are referring to?  I am not aware of
> any other...

More precisely: Another bug that I encountered using light groups. The
first one was reported in
   June 30: scattering media and light groups bug
and seems to be the same as
   Jula 3: bug with light groups and media
(both posts in p.g.). As there was no reply to those messages I assume
that that bug is not fixed (or declared feature) yet.

   Mark


-- 
merge{#local i=-11;#while(i<11)#local
i=i+.1;sphere{<i*(i*i*(.05-i*i*(4e-7*i*i+3e-4))-3)10*sin(i)30>.5}#end
pigment{rgbt 1}interior{media{emission x}}hollow}//  Mark Weyer


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: Another light groups bug
Date: 29 Aug 2003 05:39:19
Message: <3f4f1f47$1@news.povray.org>
In article <3F4### [at] informatikuni-freiburgde> , Mark Weyer 
<wey### [at] informatikuni-freiburgde>  wrote:

>> BTW, your subject line says "Another light groups bug", would you care to
>> explain which other lightgroup bug you are referring to?  I am not aware of
>> any other...
>
> More precisely: Another bug that I encountered using light groups. The
> first one was reported in
>    June 30: scattering media and light groups bug
> and seems to be the same as
>    Jula 3: bug with light groups and media
> (both posts in p.g.). As there was no reply to those messages I assume
> that that bug is not fixed (or declared feature) yet.

Ah, I checked those.  It works as expected.  light_groups are meant to place
local fill-lights.  There is no other interaction defined by a light_group.
The problem in the given scenes is essentially the same misconception as
assuming a group-based shadow interaction.  This is not what light_groups
do.

    Thorsten

____________________________________________________
Thorsten Froehlich, Duisburg, Germany
e-mail: tho### [at] trfde

Visit POV-Ray on the web: http://mac.povray.org


Post a reply to this message

From: Mark Weyer
Subject: Re: Another light groups bug
Date: 29 Aug 2003 06:50:51
Message: <3F4F30D9.2070907@informatik.uni-freiburg.de>
> Ah, I checked those.  It works as expected.  light_groups are meant to place
> local fill-lights.  There is no other interaction defined by a light_group.
> The problem in the given scenes is essentially the same misconception as
> assuming a group-based shadow interaction.  This is not what light_groups
> do.

I still do not understand my misconception (and I do understand why shadows
and light groups interact the way they do).
Do you mean that scattering media should not be placed in light groups?
If yes, then I would like to know why that restriction was chosen (and it
should be in the docs). You refer to fill-lights. According to the docs
those are shadowless. If it is really the case that light groups are meant
to only work with shadowless lights then either all lights in light groups
should automatically be made shadowless or the docs should at least say so.
Otherwise I see no reason why scattering media should be disallowed in light
groups.
If no (meaning that scattering media is supposed to work with light groups),
then I do not understand the following scene. I do not understand
  - why absorbing and scattering media behave differently without a light source
  - why the scattering medium behaves differently according to which surfaces the
    ray traverses.

Please explain,

   Mark



plane {y (-5) pigment {rgb 1}}

light_source {<-1,1,-1>*10 1}

light_group {
#local i=0;
#while (i<=10)
   sphere {
     <2*i-10,i/5-5.5,15> 1
     pigment {transmit 1}
     hollow
     #if (mod (i,2))
       interior {media {absorption 1}}
     #else
       interior {media {scattering {1 1}}}
     #end
   }
   #local i=i+1;
#end
global_lights off
}


-- 
merge{#local i=-11;#while(i<11)#local
i=i+.1;sphere{<i*(i*i*(.05-i*i*(4e-7*i*i+3e-4))-3)10*sin(i)30>.5}#end
pigment{rgbt 1}interior{media{emission x}}hollow}//  Mark Weyer


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: Another light groups bug
Date: 30 Aug 2003 11:29:09
Message: <3f50c2c5@news.povray.org>
In article <3F4### [at] informatikuni-freiburgde> , Mark Weyer 
<wey### [at] informatikuni-freiburgde>  wrote:

> You refer to fill-lights. According to the docs
> those are shadowless.

There is no concept of fill-lights in POV-Ray itself.  The docs use that
term for lights which gives the whole scene more light without altering it
otherwise.

Light groups don't really do that, but they indeed follow a similar idea:
They are most useful to add light to some parts of a scene that would
otherwise be too dark.  Especially in high-end animations this is used to
improve realism (or create some effect) compared to a real scene.  They add
realism to a computer generated image in particular if there is no or only a
simple model of global illumination (i.e. radiosity for animations is
expensive to compute).

Thus, you are kind of right - light groups are very useful when being
shadowless.  They are not intended as a separately lit scene inside a scene.
Of course, such a feature could be added, and probably will sometime in the
distant future.

    Thorsten

____________________________________________________
Thorsten Froehlich, Duisburg, Germany
e-mail: tho### [at] trfde

Visit POV-Ray on the web: http://mac.povray.org


Post a reply to this message

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