POV-Ray : Newsgroups : povray.advanced-users : distinguishing types in scene language : Re: distinguishing types in scene language Server Time
24 Jun 2024 08:07:57 EDT (-0400)
  Re: distinguishing types in scene language  
From: Ron Parker
Date: 9 Oct 2000 12:48:20
Message: <slrn8u3thn.1n1.ron.parker@fwi.com>
On Mon, 9 Oct 2000 17:27:07 +0100, Neil Freebairn wrote:
>That's exactly what I was looking for. Very elegant, many thanks.
>

Looking at it now, I see that there will be a couple of problems.  First,
it can't properly deal with vectors with an X value of zero.  If you fix that
by testing the green or blue values as well, it still can't properly deal
with zero vectors.  To fix it, make another local that's equal to
rgbft 0 + (1 + A) ,
then compare that vector's red and filter components as well.  Only if both
comparisons are equal is it a scalar (because 1+A is either a vector or a 
scalar, whichever A was, and either A or 1+A is going to have a nonzero X
component.)

-- 
Ron Parker   http://www2.fwi.com/~parkerr/traces.html
My opinions.  Mine.  Not anyone else's.
Proudly not helping RIAA and SDMI steal my rights -- 
  http://www.eff.org/Misc/EFF/Newsletters/EFFector/HTML/effect13.08.html


Post a reply to this message

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