On Fri, Aug 19, 2005 at 12:18:57PM +0200, kabutor wrote:
>
> >>Can be possible to add it to soya.Volume? so we can do
> >>soya.Volume.texture= "green.png"
> >>
> >>
> >i think the main trouble is that some shapes have multiple
> >materials.
> >
> Multiple materials?
shapes can have more than one material. thats why shape.materials
returns a list :)
> >i can definatly see though how moving the material out of shape
> >could be
> >very helpfull in some instances. for example rendering bonus items
> >or
> >such that all have the same mesh but a different texture.
> >
> >
> Well You dont definitively need to move that out of the shape (I
> dont know wich is best really), I can see a situation that using
> that code (for c in each Face) to change the texture in "real time"
> is fine, but what I really wanted is prior to rendering the volume
> in the screen assign a texture to that shape/volume
im thinking of something like:
shape = soya.ReallySimpleShape.get('box')
box1 = soya.SomeVolume(parent, shape, soya.Material.get('box1'))
box2 = soya.SomeVolume(parent, shape, soya.Material.get('box2'))
box3 = soya.SomeVolume(parent, shape, soya.Material.get('box3'))