|
![](/i/fill.gif) |
Alain <kua### [at] videotron ca> wrote:
> > Is there any option how to modify some attributes of some already created
> > object...like changing scale of some polygon instance named "PODKLAD"?
> >
> > Because this example from another post makes three new objects instead of 3x
> > modifying the one existing object:
> >
> > #declare ball = sphere {
> > 1, <0, 1, 0>
> > pigment {rgb <1, 0, 0>}
> > //... and so on
> > }
> >
> > object {
> > ball
> > translate <0, 1, 0>
> > }
> >
> > object {
> > ball
> > pigment {rgb <1, 0, 0>}
> > //not sure that this will override the pigment statement in the #define'd ball
> > }
> The pigment IS overriden, but by an identical one. Try pigment{rgb<0,
> 0.5, 1>} to see the difference.
> >
> > object {
> > ball scale <10, 10, 10>
> > }
> >
> >
>
> You can always redefine any object:
> #declare Ball=sphere{0, 1 pigment{rgb<1,0,0>}}
> #declare Ball=object{Ball scale 10 translate <5,12,1> pigment{bozo}}
>
> The original Ball object no longer exist after been replaced by a
> scalled, translated and retextured version of itself.
>
>
> Alain
Yea, seems to me that should do the "trick", simple re-declare declared and only
then place it into the scene, haha, exactly - why this has not come to my mind
automaticaly? :D Appriciate guys your help.
BTW some other question: how can I access some array values? I mean vector
values like ldd_camera_position variable consists of 3 values of x, y and z. Now
how can I access them individually? I come from FLASH ActioScript2 scene and
there you would do it easily like "ldd_camera_position[x]" where "x" is the
index number beginning with 0...so how it is made in PovRay, please?
Post a reply to this message
|
![](/i/fill.gif) |