POV-Ray : Newsgroups : povray.general : cabinet macro : Re: cabinet macro Server Time
30 Jul 2024 08:26:20 EDT (-0400)
  Re: cabinet macro  
From: clipka
Date: 26 Jun 2009 23:00:00
Message: <web.4a458aa82c18cb70371b08450@news.povray.org>
"mysdn" <kam### [at] hotmailcom> wrote:
> instead of this
> eg.  #if (DoorCount < 1)// no door
>           #if(IsGlassDoor) //door is glass
>
> I want to write this
> #if (DoorCount < 1) or (IsGlassDoor)

Try this one:

  #if ((DoorCount < 1) | IsGlassDoor)

Note that in POV-Ray this denotes logical "or", not bit-wise as in C#; POV-Ray
does not have a "||" operator.

As you may already guess, "&" is used to denote logical "and".


Post a reply to this message

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