[Papervision3D] rotations

Steve D kruass at gmail.com
Fri Mar 13 15:45:30 PST 2009


Why do you put all the planes into a container if you don't want them to
share rotation data?



On Fri, Mar 13, 2009 at 4:32 PM, Sergey Karanda <sergey_karanda at mail.ru>wrote:

> Hello all,
>
>      can anyone help with the next problem?
>
>      I have nested objects inside a scene( nested and so on..).
>      All objects have own transformations.
>      How can i set transform for objects, so the nested
>      objects will always look without rotations to world ?
>
>      So, if i rotating holder (parent object for nested objects ) , nested
>      objects will stay look without rotations
>
>      The idea is :
>
>      holder=new DiplayObject3D()
>      scene.addChild(holder)
>      planes=[]
>      for (var a=0;a<100;a++){
>           var plane=new Plane(material,w,h,2,2)
>           holder.addChild(plane)
>           plane.x=Math.random()*200-100
>           plane.y=Math.random()*200-100
>           plane.z=Math.random()*200-100
>           planes.push(plane)
>      }
>
>      private function loop(evt:*=null):void {
>      holder.yaw(1)
>      holder.roll(1)
>             for each (var i in planes) {
>
>                //here should be planes rotation transform
>                //something like
>                i.transform=?
>             }
>
>         singleRender();
>       }
>
>       ----------
>
>       please help
>
>
>
> --
> Best regards,
>  Sergey                            mailto:sergey_karanda at mail.ru
>
>
> _______________________________________________
> Papervision3D mailing list
> Papervision3D at osflash.org
> http://osflash.org/mailman/listinfo/papervision3d_osflash.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://osflash.org/pipermail/papervision3d_osflash.org/attachments/20090313/720017e0/attachment.html>


More information about the Papervision3D mailing list