I am updating my tool X16PngConverter, a .NET application for Windows. Before, I have depended on the System.Drawing, a class library that is only supported on Windows. Now, I use ImageSharp instead, which is a cross-platform library.
If I get things right, I have successfully compiled macOS and Linux versions. But I have no idea if it works. If you have macOS or Linux, would you try it quickly? No installation is needed. It is just one file.
Here is the repository: https://github.com/joolin1/x16-png-converter
Here is a direct link to the zipped folder containing all three versions: https://github.com/joolin1/x16-png-conv ... ease.1.zip
Trying to get X16PngConverter to work on Linux and macOS
Forum rules
This section is for testing Commander X16 programs and programs related to the CX16 for other platforms (compilers, data conversion tools, etc.)
Feel free to post works in progress, test builds, prototypes, and tech demos.
Finished works go in the Downloads category. Don't forget to add a hashtag (#) and the version number your program was meant to run on. (ie: #R41).
This section is for testing Commander X16 programs and programs related to the CX16 for other platforms (compilers, data conversion tools, etc.)
Feel free to post works in progress, test builds, prototypes, and tech demos.
Finished works go in the Downloads category. Don't forget to add a hashtag (#) and the version number your program was meant to run on. (ie: #R41).
-
- Posts: 292
- Joined: Wed Jun 03, 2020 11:33 am
- Location: Kalmar, Sweden
Re: Trying to get X16PngConverter to work on Linux and macOS
Tried it with Linux Mint 21.1 Cinnamon. It seems like it works. It's a terminal program (I like that) it has an easy to use interface in that commands build up, so it's easy to start a command, check the .png for ligitness, then add commands. I like that.
So I gave it a png file of a font that is 2 color , 160X320. It promptly informed me the file needs to be 320 or 640 wide (Which makes sense.) so I used gimp to resize it to 320 X 240. Then it liked it.
Then I converted it to a ".BMX" file. That seemed to work fine. Then I looked at the file with a hex editor. It starts with BMX and looks like it has a header, then it looks like it has video data after that.
I didn't take the file all the way to an X16, though.
So I gave it a png file of a font that is 2 color , 160X320. It promptly informed me the file needs to be 320 or 640 wide (Which makes sense.) so I used gimp to resize it to 320 X 240. Then it liked it.
Then I converted it to a ".BMX" file. That seemed to work fine. Then I looked at the file with a hex editor. It starts with BMX and looks like it has a header, then it looks like it has video data after that.
I didn't take the file all the way to an X16, though.
Re: Trying to get X16PngConverter to work on Linux and macOS
I am kinda wondering why it's 21 MEGS long, though. What's in this thing?
-
- Posts: 292
- Joined: Wed Jun 03, 2020 11:33 am
- Location: Kalmar, Sweden
Re: Trying to get X16PngConverter to work on Linux and macOS
Many thanks, I really appreciate you took time to test it and also your feedback. It seems that I have understood right how to compile for different systems in Visual Studio.
The executable is so big because it is a self-contained .NET program. This means that the .NET runtime and needed libraries are bundled along with the application. So you don’t need to have .NET installed to run it. Quite convenient, but when I make an official release, I might offer the alternative which will consist of several files, among them ImageSharp.dll.
The executable is so big because it is a self-contained .NET program. This means that the .NET runtime and needed libraries are bundled along with the application. So you don’t need to have .NET installed to run it. Quite convenient, but when I make an official release, I might offer the alternative which will consist of several files, among them ImageSharp.dll.
- ahenry3068
- Posts: 1131
- Joined: Tue Apr 04, 2023 9:57 pm
Re: Trying to get X16PngConverter to work on Linux and macOS
I thought QB64 was a bit bloated. My convertor (written in QB64PE) linux executable comes in about 1.1 mb's . Windows EXE around 2mb's. I use imagemagick to do an initial conversion to a REV 3, Windows BMP. Then my code does the conversion from BMP to BIN & BMX & VERA Pal.Johan Kårlin wrote: ↑Mon Jul 01, 2024 9:56 am Many thanks, I really appreciate you took time to test it and also your feedback. It seems that I have understood right how to compile for different systems in Visual Studio.
The executable is so big because it is a self-contained .NET program. This means that the .NET runtime and needed libraries are bundled along with the application. So you don’t need to have .NET installed to run it. Quite convenient, but when I make an official release, I might offer the alternative which will consist of several files, among them ImageSharp.dll.