At 13.41 +0000 03-02-17, Robert Tweed wrote:
----- Original Message -----
From: "Andreas? Gaunitz?" <[EMAIL PROTECTED]>
 Does any of you know where to find methods for converting director
 integers, floats, etc to the C data types as stored in binary files,
 like a longInt stored as "a  linear two's complement value" etc?
I'd be more concerned about whether they are stored as little-endian or
big-endian. Converting floats is a problem, although I expect something like
the vList Xtra will do it. I can't think of any way to get the binary
representation in pure Lingo. For ints, you can use bitAnd to get the value
of each byte, and then store those bytes in a string with numToChar - you
just have to put them in the right order, which will depend on the file
format you're dealing with.

It's an AIFF file. The ints and longInts seem to not be so much of a problem. right now each 16 bit sample point looks like this "000 250, 123 006" etc. I'm not sure how the floats are represented though.

-A.

[To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]


Reply via email to