sprite3D rotate

Software: Away3D 4.x

zbw, Newbie
Posted: 09 April 2012 06:49 AM   Total Posts: 12

var testMaterial: TextureMaterial = new TextureMaterial (new BitmapTexture (new CarSkin (). bitmapData));
weehlsNaterial.alphaBlending = true;
var sprite: Sprite3D = new Sprite3D (testMaterial, 100, 100);
sprite.position = worldPosition;
/ / sprite.rotationX = 90;
/ / sprite.rotationY = 90;
/ / sprite.rotationZ = 90;
Or
/ / sprite.rotationX + = 90;
/ / sprite.rotationY + = 90;
/ / sprite.rotationZ + = 90;
Or
/ / sprite.transform.appendRotation (-90, new Vector3D (1, 0, 0), sprite.position);

the _view.scene.addChild (sprite);
Why I can not rotate sprite3D? sprite3D is not to rotate?
Master to help me

   

Avatar
kurono, Sr. Member
Posted: 10 April 2012 12:52 AM   Total Posts: 103   [ # 1 ]

Sprite3D always faces to current view’s camera. So if you want to rotate it, do it within loop every “onEnterFrame”. Or simply use flat plane with texture instead.

   

zbw, Newbie
Posted: 10 April 2012 04:31 AM   Total Posts: 12   [ # 2 ]

Thank you, kurono.

original sprite3D the no direct rotation.

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X