Well, it turns out that _cube.ownSession.layer was what I was looking for! Thanks!
For anyone interested, here's a snippet of what I did : //render before your manip view.render(); //get the canvas where the cube is rendered (I'm not sure you can always assume it's a Sprite, but it works for me) var canvas:Sprite = _cube.ownSession.layer as Sprite; var bounds:Rectangle = canvas.getBounds(canvas.parent); //create a bitmap the size of the canvas and draw it var bitmap:BitmapData = new BitmapData(bounds.width, bounds.height); var m:Matrix = new Matrix(); m.translate(-bounds.x, -bounds.y); bitmap.draw(canvas, m); // do your bitmap manipulation here //bmp is a Bitmap instance bmp.x = bounds.x; bmp.y = bounds.y; //add this bitmap to the canvas, and clear what away3D has rendered canvas.addChild(bmp); canvas.graphics.clear(); On Jun 10, 4:47 pm, subb <[email protected]> wrote: > Thanks for actually reading my original question :) > > This seem like the place to look. There's also some methods like > getSpriteLayer and getShapeLayer on AbstractRenderSession that might > be related. I guess those objects are set by something external, > because AbstractRenderSession don't do anything with them. > > I will try this when I get home and let you know. > > On Jun 10, 6:21 am, Greg209 <[email protected]> wrote: > > > A potential way (I think) would be to do something along the lines > > of..... > > > aBitmapDataOfSuitableSize.draw(_cube.ownSession.layer); > > > This should draw the ownCanvas sprite of the Object3D into your > > bitmapdata. You'll probably need a matrix to the draw to get it to > > render in the correct location. > > > Give it a try and let us know how it goes. > > > Greg > > > On Jun 10, 9:02 am, Fabrice3D <[email protected]> wrote: > > > > oh I see. > > > To be honest I don't know. > > > ownCanvas generates internally a sprite holder, the one you want > > > but if you can access it... will ask Rob if I can reach him. > > > > Very often, private/protected/internal items are defined that way, > > > because there are other ways > > > to do some things. What do you want to achieve exactly? > > > > Fabrice > > > > On Jun 9, 2010, at 10:36 PM, Mexican Seafood wrote: > > > > > I think what this guy wants is simply to know how to gain access the > > > > canvas object directly. Not how to add filters or anything. Am I right > > > > subb? > > > > > And if that's not what HE wants, I still would like to know that > > > > because that's what I was looking for... > > > > > On Jun 9, 3:38 pm, Fabrice3D <[email protected]> wrote: > > > >> myMesh.ownCanvas = true; > > > >> myMesh.filters = [new GlowFilter(0x99CC66, 64, 64)]; > > > > >> etc etc > > > > >> Fabrice > > > > >> On Jun 9, 2010, at 9:35 PM, subb wrote: > > > > >>> Let me put this in other words : > > > >>> How can I access the canvas object? > > > > >>> (I'm using 3.5.0) > > > > >>> On Jun 9, 2:43 pm, subb <[email protected]> wrote: > > > >>>> Well, I know this, but, like I said, I can't use the filters array > > > >>>> because I want to create a custom filter (unless I use pixel bender, > > > >>>> but I'm trying not to). > > > > >>>> On Jun 9, 1:24 pm, Michael Iv <[email protected]> wrote: > > > > >>>>> SURE YOU CAN! Object3D filters accepts array of filters just like > > > >>>>> a regular > > > >>>>> flash display object.Man there is a lot of examples for this kind > > > >>>>> of stuff > > > >>>>> in the Web . I like Wonderflhttp://wonderfl.net/ > > > >>>>> there are a lot of examples you need there > > > > >>>>> On Wed, Jun 9, 2010 at 5:31 PM, subb <[email protected]> wrote: > > > >>>>>> Well, I've done this step, but I can't access the "canvas" object, > > > >>>>>> so > > > >>>>>> I can't modify it. And I want to create a custom effect using > > > >>>>>> BitmapData, so I cannot use the filters array. > > > > >>>>>> On Jun 9, 10:15 am, Michael Iv <[email protected]> wrote: > > > >>>>>>> make the object ownCanvas=true , then you can apply any filter > > > >>>>>>> you want > > > >>>>>> and > > > >>>>>>> create bitmap effects > > > > >>>>>>> On Wed, Jun 9, 2010 at 5:12 PM, subb <[email protected]> wrote: > > > >>>>>>>> Hi, > > > > >>>>>>>> I'm trying to apply an effect on the result of the rendering > > > >>>>>>>> pass and > > > >>>>>>>> I was wondering if there was an API for this. > > > > >>>>>>>> Basically I want to capture the result of the rendering (ex: the > > > >>>>>>>> projected (2D) representation of a cube) in a bitmap and modify > > > >>>>>>>> that > > > >>>>>>>> bitmap. I want to do this at the object level (on a cube, model, > > > >>>>>>>> etc), > > > >>>>>>>> not on the view. > > > > >>>>>>>> Basically, I want the same functionally that the filters array > > > >>>>>>>> provide, but with custom bitmap filter (not pixel bender). > > > > >>>>>>>> If it's not possible with the current code, where should I look > > > >>>>>>>> for > > > >>>>>>>> adding this functionality? > > > > >>>>>>>> Thanks! > > > > >>>>>>> -- > > > >>>>>>> Michael Ivanov ,Programmer > > > >>>>>>> Neurotech Solutions Ltd. > > > >>>>>>> Flex|Air > > > >>>>>> |3D|Unity|www.neurotechresearch.comhttp://blog.alladvanced.nethttp:// > > > >>>>>>www.meetup.com/GO3D-Games-Opensource-3D/ > > > >>>>>>> Tel:054-4962254 > > > >>>>>>> [email protected] > > > >>>>>>> [email protected] > > > > >>>>> -- > > > >>>>> Michael Ivanov ,Programmer > > > >>>>> Neurotech Solutions Ltd. > > > >>>>> Flex|Air > > > >>>>> |3D|Unity|www.neurotechresearch.comhttp://blog.alladvanced.nethttp://www.meetup... > > > >>>>> Tel:054-4962254 > > > >>>>> [email protected] > > > >>>>> [email protected]
