OpenGL音频波形渲染
我想弄清楚如何从音频文件渲染波形。我可以使用 OpenGL+OpenAL 做到这一点吗?
主要想法是我需要根据音频数据绘制 3D 场景(如过山车)。
I am trying to figure out how to render a waveform from an audio file. Can I do that using OpenGL+OpenAL?
The main idea is that I need to draw a 3D scene (like a rollercoaster) based on audio data.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
是的,你可以用 openGL 渲染任何东西,但这取决于你对 3d 编程的了解,你是 openGL 的新手,也许你想尝试使用 SDL 或 3d 引擎,如 Ogre3D,如果你想以 2D 渲染它,但使用 GPU 加速,你可能会想要使用 cairo API 来渲染它,使用 openGL 渲染后端作为纹理渲染。
您不需要 openAL 来获取音频数据并从中渲染,openAL 仅在您想使用 3D 空间化播放音频样本时有用(如在游戏中)
yes you can render anything with openGL, but it depend on your knowledge about 3d programming, you are new to openGL maybe you want to try using SDL or 3d engines like Ogre3D, if you want to render it in 2D but with GPU acceleration you might want to render it using cairo API using openGL render back-end as a render to texture.
you don't need openAL to get the audio data and to render from it, openAL is only useful if you want to play audio sample using 3D spatialization (like in game)
如果您的目标主要是渲染波形 - 无需编程 - 您可以看看 vvvv 工具。它肯定有你需要的东西。
如果使用现有的库或概念不是问题,您还可以查看 processing (Java) 或 openframeworks (C++) 应该为您提供所需的构建块。
If your aim is mainly to render the waveform - without programming - you could take a look at vvvv tool. It surely have what you need.
If using existing librairies or concepts is not a problem, you could also take a look at processing (Java) or openframeworks (C++) that should offer building blocks for what you need.