Sparrow-Framework icon indicating copy to clipboard operation
Sparrow-Framework copied to clipboard

Store the result of a tween as a GIF file

Open Briahas opened this issue 8 years ago • 6 comments

Hi, I'm trying to perform subj but with no luck. Is it possible somehow?

Briahas avatar Jun 10 '16 09:06 Briahas

What exactly are you trying to do - store the result of a tween as a GIF file?

PrimaryFeather avatar Jun 13 '16 12:06 PrimaryFeather

Yes

Briahas avatar Jun 13 '16 14:06 Briahas

Sparrow does not contain such a functionality, sorry!

PrimaryFeather avatar Jun 17 '16 10:06 PrimaryFeather

@racarone - in the latest version, is there a way to store the content of a bitmap object or the stage to a file? If that's possible, you can probably find some other library to link those images together in one GIF.

PrimaryFeather avatar Jun 17 '16 10:06 PrimaryFeather

You can get a UIImage representation of the stage with the drawToImage method. Though there is also a debugQuickLookObject method on DisplayObject that will return a UIImage representation of the display object and its contents. You could, like Daniel said, use another library and link the images together after capturing a UIImage from the display object for each frame you needed.

racarone avatar Jun 17 '16 12:06 racarone

@racarone Thanks for answers. My Sparrow version is too low for this (1.2). I did it through [[SPTexture alloc] initWithWidth:....] -> [[SPBitmapData alloc] initWithTexture:] -> [bmap drawDisplayObject:sprite]

Briahas avatar Jun 17 '16 18:06 Briahas