[vorbis-dev] encoding question

Thanatos02 at gmx.de Thanatos02 at gmx.de
Mon Dec 16 04:04:42 PST 2002



Hi there,
I've a little question abound programming an ogg-vorbis encoder.
The encode_example.c works ok for files with 44100/2/16 - but not for other
formats.
I don"t really understand what this piece of code is really doing:
 /* uninterleave samples */
      for(i=0;i<bytes/4;i++){
        buffer[0][i]=((readbuffer[i*4+1]<<8)|
                      (0x00ff&(int)readbuffer[i*4]))/32768.f;
        buffer[1][i]=((readbuffer[i*4+3]<<8)|
                      (0x00ff&(int)readbuffer[i*4+2]))/32768.f;
      }
how should this part look for files with other specifications then
44100/2/16?
I'd a look at the oggenc source - but i didn"t find something familar and
the vorbisenc-doku didn"t really help.


-- 
+++ GMX - Mail, Messaging & more  http://www.gmx.net +++
NEU: Mit GMX ins Internet. Rund um die Uhr für 1 ct/ Min. surfen!

--- >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-dev-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-dev mailing list