glue icon indicating copy to clipboard operation
glue copied to clipboard

Add cocos2d offset format

Open lzubiaur opened this issue 10 years ago • 1 comments

In cocos2d images can be cropped in the sprites sheet but they keep their original size when using them in cocos2d. This feature is useful for animations.

When cropped, sprite’s need to be offset to ensure their texture is drawn in correct alignment to their original size. This PR implement offset for the cocos2d format.

PS: An option might be added to glue to actually crop the image or keep its original size. For instance TexturePacker implements the following options: --trim-mode=None (images are not cropped at all) --trim-mode=Trim (transparency is removed but original size is kept) --trim-mode=Crop (sprite appears in the sheet as if it never had any transparency)

lzubiaur avatar Feb 25 '14 15:02 lzubiaur

Has something similar landed in the CSS generator? This is a welcome feature for CSS animations as well.

Stolzenhain avatar Jun 28 '16 15:06 Stolzenhain