Here is the source code for the Magic Carpet demo, just unpack it in your project directory of choice and import the project in Flex Builder, making sure to resolve the dependancies as it makes use of the following packages:
Let me explain the modifications in APE: i just wanted the engine to perform the timestep in a fixed fashion, so i initially modified it to accept a value, expressed in Hz, that represents the integrator’s timestep to be used, this way no matter if different machines have different framerates, animating will be the same everywhere.
Then i was in need to rebuild the mesh at runtime since i wanted to be able to define tesselation and spacing directly from the UI: by trying to modify the values i got huge slowdowns and hangs that i have no clue of what that was, until later on i realized that APE was creating and attaching hundred of Sprite objects to its container. I tried to use a NullSprite object since i thought it would be ok to provide a reference to a common null-painter object, but that won’t did the trick, so i just settled things once and for all and removed most of the “presentation” logic in it as also i really had no need to have Sprite objects instanced and added for every particle and spring.
Download Magic Carpet v1.0b5 src
*UPDATE*
I uploaded a video on YouTube if you just want to take a look at it:
11 Responses
kso
August 21st, 2007 at 13:15 1Sorry for this newbie’s question :) but I’m trying to test your application and I have problems with it. I created a Flex project, I unzip your file in this project, I downloaded all the missing libraries (papervision and aswing) and I put these lines in my mxml file.
And of course it doesn’t work (it stays in the ‘initializing’ state).
Is it possible to make a brief tutorial for newbies like me? :D
Congratulations for your job is really impressive!
Fardeen
August 21st, 2007 at 15:54 2Amazing work . Thx so much 4 sharing :)
Magic Carpet - APE
August 21st, 2007 at 21:04 3[...] Bua created a Magic Carpet using Papervison3D and [...]
Fábio Pedrosa » Magic Carpet
August 22nd, 2007 at 20:02 4[...] You can play with it here, and get all the source code here. [...]
michael
August 31st, 2007 at 9:44 5which format did you use in this example?collada or md2?
i mean how to get the 3Dfiles with phsicx,thx,
actionscript microcosmos » Blog Archive » In shortness of time…
September 5th, 2007 at 7:55 6[...] stumbled across some interesting AS3-realizations. At first a “Magic Carpet Demo” ( very nice! ), developed by bringing together APE and Papervision3D. Secondly [...]
c.moore
September 19th, 2007 at 16:57 7http://smallfly.com/ … this carpet would be fun to play with on a multitouch screen…
Not sure how well performance would hold up…. but man would it be fun…
The Magic Carpet at Manuel’s Coding Blog
December 13th, 2007 at 9:11 8[...] « Changes Carpet’s sources [...]
RIABG.org » Òъûшõñýø úøûøüчõтð ø Papervision 3D
December 19th, 2007 at 17:20 9[...] ýþòð ôõüþýÑÂтрðцøѠýð òъ÷üþöýþÑÂтøтõ ýð Papervision. Øüð ø ÑÂþрѠ÷ð ûюñþÿøтýøтõ….ÑÂûõ÷тõ ÿþ ÑÂтðрýøцðтð ýðôþûу ø ÑÂø [...]
xero / fontvir.us
January 7th, 2008 at 15:26 10this is a great demo! thanx alot for sharing the sources. i’d like to see this redone it papversion3D 2.0!
enars
January 25th, 2008 at 14:56 11very eyecatching ;)
Leave a reply