Jump to content

"Deffered" sound loading


machoman811
 Share

Recommended Posts

Hi!

 

I'm having problems while trying to use a second thread to call the loadsound function from LW. From my understanding, the issue might not be exactly with the sound system. Correct me if I'm wrong, but it seems like the sounds are linked together with the current tworld.. and that's a problem if you're working with a thread since you never know which is the current world (since I have many). Maybe I'm wrong though... I don't have the engine's sources so I can't confirm my hypothesis.

 

If I'm right, I may have to re-implement the sound engine (probably with openal again) like I did with the physics engine (I needed more control over it)... but I would like to prevent that since it does work properly right now if I don't switch from one world to the other in the loading phase of the sounds..

 

Anyway....

Link to comment
Share on other sites

From my understanding there are no thread safe commands in LE. It's not a thread safe library currently.

 

I understand that but I believe that having the sounds and graphics engines on different threads should still be possible. I just need to have enough information on the sources.

 

For instance, I realized that, in the case the non thread safe thing is creation of the sources, I could try loading the sounds on the thread and creating the sources upon every play commmands.. Since those commands are normally sent from the entity that's part of a specific world.. it could work. Anyway, I'll try that out but I still need more inputs from you all.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...