POV-Ray : Newsgroups : povray.advanced-users : command capability / syntax : Re: command capability / syntax Server Time
18 Apr 2024 16:21:49 EDT (-0400)
  Re: command capability / syntax  
From: Le Forgeron
Date: 26 May 2017 11:00:06
Message: <592842f6$1@news.povray.org>
Le 26/05/2017 à 13:57, Bald Eagle a écrit :
> Le_Forgeron <jgr### [at] freefr> wrote:
>> Le 26/05/2017 à 10:33, dick balaska a écrit :
> I'm thinking that a macro that does something like a progressive #ifdef(Q.x),
> #ifdef (Q.y), #ifdef(Q.z) ..... would be able to count vector elements and
> return the size of the vector, and if there's only 1 element, then it's a
> scalar.

You forget one thing, which lose the whole idea: automatic expansion of
scalar and vector.

#declare Scalar = 1;

Yet, Scalar.x, Scalar.y and so on are valid and defined as 1.

#declare Vector = <1,2>;

Yet, Vector.z is valid and defined as 0.

The Wise-Man said No, listen to him.


Post a reply to this message

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