Advertisement

how to program 3d sound with SDL and OpenAL?

Started by August 23, 2008 10:28 PM
0 comments, last by hh10k 16 years, 3 months ago
hi,all Could you tell me how can i program 3d sound with SDL and openal? I see an artical on how to Program 3D Sound With OpenAL and d3d. I want to know can i use SDL instead of D3D to develop 3D sound.
OpenAL just controls audio, and doesn't need to interact with SDL or Direct3D at all. You could take the OpenAL code from the article you mentioned, and put it in a console application.

You also seem a little hazy about the difference between Direct3D and SDL. Direct3D is an API for drawing 3D into a window. This window, however, must be created by some other means. On the Windows operating system you would normally do so using the Win32 API functions like RegisterClass() and CreateWindow(), however SDL is a cross-platform API that simplifies this process for you. SDL also provides many other things you would likely want in a game.

SDL only provides simple 2D drawing capabilities, so it is designed to be used with OpenGL. If you want to use Direct3D with SDL, have at look at this article.

This topic is closed to new replies.

Advertisement