Wesnoth-TC: new tool for artists (Qt4 UI needs betatesters!)
Moderator: Forum Moderators
Forum rules
Before posting critique in this forum, you must read the following thread:
Before posting critique in this forum, you must read the following thread:
Wesnoth-TC: new tool for artists (Qt4 UI needs betatesters!)
Wesnoth-TC is a command-line utility that takes a PNG file (or a list of them) as argument and iterates over each one creating separate, team-colorized copies. For instance, wesnoth-tc foo.png creates foo-TC-1.png, foo-TC-2.png, etc., where [1-9] are the default side numbers corresponding to the default team colors (1 = red, 2 = blue, etc.).
Wesnoth-TC can be used to team-colorize units with the magenta key, or flags with the flag_rgb key. It all depends on the parameters you pass to it, with the default source palette being the magenta key, and targets, the different team colors. You can also define your own color ranges and key palettes if you want to.
The latest version is 1.5.1, and can be downloaded from this page in my website, or alternatively, from SourceForge.net.
The distribution includes the full source code, partially taken from the mainline engine, and a sample image that is your generic magenta key swatch, taken from our wiki. For more details on using and installing, read the included README and INSTALL files, respectively.
I'd be particularly interested in seeing a (hopefully cross-platform) GUI frontend to this program so that it is more useful to our less tech-savvy artists.
EDIT: since my website is currently disabled due to funding issues, use the SF.net link instead.
Wesnoth-TC can be used to team-colorize units with the magenta key, or flags with the flag_rgb key. It all depends on the parameters you pass to it, with the default source palette being the magenta key, and targets, the different team colors. You can also define your own color ranges and key palettes if you want to.
The latest version is 1.5.1, and can be downloaded from this page in my website, or alternatively, from SourceForge.net.
The distribution includes the full source code, partially taken from the mainline engine, and a sample image that is your generic magenta key swatch, taken from our wiki. For more details on using and installing, read the included README and INSTALL files, respectively.
I'd be particularly interested in seeing a (hopefully cross-platform) GUI frontend to this program so that it is more useful to our less tech-savvy artists.
EDIT: since my website is currently disabled due to funding issues, use the SF.net link instead.
Last edited by Iris on July 31st, 2012, 5:02 am, edited 9 times in total.
Reason: Added SF.net project link
Reason: Added SF.net project link
Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
- thespaceinvader
- Retired Art Director
- Posts: 8414
- Joined: August 25th, 2007, 10:12 am
- Location: Oxford, UK
- Contact:
Re: Wesnoth-TC: new tool for artists
Awesome.
I share your hope that this will be ported to windows =) I'd do so if I were capable.
I share your hope that this will be ported to windows =) I'd do so if I were capable.
http://thespaceinvader.co.uk | http://thespaceinvader.deviantart.com
Back to work. Current projects: Catching up on commits. Picking Meridia back up. Sprite animations, many and varied.
Back to work. Current projects: Catching up on commits. Picking Meridia back up. Sprite animations, many and varied.
Re: Wesnoth-TC: new tool for artists
AI just reported compilation errors on libc 2.8. Release 1.0.0a fixes them.
Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
-
- macOS Packager
- Posts: 239
- Joined: April 17th, 2004, 5:16 pm
- Location: Ontario, Canada
- Contact:
Re: Wesnoth-TC: new tool for artists
I've made an initial version of a Mac interface. There's a couple things it's missing, like the ability to actually save files, but that can be added later. Please let me know what features you would actually use.
Download: Wesnoth_TC_1.0.zip
Download: Wesnoth_TC_1.0.zip
Last edited by penguin on August 10th, 2009, 4:53 pm, edited 1 time in total.
Reason: Add screenshot
Reason: Add screenshot
Re: Wesnoth-TC: new tool for artists
And now with a git repository:
http://gitorious.org/wesnoth-tc
I'll be cleaning up a lot of the source code of the command line based tool and adding a ~PAL()-like conversion.
http://gitorious.org/wesnoth-tc
I'll be cleaning up a lot of the source code of the command line based tool and adding a ~PAL()-like conversion.
Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
Re: Wesnoth-TC: new tool for artists
For those of us who don't yet have a good grasp on the technical aspects of the game and its use of art, what would this app be used for? My understanding is that units can be recolored with WML (eg Tallin).
-
- Moderator Emeritus
- Posts: 2232
- Joined: March 26th, 2004, 10:58 pm
- Location: New York, New York
Re: Wesnoth-TC: new tool for artists
I assume it's designed so that you can see the effects of your team colour work, while you're working on the sprite, without having to load it up into Wesnoth.A-Red wrote:For those of us who don't yet have a good grasp on the technical aspects of the game and its use of art, what would this app be used for? My understanding is that units can be recolored with WML (eg Tallin).
"Pure logic is the ruin of the spirit." - Antoine de Saint-Exupéry
Re: Wesnoth-TC: new tool for artists
will you add animation support ?
Fight key loggers: write some perl using vim
Re: Wesnoth-TC: new tool for artists
Exactly.Sangel wrote:I assume it's designed so that you can see the effects of your team colour work, while you're working on the sprite, without having to load it up into Wesnoth.
It's a command line tool...Boucman wrote:will you add animation support ?
Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
Re: Wesnoth-TC: new tool for artists
@shadowmaster: I'm not sure penguin informed you, but we've discovered a major endian issue with this (we don't know specifically what's causing it, unless he discovered something after I left). Basically, this doesn't work on PPC - it just passes-through the image without changing it.
Since I have a PPC, that naturally leaves me out in the cold. I was actually trying to use this for a drake image, and had an ugly surprise.
So, looking at an animation would be useless, because we wouldn't have enough time to study the image and see any offending pixels.
A side use is just seeing what the thing looks like, the primary use is the above. The reason is that loading wesnoth is a [censored]; wesnoth is a bloated space cow that takes a long time to launch - also, scripting the image into the WML is awkward. With this tool, especially when packaged by crimson_penguin with a nice drag-and-drop gui, it's really quick to check.
Since I have a PPC, that naturally leaves me out in the cold. I was actually trying to use this for a drake image, and had an ugly surprise.
That would be very counter-productive, actually. The point of this tool is to produce a single image of a single frame, so you can spend some deep-time (at least 10-30 seconds) poring over the image and making sure you didn't miss any TC pixels. Usually, you TC an image to blue with this tool, since that's so radically different from the magenta.Boucman wrote:will you add animation support ?
So, looking at an animation would be useless, because we wouldn't have enough time to study the image and see any offending pixels.
A side use is just seeing what the thing looks like, the primary use is the above. The reason is that loading wesnoth is a [censored]; wesnoth is a bloated space cow that takes a long time to launch - also, scripting the image into the WML is awkward. With this tool, especially when packaged by crimson_penguin with a nice drag-and-drop gui, it's really quick to check.
Play Frogatto & Friends - a finished, open-source adventure game!
Re: Wesnoth-TC: new tool for artists
Having taken a quick look, there's a ton of shifting to separate 32bit RGBA into its components and then throw them back together. Haven't read all of the code yet, but a quick (and ugly) fix could be to abuse htonl() and ntohl(). I only have access to i386-based systems though, so I can't test whether it works.
- solsword
- Code Contributor
- Posts: 291
- Joined: January 12th, 2009, 10:21 pm
- Location: Santa Cruz, CA
- Contact:
Re: Wesnoth-TC: new tool for artists
Also, the TeamColorizer Python script in data/tools/unit_tree/ should (as of r38796) use the same algorithm as Wesnoth proper, and it also now supports picking a color instead of just red (you can even use custom colors if you want). If you're just looking for a command-line tool to use while spriting, that ought to suffice. If *that* has endian issues (which I strongly doubt, since it's basically just a thin front-end to a complicated convert invocation), let me know and I'll do my best to fix it up.
The Knights of the Silver Spire campaign.
http://www.cs.hmc.edu/~pmawhorter - my website.
Teamcolors for everyone! PM me for a teamcolored version of your sprite, or you can do it yourself. If you just happen to like magenta, no hard feelings?
http://www.cs.hmc.edu/~pmawhorter - my website.
Teamcolors for everyone! PM me for a teamcolored version of your sprite, or you can do it yourself. If you just happen to like magenta, no hard feelings?
Re: Wesnoth-TC: new tool for artists
The online git repository's HEAD should contain a fix for the big-endian problem. But I need someone with a PowerPC Linux or MacOS X platform (with an adequate development environment) to test so I can release 1.5.0.AI wrote:Having taken a quick look, there's a ton of shifting to separate 32bit RGBA into its components and then throw them back together. Haven't read all of the code yet, but a quick (and ugly) fix could be to abuse htonl() and ntohl(). I only have access to i386-based systems though, so I can't test whether it works.
It also supports plain palette switches now (similar to the game's ~PAL image function), which is great since it already showed me some problems in my palette-switching sprites.
Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
Re: Wesnoth-TC: new tool for artists
Awesome. Crimson-penguin mentioned to me that you wanted a machine to act as a testbed, and that we can set up my machine as a target to compile to (or his). In either case; we'll probably need him around to help, so we'll see if the three of us can't convene on IRC over the next few days.
Play Frogatto & Friends - a finished, open-source adventure game!
-
- Posts: 30
- Joined: August 12th, 2008, 9:24 pm
Re: Wesnoth-TC: new tool for artists
I set out and designed a very simple interface around v1.0.0a. As you can see, it's a Win32 port, but I used wxWidgets with the libpng devels, so it should hopefully be fully x-platform, once I finish it. I am currently interfacing it with the program's core - I'm thinking about composing an emulated command line and passing it to the main routine, but it turned out to be more complex than I thought. I'll probably have to strip the source from all the cerr's cout's etc. Any chances you could help me out somehow with this? Or maybe make a dll out of it?
Clean...Simple...Devious...I like it