Easier Custom GUI Images
by Ryan Strandberg · in Torque 2D Beginner · 10/27/2014 (8:09 pm) · 4 replies
I've spent the last little while trying to figure out custom GUI images, and I'm proud to say that I think I've figured most of it out. That said I'm having trouble finding any less tedious ways of "cutting up" my custom images. I'm currently doing it manually with an image editor, but something this simple must have a program to do it, right? Google didn't help since I don't really know what this process is called, so I'm just wondering if anyone knows an easier way?
Thanks in advance.
Thanks in advance.
About the author
#2
In the mean time, just remember that you don't have to have exactly one pixel of your separator color between pieces - as long as the top left pixel is the separator color. In fact, it's probably better (but perhaps it doesn't matter) to use power-of-twos image sizes and then just match the part order for the image you need.
Unfortunately, no one ever got around to "sprite-ifying" the rest of the controls so you can't just use individual cut images for the miscellaneous stuff like scroll controls, window controls, etc....
10/27/2014 (9:38 pm)
Editing the "nine-slice" images is a pain, no matter how you approach it. Our UI guys just used Photoshop, I'm guessing they had a few templates set up. Maybe if we're lucky one of the remaining GG guys can drop a hint here.In the mean time, just remember that you don't have to have exactly one pixel of your separator color between pieces - as long as the top left pixel is the separator color. In fact, it's probably better (but perhaps it doesn't matter) to use power-of-twos image sizes and then just match the part order for the image you need.
Unfortunately, no one ever got around to "sprite-ifying" the rest of the controls so you can't just use individual cut images for the miscellaneous stuff like scroll controls, window controls, etc....
#3
10/28/2014 (5:41 pm)
Darn, thanks though. Been using gimp to slice it up. Just found it tedious.
#4
10/28/2014 (5:42 pm)
I know your pain.... lol
Associate Simon Love
What would you say is a better way to handle this?
As this is all in the C++ source code, it's simply a matter of determining how the .png is analyzed. The trick would be to find a way which makes everyone happy.
I personally don't see the current png layout as a major hurdle.