Code Monkey home page Code Monkey logo

gimp-rom-bin's Introduction

gimp file-rom-bin plugin

GIMP plugin for reading, writing and converting ROM images and tile files. Useful in emulation ROM modding, hacks and extracting/inserting artwork.

Download compiled executables here:

GIMP Image Editor opening Super Nintendo Image Tiles

Supported image formats:

  • NES 1bpp / 2bpp
  • SNES 2bpp / 3bpp / 4bpp / 8bpp
  • GB 2bpp
  • NGP 2bpp
  • GBA 4bpp / 8bpp
  • GG/SMS/WSC 4bpp
  • MD 4bpp

Supported file extensions:

  • .bin
  • .chr (nes 2bpp)
  • .nes (nes 2bpp)
  • .gb (gb 2bpp)

Acknowledgement:

Quick instructions:

Native compile/install on Linux using below.

If GIMP & build tools not yet installed:
(example for debian/ubuntu/mint)
 * sudo apt install gimp
 * sudo apt install build-essential
 * sudo apt install libgimp2.0-dev
 
Then: 
* cd gimp-rom-bin
* make

Then copy the resulting "file-rom-bin" to your GIMP plugin folder, depends on version

Plug-in folder locations:
 Linux: ~/.gimp-2.8/plug-ins  , or ~/.config/GIMP/2.10/plug-ins
 Windows: C:\Program Files\GIMP 2\lib\gimp\2.0\plug-ins

Guide for Cross-compiling to Windows on Linux

Known limitations & Issues:

  • Palettes: Does not yet import palettes and defaults to internal standard palettes. Which can then be changed using the GIMP color map and Palette tools.

  • Image size: ROMs and tile files that are not an even multiple of tile width will get padded with transparent pixels at the end of the image, and have any trailing data stored as gimp image metadata. The plugin will attempt to preserve original file size and integrity as much as possible. Setting transparent pixels (in tiles) at the end of the image to non-transparent will cause those tiles to get written to the file and therefore increase the file size. Be careful.

GIMP usage hints:

  • Set paintbrush tool to:

    • Brush: Pixel
    • Opacity: 100%
    • Size: 1
  • Set grid to 8x8

  • Colormap & Palette changing:

    • Colormap (Palette for current image)
      • Show the Palette: --> Menu --> Windows --> Dockable Dialogs --> Show Colormap
      • Assign a Palette: --> Menu --> Colors --> Map --> Set Color Map
    • Palette (GIMP system wide palettes available for use)
      • Show the Palettes Dialog: --> Menu --> Windows --> Dockable Dialogs --> Show Palettes
      • Import: Palettes Dialog --> Pop-out menu at top -> Palettes Menu -> Import (must be 768 bytes?)
    • Changing
      • Assign a palette, convert to RGB and then back to indexed to shrink down and discard unused colors
      1. Menu -> Colors -> Map -> Set Color Map -> Select desired color map (could be imported or from another image)
      2. Menu -> Image -> Mode -> RGB
      3. Menu -> Image -> Mode -> Indexed -> Use Custom Palette + check Remove unused -> Select desired color map (could be imported or from another image)

gimp-rom-bin's People

Contributors

bbbbbr avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

gimp-rom-bin's Issues

pkm support

Would it be possible to add pkm file support? as a majority of sprites now user pkm / pkm10

gimptool-2.0 failed and manually make'ing and cp'ing didnt work either

i tried with gimptool-2.0 firstly but couldnt find file etc, then renamed to fit ./src/file-rom-bin.c and that didnt work either. dumps below.

lastly from /home/e/stream/nesdev/git/gimp-rom-bin i ran make, compile successful so i took a guess and copied contents of ./obj/ into this system's gimp plug-in dir at /home/e/.config/GIMP/2.10/plug-ins/

when i started gimp i didnt receive any extra file opening superpowers and at this point became stuck as what to do.

advice please?

[e@e-pc gimp-rom-bin]$ gimptool-2.0 --install file-rom-binfile.c
gcc -I/usr/include/gimp-2.0 -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/lib/libffi-3.2.1/include -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/cairo -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/harfbuzz -I/usr/include/uuid -I/usr/include/gegl-0.4 -I/usr/include/json-glib-1.0 -I/usr/include/gio-unix-2.0 -I/usr/include/babl-0.1 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/pango-1.0 -I/usr/include/fribidi -I/usr/include/atk-1.0 -pthread -o '/home/e/.config/GIMP/2.10/plug-ins/file-rom-binfile' 'file-rom-binfile.c' -lgimpui-2.0 -lgimpwidgets-2.0 -lgimpmodule-2.0 -lgimp-2.0 -lgimpmath-2.0 -lgimpconfig-2.0 -lgimpcolor-2.0 -lgimpbase-2.0 -lgegl-0.4 -lgegl-npd-0.4 -lm -Wl,--export-dynamic -pthread -lgmodule-2.0 -ljson-glib-1.0 -lbabl-0.1 -lgtk-x11-2.0 -lgdk-x11-2.0 -lpangocairo-1.0 -latk-1.0 -lcairo -lgdk_pixbuf-2.0 -lgio-2.0 -lpangoft2-1.0 -lpango-1.0 -lgobject-2.0 -lglib-2.0 -lharfbuzz -lfontconfig -lfreetype
gcc: error: file-rom-binfile.c: No such file or directory
[e@e-pc gimp-rom-bin]$ pwd
/home/e/stream/nesdev/git/gimp-rom-bin
[e@e-pc gimp-rom-bin]$

[e@e-pc gimp-rom-bin]$ cd src/
[e@e-pc src]$ gimptool-2.0 --install file-rom-binfile.c
gcc -I/usr/include/gimp-2.0 -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/lib/libffi-3.2.1/include -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/cairo -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/harfbuzz -I/usr/include/uuid -I/usr/include/gegl-0.4 -I/usr/include/json-glib-1.0 -I/usr/include/gio-unix-2.0 -I/usr/include/babl-0.1 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/pango-1.0 -I/usr/include/fribidi -I/usr/include/atk-1.0 -pthread -o '/home/e/.config/GIMP/2.10/plug-ins/file-rom-binfile' 'file-rom-binfile.c' -lgimpui-2.0 -lgimpwidgets-2.0 -lgimpmodule-2.0 -lgimp-2.0 -lgimpmath-2.0 -lgimpconfig-2.0 -lgimpcolor-2.0 -lgimpbase-2.0 -lgegl-0.4 -lgegl-npd-0.4 -lm -Wl,--export-dynamic -pthread -lgmodule-2.0 -ljson-glib-1.0 -lbabl-0.1 -lgtk-x11-2.0 -lgdk-x11-2.0 -lpangocairo-1.0 -latk-1.0 -lcairo -lgdk_pixbuf-2.0 -lgio-2.0 -lpangoft2-1.0 -lpango-1.0 -lgobject-2.0 -lglib-2.0 -lharfbuzz -lfontconfig -lfreetype
gcc: error: file-rom-binfile.c: No such file or directory
[e@e-pc src]$

i changed filename to point to file-rom-bin.c but that failed also

[e@e-pc src]$ gimptool-2.0 --install file-rom-bin.c
gcc -I/usr/include/gimp-2.0 -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/lib/libffi-3.2.1/include -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/cairo -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/harfbuzz -I/usr/include/uuid -I/usr/include/gegl-0.4 -I/usr/include/json-glib-1.0 -I/usr/include/gio-unix-2.0 -I/usr/include/babl-0.1 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/pango-1.0 -I/usr/include/fribidi -I/usr/include/atk-1.0 -pthread -o '/home/e/.config/GIMP/2.10/plug-ins/file-rom-bin' 'file-rom-bin.c' -lgimpui-2.0 -lgimpwidgets-2.0 -lgimpmodule-2.0 -lgimp-2.0 -lgimpmath-2.0 -lgimpconfig-2.0 -lgimpcolor-2.0 -lgimpbase-2.0 -lgegl-0.4 -lgegl-npd-0.4 -lm -Wl,--export-dynamic -pthread -lgmodule-2.0 -ljson-glib-1.0 -lbabl-0.1 -lgtk-x11-2.0 -lgdk-x11-2.0 -lpangocairo-1.0 -latk-1.0 -lcairo -lgdk_pixbuf-2.0 -lgio-2.0 -lpangoft2-1.0 -lpango-1.0 -lgobject-2.0 -lglib-2.0 -lharfbuzz -lfontconfig -lfreetype
/usr/bin/ld: /tmp/ccn1Zb6y.o: in function run': file-rom-bin.c:(.text+0x3fe): undefined reference to export_dialog'
/usr/bin/ld: file-rom-bin.c:(.text+0x437): undefined reference to read_rom_bin' /usr/bin/ld: file-rom-bin.c:(.text+0x595): undefined reference to export_dialog'
/usr/bin/ld: file-rom-bin.c:(.text+0x5c2): undefined reference to `write_rom_bin'
collect2: error: ld returned 1 exit status
[e@e-pc src]$

manual

Hi

Can you write a manual?
As a beginner, i don't know how to use this

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.