|
![](/i/fill.gif) |
Lutz-Peter Hooge wrote in message ...
> I know, when #declaring a mesh, it is only loaded only once, so you can
> use many instances of it, without running out of memory.
> Why isn't this possible with all objects, like a union of 10000 cones for
> example?
Becouse you can treat set of triangles as property of object as well as radius
and center for sphere or normal and distance for plane.
Look at summary of sphere definition in megapov 0.7;
- pointers
(Methods,Sibling,Texture,Interior,Interior,Bound,Clip,UV_Trans,Label,Interior_Te
xture,glowList,Trans
- ints (Type,Ph_Flags,No_Shadow_Group, Light_Group,Flags,TimeStamp)
- sngl (BBOX,Ph_Density)
- dbl (Radius,Center)
you can save space for radius where you copy object{MySphere OBJECT_MODS} but
nearly all other properities you reserve for child becouse they can be
overwritten.
this way you get another level of abstract but instead of 4 dbl you must
remember pointer to parent - is it worth ?
--
#macro Sig(A,B,X)_(A,B)_(B,X)_(X,A)#end#macro _(A,B)cylinder{<A.x,A.y,3>,<B.u,
B.v,3>.1,9}#end global_settings{max_trace_level 9}light_source{0 1}camera{up y
*4right-3*x}blob{_(<3,1>,<1,-5>)_(<2,-2>,<4,-2>)Sig(x,<-1,1.5>,<1,3>)_(z-1,z-4
)pigment{rgb 1}}box{-3 3pigment{rgb 0}finish{reflection 1}hollow} // POV-Ray31
Post a reply to this message
|
![](/i/fill.gif) |