POV-Ray : Newsgroups : povray.newusers : curious: degenerate triangles and cameras : Re: curious: degenerate triangles and cameras Server Time
28 Jul 2024 14:26:51 EDT (-0400)
  Re: curious: degenerate triangles and cameras  
From: Cousin Ricky
Date: 12 Mar 2009 08:00:00
Message: <web.49b8f81226995c4385de7b680@news.povray.org>
"joost_1972" <joo### [at] hotmailcom> wrote:
>  And why does povray simply not render a
> degenerate triangle, while a degenerate cylinder causes an error and stop in
> rendering altogether?

The cylindrical axis is required to orient the discs that cap the cylinder.  The
axis, in turn, requires 2 distinct end points.  With a zero-length cylinder, the
discs cannot be oriented, leaving no way to know what to render.  My guess is
that the POV Team decided it improper to proceed under that circumstance.
Degenerate triangles do not have this problem.

> Secondly I was wondering if there is an option to choose different camera angles
> like there is the pull down menu for choosing the resolutions. Now changing
> camera angles involves editing the code constantly (adding and removing // in
> my case).

I use command-line arguments.  For your specific question, using it straight as
the camera angle will suffice.  In the scene file, set:

   #ifndef (Cam) #define Cam = 60; #end
   camera
   {  angle Cam
   }

Then on the command line, use (for example):

   declare=Cam=25

For a more general solution (which is what I invariably need), use something
like:

   #ifndef (Cam) #define Cam = 0; #end
   camera
   {  switch (Cam)
      #case (1) /*camera settings*/ #break
      #case (2) /*camera settings*/ #break
      #case (3) /*camera settings*/ #break
      ...
      #else /*camera settings*/ #break
      #end
   }


Post a reply to this message

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