The VG Resource
Improved Icons - Printable Version

+- The VG Resource (https://www.vg-resource.com)
+-- Forum: Archive (https://www.vg-resource.com/forum-65.html)
+--- Forum: July 2014 Archive (https://www.vg-resource.com/forum-139.html)
+---- Forum: Main Stuff (https://www.vg-resource.com/forum-1.html)
+----- Forum: Site Discussion (https://www.vg-resource.com/forum-3.html)
+----- Thread: Improved Icons (/thread-24421.html)

Pages: 1 2 3 4 5


RE: Improved Icons - Dazz - 01-12-2014

I think doubling could cause some extremely inflated sprites, or severe cropping...

I don't think the temporary solution looks all that bad, but that's me. What does everyone else think?
[Image: Fxc57zN.png]


RE: Improved Icons - Jermungandr - 01-12-2014

(01-12-2014, 04:27 AM)Dazz Wrote: The first link you posted for the background is almost the right thing I was aiming for, but setting limitations to it;
checkbox to trim all empty pixels surrounding the outcome sprite
if out larger than the maximum accepted size, fail.
batch processable.
How exactly do you want batch processing to work here. Are we talking, like, uploading all the sprites to a folder via ftp and just mass-editing everything in said folder like I did with the background remover? Or are we talking like uploading and editing twenty sprite images at once via an on-page uploader. Both are do-able.


RE: Improved Icons - Dazz - 01-12-2014

Whichever you think will be easier; I'd imagine a folder based process would be easiest, but then that does add extra complications. There wouldn't be a way of dragging and dropping a bunch of images with the on-page system, would there? Rather than 1 at a time?


RE: Improved Icons - Jermungandr - 01-12-2014

Drag 'n drop would require html5 which is a bit beyond my abilities at the moment. However I think this does what you want:

http://www.jermungandr.net/experiments/tsr-cropper.rar

How to use:
- Upload images or a folder containing images to the "original" folder.
- Open "index.php". Alter any of the default settings for each image as needed, then hit refresh to apply changes.
- Altered files will be saved in the "result" folder.

Here is a demo:
http://www.jermungandr.net/experiments/tsr-cropper/index.php

Features:
- By default it tries to apply a transparency based on the color in position (0,0). This can be turned off if it is causing problems.
- Auto-Cropping attempts to trim empty pixels around the image in order to decrease the size of the file. This is on by default.
- If the image is less than half the size of the maximum 148x125 allowed file size, it offers the option to resize the image to fill more space, to a maximum of 4 times.
- If the image size is greater than the maximum allowed size, instead of failing the file altogether it attempts to simply crop the image. In these cases it will offer you a chance to decide how the image will be positioned.

I wish I could make you a java console or something so you can do this all right on your computer without involving a browser, but unfortunately all I know is web coding, so I hope this will be enough.


RE: Improved Icons - Dazz - 01-13-2014

This is awesome man, I'll give this a try later when Pete is around so we can both become accustomed with it.


RE: Improved Icons - puggsoy - 01-13-2014

I'm out of town atm (should be back tomorrow), but this looks really cool. I'd be glad to make both game and sheet icons for all games I've submitted to.

Also, just so you know, I can make native Windows console programs, so if needed/wanted I can make such a version of Drshnaps's app.


RE: Improved Icons - Jermungandr - 01-15-2014

Oh gosh I am tooting my own horn quite a bit recently and I apologize, but I just remembered I started another project a while ago which might actually prove useful for this, so tonight I worked on finishing it up.

Here: http://www.jermungandr.net/experiments/sprite-chopper/index.php

You have to upload a file to actually see the demonstration on this one, but basically what it does is you upload a whole sprite sheet and it cuts out each individual sprite into individual image files with the background color removed (by default).

So basically all you would have to do for the majority of the sheets is just process it through this, which is fairly quick, and then save your sprite of choice from the output.

Using it is super simple; with most sheets all you have to do is select a sheet and hit "go", as the default settings should do the trick for most files. However if you need to change the settings:

- Transparency Mode "Back": Uses the overall background color of the sheet as the transparency color. Color is determined by the pixel in coordinates (0,0).

- Transparency Mode "Box": This mode is for if the sprites on the sheet are saved with little box containers around them, like this sheet here. It will attempt to choose the transparency by color of the box the sprite lies on.

- Checking the "x2" box will double the size of the output images.

This is not guaranteed to work with every sheet because it depends a lot on the person creating it using a sensible arrangement and the use of separator lines may sometimes fool the code, but I'd say it should work for about 95% of all sprite sheets.

... anyways I'm going to go find a hole to climb into now.


RE: Improved Icons - Dazz - 01-15-2014

Holy crap, this could be amazing... Not got a chance to try it out yet but a quick question;
Could you have it work with the restrictions we put in place for the icon size? So it will insert it into an image of the icon's maximum resolution without trimming (we've removed the trimming option because it caused problems with clicking the icon without javascript enabled)


Gave it a quick wizz on your link; if this can be batched, Jeez we'll be rolling in icons.


RE: Improved Icons - Jermungandr - 01-15-2014

That is possible ... but now you have me curious about what the code for creating these icons looks like. You should be able to accomplish what you're trying to create with nothing more than simple CSS code; no javascript should be required.

This is the method I've been using: http://www.jermungandr.net/experiments/tsr-justify/index.php

[EDIT] Oh ... there are other topics about this ... one of which you show off the format you're using. Once again my skills of observation fail me.

I'm not sure exactly what javascript you are trying to utilize that would be causing issues, but you might want to try not simply overlaying the sprite image with an <img> tag, but rather make it the background of the iconbody <div> tag with no-repeats and center alignment. That should make sprite images of the wrong size less of an issue ... even if the image size is greater than the limit, as it would take care of cropping for you.


RE: Improved Icons - Dazz - 01-16-2014

That... Does make total sense. I've never used CSS to make a div a clickable item. That's pretty clever; I'll talk to Pete about whether there might for some reason be an issue with this.


RE: Improved Icons - Petie - 01-16-2014

He's not using CSS to make the div clickable - he's wrapping the entire thing in a link tag which, until HTML5, was not valid form of doing things. Apparently, it's now possible to stick block-level elements within <a></a> tags which makes this entire discussion pointless. We can definitely use variable sized images up to the max, set them as a background, center that background, and then just make the entire div clickable directly.


RE: Improved Icons - Cyrus Annihilator - 01-17-2014

I would like to download the list, to find my sheets faster. But when I download from google drive the file comes corrupted.

Do you have an alternative link?


RE: Improved Icons - Petie - 01-17-2014

This is likely just due to the massive amount of data in that list. Unfortunately, there is no alternate URL available but you should be able to sort, filter, and search based on the submitters right from Google Drive.

Additionally, downloading the desktop app may sync a working copy of the file to your computer directly.


RE: Improved Icons - Jermungandr - 01-17-2014

Well, I spent too much time on this, mostly due to a single error that took me forever to figure out, but I finally completed something that might actually be useful for once:

The Super Lazy Icon Dispenser

It's so easy any idiot can use it. All you do is upload a file, and then it returns a ton of possible icons. Then all you have to do is pick which icon you like the best and click on it, and it will bring you to the image for downloading. No effort whatsoever!

Unfortunately there are limitations to how much memory the script can process at a time (and I don't seem to have the ability to alter my .htaccess), so spritesheets with extremely large dimensions may return an error. If someone wanted to make a console version of this it would probably eliminate that issue, but for the majority of sheets that shouldn't be a problem.


RE: Improved Icons - Ton - 01-17-2014

Awesome! I look forward to somehow breaking this program!