[vorbis-dev] Clean separation of encode and decode?

David Etherton etherton at rockstarsandiego.com
Wed May 21 10:50:28 PDT 2003


Okay, that wasn't so painless after all.  Attached is a cvs diff of my DECODE_ONLY changes; I can resupply the patch with whatever diff options somebody would prefer.

Here are the files I needed to get it to link properly:

cl -D DECODE_ONLY -I ../include -I ../../ogg/include decoder_example.c info.c block.c registry.c mapping0.c res0.c floor0.c floor1.c bitrate.c synthesis.c mdct.c psy.c lsp.c envelope.c codebook.c sharedbook.c window.c smallft.c bitwise.c framing.c 

The last two are actually part of ogg, not vorbis.

The only potential problem I saw is in mapping0.c, which sets up a table of function pointers.  My assumption is that mapping0_forward is an encode-only function, so I ifndef'd its reference and replaced it with a null pointer.  Also, while mucking around in psy.c I assume that functions containing "anaylsis" were encode-only.

Hope this helps,

-Dave

<p><p>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: decode-only-patch
Type: application/octet-stream
Size: 1750 bytes
Desc: decode-only-patch
Url : http://lists.xiph.org/pipermail/vorbis-dev/attachments/20030521/5855db28/decode-only-patch.obj


More information about the Vorbis-dev mailing list