Hi guys, I am creating a bitmap material on the fly of some text like so:
var container:Sprite = new Sprite() var txtFormat:TextFormat = new TextFormat(); txtFormat.bold = true; txtFormat.size = 140; txtFormat.color = 0x0000CC; var txt:TextField = new TextField(); txt.text = (1900+i).toString() + ":"; txt.autoSize = TextFieldAutoSize.LEFT; txt.setTextFormat(txtFormat); container.addChild(txt); var bmatData:BitmapData = new BitmapData(500,150,false,0xcccccc); var bmat:Bitmap = new Bitmap(); bmatData.draw(container); var mat:BitmapMaterial = new BitmapMaterial(bmatData); var p:Plane = new Plane(); p.material = mat; // etc This works fine, however when I addOnMouseDown to the plane like so: p.mouseEnabled = true; p.useHandCursor = true; p.addOnMouseDown(clickHandler); The only part that is actually clickable is the part of the bitmap that is not the clone of the textfield. Interestingly if I set the bitmapdata paramater transparent = true; like so: var bmatData:BitmapData = new BitmapData(500,150,true,0xcccccc); Which results in only seeing the bitmaped text, then the mouse event works on the text. Any ideas? See running example here: http://www.allforthecode.co.uk/development/away3d/Spiral/ Thanks Darcey
