|
![](/i/fill.gif) |
Rune <run### [at] mobilixnet dk> wrote:
> Yes, if it is possible to detect, I'd be interested. Especially since
> there are several other macros in math.inc which also come in several
> versions due to the various types of vectors.
> But I don't know of such a method.
I found a method. It may not be the fastest possible, but at least it works.
#macro Is5DVector(V)
(strcmp(vstr(5, (V=V), "", 0, 0), "11111") = 0)
#end
#declare V1 = <1,2,3>;
#declare V2 = <4,5,6,7,8>;
#if(Is5DVector(V1)) #debug "yes, " #else #debug "no, " #end
#if(Is5DVector(V2)) #debug "yes" #else #debug "no" #end
#debug "\n"
--
#macro M(A,N,D,L)plane{-z,-9pigment{mandel L*9translate N color_map{[0rgb x]
[1rgb 9]}scale<D,D*3D>*1e3}rotate y*A*8}#end M(-3<1.206434.28623>70,7)M(
-1<.7438.1795>1,20)M(1<.77595.13699>30,20)M(3<.75923.07145>80,99)// - Warp -
Post a reply to this message
|
![](/i/fill.gif) |