Skip to content

Commit

Permalink
Updated both GIMP's and main README
Browse files Browse the repository at this point in the history
  • Loading branch information
Ragnar Brynjulfsson committed Apr 9, 2016
1 parent ff3b203 commit 76bae5c
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 11 deletions.
23 changes: 12 additions & 11 deletions GIMP/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,28 +5,29 @@

Simply copy the coatools_exporter.py into the GIMP plug-ins folder.

On Linux this is /home/YOU/.gimp2.8/plug-ins/
On Windows this is C:\Users\YOU\.gimp2.8\plug-ins
On OSX this is TODO! Not tested, but should work.
- on Linux this is /home/YOU/.gimp2.8/plug-ins/
- on Windows this is C:\Users\YOU\.gimp2.8\plug-ins

If the plug-in loaded correctly, you should find it under File>Export to CoaTools...
You should find it under File>Export to CoaTools... after restarting GIMP.

Note that the .gimp2.8 folder may be hidden.

## Usage

Start by drawing a character or object using GIMP. Divide the movable parts up on different layers, like arms, legs, head and so on.
## Usage

If you want to use multiple frames for one part, simply create a Layer Group, with one child layer for each frame. This can for instance be used to create different mouth shapes for animating dialog.
Start by drawing a character or object you want to animate using GIMP. Divide the movable parts up on different layers, like arms, legs, head and so on. If you want to use multiple frames for some parts, such as different mouth shapes, simply create a Layer Group with one child layer for each frame.

Choose a destination and name in the export dialog and hit OK.
Run File>Export to CoaTools... and choose a destination folder and name and hit OK.

Each visible layer will be exported to a a separate .png file. The child layers of a Layer Group are exported as a single sprite sheet to a .png file. In addition a writes out a .json file use by CoaTools to put everything back together agani in Blender.

Note that the exporter will overwrite previous exports without asking.
Note that the exporter will overwrite previous exports without asking, only outputting a warning in GIMP's Error Console.


## Limitations

The script uses the Layer>Autocrop Layer function in GIMP to crop the layers down to the size of it's content, rather than looking at the actual Alpha channel of the layer. This will work fine in almost all cases, with a few exceptions. If your layer has a flat color all the way to edge of the image, such as a white border around an old style photograph, this color will be cropped. You can test this, by simply running Layer>Autocrop Layer on your image.
The script uses the Layer>Autocrop Layer function in GIMP to crop the layers down to the size of it's content, rather than looking at the actual alpha channel of the layer. This works fine in almost all cases, except if your layer has a flat color all the way to edge of the image, such as a white border around an old style photograph. You can test this by simply running Layer>Autocrop Layer on your layer. A simple workaround for this would be to add a 1 pixel transparent border around your layer, or just add slight noise to the layer.

In addition nested Layer Groups are not supported.

A workaround for this would be to add a 1 pixel transparent border around your layer, and that will get cropped instead, or just add slight noise to the layer.
The GIMP export has not been tested on OSX, but there is no reason why it shouldn't work.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ Features:
- export folder with multiple layers as spritesheets
- generate json data with all layer positions and spritesheet informations

### GIMP sprite exporter
Export GIMP layers and layer groups into separate files with json coordinate information. For additional usage information see the README.md in the GIMP folder.

### Cutout Animation Tools Blender
This is the biggest component, as most of the work will be done here.
Features the addon offers are:
Expand Down Expand Up @@ -52,6 +55,15 @@ C:\Program Files\Adobe\Adobe Photoshop CC 2015\Presets\Scripts

Don’t forget to restart Photoshop and then go to File -> Scripts -> BlenderExporter.jsx

### GIMP Exporter:

The coatools_exporter.py should be copied to your GIMP plug-ins folder which is located in:
- Linux: /home/YOU/.gimp2.8/plug-ins/
- Windows: C:\Users\YOU\.gimp2.8\plug-ins

It should show up unde Files>Export to CoaTools... after your restart GIMP


### Blender Addon:
Zip the coa_folder.
Go to File -> User Preferences -> Add-ons and click the “Install from file...” button.
Expand Down

0 comments on commit 76bae5c

Please sign in to comment.