[vorbis] Getting started with vorbisfile_example.c (MS VC6)

Govind Kharbanda govind.kharbanda at sli-institute.ac.uk
Mon Jul 1 07:52:10 PDT 2002



Hi,

Thanks for your help guys... we've successfully got vorbisfile_example.c
and seeking_example.c to compile, link and execute.

When the executables were run, nothing happened because the program
looks for input from stdin.  Therefore, we changed the source to open a
file (using "rb" as suggested by Michael and others) and passed its
handle to the ov_open() call made in the program.  When this was
completed the program ran and printed the PCM stream as text to the
screen; the file information should have been printed first but the
garbage prevented us from reading this, so we uncommented the
fwrite(pcmout, 1, ret, stdout) line; rebuilding the program gave the
file comments as expected.

Cheers,
Gov

Michael Smith wrote:
> 
> >file * myfile;
> >myfile = fopen("C:\downloads\music.ogg","r");
> 
> This is an incredibly stupid 'feature' of DOS and windows. Use "rb" for
> the file open mode, or reading the file does not give you the file
> contents.
> 
> Michael
> 
> --- >8 ----
> List archives:  http://www.xiph.org/archives/
> Ogg project homepage: http://www.xiph.org/ogg/
> To unsubscribe from this list, send a message to 'vorbis-request at xiph.org'
> containing only the word 'unsubscribe' in the body.  No subject is needed.
> Unsubscribe messages sent to the list will be ignored/filtered.


-- 
Govind S Kharbanda                Institute for System Level Integration
MSc Course Rep.                        Alba Campus, Livingston, EH54 7EG
http://www.sli-institute.ac.uk/~gk/                    Tel: 01506 469340

--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'vorbis-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.




More information about the Vorbis mailing list