Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

HTML5 videos and embeded Youtube black screen issues only on Android
Started by daljit.kumar4 Mar 11 2019 08:53 AM

4 replies to this topic
html5 videos embeded youtube video black screen on android

Best Answer daljit.kumar4 , 11 June 2019 - 12:35 AM

We were able to identify and resolve this issue. We had set the webview to have a transparent background which was causing this issue. Removing the following line of code resolved the issue.

webView.hasBackground = false;

Because of this line of code there was one more issue happening. It was causing the webview's scroll to be jerky.

 

Removing this line resolved both the issues on Android. There was no issue on iOS. Hope this is fixed in future builds.

[TOPIC CONTROLS]
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

daljit.kumar4

[GLOBAL: userInfoPane.html]
daljit.kumar4
  • Observer

  • 5 posts
  • Corona SDK

I am facing an issue with the HTML5 videos and Youtube black screen issues only on Android, it is working fine when video is running on Fullscreen but has the black screen with audio playing fine when running in normal mode. This issue even persists with Youtube embed videos.

 

We have also tested it on Android mobile browser (Chrome) and it running fine but not working in native webview.

 

Using Corona SDK (ver. 2018.3326)

 

HTML 5 video: <iframe id="video-container" width="100%" height="100%" frameborder="0" src="videos/<videopage>.html" allow="" allowfullscreen></iframe>

 
Youtube embed video: <iframe id="video-container" width="100%" height="100%" frameborder="0" src="https://www.youtube.com/embed/XXXXXX?version=3&amp;enablejsapi=1&amp;html5=1" allow="accelerometer; encrypted-media; gyroscope" allowfullscreen></iframe>


[TOPIC: post.html]
#2

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,786 posts
  • Enterprise

I certainly would grab the latest daily build. There were a ton of HTML5 enhancements since 2018.3326.

 

Rob



[TOPIC: post.html]
#3

daljit.kumar4

[GLOBAL: userInfoPane.html]
daljit.kumar4
  • Observer

  • 5 posts
  • Corona SDK

Hi Rob,

 

We tried publishing the apk with the latest daily build (2019.3473). However, the result is same. Do you have any other suggestion to fix this issue. Your timely help is greatly appreciated as our app is live and we are receiving tickets regarding this issue.

 

Thanks!



[TOPIC: post.html]
#4

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,786 posts
  • Enterprise

Are you playing this in a webView or building an HTML5 app and attempting to play a video?

 

Rob



[TOPIC: post.html]
#5

daljit.kumar4

[GLOBAL: userInfoPane.html]
daljit.kumar4
  • Observer

  • 5 posts
  • Corona SDK

  Best Answer

We were able to identify and resolve this issue. We had set the webview to have a transparent background which was causing this issue. Removing the following line of code resolved the issue.

webView.hasBackground = false;

Because of this line of code there was one more issue happening. It was causing the webview's scroll to be jerky.

 

Removing this line resolved both the issues on Android. There was no issue on iOS. Hope this is fixed in future builds.




[topic_controls]
[/topic_controls]