Re: AW: AW: Implementing PseudoColor support on TrueColor screens

2020-06-02 Thread Sleep
This should be slightly easier to read: Display*X_display = NULL; Window X_mainWindow; ColormapX_cmap; Visual* X_visual; GC X_gc; int X_screen; XVisualInfo X_visualinfo; XImage* image = NULL; int X_width; int

Re: AW: AW: Implementing PseudoColor support on TrueColor screens

2020-06-02 Thread Sleep
No, that is not intentional, the original function had x = width-1 and I forgot to change that for clarity, and yes, the colors are converted perfectly, by "squashed" I mean what is happening in this image (that is Doom). https://postimg.cc/MfRz0Dk7 You see, only 1/4 of the window is being fill

AW: AW: Implementing PseudoColor support on TrueColor screens

2020-06-02 Thread Walter Harms
a assume this is intentional backwards ? for (int x = width-1; x >= 0; x--) { if st2d_8to24table contains no rubbish the colors should be ok now, are they ? what means "squashed image" ? a scaling problem ? To make things more easy to debug, can you save image->data where you know what who that