Archive for the ‘ANIMATION’ Category

AS3 FOAM 2D Physics Engine

Wednesday, November 7th, 2007

A new AS3 physics engine has been released from generalrelativity and adds itself to the block. It is in early alpha but this is looking pretty good so far. APE, the highly anticipated Motor Physics from polygonal labs and now FOAM, so many wonderful physics toys to build games with!

Current Features:

  • Rigid body simulation
    • Arbitrary convex polygons
    • Circles
    • Cubic Bezier curves
    • Lines
  • Constraints
    • Springs
    • Bungees
  • Easily swappable numerical integrators
    • RK4
    • Euler
    • Midpoint
  • Separation Axis Theorem based collision detection
  • Modular force generation

Source

Demos:

SVN:

  • http://foam-as3.googlecode.com/svn/trunk/

Here’s a list of classes in the repo:

AABR
AABRDetector
AbstractSolver
AxisProjection
BezierDetector
Bungee
Circle
CircleAxisProjection
CircleCircleDetector
CirclePolygonDetector
CollisionResolver
CollisionType
Contact
CubicBezierCurve
Euler
Foam
FOAM_AS3
Friction
GravitationalForceGenerator
Gravity
IBody
ICoarseCollisionDetector
ICollisionFactory
IFineCollisionDetector
IFoamRenderer
IForceGenerator
IODE
IODESolver
ISimulatable
KeyDrivenTorqueGenerator
MathUtil
MouseSpring
PerpetualFall
PhysicsEngine
PointPolygonDetector
PolygonPolygonDetector
Renderable
RenderingUtil
RigidBody
RigidBodyBungee
RigidBodySpring
RK4
RotationMatrix
SATCollisionFactory
ShapeUtil
SimpleFoamRenderer
SimpleForceGenerator
SimpleMap
SimpleOrbit
SimpleParticle
Simplification
Spring
Vector
ZeroGravityToyChest

game on! Thanks Drew!

TweenBencher, Another Flash Animation Kit Speed Performance Test By MosesSupposes

Monday, October 22nd, 2007

MosesSupposes posts a flash animation kit, TweenBencher, for benchmarking speed performance for Flash Animation Kits in AS3.

He also is calling for standards in Flash Animation kits but this is good and bad. I agree a common syntax should be used and the base components should be agreed upon and integrated into Flash, but standards need to be extremely simple and performing systems. We have seen how packaged Tween bloats and I think the Go approach mentioned below is a good direction for that. Adobe seems more open to this though talking about including SWFObject and possibly helping other kits like Papervision3D with performance enhancements.

I think that a standard is already emerging out of the AS3 toolkits leading the way Tweener, TweenLite, AS3Easing , Animation Package, Animation System, Twease and possibly Go (as Fuse had many users) which is the replacement in AS3 for Fuse that is unreleased. I think the developer market will decide that. Also, the big draws to good kits are simplicity, size, performance and maybe most important, the community and author’s willingness to get out there as technology changes. Right now Fuse is a bit behind in the last aspect, I think people are already enjoying the smaller Tweener, TweenLite kits that have simple syntax and are extremely small. Go is going the right direction in making the pieces much smaller as I agree when you have to use two kits there is extra uneeded duplication.

MosesSupposes might release a Fuse 3 still (built from Go?) but that is still in an private beta stage ( for Go- not Fuse) fairly recently and seems a bit unsure as to whether it will be released or not per the blog.

To forewarn the fanbase, this is not a release announcement, no major progress to announce at this time.

I’ve been holding my cards close since I came up with these concepts around January of this year but it’s time I layed ‘em on the table.

Fuse 3 (if built) will be a combination Physics + Tweening Engine with 2D + 3D animation & sequencing capabilities.

The idea is that all details are registered with a central class (probably FuseCentral) that monitors and prevents overlap between various handlers during runtime.

From the description of Go it seems pretty flexible and useful with making your own syntax but sometimes flexibility there creates a partitioned platform as syntaxes emerge, but it can also change with the best simple syntax. I think making it pluggable is more important than custom syntax, actually I wish animation kits all used the same syntax. Right now that is the biggest hurdle getting people to switch. Also, syntax that still works in AS2 is a bit attractive such as Tweener and TweenLite so that work in AS2 and AS3 does not hinder maintenance.

I have an idea cooking, now in private beta, called Go. I will be posting shortly with some background information on what led me to this approach, but right away let me share the concept and architecture with you.

  • Go is a lightweight – around 4k – portable set of base classes for creating your own AS3 animation tools.
  • Go provides an agile, purposeful architecture that is highly extensible.
  • Go is not a does-it-all Kit (a la Fuse), but such a kit can be built using Go. If Fuse was a vending machine, this is more like a knife and a pan and a way to cook for yourself.
  • Go does not require special syntax to use. You can instead, design your own.
  • Go’s engine is efficient, capable of processing a jaw-dropping 10-20,000 individual animations on a typical system. (Disclaimer: it remains to be seen how Go will perform in a real-world setting.)
  • Go is designed to encourage developers to use tweening, physics and 3D together.
  • Go is inspired by the popular Cairngorm framework in its approach. That tiny set of classes does so much, truly useful without dictating your code.

At this point in the Animation Kit game for Flash, real tests matter, and performance will start to become the main focal point as well as simplicity from released and completed packages that have strong communities and user bases. I think the kits that have succeeded well and created platforms have been the most simple and compact (the evolution is this way) that can be used as base kits in other larger systems. Starting with simple core systems that perform is good systems design to help minimize complexity as long as the pieces together aren’t too complex to use for general coders in Actionscript. Looking forward to watching this space progress.

Flash Animation Kit Speed Performance Test (Tweener, TweenLite and Twease) in AS2/AS3 [benchmark]

Sunday, October 21st, 2007

Here is a performance test by Jack at GreenSock who created TweenLite and TweenFilterLite that tests Tweener, TweenLite, Fuse/ZigoEngine and Twease animation kits for flash. This test is only AS2 but in this test TweenLite is quite a ways ahead in means of performance for many tweens via code. I would like to use this in AS3 to check the speeds there as well but from the onset it appears if you have many tweens that the smaller TweenLite kit compared to the AS2 version of Tweener and Twease is the better bet for performance.

Personally I don’t do much AS2 other than maintenance or converting to AS3 so I will be digging into this further this week in AS3 to check the speeds.

In Jack’s AS2 benchmark it appears they are pretty even up until around 150-200 Tweens per half second. If your application is built in AS2 and has more than 200 Tweens per second (very possible in gaming and just to have processing left over for other things) then TweenLite seems like it has less overhead. TweenLite is pulling in a respectable 10FPS on this machine at 500 tweens per .5 seconds.

UPDATE: Jack has updated the test to include AS2 (the dog) and AS3 for Tweener and TweenLite. This version in AS3 the threshold is much much higher and Tweener at 1200 tweens comes in around 10fps on this machine while TweenLite comes in at 1200 tweens at 15-20fps. They again are pretty even until around 800 tweens per second on this test machine where a critical mass is hit, at that point TweenLite starts scaling a bit better and around 1200 tweens is roughly double the FPS. I need to look further at the benchmark test as it is made by one of the authors but Jack is a respectable source and offers the source so anyone is willing to look at this. Results will vary but I think this still shows Tweener has a slightly smaller overhead (which when you compound it with many short tweens it adds up) but does not negate the use or quality of Tweener as 1200 tweens per half second is very respectable thanks to the new AVM2 virtual machine in AS3, but it is always important to perform to save up room for other kits such as Papervision3D and memory for more assets. I think this has been a very worthwhile exercise and I think that a need for a comparison tool for all animation kits in AS2 and AS3 (or just AS3 as we move forward), it will only improve both toolkits. Also, not just straight tweens but bezier, color, filters and general movement.

As always thanks Zeh, Jack and Nate for your excellent toolkits and work that you put out there.

Tweener Robert Penner Easing Equation Visualization Cheat Sheets

Friday, September 14th, 2007

Zeh has posted an excellent cheat sheet for Tweener Easing Penner equations based on the original cheat sheet by Nate Chatellier. This is a very nice visual lookup to see what easing equation you want to use on your motion animations. Usually it is a trial-error approach without some visualization like this unless you were going to Robert Penner’s site visualization tool. It is not specific to Tweener in visualizing the Penner easing equations as many kits use them such as Fuse (AS2), TweenLite, Animation Package etc.

View the large demo here

Download from Tweener on Google Code

Download the source

View Robert Penner’s Easing Visualization Tool

Thanks Zeh/Nate one again and always Robert Penner!

Tweener AS3 extension for color properties “_brightness”, “_contrast” and “_saturation”

Tuesday, August 28th, 2007

Jens Krause beat me to the punch. I had brightness added to Tweener AS3 and was adding contrast and saturation as needed on projects but it has already been done!

WS-Blog has added in special properties for Tweener for brightness, contrast and saturation which was the only part missing from the public version of Tweener. I am not sure of the file size with this addition (Tweener is around 9kb) but it is probably the same size with this in as brightness in my updated copy was the same. Adding special properties in Tweener is quite simple and not enormous amounts of script needed and when compressed in the swf it is very small.

There are other kits like TweenerFilterLite, Animation Package etc that do these right now but you have to wait no longer for these functions in Tweener itself which has quickly become many flash developers favorite in AS3 and since it is compatible with AS2 in the same syntax it makes animation in flash and the learning curve for that from AS2 to AS3 non existent for motion.

Jens has a sample demo, script samples and source on his blog.

JohnK Flash Ad and Good Flash Use

Wednesday, July 18th, 2007

This has to be one of the best ads I have seen online in some time. If you like JohnK cartoons (Ren & Stimpy creator) check out this excellent Comcast ad by JohnK and his production team.

This is a good example of the right amount of Flash in mixed media content environments. Short, quick and entertaining, and gets the message out. JohnK has always been a good proponent of Flash and using it for web cartoons. The Goddamn George Liquor Program and Spumco (now defunct) were essentially the first online cartoons and web toon shops before even CampChaos, joecartoon, icebox etc.

If you are into illustration and web movies of your toons be sure to check out JohnK at all kinds of stuff regularly.

Right now for webtoons, shows, games, interactives, web based apps there is no match to Flash.

3D Flash Perlin Noise Terrains with AS3 and Sandy

Sunday, July 15th, 2007

Rafajafar posted a great tutorial on 3D Flash Perlin Noise dynamic terrain generations with AS3 and Sandy.

Sandy is a flash 3d engine that has been out just a little longer than Papervision3D. The code for Sandy is very clear and it is a great engine. I have experimented with it and found it to be a bit slower it seems that papervision but it has great tools, including an extra 3ds file importer in addition to the Collada and ASE formats that most flash 3d engines support.

Using Perlin Noise is very common in 3d engines to draw large terrains and realistic terrains for 3d games or simulations. This technique makes it very easy to make dynamic terrains or randomly generated terrains, water effects, fire, clouds, whatever your need.

The demo has terrain generation class that can be used to build the dynamic terrain generation and the perlin noise material movement.

Samples using the TerrainCreator class to make different terrains. This could be used to also make level editors and other components of the game making pipeline in flash 3d.

//Water
ter = new TerrainCreator("MyTerrain", 1000000,
128, 9, 6000, 6000, 10,60,60, false,false, 15,
BitmapDataChannel.BLUE, false);
 
//Gentle Hills
ter = new TerrainCreator("MyTerrain", 10, 128, 9,
6000, 6000, 10,120,120, false,false, 15, 7, true);
 
//Smooth Hills
ter = new TerrainCreator("MyTerrain", 10, 128, 9,
6000, 6000, 10,120,120, true,true, 30, 7, true);
 
//Mountainous
ter = new TerrainCreator("MyTerrain", 30, 128, 3,
6000, 6000, 15,100,100, false,false, 10, 7, true);

Click here for the full tutorial and source files on 3D Flash Perlin Noise dynamic terrain generations with AS3 and Sandy.

Now if we could just fast forward 2-3 years on processor power and speed, or get hardware acceleration for Flash…

3D Materials, Texturing and Mapping in AS3 and the Limits of Flash and Software Rendering

Saturday, July 7th, 2007

Who’s got the textures and cool chrome shiny 3d objects in Flash? There have been lots of materials work recently from papervision list developers and away3d developers (away3d is a branch of Papervision3D) and recently it is heating up a bit.

Early on on the papervision3D excitement, flash possibilities in 3d with AS3 specifically, much of that was due to 3d in flash but also the ability to texture and have bump mapping, toon rendering/cell shading and other neat effects like baked lighting, faked real-time lighting, video and movieclips on flash 3d objects and animated textures.

But when it comes to environmental mapping and true 3d reflection that might be simply stretching Flash to a limit that might require hardware acceleration but that isn’t stopping some.

I am not sure if environmental mapping will every be possible on a large scale without hardware acceleration. Pushing the limits could help influence Adobe to the market direction. But then again I never thought I would see the level of 3d in flash that we have and maybe in 2-3 years with multi-core processors it will be possible.

Here’s a snapshot of the current materials and environmental mapping (fake and real attempts).

UnitZeroOne first environment mapping /bump mapping:


Some toon renderings from UnitZeroOne

Recent work by mr doob

Wood

Metal

Weird

Weird 2

Recent work by actionscript architect

Perlin noise algorithm to animate texture real-time into water effect

More environmental mapping effects by the away3d materials developer Fabrice. Fabrice and the away3d developers are really taking off with the papervision3d core. I am seeing lots of engine limits tested and some great work at away3d.

Bumpy Meteor

Flat Lighting on bitmapMaterial

Chrome Ball (dont’ zoom in too far :) )

Did your processor melt yet?

I think that for games and flash effects faking it or real environmental mapping will have to be judged by what is needed for your purpose. I think that Flash player on software rendering can only go so far. So if you have real-time environmental reflections and surroundings it doesn’t always make your gameplay better and it won’t make your demo better if it means removing assets in other areas to make up for the performance drain of software rendering and the pressures it puts on the processor or browser plug-in.

You can still make really killer effects with baked animations, fake environmental mapping, faked dynamic real-time lighting and other effects. Flash, nor silverlight, will not be able to match hardware rendered shaders, per pixel lighting and physics anytime soon. But people are making good progress on this. I think it would be great if hardware acceleration were added to both Silverlight and Flash, with that, a brand new massive game market online, and it will be game on!

3D Pathfinding in AS3

Wednesday, July 4th, 2007

The actionscript architect Paul Spitzer has posted two killer demos of pathfinding using A* in AS3/Flash 9 using the Away3D engine (derivative of Papervision3D that is taking off) and you can download the source for both. These demos not only highlight the pathfinding but also provide editing of the graph to be traversed which could easily be made into a game world editor.

Paul adds to some path finding work with the likes of Zeh using Tweener (the best animation kit for AS3 yet) with the bezier papervision pathfinding and the good work going on at polygonal labs in data structures for games and their usage in pathfinding for gaming in flash.

At the actionscript architect’s blog check out the true 3d path finding in all three dimensions, and a 2d based pathfind using A* algorithm in 3d.

Here’s the 3d pathfinding with true 3d (x,y,z) points used in the path.

Here’s the 2d pathfinding with 3d interface.

Paul has been doing very cool vector work from video on 3d in flash using papervision3D, to being one of the first people making demos for WPF and Silverlight such as the Northface Demo.

If you are working on path finding or gaming in AS3 be sure to check out Paul’s work, Zeh’s bezier pathing in papervision and polygonal labs often.

Best Of Commercial Flash Papervision3D (yet)

Thursday, June 7th, 2007


Here’s some of the best commercial Papervision3d projects so far
(all commercial papervision I have seen so far has made theFWA):

1)  The Brahma Bus interactive project
       by Russian firm PARK Studios.


Customize your own VW Bus, received theFWA recognition.

2) Eye Project
      by
Takayuki Fukatsu aka fladdict

This is a killer use of pixel color mapping to video overall color.  It has papervision in the archives where it uses some more really well done pixel manipulation effects, received theFWA recognition.

3) The Net Eye interface (based on pv3d sample PaperCloud)
      by Neteye


Nice interface based on a pv3d sample project, received theFWA recognition.

*** The authors of papervision3D also have some of the coolest demos with it as well listed here.

Carlo Ulloa (based on pv3d sample Focus – by far the best)
      by Carlo Ulloa


Papervision3d homepage Shark Demo (wait for it, wait for it…)

Very First Papervision3D Star Wars Game by John Grden.


Also the original shader demos by Ralph Hauwert were killer.

About Vector/Web 3d

Papervision3d created by Carlos Ulloa Matesanz, Ralph Hauwert, and last but not least John Grden has really hit a development and design nerve, along with AS3 finally being ready for primetime. People are really excited about projects like this and it just goes back to my point that in the Vector Wars (Adobe vs Microsoft (haxe making a little noise in dev circles as well)) whoever rolls out cross platform 3d harware rendering in their plug in they will pwn.

Whos the Next Leader of 3d on the Web?

Director has been abandoned for new released until 2008 at least for any 3d updates (if we ever see another version).  But Flash could implement OpenGL (which would lead to it maybe being open one day) and Silverlight would implement DirectX but woudl probably stop at implementing OpenGL.  Flash *could* own with hardware rendering but it opens it up to many more plugins which lead to Director being maxed out at 50% market saturation. 

Anyways, it probably won’t happen but today we have some nice 3d engines in Flash that are fast enough in AS3 with its new shiny VM and there have been some nice commercial successes of the wise early adopters of this technology. Papervision3D, Away 3d (possible merging of code), and Sandy have all helped to add to the buzz around AS3.

UPDATE: Check out this Mech Demo that is making the rounds.  The demo has working hit detection and projectiles from the mech as well as animation on the 3d model.

Your Ad Here
Your Ad Here


*drawlogic is proudly powered by WordPress
Entries (RSS) and Comments (RSS).
Your Ad Here Your Ad Here