Flint Particle System Forum - 3D Globe example 2011-06-23T16:32:28+01:00 http://flintparticles.org/forum/ Lussumo Vanilla & Feed Publisher 3D Globe example http://flintparticles.org/forum/comments.php?DiscussionID=90&Focus=405#Comment_405 2008-09-13T12:24:45+01:00 2008-09-15T13:45:26+01:00 sandersnake http://flintparticles.org/forum/account.php?u=4 First of all I would really like to thank you Richard for creating this particle system! It's really awesome. I spend some time now with the new v2 version and created a nice imploding / ... It's really awesome.

I spend some time now with the new v2 version and created a nice imploding / exploding Globe example.
Check the result over here.

]]>
3D Globe example http://flintparticles.org/forum/comments.php?DiscussionID=90&Focus=406#Comment_406 2008-09-15T09:29:38+01:00 2011-06-23T16:32:28+01:00 VKT http://flintparticles.org/forum/account.php?u=62 it's seem so good! great work~. great work~.]]> 3D Globe example http://flintparticles.org/forum/comments.php?DiscussionID=90&Focus=408#Comment_408 2008-09-15T13:45:43+01:00 2011-06-23T16:32:28+01:00 Richard http://flintparticles.org/forum/account.php?u=1 Very nice. 3D Globe example http://flintparticles.org/forum/comments.php?DiscussionID=90&Focus=409#Comment_409 2008-09-16T07:25:23+01:00 2008-09-16T07:28:18+01:00 sandersnake http://flintparticles.org/forum/account.php?u=4 Thanks! Here's the source code (Flex): package { import flash.display.Sprite; import flash.display.StageAlign; import flash.display.StageScaleMode; import ...
Here's the source code (Flex):


package {
import flash.display.Sprite;
import flash.display.StageAlign;
import flash.display.StageScaleMode;
import flash.events.MouseEvent;
import flash.filters.BlurFilter;
import flash.geom.Rectangle;
import flash.text.TextField;
import flash.text.TextFormat;
import flash.text.TextFormatAlign;

import org.flintparticles.common.actions.*;
import org.flintparticles.common.counters.*;
import org.flintparticles.common.displayObjects.*;
import org.flintparticles.common.initializers.*;
import org.flintparticles.threeD.actions.*;
import org.flintparticles.threeD.emitters.Emitter3D;
import org.flintparticles.threeD.geom.Vector3D;
import org.flintparticles.threeD.initializers.*;
import org.flintparticles.threeD.renderers.*;
import org.flintparticles.threeD.renderers.controllers.*;
import org.flintparticles.threeD.zones.*;

public class Globe extends Sprite {
private var w:Number = 400;
private var h:Number = 400;
private var text:TextField;

public function Globe(){
stage.scaleMode = StageScaleMode.NO_SCALE;
stage.align = StageAlign.TOP_LEFT;

text = new TextField();
var format:TextFormat = new TextFormat("Verdana", 36, 0xffffff,null,null,null,null,null,"center");
text.defaultTextFormat = format;
text.x = 0;
text.y = h/2 - 18;
text.width = w;
text.selectable = false;
text.text = "Click";
addChild(text);

stage.addEventListener(MouseEvent.CLICK, init);
}

private function init(e:MouseEvent):void {
stage.removeEventListener(MouseEvent.CLICK, init);
removeChild(text);

var emitter:Emitter3D = new Emitter3D();
emitter.counter = new Blast( 500 );

emitter.addInitializer( new ImageClass( Dot, 1 ) );
emitter.addInitializer( new Position( new SphereZone ( new Vector3D(0, 0, 0), w/2, w/2) ) );
emitter.addInitializer( new ColorInit( 0xffffffff, 0xffffffbe) );
emitter.addAction( new Move() );
emitter.addAction( new GravityWell(50, new Vector3D(0, 0, 0) ) );

var renderer:BitmapRenderer = new BitmapRenderer( new Rectangle( -w/2, -h/2, w, h ), false );
renderer.camera.dolly( -300 );
renderer.camera.lift( 100 );
renderer.camera.target = new Vector3D( 0, 0, 0 );
renderer.addFilter( new BlurFilter( 8, 8, 4 ) );
renderer.addEmitter( emitter );
renderer.x = w/2;
renderer.y = h/2;
addChild( renderer );

emitter.position = new Vector3D( 0, 0, 0, 1 );
emitter.start( );

var orbitter:OrbitCamera = new OrbitCamera( stage, renderer.camera );
orbitter.start();
}
}
}
]]>