|
ForumsSega Master System / Mark III / Game GearSG-1000 / SC-3000 / SF-7000 / OMV |
Home - Forums - Games - Scans - Maps - Cheats - Credits Music - Videos - Development - Hacks - Translations - Homebrew |
Author | Message |
---|---|
|
Convert a PNG to tiles without BMP2Tiles
Posted: Fri Nov 20, 2020 8:41 pm
|
Hello! I'm new here, because I decided to learn about the programming on Master System. To continue my learning, I need to know how to convert a PNG to tiles for the Master System.
I couldn't find any examples or indications on Google. I would like a simple example in order to create my own tool that will work in Linux like I did for the Mega Drive. Why not use BMP2Files directly? It doesn't work on Linux even with Wine. Thanks for your help :) |
|
|
Posted: Fri Nov 20, 2020 9:43 pm |
Welcome to the forum!
Actually, I have used BMP2Tiles successfully on Linux with Wine; to be fair, it was called through the command line rather than through the interface, but worked okay, nevertheless. As an alternative, you may try https://github.com/grz0zrg/bmp2sms |
|
|
Posted: Sat Nov 21, 2020 8:59 am |
The older versions may work as they are straight win32, newer ones are using .net so you may need to use Mono. I may see if it ports nicely to .net 5... | |
|
Posted: Sat Nov 21, 2020 1:54 pm |
@haroldoop thanks a lot :) Currently when I run BMP2Tile with Wine, the GUI does not display correctly and freeze. I tried the command line version, but it stops immediately after running:
[kentosama@archlinux bmp2tile-0.5]$ wine BMP2Tile.exe ~/Workspace/SMS/sonic.png
00f4:fixme:ntdll:NtQuerySystemInformation info_class SYSTEM_PERFORMANCE_INFORMATION I installed the wine-mono package but it's the same. Maybe I should actually install the Mono environment as suggested by @Maxim I will try bmp2sms :) However, I would have liked to have understood how to create the binary file for my learning, it's exciting. Thanks a lot for your help :) edit: I just used bmp2sms, it's a tool that gives all the information. I now see how to create the binary file or prepare the data. |
|
|
Posted: Sat Nov 21, 2020 5:33 pm |
I’ve got an example using straight Python code that optimizes tiles here:
https://github.com/SavagePencil/RetroGraphicsToolkit/blob/master/examples/Unique... |
|
|
Posted: Sun Nov 22, 2020 4:24 am |
You can use png2tiles from efry.
It's a Bmp2tiles clone but only in command line. No problem to compile and use it on unix. Old Bmp2tiles work also without problem (with wine or playonmac... On Mac, lol) . Unfortunately, same problem with recent Bmp2tiles version. Even with mono, impossible to compile/run it on my side. PS. You can also easily manipulate png with python and PIL library. |
|
|
Posted: Sun Nov 22, 2020 4:51 pm |
I can run both old versions (0.4x) of BMP2Tile and new versions (0.5x, 0.6x) on wine (wine-5.0.3) on my Linux Mint. Can't remember if I had to install something more than that to make it work, probably Mono... | |
|
Posted: Fri Nov 27, 2020 8:42 pm |
Hi! Yes, finally i wrote a rescomp like SGDK in C++ with Qt. This has several advantages since the data is generated for direct use in code. |
|