theunreplicated / spriteme

Automatically exported from code.google.com/p/spriteme
0 stars 0 forks source link

sprite image editor #11

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
A huge issue with sprites is maintenance. What if one of the embedded
images changes - it's a pain to regenerate the entire sprite. And it's
critical not to change any of the other embedded images' positions so their
CSS doesn't have to change.

During sprite generation, we could add a comment to the PNG that contains
the URL and bounding box (top-left, lower-right) of each embedded image.
This shouldn't be too much extra data. Later, when changes were necessary,
we could have a special spriteme image editor that would recognize each
embedded image as a hotspot and let the user rearrange and modify the sprite. 

To avoid the size increase of the comment, have an option to store this in
a separate manifest file that could be used later during editing.

Original issue reported on code.google.com by stevesou...@gmail.com on 1 Sep 2009 at 5:54

GoogleCodeExporter commented 9 years ago
CSS itself can probably be used to get position coordinates for the sprite - as 
sprites are not used without CSS.

It's probably worth treating each sprite element as an image in itself in the 
interface  and display it's boundaries on sprite preview image (I went and 
created it 
as separate request #65). In this case, it will be easier to just have "upload 
new 
version" next to each image so user can upload from desktop or point at the URL 
to 
replace this portion of the sprite with new version.

Original comment by sergey.c...@gmail.com on 20 Sep 2009 at 2:20

GoogleCodeExporter commented 9 years ago

Original comment by stevesou...@gmail.com on 22 Sep 2009 at 7:43

GoogleCodeExporter commented 9 years ago

Original comment by stevesou...@gmail.com on 22 Sep 2009 at 5:27

GoogleCodeExporter commented 9 years ago
spriteutils project will include some work on sprite layout/metadata format for 
automated builds and more.

If SpriteMe (or CoolRunnings to be exact) was able to output the results of 
spriting in this format (in addition to human-readable Export CSS page), the 
tool you're talking about could be used universally.

Here's a sample of the format envisioned:
https://github.com/andrewschaaf/spriteutils/blob/master/samples/sharingbuttons.j
son

Original comment by sergey.c...@gmail.com on 17 Nov 2010 at 6:27