Hey Carlos well, DofSprite2D is designed to use a static bitmao as it's sprite contents (so that the blur can be cached), so what you're suggesting wouldn't really be applicable with the current setup we have. However, you can create your own dof sprite by using MovieClipSprite and applying blur to the movieclip objects as their distance from the camera changes.
currently it's a little tricky to access the projected distance from the view once it's been rendered, i think we should look at making this a bit easier in the future! but a good shortcut is the following: var zDepth:Number = view.camera.screen(myMovieClipSprite).z from this value, you can apply your own blur filter to the movieclip hth! Rob On Tue, Sep 29, 2009 at 12:28 AM, carlos.lunetta <[email protected]>wrote: > > Hello all > > I'm wondering if it's possible to implement the Dof utitily from the > DofSprite2D to the MovieClipSprite; I'm in a situation where the > content must be a movieClip running some code, but with the DoF > blurring... > > If not, any suggestions for an easy DoF implementation? The best I can > think of is to use distanceTo to set blur values in the render loop... > > Thanks! -- Rob Bateman Flash Development & Consultancy [email protected] www.infiniteturtles.co.uk www.away3d.com
