|
|
I think the method to go about it would depend on two things: 1) if the objects
have *already* been made and pre-positioned, or not; and 2) the relative sizes
of the objects. You didn't mention that the many objects may have different
sizes; that would complicate things.
*IF* your're making a group of objects from scratch, and ALL of the same size,
then this simple code would suffice--although, I have a funny feeling that this
is WAY too simplistic for the idea you have in mind ;-) Offhand, I don't have a
good idea for adding equal spacing between objects of *different* sizes. I would
imagine that it would involve finding the sizes of the objects' bounding boxes
first, using max_extent, then... ??
#version 3.71;
global_settings{assumed_gamma 1.0}
#default {texture{pigment {rgb 1} finish{ambient 1 emission 0 diffuse 0}}}
camera {
perspective
location <28, 16, -300>
look_at <28, 16, 0>
right x*image_width/image_height
angle 16
}
#declare CX = 0;
#declare CY = 0;
#while(CY < 30)
#while (CX < 30)
sphere{0,.25
translate <-9,-14,0> // just to offset the objects arbitrarily, before
// re-positioning them
translate 1*<CX,CY,0>} // simply change the multiplier!
#declare CX = CX + 1;
#end
#declare CX = 0;
#declare CY = CY + 1;
#end
Post a reply to this message
|
|