POV-Ray : Newsgroups : povray.general : Sunny outdoor lighting : Re: Sunny outdoor lighting Server Time
31 Jul 2024 10:28:12 EDT (-0400)
  Re: Sunny outdoor lighting  
From: Sherry Shaw
Date: 29 Oct 2007 11:02:22
Message: <4726040e@news.povray.org>
Alain wrote:
> Even beter: use this "trick"
> #declare Rad = 1;
> 
> have:
> #if(Rad)radiosity{ your_radiosity_settings }#end
> 
> and add this to your finishes:
> ... #if(Rad)ambient 0 #else ambient 0.3 #end
> 
> Now, set Rad to 0 for the test renders and to 1 for the radiosity renders.
> No ugly trick, only 1 variable to set.
> 


If you check the flag *inside* the global_settings block--

global_settings{
   // assumed_gamma etc.
   #if (Rad)
     ambient_light 0.001
     radiosity {
       // Radiosity settings
     }
   #end
   }
}

--then you have only one variable to set and no changes to the finishes. 
  But it's all good.  ;)  The "best" approach depends on things like the 
length of your scene code, whether you're using textures from an 
#include file, whether or not you're already basing textures on the 
state of a flag (like "#if (test-mode) Little_Texture #else Big_Texture 
#end"), and the way you like to do things.

--Sherry Shaw


-- 
#macro T(E,N)sphere{x,.4rotate z*E*60translate y*N pigment{wrinkles scale
.3}finish{ambient 1}}#end#local I=0;#while(I<5)T(I,1)T(1-I,-1)#local I=I+
1;#end camera{location-5*z}plane{z,37 pigment{granite color_map{[.7rgb 0]
[1rgb 1]}}finish{ambient 2}}//                                   TenMoons


Post a reply to this message

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