DaDither - another one Img2Msx tool

Page 5/8
1 | 2 | 3 | 4 | | 6 | 7 | 8

Par sd_snatcher

Prophet (3659)

Portrait de sd_snatcher

11-02-2023, 15:12

Dec wrote:

I hope you used a Pixel aspect ratio of 1:1 and a dithering method None?

Yes. This is the settings I used: PAR=1:1, dithering=none, position=centered.

Par Dec

Resident (38)

Portrait de Dec

14-02-2023, 17:32

I updated the Mode12 generation algorithm. Now it is possible to do scc->png->scc transformation without loss.

I use the following scheme to test my algorithm:
1) Import Original.SCC
2) Save Original.SCC as Original.BMP (new feature of the program)
3) Convert imported Original.SCC
4) Save as Test.SCC
5) Import Test.SCC
6) Save Test.SCC as Test.BMP
7) Compare Original.BMP and Test.BMP

I cannot guarantee that my algorithm will be able to "recover" SCC file from PNG images created with any other program such as Recoil because the conversion is very dependent on the formulas and palette values used.

Par sd_snatcher

Prophet (3659)

Portrait de sd_snatcher

15-02-2023, 01:51

I did some testing, and while the error much smaller, there's still some error. Maybe I did something wrong?

1) To generate the original BMP, I selected Platform=Common, Screen=Original palette. Also checked the "Use only original colors" checkbox.

2) The converted BMP was saved directly from the conversion.

3) The following image shows the result of the following formula I used to check: MOD(PixelsOriginal-PixelsConverted)*64

This is the image used for this test.

Par Dec

Resident (38)

Portrait de Dec

15-02-2023, 06:58

It is better to use this option to save scc as bmp :

Par Dec

Resident (38)

Portrait de Dec

15-02-2023, 08:53

sd_snatcher wrote:

To generate the original BMP, I selected Platform=Common, Screen=Original palette. Also checked the "Use only original colors" checkbox.

There was a small bug, I fixed it. Now this way should give you correct results too.

Par sd_snatcher

Prophet (3659)

Portrait de sd_snatcher

16-02-2023, 21:22

I did some more testing and it's working like a charm now for SCREEN12. All images I tested were recreated perfectly. Congrats!! 🎉

But, sadly, for SCREEN10 it's still not possible to perfectly recreate the images. Many of those I tested had differences. This one uses that checking formula, but just with a different multiplier: MOD(PixelsOriginal-PixelsConverted)*2

This is the image I used for this test.

Par Dec

Resident (38)

Portrait de Dec

16-02-2023, 21:37

I am working on Screen10. But I'm not sure if I can create a good algorithm similar to the Screen12 algorithm.

Par Dec

Resident (38)

Portrait de Dec

20-02-2023, 04:58

Updated.
-Now you can save Screen5-Screen12 images with any resolution as GLx/PLx or MAG. Limitations: the height of interlaced images must be a multiple of two, and the width of Screen10/12 images must be a multiple of four.
-When you import GLx/PLx or SRx/PLx files you can select any palette stored in the PL file.
-Creation of Screen10 images improved. The algorithm can sometimes "recover" the original SCA file from a PNG file, sometimes not. This limitation can be circumvented by importing the palette from the original SCA file (this can be done in the Import window). After that, you need to select it in the Fixed Palette list. In this case, the original SCA image will be completely restored.

Par sd_snatcher

Prophet (3659)

Portrait de sd_snatcher

21-02-2023, 00:45

I did an extensive testing session with this new version, and I must say that again I'm quite impressed. Here's my report. I hope it helps.

1) Positive aspects

a) It can indeed perfectly recreate both SCREEN10 and SCREEN12 images. 🎉

b) And your efforts to achieve this had an awesome side effect: DaDither now makes perfect use of the Out of Gamut colors of the YJK, meaning that for converting images from other sources (either Pixel Art or photos), it's able to achieve some unbelievable results and hide the color bleed impressively well in SCREEN10.

c) Being able to choose from any of the available palettes when importing SRx+PLx was a very welcome addition

d) It works fine on macOS using wineCX

2) Bugs

a) There seems to be a typo in the MSX Pixel Aspect ratio. It's being used as 1.104:1, when it should have been 1.14:1. But if you want to use 3 decimal places, then it should be 1.138:1.

3) Where there's space for improvement

a) Whenever the screen mode is changed, many of the conversion parameters are reset to their defaults: Dimension, Position, Pixel Aspect Ratio, Dithering Method, etc. Ideally, those should persist, as it makes easier to easily compare between the screen modes to choose which will yield better results. A "reset parameters to the defaults" menu option could be offered for when the user messed up with the settings too much.

b) Usability: when importing SRx+PLx images, it would be easier if all the available palettes were also automatically imported to the "Fixed Palette" combo-box of the converter window. This way the user could select between them without having to import the image again.

c) Usability: Similarly, when importing SCx/MAG images, its embedded palette could also be automatically imported to the " Fixed Palette" combo-box of the converter window

d) Still on the image regeneration topic, similar to the way RGB colors are used to hide the color bleed on SCREEN10, on the SCREEN2/SCREEN4 the sprites were used for that. If I try to regenerate such images with DaDither, it chews the details on those parts. Here you can find examples of SCREEN2 and SCREEN4 images with sprites.

e) Many dithering methods are offered, but their results don't differ that much between them. But one important dithering method for Pixel Art that's missing is the Ordered Dithering, AKA "checkerboard dithering". This was extensively used in PC-98 art and to some extend on the MSX2

Par sd_snatcher

Prophet (3659)

Portrait de sd_snatcher

21-02-2023, 00:42

Here's one example of a SCREEN2 image with sprites regenerated using DaDither. It doesn't support the sprites, but also is limited to the TMS9928 palette, when this image has the V9938 palette.

And this was the original image:

The native file can be downloaded here.

Page 5/8
1 | 2 | 3 | 4 | | 6 | 7 | 8