YCAMInterlab / Duration

Duration is an application for designing change over time
334 stars 54 forks source link

When you explicitly load a duration document, it doesn't load the audio #27

Open mazbox opened 10 years ago

mazbox commented 10 years ago

If you use the menu to open a duration document with an audio track, it doesn't load the audio track. This is because alGetError()!=AL_NO_ERROR at the beginning of ofOpenALSoundPlayer_TimelineAdditions::loadSound() a bit like glGetError(). This causes the method to return with an error, even though the load is successful. To fix it, just put an alGetError() at the beginning of the function to clear the error message (and print out something saying there was an error previously

int err = alGetError();
if (err != AL_NO_ERROR){
    ofLogError("ofOpenALSoundPlayer_TimelineAdditions")
         << "found error in openAL - err no:  " << ofToString(err));
    // don't return
}