View Mode: Normal | Article List
as3: ActionQueue
[ 2009-08-16 22:50:47 | Author: liuhuan ]
ActionQueue is a useful class executing actions in queue. You can download it at: http://www.libspark.org/svn/as3/ActionQueue/ActionQueue.as
Read More...
package {
import flash.display.*;
import flash.events.*;
public class Main extends Sprite {
var aq:ActionQueue;
public function Main():void {
aq = new ActionQueue();
initAction();
...import flash.display.*;
import flash.events.*;
public class Main extends Sprite {
var aq:ActionQueue;
public function Main():void {
aq = new ActionQueue();
initAction();
Read More...
PV3D: Bump map
[ 2009-08-16 14:06:16 | Author: liuhuan ]
var bmp:Bitmap=new Bitmap(new Skin1(640,480));
var bmpBump:Bitmap=new Bitmap(new Bump(640,480));
var bmpMaterial:BitmapMaterial=new BitmapMaterial(bmp.bitmapData,true);
var shader:Shader=new PhongShader(light,0xFFFFFF,0x333333,50,bmpBump.bitmapData);
var shadedMaterial:ShadedMaterial=new
...var bmpBump:Bitmap=new Bitmap(new Bump(640,480));
var bmpMaterial:BitmapMaterial=new BitmapMaterial(bmp.bitmapData,true);
var shader:Shader=new PhongShader(light,0xFFFFFF,0x333333,50,bmpBump.bitmapData);
var shadedMaterial:ShadedMaterial=new
Read More...
PV3d: Star Sky
[ 2009-08-16 09:55:47 | Author: liuhuan ]
star disperse algorithm:
star.x = Math.sin(radian) * radius;
star.y = Math.floor(Math.random() * diameter);
star.z = Math.cos(radian) * radius;
star.y = Math.floor(Math.random() * diameter);
star.z = Math.cos(radian) * radius;
FLARToolKit
[ 2009-08-13 22:58:41 | Author: liuhuan ]
http://www.libspark.org/wiki/saqoosha/FLARToolKit/en
FLARToolKit recognize the marker from input image. and calculate its orientation and position in 3D world.
examples: http://flash.tarotaro.org/blog/
also: http://saqoosha.net/2008/08/31/1221/
FLARToolKit recognize the marker from input image. and calculate its orientation and position in 3D world.
examples: http://flash.tarotaro.org/blog/
also: http://saqoosha.net/2008/08/31/1221/
AS3 Particle
[ 2009-08-12 17:47:08 | Author: liuhuan ]
An experiment with as3 bitmapdata.
Read More...
import fl.controls.CheckBox;
var ease:Boolean = false;
var drawHolder:Sprite = new Sprite();
var line:Shape = new Shape();
drawHolder.addChild(line);
this.addChild(drawHolder);
stage.addEventListener(MouseEvent.MOUSE_DOWN , onMouseDownHandler);
var arr_particle:Array = new Array();
var textFormat:TextFormat = new TextFormat();
...var ease:Boolean = false;
var drawHolder:Sprite = new Sprite();
var line:Shape = new Shape();
drawHolder.addChild(line);
this.addChild(drawHolder);
stage.addEventListener(MouseEvent.MOUSE_DOWN , onMouseDownHandler);
var arr_particle:Array = new Array();
var textFormat:TextFormat = new TextFormat();
Read More...