CocosDenshion: fixed wrong assertion in android OpenSL engine

Playback rate interface cannot be initialized for some players in
android 4.x, it's not cocos2d bug.
This commit is contained in:
Sergey Shambir 2013-07-08 19:46:29 +04:00
parent 52a987b84e
commit 3d3a628fb5
1 changed files with 2 additions and 3 deletions

View File

@ -311,9 +311,8 @@ bool createAudioPlayerBySource(AudioPlayer* player)
result = (*(player->fdPlayerObject))->GetInterface(player->fdPlayerObject, getInterfaceID("SL_IID_SEEK"), &(player->fdPlayerSeek));
assert(SL_RESULT_SUCCESS == result);
// get the playback rate interface
result = (*(player->fdPlayerObject))->GetInterface(player->fdPlayerObject, getInterfaceID("SL_IID_PLAYBACKRATE"), &(player->fdPlaybackRate));
assert(SL_RESULT_SUCCESS == result);
// get the playback rate interface, if available
(*(player->fdPlayerObject))->GetInterface(player->fdPlayerObject, getInterfaceID("SL_IID_PLAYBACKRATE"), &(player->fdPlaybackRate));
return true;
}