3DFA hobby scripter
motion blur effect
Does anyone know how to make an effect like in that game?
http://www.kongregate.com/games/Stuv/shape-wars
It looks like the elements are drawn in a bitmapData object and on every second a blur filter is applied on it.
It could also be possible that the elements will be cloned and blurred to make such an effect.
If you want to know how it works with the bitmapData, I will have to do some experiments first. I think I can explain it to you on the weekend.
3DFA hobby scripter
That "motion" blur or recursive blurring is quite easy and there is few example floating around.. However I run into some trouble making a 3dfa example so no demo yet
nonworking code basics of recursive blur:
...for every frame...
// draw you stuff in stage..
....
// copy stage to bitmap
bmpMain.draw(stage);
// apply blurring and colormatrix if needed (like if you like fade color values )
bmpMain.applyFilter(bmpMain,rectMain,pntOrigin,blu r);
bmpMain.applyFilter(bmpMain,rectMain,pntOrigin,col orMatrix);
Ok, I got it working in flash export... demo movie included:
Attached Files
3DFA hobby scripter
Wow thanks,
with that code I can make so many effects possible.
e.g: this test (blur.movie )
Last edited by LewxX²; 03-20-2008 at 02:19 PM .
For whole stage blur try 3dfa clones sample and add..
this at the start of the starting script:
Code:
var buf = new Bitmap();
addChild(buf);
swapChildren(buf,element ("ball"));
blur = new BlurFilter(4, 4, 1);
buf.bitmapData = new BitmapData(stage.stageWidth, stage.stageHeight, false, 0x000000);
and this to "on every frame" script:
Code:
buf.bitmapData.draw(stage);
buf.bitmapData.applyFilter(buf.bitmapData, new Rectangle(0,0,stage.stageWidth, stage.stageHeight), new Point(0,0), blur);
3DFA hobby scripter
awesome!
I've created a new movie, too:
here (and here the .movie file)
BTW:
where do you get the "new BlurFilter()" filter-syntax from?
I can't find a filter list in 3DFA
Last edited by LewxX²; 03-20-2008 at 05:46 PM .
From Adobe flash9/as3 doc website http://livedocs.adobe.com/flash/9.0/...riptLangRefV3/
It is bit slow from there but I think there is pdf version available from this page.. http://www.adobe.com/support/documentation/en/flash/
Senior Member
3DFA hobby scripter
Yeah i just love what can be done with these effect ^^
Senior Member
I want to use this effect in a game, but the blur trail is too long! How can I make it "Dissolve" faster so that the trail is shorter?
Zoranan
use colortransform after blurring:
var r1 = new Rectangle(0,0,stage.stageWidth, stage.stageHeight)
// check 3dfa colortransform help....
var ct1 = new ColorTransform (0.99, 0.99, 0.99, 0, 0, 0, 0, 0);
buf.bitmapData.colorTransform (r2, ct1);
Posting Permissions
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
Forum Rules
Click Here to Expand Forum to Full Width