BMPTO105

por dvik en 01-03-2006, 09:41
Tema: Software
Etiquetas: Utilities
Idiomas:

Daniel Vik has optimized and fixed bugs in the tool used to create the 105 color images, as seen in the MSX Unleashed demo. The optimized tool is now released in a package that contains the encoder tool and assembly source for a viewer application. The tool converts Windows .bmp files into 105 color .si2 files that can be assembled with the viewer source and displayed on the MSX.

Relevant link: BMPTO105

Comentarios (28)

Por dvik

Prophet (2200)

Imagen del dvik

01-03-2006, 09:47

I saw the files in the package are renamed. Thats of course ok but line 71 in I105VIEW.ASM needs to be changed to:
INCLUDE "I105CORE.ASM"

Por snout

Ascended (15187)

Imagen del snout

01-03-2006, 09:49

uploaded a fixed version. Thanks for spotting this so quickly Wink

Por anonymous

incognito ergo sum (116)

Imagen del anonymous

01-03-2006, 09:50

Nice!! Dvik, do you want to present this software in MadriSX & Retro? If you send us some slides we can show them in the big screen Big smile Big smile

Por dvik

Prophet (2200)

Imagen del dvik

01-03-2006, 09:56

That would be very nice Smile I made a small slideshow demo at:

http://www.msx.org/Technicolor.newspost3604.html

Por anonymous

incognito ergo sum (116)

Imagen del anonymous

01-03-2006, 10:00

What about the BMPTO105 software itself. I mean, not to show only the results but the process itself. I know that this program is very cpu intensive, but maybe some slides of the process can be shown before the slideshow in the MSX1.

What do you think?

Por viejo_archivero

Paragon (1395)

Imagen del viejo_archivero

01-03-2006, 10:03

@dvik: great, great, GREAT! Big smile

Por dvik

Prophet (2200)

Imagen del dvik

01-03-2006, 10:06

Ah, you mean like powerpoint slides. Yes I can try to do something and explain the concepts and the algoritm a little bit and how to use the tool.
This version is quite a lot faster than the original. Instead of taking 8 hours to create an image, this version does it in a couple of seconds. So its quite easy to also use the tool in a presentation.

Por jltursan

Prophet (2619)

Imagen del jltursan

01-03-2006, 11:56

Fab!, I'm eager to see the inner workings of the routine! Smile

Por KNM

Master (172)

Imagen del KNM

01-03-2006, 15:05

This is FANTASTIC!!!People will get amazed when we launch the slideshow in MadriSX & Retro! COOOOOOOL!CoolCoolCool

Por Ada

Resident (49)

Imagen del Ada

01-03-2006, 15:14

Great news, dvik! LOL! Can we use it freely? It would be nice to include it in a game! Tongue

Por anonymous

incognito ergo sum (116)

Imagen del anonymous

01-03-2006, 16:00

Dvik, perfect. If you can make the powerpoint slides and a little commentary I can show them in the Big Screen Conferences in the main hall of MadriSX & Retro. I have a math background, so don't worry if you include formulae in your slides TongueTongueTongue

Por mars2000you

Enlighted (6430)

Imagen del mars2000you

01-03-2006, 19:46

This tool is for your PC, not your MSX ... Here's a ZIP file :

http://www.msxblue.com/BMPTO105.zip

Por anonymous

incognito ergo sum (116)

Imagen del anonymous

01-03-2006, 19:53

Yes, I know, but it's a tool related to old computers, like Polka or Vortex Tracker.

I guess that present this tool in a retro-computer fair as MadriSX & Retro is a good idea.

Por mars2000you

Enlighted (6430)

Imagen del mars2000you

01-03-2006, 19:59

My remark had only the following meaning : the ZIP format is the most populair format on a PC. Of course, the pictures that you create with this tool can be used on the MSX ! Smile

Por ARTRAG

Enlighted (6932)

Imagen del ARTRAG

01-03-2006, 20:13

Daniel,
instead of computing MSE in the RGB space, you could compute the error in the YUV space
in in others space that gives better subjective results.
Look at this for example
http://lcavwww.epfl.ch/%7Edragotti/publications/eus98.ps

Por dvik

Prophet (2200)

Imagen del dvik

01-03-2006, 20:30

Yes I was thinking of doing that when I did the original version but didn't remember it now. I already have code to convert back and forth between RGB and YUV in the emulator so it shouldn't take long to do.

Por dvik

Prophet (2200)

Imagen del dvik

01-03-2006, 21:51

Can we use it freely? It would be nice to include it in a game!

Of course, thats why we released it Smile The code and application is under zlib license which is really nice and a lot better than GPL (I think). If you look at the code you'll see the little license note and you are free to do pretty much what you want with it except claim that you wrote it.

Por dvik

Prophet (2200)

Imagen del dvik

01-03-2006, 22:42

I tested using YUV instead of RGB in the MSE and this is the result. First pic uses RGB. Second pic uses YUV. As you can see the result of using YUV is that the colors are quite distorted which I think happens because there are only 15 colors to blend. so the Y component (the light intensity channel) gets too much input.

www.bluemsx.com/demos/Technicolor/image_med2.gif
MSE using RGB values

www.bluemsx.com/demos/Technicolor/image_med2_yuv.gif
MSE using YUV values

Por ARTRAG

Enlighted (6932)

Imagen del ARTRAG

01-03-2006, 23:38

In our paper we used the C.I.E. L*u*v* perceptually uniform space
with the transform as defined in W.K.Pratt, "Digital image processing,''
John Wiley, 1991 and the illuminant C as standard white.

The transform is followed by the equalization procedure :
L_eq = (-0,020186L + 7,971237)L
u_eq = (0,003210u + 0,767563)u
v_eq = (0,001666v + 0,628228)v
which further improves the visual quality after quantization.

I have lost the original C programs and the references...

Por dvik

Prophet (2200)

Imagen del dvik

01-03-2006, 23:43

Here is an interesting one. I do MSE on YRGB and I think this one looks pretty good:

www.bluemsx.com/demos/Technicolor/image_med2_yrgb.gif
MSE using YRGB values

Por ARTRAG

Enlighted (6932)

Imagen del ARTRAG

02-03-2006, 16:52

go here for the RBG to L*u*v* conversion

http://www.engineering.uiowa.edu/~xjiang/aiphwk/hw1/index.htm

Por ARTRAG

Enlighted (6932)

Imagen del ARTRAG

02-03-2006, 19:25

RGB = [ 5; 7; 255]; % generic RGB color pixel at 24 bit (8 bit per component)

RnGnBn = RGB/255; % the same pixel in float in [0 1]

RnGnBn2XYV = [ 0.607 0.174 0.200 ;
0.299 0.587 0.114 ;
0.000 0.066 1.116 ];

XYZ = RnGnBn2XYV * RnGnBn; % the same pixel in float in XYZ coordinates
X = XYZ(1);
Y = XYZ(2);
Z = XYZ(3);

X0Y0Z0 = RnGnBn2XYV * [ 1; 1; 1]; % Standard while in XYZ coordinates
X0 = X0Y0Z0(1);
Y0 = X0Y0Z0(2);
Z0 = X0Y0Z0(3);

up = 4*X/(X+15*Y+3*Z);
vp = 9*Y/(X+15*Y+3*Z);

up0 = 4*X0/(X0+15*Y0+3*Z0);
vp0 = 9*Y0/(X0+15*Y0+3*Z0);

if (Y/Y0>0.008856)
Ls = 25*(100*Y/Y0)^(1/3) - 16;
else
Ls = 903.3 *Y/Y0;
end

us = 13*Ls*(up-up0);
vs = 13*Ls*(vp-vp0);

[Ls,us,vs] % teh original point in L*u*v*

Por Ivan

Ascended (9341)

Imagen del Ivan

02-03-2006, 21:24

Here is an interesting one. I do MSE on YRGB and I think this one looks pretty good:

Yes, this image is the best.

Por Manuel

Ascended (19301)

Imagen del Manuel

03-03-2006, 11:55

Wow, nice results!

Some remarks:
- is technicolor based on the new conversion routines?
- the source doesn't compile on gcc, but all you have to do to get it working is change the return type of main to 'int' and fix the 'return' statements in the main function
- keep up the great work! Smile
- please dont' forget to send a mail to openmsx-devel with that list of glitches of Unleased on openMSX, which I missed.

Por dvik

Prophet (2200)

Imagen del dvik

03-03-2006, 17:58

Thanks manuel, Technicolormania is indeed created by this tool. I'll update the source with the correct return type of main (and If I release an update I'll make sure it compiles with gcc before releasing). We can talk about it on #openmsx. I'm a bit busy this and next weekend but the weekend after I'm all free.

Por Manuel

Ascended (19301)

Imagen del Manuel

03-03-2006, 20:34

I meant specifically the *new* routines you were experimenting with in this reaction thread. They seem to be giving better results (when using the other color space).

Por dvik

Prophet (2200)

Imagen del dvik

03-03-2006, 20:50

Ah, no I haven't updated the demo yet. The difference is not that big though but small improvments are also good so I'll definately release an updated version soon (of course also with your comile fix).

Por dvik

Prophet (2200)

Imagen del dvik

04-03-2006, 01:17

@ARTRAG: I tried the algorithm and the result wasn't too good. Not really sure why but it could be because the Y channel is not linear. I also tried using the eucledian distance in the cost function but the result was similar. Here is a screenshot:

www.bluemsx.com/demos/Technicolor/image_med2_luv.gif

And for reference, here is a screenshot with the original:

www.bluemsx.com/demos/Technicolor/image_med2_orig.png