Flint Particle System Forum - RGB Blending 3D Discs examples2010-12-26T10:39:44+00:00http://flintparticles.org/forum/
Lussumo Vanilla & Feed Publisher
RGB Blending 3D Discs exampleshttp://flintparticles.org/forum/comments.php?DiscussionID=91&Focus=410#Comment_4102008-09-16T08:18:02+01:002008-09-16T08:18:41+01:00sandersnakehttp://flintparticles.org/forum/account.php?u=4
In the examples I created over here I used 3 seperated Renderers for Red, Green and Blue.
Adding a Blendmode ("add") to the renderer give's the nice colorfull effect.
Downside for ...
over here I used 3 seperated Renderers for Red, Green and Blue. Adding a Blendmode ("add") to the renderer give's the nice colorfull effect.
Downside for the colorfull effect is that i have to use 3 seperated renderers? Or is there a way giving a blendmode to an emitter?
public class RGBBlendDisc1 extends Sprite { private var w:uint = 400; private var h:uint = 400; private var amount:uint = 200; private var text:TextField; private var loader:Loader;
public function RGBBlendDisc1(){ stage.scaleMode = StageScaleMode.NO_SCALE; stage.align = StageAlign.TOP_LEFT;
createDisc(0xffff0000, 0xffffcc33, new Vector3D(0, 0, 0), new Vector3D(1, 0, 0)); createDisc(0xff00ff00, 0xff33ffcc, new Vector3D(0, 0, 0), new Vector3D(0, 1, 0)); createDisc(0xff0000ff, 0xffcc33ff, new Vector3D(0, 0, 0), new Vector3D(0, 0, 1)); }
private function createDisc(color1:uint, color2:uint, point1:Vector3D, point2:Vector3D):void { var emitter:Emitter3D = new Emitter3D(); emitter.counter = new Blast( amount );
emitter.addInitializer( new SharedImage( new Dot( 1 ) ) ); emitter.addInitializer( new Position( new DiscZone(point1, point2, 100, 100 ) ) ); emitter.addInitializer( new ColorInit( color1, color2) ); emitter.addAction( new Move() ); emitter.addAction( new GravityWell(5, new Vector3D(0, 0, 0) ) );
var orbitter:OrbitCamera = new OrbitCamera( stage, renderer.camera ); orbitter.start(); } } } ]]>
RGB Blending 3D Discs exampleshttp://flintparticles.org/forum/comments.php?DiscussionID=91&Focus=411#Comment_4112008-09-16T09:45:52+01:002008-09-16T09:46:08+01:00Richardhttp://flintparticles.org/forum/account.php?u=1
These examples are looking great. Have you found any bugs yet, or is it all working fine?
Re: blendMode. Flash applies blend modes to display objects, so to separately apply blendModes to each ...
Re: blendMode. Flash applies blend modes to display objects, so to separately apply blendModes to each emitter's output they have to use different display objects, hence needing a new renderer for each emitter.
If you use display objects rather than pixels for the particles, you can apply a blend mode to each particle's image and it will be used when drawing the particle, but this means you can't use a pixel renderer - you have to use a bitmap renderer or display object renderer and use a display object of some form for each particle.
I haven't created an initializer to do this, but probably will at some point. I am currently concentrating on the away3d and papervision3d renderers.]]>
RGB Blending 3D Discs exampleshttp://flintparticles.org/forum/comments.php?DiscussionID=91&Focus=412#Comment_4122008-09-16T10:41:04+01:002010-12-26T10:39:44+00:00sandersnakehttp://flintparticles.org/forum/account.php?u=4
I think i just found one little bug with the explosion action.
You have to fill in a very large number to get a bit of an explosion
//emitter.addAction( new Explosion( 10000, new Vector3D(0, 0, ...
You have to fill in a very large number to get a bit of an explosion
//emitter.addAction( new Explosion( 10000, new Vector3D(0, 0, 0)));
Thanks for clearing out the blending mode stuff. If i have some time i'll dive into it.
Good luck with the papervision3d renderers, really looking forward to it!]]>
RGB Blending 3D Discs exampleshttp://flintparticles.org/forum/comments.php?DiscussionID=91&Focus=417#Comment_4172008-09-20T11:57:49+01:002010-12-26T10:39:44+00:00Richardhttp://flintparticles.org/forum/account.php?u=1
I've fixed the explosion thing in Alpha 2 - An explosion of power 1 should have a visible effect now.