[Help] Problem with ximage in 3.7.2

Greg,

I've finally a clue why [on my SGI FUEL, IRIX 6.5.28,
MipsPro 7.4.4, VPro12] ximage from Radiance 3.7.2 displays
my pics color-wise *wrongly* but - on the same machine -
ximage from Radiance 3.1.11 shows them *correctly*; I found this
by re-compilation with -DDEBUG.

As it turned out, the two Radiance versions actually choose
*different* "best" visuals; 3.1.11 selects "TrueColor, depth 24"
(ximage ok), but 3.7.2 picks "TrueColor, depth 30" (ximage wrong)
(just compare <viscmp>/x11image.c 3.1.11/3.7.2).

As a test, I explicitely set the visual in 3.1.11 to a
"TrueColor, depth 30" visual and then ximage displays my pics
color-wise *wrongly* as well [just like 3.7.2 with its own "best"
visual does]. Conversely, setting a "TrueColor, depth 24" visual
explicitely in 3.7.2, pics are displayed correctly.

So, I think that handling of "TrueColor, depth 30" is *buggy* in
*both* 3.1.11 and 3.7.2. BTW, "DirectColor, depth 24" doesn't
display my pics either - I just get a window with black background
(?) and no image...

For a temporarily by-pass [hopefully only until the next official
release?], I set the visual in 3.7.2 *explicitely* to a "TrueColor,
depth 24" visual - and 3.7.2 ximage works fine on my FUEL ...

Only as a side-note, I've changed the printed information in
<getbestvis>/x11image.c for DEBUG defined to

fprintf(stderr, "Supported visuals:\n");
for (i = 0; i < vismatched; i++)
fprintf(stderr, "index= %d, id 0x%lx (%lud), class %s, depth %d\n",
i, XVisualIDFromVisual(xvi[i].visual),
XVisualIDFromVisual(xvi[i].visual),
vistype[xvi[i].class], xvi[i].depth);

and

fprintf(stderr, "Selected visual: index= %d, id 0x%lx (%lud), class %s,
depth %d\n",
i, XVisualIDFromVisual(ourvis.visual),
XVisualIDFromVisual(ourvis.visual),
vistype[ourvis.class], ourvis.depth);

respectively, as I found this a bit more informative for my debugging...

Anyway, thanks for a great piece of software!

/oskar

ยทยทยท

-----Original Message-----
From: Gregory J. Ward [mailto:[email protected]]
Sent: Wednesday, May 24, 2006 18:15
To: code development
Cc: Radiance general discussion; Itzinger, Oskar
Subject: Re: [Radiance-general] [Help] Problem with ximage in 7.3.2

Hi Oskar,

I'm moving this to the Radiance development list, since it is a code
issue that's of limited use to others. Please respond there rather
than replying to this. (You will need to subscribe first if you
aren't already on that list at <http://www.radiance-online.org/
mailman/listinfo/radiance-dev>.)

Definitely run both versions of ximage on both machines after
compiling with -DDEBUG, because the visual selection code changed
considerably between 3.1.11 and 3.7.2. It seems the color
table code
also changed, though, and the problem might be there.

-Greg

> From: "Itzinger, Oskar" <[email protected]>
> Date: May 24, 2006 3:12:55 AM PDT
>
> Greg,
>
> sorry if I sounded too complicated. What I meant is simply:
>
> I have two machines,
>
> A. SGI INDIGO2, IRIX 6.5.22, MipsPro 7.4.2 compiler, "Extreme"
> graphics
>
> B. SGI FUEL, IRIX 6.5.28, MipsPro 7.4.4 compiler, "VPro12"
> graphics
>
> Now, after re-compilation on A and B respectively, I have on
>
> A. Radiance 3.1.11: ximage displays pics *ok" color-wise
> Radiance 3.7.2: ximage displays pics *ok* color-wise
>
> B: Radiance 3.1.11: ximage displays pics *ok* color-wise
> Radiance 3.7.2: ximage displays pics *wrongly* color-wise
>
> Perhaps something in the way X visuals are selected changed from
> 3.1 to 3.7 [my default on B is an 8-bit PseudoColor visual - but
> I could alter that to something else if necessary].
>
> Maybe it helps if I recompile 3.7.2 on B with -DDEBUG to see
> which visuals are recognized and which one is finally selected in
> x11image.c?
>
> BTW, running "rmake ximage" in ray/sr/px didn't change any...
>
> Thanks.
> /oskar

DISCLAIMER

This e-mail and any files transmitted with it are intended solely for the use of the individual or entity to which they are addressed and may be legally privileged and/or confidential. Any unauthorized use, disclosure or copying of this e-mail or any of its attachment(s) by unintended recipient may be unlawful and is strictly prohibited. If you have received this e-mail in error, please immediately notify the sender by e-mail and permanently delete the original e-mail and attachment(s) from your computer system.

Any opinions contained in this message are those of the author and are not given or endorsed by OPEC, unless otherwise clearly indicated in the message, and the authority of the author to so bind OPEC is duly verified. OPEC does not warrant or assume any legal liability or responsibility for the accuracy, completeness, or usefulness of any information contained in the e-mail content transmitted over the Internet.

Thank you for your cooperation.