I've been playing with applying flash filters to the viewport object and wanted to share a few examples of what can be done!
This is NOT the effects branch of papervision, this is simply applying filters onto the viewport object, really simple and fast, check it out:
Cel Shading!!
"Dazed" Effect:
Shadow:
How cool is that?! Fast too.
Cel-Shading Code:
Actionscript:
package
{
import org.papervision3d .objects .DisplayObject3D ;
import PaperBase;
import org.papervision3d .objects .parsers .Collada ;
import org.papervision3d .materials .BitmapFileMaterial ;
import flash.filters .*;
public class Main extends PaperBase
{
public var cow:DisplayObject3D;
public var filter:GlowFilter = new GlowFilter ( 0x000000,1 ,5 ,5 ,50 ,1 ,false ,false ) ;
public function Main( ) {
init( 300 , 200 ) ;
viewport.filters = [ filter] ;
}
override protected function init3d( ) :void
{
cow = new Collada( "http://papervision2.com/wp-content/downloads/dae/cow.dae" ) ;
cow.moveDown ( 100 ) ;
cow.scale = 3 ;
cow.pitch ( -30 ) ;
default_scene.addChild ( cow) ;
}
override protected function processFrame( ) :void
{
cow.yaw ( 5 ) ;
}
}
}
Try changing the line:
public var filter:GlowFilter = new GlowFilter (0x000000,1,5,5,50,1,false,false);
To one of the following:
public var filter:BlurFilter = new BlurFilter();
or
public var filter:BevelFilter = new BevelFilter();
or any other filters you can think of!
Have fun :)
Delicious Digg This Post Facebook Stumble This Post