POV-Ray : Newsgroups : povray.newusers : using coordinate vectors in #if statements : Re: using coordinate vectors in #if statements Server Time
30 Jul 2024 00:26:10 EDT (-0400)
  Re: using coordinate vectors in #if statements  
From: Floyd
Date: 11 Dec 2004 14:00:01
Message: <web.41bb42fcb94966d25ca17c0e0@news.povray.org>
> >   Perhaps you should read the documentation for time to time?
>
> As necessary as this note often is (as really almost everything can be read
> in the docs), sometimes it's just difficult to *find* what you're looking
> for. You can't just enter "y-component" into the Help and get the answer.

Just for the record, I spent a great deal of time looking in the
documentation and elsewhere for examples where people have tried this
before.  Many of us don't have the docs memorized, and I figured if I've
spent as much time trying to find out, then an answer might be useful for
other people as well.  This forum is a good place to discover if a
particular approach is even possible in povray before wasting more time
trying to find a non-existent answer in the documentation.

Also, if it is known to be in the documentation, then simply pointing out
where or under what heading would be helpful (in this case 2.2.1.4.3
Operators).  From the cryptic response provided I assumed it could be done,
was in the documentation and once I found it I got it to work nicely with
the following code:

#declare Inter=
   trace (HFlandscape, <Xpos, 1000, Zpos>, <Xpos, -1000, Zpos>,);

translate Inter

#if (Inter.y > 10)
   translate y-100
#end

Thanks for your suggestions,
- Floyd


Post a reply to this message

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