问题编码WAV到的Ogg Vorbis [英] Problem encoding wav into ogg vorbis
问题描述
我有一个MFC应用程序。我有存储在WAV格式的音频数据。我的问题是,我怎么能带code数组这些字节成的Ogg Vorbis格式?
I have an MFC application. I have audio data stored in wav format. My question is, how can I encode an array of those bytes into an ogg vorbis format?
我发现了一个例子:
http://svn.xiph.org/trunk/ Vorbis格式/例子/ EN coder_example.c
,并试图在我的应用程序中使用它。
首先,我试着将它添加到我的项目和编译。我不得不添加包括在上述文件中的文件,所以我发现他们在图书馆libvorbis和libogg。可是我还是不能链接:
and tried to use it in my application. First, I tried to add it to my project and compile. I had to add files included in the above file, so I found them in the libraries libvorbis and libogg. And still I cannot link:
Error 4 error LNK2019: unresolved external symbol _oggpack_writetrunc referenced in function _vorbis_bitrate_addblock bitrate.obj
Error 2 error LNK2019: unresolved external symbol _oggpack_write referenced in function _vorbis_bitrate_addblock bitrate.obj
Error 8 error LNK2019: unresolved external symbol _oggpack_read referenced in function _vorbis_staticbook_unpack codebook.obj
Error 10 error LNK2019: unresolved external symbol _oggpack_look referenced in function _decode_packed_entry_number codebook.obj
Error 7 error LNK2019: unresolved external symbol _oggpack_get_buffer referenced in function _vorbis_bitrate_flushpacket bitrate.obj
Error 5 error LNK2019: unresolved external symbol _oggpack_bytes referenced in function _vorbis_bitrate_addblock bitrate.obj
Error 9 error LNK2019: unresolved external symbol _oggpack_adv referenced in function _decode_packed_entry_number codebook.obj
Error 3 error LNK2001: unresolved external symbol _oggpack_write codebook.obj
Error 6 error LNK2001: unresolved external symbol _oggpack_bytes codebook.obj
我找不到在哪里那些家伙的定义。
我想AP preciate任何帮助。
I could not find where those guys are defined. I would appreciate any help.
感谢。
推荐答案
GCC c页-lvorbisenc -o p结果
或结果
GCC c页-lvorbis -lvorbisenc -o P
gcc p.c -lvorbisenc -o p
or
gcc p.c -lvorbis -lvorbisenc -o p
但我没有检查它是否会带code一个wav呢。
But I have not checked if it will encode a wav yet.
这篇关于问题编码WAV到的Ogg Vorbis的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!