I dont get an error but i cant load the surface with height.
(both jpg 1000X1000)

I am trying to follow http://www.closier.nl/blog/?p=62

the example from above uses flash and I use flashbuilder.

[Embed(source=“grass2.jpg”)] private var grassBitmap:Class;
[Embed(source=“redmap.jpg”)] private var elevationBitmap:Class;
private var grassTexture:BitmapData;
private var elevationTexture:BitmapData;
...
var extrude:SkinExtrude;
  var bitmap:Bitmap = new grassBitmap() as Bitmap;
  grassTexture = bitmap.bitmapData;

  var bitmap2:Bitmap = new elevationBitmap() as Bitmap;
  elevationTexture = bitmap2.bitmapData;
  // mygrass = new BitmapMaterial(Cast.bitmap(grassTexture));


  var source_elevation:BitmapData = elevationTexture;
  var mat:BitmapMaterial = new
BitmapMaterial(Cast.bitmap(grassTexture) , {smooth:true});
  var elevate:Elevation = new Elevation();

  extrude = new SkinExtrude(elevate.generate(source_elevation, “r”, 5,
5, 50, 50, 4), {material:mat, recenter:true, closepath:false,
coverall:true, subdivision:1, bothsides:false, flip:true});
  extrude.rotationX = 90;
  view.scene.addChild(extrude);

Reply via email to