|
|
I'm still working on my jellyfish model, first part is convert in ISO CGS
and work fine - at least the way I want -
See attached image.
But I am in trouble using IC_Merge_Array. The code I try is:
#declare SP4 = IC_Translate ( IC_Scale ( IC_Sphere ( <0, 0, 0 > , 1 ), < 0.5
, 1 , 0.2 > ), < 0.7 , -0.7 , 0 > )
#declare SP_Array = array[12]
#declare SP_Array[0] = SP4
#declare SP_Array[1] = IC_Rotate( SP4 , y*30 )
#declare SP_Array[2] = IC_Rotate( SP4 , y*30 )
#declare SP_Array[3] = IC_Rotate( SP4 , y*60 )
#declare SP_Array[4] = IC_Rotate( SP4 , y*90 )
#declare SP_Array[5] = IC_Rotate( SP4 , y*120 )
#declare SP_Array[6] = IC_Rotate( SP4 , y*150 )
#declare SP_Array[7] = IC_Rotate( SP4 , y*180 )
#declare SP_Array[8] = IC_Rotate( SP4 , y*210 )
#declare SP_Array[9] = IC_Rotate( SP4 , y*240 )
#declare SP_Array[10] = IC_Rotate( SP4 , y*270 )
#declare SP_Array[11] = IC_Rotate( SP4 , y*300 )
#declare MedTent = IC_Merge_Array ( SP_Array )
but I get the following message:
File: D:\transfert\perso\povfile\include\iso_csg.inc Line: 82
#if (Counter>0) , #end
_ICSG_Array[Counter] <----ERROR
Parse Error: Attempt to access uninitialized array element.
and Christoph Hormann code is:
#macro IC_Merge_Array(_ICSG_Array) // merge an array of objects
#local Size=dimension_size(_ICSG_Array,1);
function {
min(
#local Counter=0;
#while (Counter<Size)
#if (Counter>0) , #end
_ICSG_Array[Counter] (x,y,z) // line 82
#local Counter=Counter+1;
#end
)
}
#end
Any clue to solve this?
Chaps.
Post a reply to this message
Attachments:
Download 'meduse2.jpg' (22 KB)
Preview of image 'meduse2.jpg'
|
|