Sign in to follow this  

OpenAL: Callbacks?

This topic is 3338 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I am wrapping the source into a AudioSource class which has convenient methods to execute an audio. The problem is that I want to execute some business logic just before the source ends playing. I cannot use a "while" to query the audio until its status is AL_STOPPED because the new layout will be redraw later in the execution flow. I already have the necessary classes to create callbacks but now I am trying to figure out if OpenAL provides me some mechanism to attach these callbacks. This is the real problem: I have a Button class that has a AudioSource and two different loyouts, one for the normal state and the other for when it is touched. The touch method then will show the "touch" layout, play the audio and finally swap again to the normal layout. The first layout change can be done without callbacks. I am open to suggestions :-)

Share this post


Link to post
Share on other sites

This topic is 3338 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this