Calling the Flash 10 beta player 3D API from a Laszlo app
Sunday, May 18th, 2008The beta Flash 10 compiler and player from Adobe support some new 3D graphics APIs.
I tried downloading the new flex compiler, and adding support to the swf9 kernel for the three dimensional rotation attribtutes, rotationX, rotationY, and rotationZ.
After adding these attributes to LzView, an app can be written which, for example, animates the rotation of a view about the X axis:
this.animate('rotationX', 360, 2000, true);
Compiling to Flash 10 does not seem to require any special changes to the Laszlo compiler, just an update to the Flex SDK compiler. The support looks somewhat preliminary now, because I had to set the rotationX var of the sprite by saying "this['rotationX']", as the flex compiler did not recognize sprite.rotationX yet.
This is an example of a swf9 test case, with rotation about X and Y added:
|
|
Thanks to Raju Bitter for making a quicktime movie of this, so you don't need the Flash 10 player to see it!








