comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: strange behaviour with z-buffer
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: strange behaviour with z-buffer [message #11950 is a reply to message #11939] Mon, 08 June 1998 00:00 Go to previous messageGo to previous message
DAMIANO ZILIO is currently offline  DAMIANO ZILIO
Messages: 8
Registered: February 1997
Junior Member
Dear ALL

David Fanning wrote:

> Damiano Zilio (damiano.zilio@jrc.it) writes:
>
>> I produce gif files with these 2 different ways:
>>
>> 1)
>> set_plot,'x'
>> window,0,reatin=2,xsixe=700,ysize=500
>> plot.....
>> img=tv()
>> write_gif,'filename',img
>>
>> 2)
>> set_plot,'z'
>> device,set_resolution=[700,500]
>> plot
>> img=tv()
>> write_gif,'filename',img
>>
>> But the gif files obtained are different!!!
>> The relative position of the colorbar, using the z-buffer are wrong!,
>> there are some
>> strange overplottings!!
>> Can I avoid this problem?
>
> You must configure the Z-graphics buffer to be exactly like
> your window. This means you need to make the resolution
> and number of colors the same. (The Z-buffer has 256 colors
> by default, which can be a very nice feature when making
> GIF files. In fact, is one reason why I almost always use
> the Z-buffer to make GIF files.) To make the Z-buffer
> exactly like your current graphics window, try this:
>
> ncolors = !D.N_Colors - 1
> Set_Plot, 'Z'
> Device, Set_Resolution=[!D.X_Size, !D.Y_Size], $
> Set_Colors=ncolors
>
> Cheers,
>
> David

am I creazy or... the plots produced on the momitor by this stupid program
are different????
Why????
>>>> >>>>>>>>>>>
pro test1
loadct,16
set_plot,'x'
plot,findgen(5),/nodata,position=[0,0,1,1]
img=tvrd()
write_gif,'x.gif',img
set_plot,'z'
ncolors=!D.N_Colors-1
device,set_Resolution=[!D.X_Size,!D.Y_Size],set_colors=ncolo rs
plot,findgen(5),/nodata,position=[0,0,1,1]
img=tvrd()
write_gif,'z.gif',img
device,/close
set_plot,'x'
read_gif,'x.gif',imgx
read_gif,'z.gif',imgz
window,1,retain=2,title='xgif'
tv,imgx
window,2,retain=2,title='zgif'
tv,imgz
end
>>>> >>>>>>>>>>>>>.

On my monitor the position af the axis in the tv of the image
plotted in the z-buffer is different from the same axes plotter in the x
device
WHY?
WHY?
WHY?

--

Damiano Zilio

Joint Research Centre of the Commission of
the European Communities
I-21020 Ispra (VA)
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: IDL and COM
Next Topic: Upgrade from 3.6

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sun Nov 30 20:20:21 PST 2025

Total time taken to generate the page: 1.03557 seconds