Webdevotion.be

Developer for the Flash Platform

Changing a material on a cube at runtime

Changing a material on a cube at runtime with Papervision3D is easy!


public function setSnapshotOnVideo( bmp : Bitmap ) : void
{
// create your new material
var bMat : BitmapMaterial = new BitmapMaterial( bmp.bitmapData, false );
// videoBlok is a cube
videoBlok.replaceMaterialByName(bMat,"back");
}



Tagged as + Categorized as Papervision3D

Leave a Reply