POV-Ray : Newsgroups : povray.general : Object on or off ??? : Re: Object on or off ??? Server Time
7 Nov 2024 17:32:08 EST (-0500)
  Re: Object on or off ???  
From: Kurts
Date: 14 Aug 2003 17:11:54
Message: <kurtzlepirate-B30287.23115314082003@netplex.aussie.org>
In article <web.3f39862ac76d2e2e6af901ee0@news.povray.org>, "BorisW37"
<Bor### [at] yahoocom> wrote:

> I saw it in somebody elses scripts but cant remember where...
> I need to easily turn certain object on or off.
> Let say i have object my_sphere, used as a trouble shooting marker for
> development purpose only. But intsead of puting /* ..... */ every time in
> need to get rid of it, can i write
> my_sphere = true/false, or something along those lines
> 

some methods :

1) one variable, multiple object

  #declare troubleShooting=true/false;
  
  source
  ...
  #if (troubleShooting)
    object {...}
    object {...}
  #end
  ...
  #if (troubleShooting)
    object {...}
    object {...}
  #end

2) one variable, one object

  #declare drawPlane = true/false;
  #declare drawSky = true/fase;


  source
  ...
  ...
  #if (drawPlane)
    plane { }
  #end
  ...
  #if (drawSky)
    sky_sphre { }
  #end
  ...

hope this help


Post a reply to this message

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