Video Freeze Issues on iOS

I'm having an issue on an iOS app where the Hype animations cause the auto-played video to freeze upon activating the html. I'm not using video in the Hype file itself. The video is incorporated into the app itself. You can see numerous examples of the problem by downloading the free version of the app on Apple's App Store here: https://apps.apple.com/us/app/cafe-hebrew-safari/id1199800084
You can also just type in Cafe Hebrew: Safari in their search bar if you don't want to click on the link.
Note: I do not have issues with this on Android, but just on iOS.
For example: on each page you will see an animal, along with my Hype interactive coffee cups at the bottom. Additionally, there is an interactive (Hype html) speech cloud floating near a parrot. If you tap either the coffee cup or the speech cloud, the video will suddenly freeze up. Is there a way to fix this? Why does the hype interaction cause the video to freeze?

It seems this happens when the hype part is playing audio? It is probably the case that iOS wants there to only be one "active" video/audio component, and is therefore pausing the active one when a new one wants to be played?

I think the questions would be how you're setting up the video if it isn't in the Hype document? And also how you're setting up the audio in the Hype document?

There's probably ways to configure the iOS video class you're using, but I'm no expert on AVMediaPlayer stuff...

About the best thing you could try from the Hype side if you're using Hype's built-in audio functionality is toggling the "Use low latency web audio api" button in the document inspector.

I included a link to the Hype file for the Lion which can be found in the actual iOS app by swiping right to pg 3. See link here: WeTransfer - Send Large Files & Share Photos Online - Up to 2GB Free
In the Lioness Hype file, it shows that the "Use low latency web audio api" is already activated. So since that doesn't appear to solve the issue because it is already in use in the app- are you saying i should uncheck the "use low latency web audio api" option in Hype?

Not looked at the project as Not at Mac.

But I think @jonathan is pointing out that for the AVPlayer framework in the iOS coding you may need to change its play back options.

They normally (if remember correctly ) are set to playback that wiil stop other sounds while doing so. .

They have other options like mixed and so on.
And you may need to set yours up to give you the correct results you are after.

It can be tricky to workout which options you need.
Best bet is to search google and stackoverflow as well as look at apples docs.

If I get a chance I will look what I have done in the past


Found this on Stackoverflow. Which looks like what you can try.


In my App Audio is set to .playback but yours may need to be set as stated in the stackoverflow post to Ambient

audioSession.setCategory(.ambient)

Note depending on how you wrote your player depends on the correct syntax.

--

Really nice App by the way... :+1:

I'm saying this is the only control in Hype that might have an effect. I'm not sure, and it could go either way :slight_smile:. It is more likely it is something you need to do on the iOS app side of things, like what @MarkHunte followed up with.

1 Like