Mechanized Assault & eXploration Reloaded



#1 Oct 05, 2016 3:42 am
mdooligan mdooligan Offline
Approved Member
Registered since: Dec 07, 2008
Posts: 36


Subject: Cursors have magenta backgrounds?
I just compiled 0.2.9, seems to work great. Thank you very much. Many fixes and new developments!

However, all the cursors now have magenta backgrounds. This is the default transparent color, and looks like it should get handled in pcx.cpp properly. Is this something on my end? 0.2.8 works fine. I'm using Arch linux, reasonably new. I'm not sure if this is an issue, but the only thing I have that opens PCX files is gimp, and it looks like it has trouble too. A missing library perhaps?

It looks like the cursor is drawn by the Xorg/SDL, because it changes when I try to take screenshot. I've never seen this magenta transparency before, and I do a fair bit of SDL/game hacking. There is *some* transparency happening, but it appears the XOR for alpha color is not happening fully. Odd.
Miven Dooligan
Peace and cheer
This post has been edited 1 times. Last edit on Oct 05, 2016 4:04 am by mdooligan. ↑  ↓

#2 Oct 05, 2016 5:34 am
mdooligan mdooligan Offline
Approved Member
Registered since: Dec 07, 2008
Posts: 36


Subject: Re: Cursors have magenta backgrounds?
As a funny sidenote, the cursor images are in PCX format. After checking around my system everything that opens PCX files has it's own implementation of the process. GIMP opens them fine, but has trouble with a limited palette it seems. Gqview just fails and doesn't even try, as does EOG. Xloadimage, xli, all show static, but they have their own little pcx.c files and their own notion of what a PCX file is. So far I cannot find a graphics library that has some standard implementation. ImageMagick converts them fine, with magenta background.

Also, my video card is AMD Radeon. I see there may be trouble with radeon and SDL2. Is this a hwcursor issue do you think?
Miven Dooligan
Peace and cheer
This post has been edited 1 times. Last edit on Oct 05, 2016 5:37 am by mdooligan. ↑  ↓

#3 Oct 06, 2016 9:56 am
beko beko Offline
Developer, Administrator
Registered since: Jun 04, 2004
Posts: 2,279


Subject: Re: Cursors have magenta backgrounds?
We've some own class for PCX. I don't recall the name but it's somewhat named with "SDL". That's probably the place to poke. This file wasn't touched in years and I've no idea what exactly is going on. Mayhap it's some compatibility issue with SDL2.

We were going to switch to SDL_Image some day and make use of PNG.
Bernd Kosmahl
"Sir, we are surrounded!" - "Great - we can attack in any direction."
↑  ↓

#4 Oct 06, 2016 7:55 pm
mdooligan mdooligan Offline
Approved Member
Registered since: Dec 07, 2008
Posts: 36


Subject: Re: Cursors have magenta backgrounds?
Thank you for the reply.

I don't think it's in the maxr implementation of PCX either. PCX is a very straightforward format, and we need to keep it because the original graphics are in PCX. I think it's SDL2, I had trouble with it recently when re-compiling something, maybe a year ago... When I down-graded the project to SDL1.2 the problem went away. Now if I could only remember what that was...

So nobody else has reported this problem? That's what I wanted to know, and get the topic up here in case anyone else does encounter it.

BTW I think the code re-work is fantastic, the way eveything is parceled out into it's own subdirectory in a very organized and easy to follow manner. I see why it took 4 years to get this release out.

SDL_Image is pretty mature, and we're already using SDL for everything else, so why not? I was actually surprised when cmake didn't go looking for it. The choice of cmake is good too, maybe you guys dislike autotools as much as me Wink

If I solve the magenta-transparency-cursor issue, I will post the details here.
Miven Dooligan
Peace and cheer
↑  ↓

#5 Oct 07, 2016 2:07 am
mdooligan mdooligan Offline
Approved Member
Registered since: Dec 07, 2008
Posts: 36


Subject: Re: Cursors have magenta backgrounds?
Update: I found a program that will grab the screen *and* grab the cursor also. xfce4-screenshooter does a nice job and sends the file straight to gimp.

The strange thing is that the screenshot has no magenta but the *actual* screen does have magenta. Does that point to a driver issue? Something between xorg and the monitor?
Miven Dooligan
Peace and cheer
↑  ↓

#6 Oct 14, 2016 6:56 am
nonsinn nonsinn Offline
G-Mod, Approved Member
Registered since: Apr 02, 2012
Posts: 254


Subject: Re: Cursors have magenta backgrounds?
It seems as you are compiling everything for yourself, how is it working with the "official" one and the patched sdl2 -> nice topic ?
[15:23:19] nonsinn [..] heißt nun bug-hunter
[19:58:09] Eiko_ [..] heißt nun mother-of-bugs
[20:38:11] <bug-hunter> mother-of-bugs: ..argh..
[20:38:26] <@mother-of-bugs> want some new bugs?
↑  ↓

#7 Oct 14, 2016 9:19 am
beko beko Offline
Developer, Administrator
Registered since: Jun 04, 2004
Posts: 2,279


Subject: Re: Cursors have magenta backgrounds?
Quote by mdooligan:

The strange thing is that the screenshot has no magenta but the *actual* screen does have magenta. Does that point to a driver issue? Something between xorg and the monitor?
Afraid nobody of us is deep enough into this. It's also the first time I read about this as an issue.
Bernd Kosmahl
"Sir, we are surrounded!" - "Great - we can attack in any direction."
↑  ↓

#8 Oct 14, 2016 4:06 pm
mdooligan mdooligan Offline
Approved Member
Registered since: Dec 07, 2008
Posts: 36


Subject: Re: Cursors have magenta backgrounds?
Quote by nonsinn:
It seems as you are compiling everything for yourself, how is it working with the "official" one and the patched sdl2 -> nice topic ?
I know nothing of patches. I had some time on my hands and wandered by to see the new release up for grabs. The tarball compiled beautifully on my Arch Linux box and works great. I see no fundamental problems, just a gajillion little things here and there that need tweaking, as usual.

I have nothing but praise for the code re-organization. I've been enjoying myself hacking about, getting to know the code, and playing it. The interface is great, that SPACE=done+next makes it super easy to play a couple teams at the same time and blast through the turns. Fantastic, I say.
Miven Dooligan
Peace and cheer
↑  ↓

#9 Oct 14, 2016 4:43 pm
mdooligan mdooligan Offline
Approved Member
Registered since: Dec 07, 2008
Posts: 36


Subject: Re: Cursors have magenta backgrounds?
Quote by beko:
Quote by mdooligan:

The strange thing is that the screenshot has no magenta but the *actual* screen does have magenta. Does that point to a driver issue? Something between xorg and the monitor?
Afraid nobody of us is deep enough into this. It's also the first time I read about this as an issue.
Me neither. I used to be that deep, but not for many years.

I'm sure it's something between SDL2 and the radeon driver, something peculiar to my system, radeon have demonstrated issues all over the place, and SDL2 is still a little green. I have not yet compiled it on my gentoo OS to see if the problem exists there too.
Miven Dooligan
Peace and cheer
↑  ↓

#10 Oct 15, 2016 10:47 am
beko beko Offline
Developer, Administrator
Registered since: Jun 04, 2004
Posts: 2,279


Subject: Re: Cursors have magenta backgrounds?
So nothing changed for ATI after all?

I stopped using any radeon stuff back in 2007 when I always missed the beginning of the new years because I was trying to get that mofo of an ATI card going.

Nvidia since then all the way down. So much... less... PITA. On Linux.
Bernd Kosmahl
"Sir, we are surrounded!" - "Great - we can attack in any direction."
↑  ↓

Pages (1): 1

All times are GMT +01:00. Current time: 7:51 pm.