The VG Resource
Binxelview tool for locating image data in files - Printable Version

+- The VG Resource (https://www.vg-resource.com)
+-- Forum: The Resources (https://www.vg-resource.com/forum-109.html)
+--- Forum: The Spriters Resource (https://www.vg-resource.com/forum-110.html)
+---- Forum: Ripping Help (https://www.vg-resource.com/forum-114.html)
+---- Thread: Binxelview tool for locating image data in files (/thread-36715.html)



Binxelview tool for locating image data in files - rainwarrior - 02-23-2020

I made this tool a little while ago to help myself find uncompressed image data, maps, or otherwise look for grid-organized data in files.

Since being able to find sprites in game data files and ROMs was one of the big reasons I wanted the tool, I thought others here might like to know about it:

https://github.com/bbbradsmith/binxelview


Simple tutorial:
  1. Drag the file you want to inspect onto the window (or use the file menu to open it).
  2. Adjust the "width" parameter and look at the data, with the right width images will start to line up.
  3. Once the width is figured out, adjust the height and the starting position to bring the images into alignment.
That's the basic idea. It can handle a lot of different arbitrary formats for packing bits. The default is 8BPP (8 bits / 1 byte per pixel) but the display format is very customizable. If you have an educated guess about the format, you can select that instead. There are presets for the native data formats of a few platforms already, but you can make your own presets too.

For some things, you can just save the images directly out of the tool. I've very quickly found a lot of font sets this way, and it's easy to just resize the window to put them in a nice grid and then save directly out of the tool. Other times it's just a starting point for figuring out where the data is stored, and what format it might be in. For instance, you will normally need to come up with a colour palette for the images separately.


Here's a twitter thread with a few screenshots that kinda show what it can do, and a brief animation showing how I used it recently for finding textures in a Dreamcast game.


It's completely free and open source. No strings attached.


RE: Binxelview tool for locating image data in files - Raccoon Sam - 02-25-2020

Stellar work, man!!


RE: Binxelview tool for locating image data in files - Deathbringer - 02-25-2020

Is there a way to use a palette inside the file you are viewing?

http://prntscr.com/r7cgiu


RE: Binxelview tool for locating image data in files - rainwarrior - 02-25-2020

(02-25-2020, 05:52 AM)Deathbringer Wrote: Is there a way to use a palette inside the file you are viewing?

You can load a palette from an image containing a palette, or a file of RGB 8-bit triples, by clicking the "Load" button in the palette section. Images up to 8bpp will be saved as images with palette, as well, so if you save the image from binxelview you can still apply a palette later in your preferred image editor.

However, if you're asking if you can automatically grab a palette out of data inside the file you're looking at, no I didn't build a mechanism for that. Palette formats vary a lot, and every platform has its own way for it. I'd kinda need about as much UI to describe arbitrary palette formats as I have for the image itself.

You can use this tool to find palette data in some cases, like if you know their format you can see the colours visually, but in general you'll need to find and extract those separately. Once converted to RGB 888 you can use it with this tool, though.


RE: Binxelview tool for locating image data in files - Deathbringer - 02-26-2020

Not entirely sure what "image containing a palette" means. And the other idea was cutting the palette out of the file itself and make that a pal but the palettes I'm working with are 2bpp, not 3bpp.


RE: Binxelview tool for locating image data in files - SonicFan53 - 02-26-2020

That looks awesome. Would it work for Game Gear games? Cause I'm looking to rip some sprites from those.


RE: Binxelview tool for locating image data in files - rainwarrior - 02-26-2020

(02-26-2020, 10:29 AM)Deathbringer Wrote: Not entirely sure what "image containing a palette" means.
If you have a PNG or a GIF or BMP that contains a palette, you can use the "Load" button on the palette control to use the palette from it.

Otherwise you can use a binary palette file containing a series of RGB 888 values.

(02-26-2020, 11:13 AM)SonicFan53 Wrote: That looks awesome. Would it work for Game Gear games? Cause I'm looking to rip some sprites from those.

If the sprites are uncompressed in the ROM it would work. A lot of games do not compress their sprite tiles, but some do.