使用带有c#的asp.net将amr文件转换为wav文件 [英] converting amr file to wav file using asp.net with c#
问题描述
如何使用带有c#的asp.net将amr文件格式转换为wav文件格式?
您可以尝试通过以下方式查找编解码器源代码:此处列出的参考文献: http://en.wikipedia.org/wiki/Adaptive_Multi-Rate_audio_codec#Software_support [ ^ ]。
许多代码都是开源的(我记得VLC和FFmpeg都是)但不幸的是,大多数是在C语言中,在C ++中不太可能。
以下是您可以做的事情:
- 将代码翻译成C#;
- 使用P /调用以在项目中使用C代码;请参阅 http://en.wikipedia.org/wiki/P/Invoke [ ^ ], http://msdn.microsoft.com/en-us/library/Aa712982 [ ^ ],另请参阅此CodeProject文章: Essential P / Invoke [ ^ ];
- 创建用C ++ / CLI和C ++编写的混合模式(托管+非托管)项目,将编解码器代码嵌入到C ++部分中,并将一些方法导出为托管方法;在C#项目中引用时,生成的可执行文件可用作普通的.NET程序集。
经过短暂的搜索,我找不到任何现成的C#代码;有很多项目,但大多数只是提出答案的问题...在CodeProject和Google中寻找答案。是的,你可以尝试找别的......
祝你好运,
-SA
这是关于.NET的VLC组件绑定的更新有用信息:
http://sourceforge.net/projects/libvlcnet/ [ ^ ],
https://wiki.videolan.org/C_Sharp/ [ ^ ],
https://wiki.videolan.org/.Net_Interface_to_VLC/ [ ^ ]。
值得注意的是,您可以找到使用该组件的材料WPF和System.Windows.Forms
。
-SA
how to convert amr file format to wav file format using asp.net with c#?
解决方案You can try to find the codec source code by the references listed here: http://en.wikipedia.org/wiki/Adaptive_Multi-Rate_audio_codec#Software_support[^].
Many of the codes are open-source (I remember VLC and FFmpeg are) but, unfortunately, mostly in C, less likely in C++.
Here is what you can do:
- Translate the code into C#;
- Use P/Invoke to use C code in your project; see http://en.wikipedia.org/wiki/P/Invoke[^], http://msdn.microsoft.com/en-us/library/Aa712982[^], see also this CodeProject article: Essential P/Invoke[^];
- Create mixed-mode (managed+unmanaged) project written in C++/CLI and C++, embed the codec code in C++ part and export some method as managed method; the resulting executable can be used as a normal .NET assembly when referenced in your C# project.
After a short search, I could not find any ready-to-use C# code; there are many items but most of them are just question with the answers advising to… search for an answer in CodeProject and Google. Yes, you can try to find something else…
Good luck,
—SA
This is the updated useful information on the VLC component binding for.NET:
http://sourceforge.net/projects/libvlcnet/[^],
https://wiki.videolan.org/C_Sharp/[^],
https://wiki.videolan.org/.Net_Interface_to_VLC/[^].
Notably, you can find material for using the component for both WPF andSystem.Windows.Forms
.
—SA
这篇关于使用带有c#的asp.net将amr文件转换为wav文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!