 marco
|
Hi Halle,
As the topic title states, OpenEars stops recognizing after i play a video. I’ve tried using both MPMoviePlayerController and AVPlayer. When i log the OpenEars after playing the video, it just listens. I have to restart the app so that OpenEars would recognize speech again. Any ideas?
-
This reply was modified 219 days ago by
marco. Reason: edit post
|
 Halle
|
Hi Marco,
Are you using the current version and have you read the other posts about this issue?
http://www.politepix.com/forums/topic/cant-recognize-speech-after-playing-video-with-avplayer/
http://www.politepix.com/forums/topic/unable-to-re-initialize-audio-session-after-mpmovieplayercontroller/
http://www.politepix.com/forums/topic/simultaneous-mpmovieplayercontroller-video-and-speech-recognition/
Note: I think this last one has a typo in this part:
1) Set any MPMoviePlayerController you create in the application to use the applicationAudioSession. This prevents some conflicts between the PocketSphinx audio session setting and the MPMoviePlayerController audio session settings. It also stops kAudioUnitErr_CannotDoInCurrentContext errors being thrown in the AudioUnitRender in the AudioUnitRenderCallback function during video playback.
moviePlayerController.useApplicationAudioSession = NO;
But I don’t know if the typo is in the code or the description of what you are trying to accomplish with it, and the poster hasn’t followed up.
|
 marco
|
Hi Halle,
calling the “startAudioSession” method did it. I am using version 0.912. THANK YOU Halle. OpenEars has saved me a LOT of time and work. As always you still amaze me for your quick responses. Thank you once again! I’m sorry for not digging deep into the forums as I’ve been struggling for days now to find a workaround. I did thought about calling the “startAudioSession” method again but having read your instructions about creating the AudioSessionManager to be instantiated only ONCE in the lifetime of the app, i didn’t dwell on the thought.
|
 Halle
|
It’s no problem, there’s also the issue that I’m using bbpress 2 for the forum software which doesn’t currently have a working forum search feature (not that that’s important or anything) so it isn’t easy to find previous posts on a topic right now.
having read your instructions about creating the AudioSessionManager to be instantiated only ONCE in the lifetime of the app, i didn’t dwell on the thought.
I know, to be honest I’m not quite sure whether I want to put this info into the main instructions yet because I think it could be very confusing to developers who don’t need it, and the advice goes contrary to best practices with Audio Sessions so I’m ambivalent. I also don’t really have a ton of data yet about whether the fix works definitively. I could link the discussions in the FAQ though.
|