[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: writing integer with fwrite
From: |
Miroslaw Kwasniak |
Subject: |
Re: writing integer with fwrite |
Date: |
Tue, 14 Dec 2004 16:01:52 +0100 |
User-agent: |
Mutt/1.5.6+20040907i |
On Tue, Dec 14, 2004 at 01:26:41AM -0600, address@hidden wrote:
> Hello and thanks for the quick answer,
>
> But it doesn't solve the problem.
> The statement:
> cnt=fwrite(fid, bytes,'uint32')
> Returns cnt=2, so it uses two uint32 values to store the one variable,
> in Matlab it returns cnt=1, converting the value bytes to a
> 32bit-Integer before writing. I need it to store as a 4byte value when
> using uint32.
> Any ideas?
> I am using the precompiled windows version 2.150 from sourceforge.
> Is this perhaps a known bug?
On linux:
octave:1> f=fopen('xxx','wb'); fwrite(f,12.5,'uint32'), fclose(f); ls -l xxx
ans = 1
-rw------- 1 mirek mirek 4 2004-12-14 16:00 xxx
octave:2> OCTAVE_VERSION
OCTAVE_VERSION = 2.1.50
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------
- Re: Packaging Octave for Windows and OS X (was: writing integer with fwrite), (continued)
- Re: Packaging Octave for Windows and OS X (was: writing integer with fwrite), Paul Thomas, 2004/12/14
- Re: Packaging Octave for Windows and OS X (was: writing integer with fwrite), John W. Eaton, 2004/12/14
- Re: Packaging Octave for Windows and OS X (was: writing integer with fwrite), Paul Laub, 2004/12/14
- Re: Packaging Octave for Windows and OS X (was: writing integer with fwrite), Andy Adler, 2004/12/14
- Re: Packaging Octave for Windows and OS X (was: writing integer with fwrite), Paul Kienzle, 2004/12/14
- Octave type system., Muthu, 2004/12/16
Re: writing integer with fwrite,
Miroslaw Kwasniak <=