|  |  | 
|  |  |  |  | 
|  |  | 
|  |  | 
|  |  |  |  | 
|  |  | 
|  |  | 
|  |  | This is mainly for Chris but anyone else playing with glows may
want to take note.
I've been working on a scene with glows and I've encountered a problem
Glows do not behave well when #declared.
The following gives an error.
#declare Test=
 glow {
  location <0,0,0>
  color rgb <1,0,0>
 }
while
#declare Test =
 union {
  glow {
   location <0,0,0>
   color rgb <1,0,0>
  }
  sphere {
   <0,0,0>,1
   pigment {rgb 1}
  }
 }
gives a warning that there should be at least 2 objects in a CSG
and places the glow in the scene.
A subsequent call
object {Test}
simply places the sphere into the scene.
Also pov-ray returns an error if a glow is the last thing in a scene.
Chris, are these issues going to be addressed in the next version?
Gail
********************************************************************
* gsh### [at] monotix co  za              * System.dat not found.         *
* http://www.rucus.ru.ac.za/~gail/ * Reformat hard drive Y)es O)k  *
********************************************************************
* If at first you don't succeed, call it version 1.0               *
********************************************************************Post a reply to this message
 |  | 
|  |  | 
|  |  | 
|  |  |  |  | 
|  |  | 
|  |  | 
|  |  | Gail Shaw <gsh### [at] monotix co  za> wrote:
> This is mainly for Chris but anyone else playing with glows may
> want to take note.
> 
> I've been working on a scene with glows and I've encountered a problem
> 
> Glows do not behave well when #declared.
> 
> The following gives an error.
[...]
We just discovered that while testing the patch. We will take a look at
it, but Chris, if you find a solution before us: Please send it over!
Thanks.
> 
> gives a warning that there should be at least 2 objects in a CSG
> and places the glow in the scene.
> 
> A subsequent call
> object {Test}
> simply places the sphere into the scene.
> 
> Also pov-ray returns an error if a glow is the last thing in a scene.
We fixed that one for MegaPov 0.6. A small fix is still needed for a
simular problem.
 
Smellenbergh
> Chris, are these issues going to be addressed in the next version?
> 
> Gail
> ********************************************************************
> * gsh### [at] monotix  co  za              * System.dat not found.         *
> * http://www.rucus.ru.ac.za/~gail/ * Reformat hard drive Y)es O)k  *
> ********************************************************************
> * If at first you don't succeed, call it version 1.0               *
> ********************************************************************
-- 
e-mail:sme### [at] skynet  be
http://users.skynet.be/smellenbergh Post a reply to this message
 |  | 
|  |  | 
|  |  | 
|  |  |  |  | 
|  |  | 
|  |  | 
|  |  | In article <39d1b98d@news.povray.org>, "Gail Shaw" 
<gsh### [at] monotix co  za> wrote:
> I've been working on a scene with glows and I've encountered a problem
> 
> Glows do not behave well when #declared.
Not surprising, since I haven't put code in to allow declaring them...on 
the to-do list.
> gives a warning that there should be at least 2 objects in a CSG
> and places the glow in the scene.
> 
> A subsequent call
> object {Test}
> simply places the sphere into the scene.
That is simply because glows are not objects and do not behave 
completely like objects yet. Another item on the to-do list.
> Also pov-ray returns an error if a glow is the last thing in a scene.
That is odd...
-- 
Christopher James Huff
Personal: chr### [at] mac  com, http://homepage.mac.com/chrishuff/
TAG: chr### [at] tag  povray  org, http://tag.povray.org/
<>< Post a reply to this message
 |  | 
|  |  | 
|  |  | 
|  |  |  |  | 
|  |  | 
|  |  | 
|  |  | In article <1ehmqh4.c2356i1u7rkttN%smellenbergh@skynet.be>, 
sme### [at] skynet be (smellenbergh) wrote:
> We just discovered that while testing the patch. We will take a look at
> it, but Chris, if you find a solution before us: Please send it over!
I will try to figure out how to implement this...
> We fixed that one for MegaPov 0.6. A small fix is still needed for a
> simular problem.
What was the problem?
-- 
Christopher James Huff
Personal: chr### [at] mac  com, http://homepage.mac.com/chrishuff/
TAG: chr### [at] tag  povray  org, http://tag.povray.org/
<>< Post a reply to this message
 |  | 
|  |  | 
|  |  | 
|  |  |  |  | 
|  |  | 
|  |  | 
|  |  | Another item on the to-do list.
Good to know. I really like glows.
>
> > Also pov-ray returns an error if a glow is the last thing in a scene.
>
> That is odd...
I tried the following as a test scene:
// start ********************************
camera {
 location <0,0,-5>
 look_at <0,0,0>
}
glow {
  location <0,0,0>
  color rgb <0.8,0.6,0>*2.5
  type 1
 }
// End****************************
and I got the following message:
--------------------------------------------------
  All Streams to console..........On
  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
  type 1
 }
 <----ERROR
C:\My Documents\test.pov:10: error: object or directive expected but End of
File found instead.
Returned from renderer (non-zero return value)
-------------------------------------------------
If I put any object after the glow then the scene renders.
Gail
********************************************************************
* gsh### [at] monotix co  za              * System.dat not found.         *
* http://www.rucus.ru.ac.za/~gail/ * Reformat hard drive Y)es O)k  *
********************************************************************
* If at first you don't succeed, call it version 1.0               *
********************************************************************Post a reply to this message
 |  | 
|  |  | 
|  |  | 
|  |  |  |  | 
|  |  | 
|  |  | 
|  |  | > > We fixed that one for MegaPov 0.6. A small fix is still needed for a
> > simular problem.
> 
> What was the problem?
First of all, in parse.c in function Parse() change things like this
(and this is for that last little fix mentioned):
  Parse_Frame ();
  Post_Media(Frame.Atmosphere);
#ifdef GlowPatch
  if (Frame.Objects == NULL && Frame.Glows == NULL)
  {
    Error ("No objects or glows in scene.");
  }
#else
  if (Frame.Objects == NULL)
  {
    Error ("No objects in scene.");
  }
#endif
  Stage = STAGE_CLEANUP_PARSE;
This makes it possible to render a scene with no objects, no lights but
only glows.
To allow parsing you should modify Parse_Frame() in parse.c like this
(at the end of the function):
#ifdef GlowPatch
  /*YS sept 18 2000 
     added this here too to allow 
    for a scene with only glow */
  CASE(GLOW_TOKEN)
    #ifdef UnofficialBlocking
        parseUnofficialFeature(60);
    #endif  
    {
    GLOW * NewGlow = Create_Glow();
    Parse_Glow(NewGlow);
    Add_Glow(NewGlow);
  }
  END_CASE
#endif
     OTHERWISE
       UNGET
       Object = Parse_Object();
       if (Object == NULL)
         Parse_Error_Str ("object or directive");
       Post_Process (Object, NULL);
       Link_To_Frame (Object);
     END_CASE
   END_EXPECT
  }
Smellenbergh
-- 
e-mail:sme### [at] skynet be
http://users.skynet.be/smellenberghPost a reply to this message
 |  | 
|  |  | 
|  |  | 
|  |  | 
| From: Fabien Mosen Subject: Re: Allowing a scene with only glow, no lights or objects [was Re:  Megapovplus glows]
 Date: 29 Sep 2000 01:49:54
 Message: <39D42C6C.5BFCC87B@skynet.be>
 
 |  |  | 
|  |  | 
|  |  | 
|  |  | smellenbergh wrote:
> 
> This makes it possible to render a scene with no objects, no lights but
> only glows.
Why not simply allowing POV-Ray to render even if there are no
objects ?  Issuing a simple warning instead of an error...
Fabien.
 Post a reply to this message
 |  | 
|  |  | 
|  |  | 
|  |  | 
| From: Warp Subject: Re: Allowing a scene with only glow, no lights or objects [was Re:  Megapovplus glows]
 Date: 29 Sep 2000 07:59:58
 Message: <39d4843d@news.povray.org>
 
 |  |  | 
|  |  | 
|  |  | 
|  |  | Or making povray consider a glow to be an object.
  If there are lots of glows in the scene, wouldn't they benefit from
bounding objects (perhaps spheres could be the best)?
-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):_;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/
Post a reply to this message
 |  | 
|  |  | 
|  |  | 
|  |  |  |  | 
|  |  | 
|  |  | 
|  |  | In article <39d4843d@news.povray.org>, Warp <war### [at] tag povray  org> 
wrote:
>   Or making povray consider a glow to be an object.
That is my goal...to make them imitate objects, like light_sources do. 
Of course, things like "hollow" and "open" would be meaningless to 
them...but they will eventually be useable in CSG's and variables.
>   If there are lots of glows in the scene, wouldn't they benefit from
> bounding objects (perhaps spheres could be the best)?
No more than plane objects or sky_spheres would...the "realistic" glow 
types are "infinite". They are not objects, but effects which depend on 
the angle and proximity of the ray to a point, which makes bounding a 
bit...tricky. However, my most recent version does include a "radius" 
feature which allows you to cut off calculation beyond a certain 
distance. But this can often make a large difference in the output, 
especially when using large numbers of glows, and isn't useful as an 
optimization technique for small numbers.
-- 
Christopher James Huff
Personal: chr### [at] mac  com, http://homepage.mac.com/chrishuff/
TAG: chr### [at] tag  povray  org, http://tag.povray.org/
<>< Post a reply to this message
 |  | 
|  |  | 
|  |  | 
|  |  |  |  | 
|  |  |