0

I have a flv stream played on my android device using flv.js. Everything works fine when playing in normal mode, except when I switch to fullscreen mode, it plays for 1 second and then crash. The FlvPlayer error log says:

[MSEController] > Failed to execute 'appendBuffer' on 'SourceBuffer': The HTMLMediaElement.error attribute is not null.

if I log error manually when the error occurs, i.e. flvPlayer.on(flvjs.Events.ERROR, function(e)), the corresponding logs are:

e : MediaError
videoElement.error : MediaErrorĀ {code: 3, message: "PIPELINE_ERROR_DECODE: video decode error"}

this only occurs when in fullscreen mode, I set document.body to fullscreen

Edit:

If I set the videoElement to fullscreen instead, the video can keep running, but it will be shrinked and keep flashing, also all elements on top of it are gone

Smelly Potato
  • 403
  • 3
  • 9

1 Answers1

0

Apparently adding a div as the video's parent can help

during fullscreen mode, the div tag needs to have the following style:

height/width: browser-size //without this cannot see video as overflow is hidden
overflow: hidden
transform: rotate(0.000001deg) //known bug for chrome
Smelly Potato
  • 403
  • 3
  • 9