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

Home » Public Forums » archive » Re: Determining machine endian-ness
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: Determining machine endian-ness [message #12137 is a reply to message #12129] Thu, 02 July 1998 00:00 Go to previous messageGo to previous message
pit is currently offline  pit
Messages: 92
Registered: January 1996
Member
In article <6nen9j$s9s$1@nnrp1.dejanews.com>,
menakkis@my-dejanews.com writes:
> Mark Rivers (rivers@cars3.uchicago.edu) asked:
>>> Is there a way to determine whether the machine on which IDL is executing is
>>> big endian or little endian?
>
> And David Fanning (davidf@dfanning.com) replied:
>> I see in the IDL 5.1 on-line help that there are keywords
>> SWAP_IF_BIG_ENDIAN and SWAP_IF_LITTLE_ENDIAN to the
>> BYTEORDER procedure that allow conditional byte ordering depending
>> upon the "endianness" of the machine IDL is running on. Sounds
>> like just the ticket. :-)
>
> Even more conveniently, in IDL 5.1 the OPEN routine (now) takes keywords
> SWAP_ENDIAN, SWAP_IF_LITTLE_ENDIAN and SWAP_IF_BIG_ENDIAN. These pertain to
> the computer running IDL, not the file. Presumably they make READU/WRITEU
> (and ASSOC?) smart about byte reordering. Anyone tried them yet?

Unfortunately, both ways are no option for us, as we have to be backward
compatible (some of our HP's still run 3.0.....).

But the solution of Robert works fine :-)

Peter

--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~
Peter "Pit" Suetterlin http://www.uni-sw.gwdg.de/~pit
Universitaets-Sternwarte Goettingen
Tel.: +49 551 39-5048 pit@uni-sw.gwdg.de
-- * -- * ...-- * -- * ...-- * -- * ...-- * -- * ...-- * -- * ...-- * --
Come and see the stars! http://www.kis.uni-freiburg.de/~ps/SFB
Sternfreunde Breisgau e.V. Tel.: +49 7641 3492
____________________________________________________________ ______________
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Important object lesson
Next Topic: Re: Using ASSOC function

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

Current Time: Thu Dec 04 13:39:56 PST 2025

Total time taken to generate the page: 1.44578 seconds