On Tuesday 29 Dec 2009, Roshan wrote:
I have been trying to search on reading an image file
via C. I
haven't been able to find code without libraries. However, being
aware of the 'binary' mode in Windows (Turbo C++), I had read it
using fopen, fread and fseek to read the header and then the
contents. However, this reading was done reading individual bytes
and not reading it using structures.
Unix/Linux don't distinguish between binary and ASCII mode files. Use
the same function calls as you do in Winduhs, just omit the "b" in the
fopen.
Regards,
-- Raju
--
Raj Mathur raju(a)kandalaya.org
http://kandalaya.org/
GPG: 78D4 FC67 367F 40E2 0DD5 0FEF C968 D0EF CC68 D17F
PsyTrance & Chill:
http://schizoid.in/ || It is the mind that moves