This solution
for i=0,24 do cgimage, im,xv=x,yv=x,/axis, color='dodger blue'
works like a charm, regardless of Device settings etc.
About the retain:
If i use:
Device, Retain=0
!p.multi=[0,5,5]
for i=0,24 do cgImage, im, /Axes & !p.multi=0
I get colors.
If i use
Device, Retain=2
!p.multi=[0,5,5]
for i=0,24 do cgImage, im, /Axes & !p.multi=0
I get colors
if i use
Device, Retain=2
cgDisplay
!p.multi=[0,5,5]
for i=0,24 do cgImage, im, /Axes & !p.multi=0
I don't get colors, but i have the other "bug" the first 4 plots have black axes and the others have white..
i get the same result if retain is set to 0, so i think that cgDisplay does some trick and solves the problem at some extent.
On Monday, April 7, 2014 6:27:44 PM UTC+1, David Fanning wrote:
> David Fanning writes:
>
>
>
>> I suspect the problem, whatever it is, has to do with reading pixel
>
>> values from the display. We could confirm that by doing something like
>
>> this and seeing if the axes are the correct color:
>
>>
>
>> !p.multi=[0,5,5]
>
>> for i=0,24 do cgimage, im,xv=x,yv=x,/axis, color='dodger blue'
>
>> !p.multi=0
>
>
>
> Another idea just occurred to me. Type this command, then open a window
>
> and see what happens:
>
>
>
> IDL> Device, Retain=2
>
> IDL> cgDisplay
>
> IDL> cgImage, cgDemodata(7), /Axes
>
>
>
> Maybe it is a backing store problem.
>
>
>
> Cheers,
>
>
>
> David
>
> --
>
> David Fanning, Ph.D.
>
> Fanning Software Consulting, Inc.
>
> Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
>
> Sepore ma de ni thue. ("Perhaps thou speakest truth.")
|