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

Home » Public Forums » archive » Re: TV, AXIS, T3D, Coordinate Systems
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: TV, AXIS, T3D, Coordinate Systems [message #33879 is a reply to message #33878] Wed, 05 February 2003 05:26 Go to previous messageGo to previous message
bias is currently offline  bias
Messages: 7
Registered: February 2003
Junior Member
David Fanning <david@dfanning.com> wrote in message news:<MPG.18a98de2d2c2fb11989ac2@news.frii.com>...
>
> What happens is that the SURFACE command establishes
> a data coordinate system and sets up scaling parameters
> in the !X.S, !Y.S, and !Z.S system variables. These
> scaling parameters tell IDL how to take a point in data
> space and place it in the display window in pixel space.
> As system variables, of course, these persist until you
> exit IDL and start over.
>
> The AXIS command can generate its own data space, of course,
> if you use the SAVE keyword, but its normal behavior is to use
> the data space that was previously established. Had you not
> done some kind of graphics command before issuing the AXIS
> command,the default coordinate system would have the z-axis coming
> out of the display screen directly toward you. So you need some
> way to make the Z axis point in the right direction. The SURFACE
> command is doing this rotation for you, but you could do it
> yourself with the T3D command, for example. (I would probably
> use SURFR or SCALE3 to do this in your case.)
>
> In any case, whatever data system you had in place when you
> first issued the AXIS command resulted in a very short Z axis.
> I think your best bet would be to set up a 3D coordinate system
> with the correct axis ranges with SCALE3, then use this coordinate
> system (set the T3D keyword) when calling your graphics commands.
>
> Cheers,
>
> David

First thank you, but i must admit that i still have problems with
understanding.

I actually thought i had set up the transformation when i called
SCALE3 and used it by setting the T3D keyword with AXIS.
The TV command doesn't seem to have any influence to !P.T and so
i thought i could draw the axis right away.

The problem is, as you pointed out, that !X.S, !Y.S and !Z.S have
to be generated in the correct manner. The SURFACE procedure does
that but SURFR and SCALE3 seem not to, although the help says that
SURFR 'duplicates ... the features of the SURFACE routine'.

So my question is what would you suggest to correctly calculating
!X.S etc. before calling AXIS?

the according piece of program looks like this:

S = SIZE( x )
SCALE3, XRANGE=[0,S[1]], YRANGE=[0,S[2]], ZRANGE=[0,S[3]]
SHADE_VOLUME, x, level, v, p
TV, POLYSHADE( v, p, /T3D )
;SURFACE, x[*,*,0], /NODATA, /NOERASE, /T3D ; <--- this does work
;SURFR... ;<--- these do
;SCALE3... ;<--- not
AXIS, ZAXIS = 0, /NOERASE, /T3D
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Re: Expert information needed
Next Topic: strmatch in idl versions earlier than 5.3

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

Current Time: Sun Oct 12 08:15:07 PDT 2025

Total time taken to generate the page: 0.87083 seconds