Ultralight icon indicating copy to clipboard operation
Ultralight copied to clipboard

Video support in <video> tag for WebM not working properly, causing crashes or hanging the app

Open p0358 opened this issue 1 year ago • 2 comments

Trying to play a video like below causes Ultralight crash (0.0.0.0 being replaced with real IP) (using latest v1.3 SDK and sample app or own app integration):

<video controls autoplay height="640">
<source src="http://0.0.0.0/3.webm" type="video/webm">
</video>

ffprobe of affected video:

Input #0, matroska,webm, from '3.webm':
  Metadata:
    encoder         : libwebm-0.2.1.0
    creation_time   : 2017-08-12T18:07:05.000000Z
  Duration: 00:04:26.63, start: 0.000000, bitrate: 7638 kb/s
  Stream #0:0(eng): Video: vp8, yuv420p(progressive), 1920x1080, SAR 1:1 DAR 16:9, 29.97 fps, 29.97 tbr, 1k tbn (default)
  Stream #0:1(eng): Audio: vorbis, 44100 Hz, stereo, fltp (default)

Another webm video which doesn't crash, but causes indefinite app hang as soon as its playback is attempted:

<video controls autoplay height="640">
<source src="http://upload.wikimedia.org/wikipedia/commons/transcoded/f/f1/Sintel_movie_4K.webm/Sintel_movie_4K.webm.720p.webm" type="video/webm">
</video>

Its ffprobe:

Input #0, matroska,webm, from 'Sintel_movie_4K.webm.720p.webm':
  Metadata:
    encoder         : Lavf53.21.1
  Duration: 00:14:48.03, start: 0.000000, bitrate: 2110 kb/s
  Stream #0:0(eng): Video: vp8, yuv420p(progressive), 1280x546, SAR 641:640 DAR 641:273, 24 fps, 24 tbr, 1k tbn (default)
  Stream #0:1(eng): Audio: vorbis, 48000 Hz, 5.1, fltp (default)
    Metadata:
      title           : AC3 5.1 @ 640 Kbps

Both videos are around 250 MB in size.

Trying to open up this page also causes crash: https://tekeye.uk/html/html5-video-test-page

I cannot even post a useful stack trace, as it seems Ultralight does not provide PDBs for the releases anywhere I could find, not even for the open-sourced components...

>	vcruntime140.dll!memcpy() Line 435	Unknown
 	gstreamer-full-1.0.dll!00007ff87156ec91()	Unknown
 	gstreamer-full-1.0.dll!00007ff87156bbfa()	Unknown
 	gstreamer-full-1.0.dll!00007ff87156cb13()	Unknown
 	gstreamer-full-1.0.dll!00007ff87157dd81()	Unknown
 	gstreamer-full-1.0.dll!00007ff87157f154()	Unknown
 	gstreamer-full-1.0.dll!00007ff8715b210a()	Unknown
 	gstreamer-full-1.0.dll!00007ff87157dd81()	Unknown
 	gstreamer-full-1.0.dll!00007ff87157f154()	Unknown
 	gstreamer-full-1.0.dll!00007ff87157dd81()	Unknown
 	gstreamer-full-1.0.dll!00007ff87157f154()	Unknown
 	gstreamer-full-1.0.dll!00007ff87180cf6f()	Unknown
 	gstreamer-full-1.0.dll!00007ff87180841c()	Unknown
 	gstreamer-full-1.0.dll!00007ff8715af6d8()	Unknown
 	glib-2.0-0.dll!00007ff871363043()	Unknown
 	glib-2.0-0.dll!00007ff871362413()	Unknown
 	glib-2.0-0.dll!00007ff871386a5b()	Unknown
 	ucrtbase.dll!thread_start<unsigned int (__cdecl*)(void *),1>()	Unknown
 	kernel32.dll!BaseThreadInitThunk()	Unknown
 	ntdll.dll!RtlUserThreadStart()	Unknown

YouTube however works just fine... Same does this example video: http://video.dailymail.co.uk/video/1418450360/2015/02/1418450360_4056782948001_nerdist--1424015378606.mp4

Which suggests it's webm support that's broken, I guess.

Also the webms that do manage to play get a ton of artifacts and then refuse to re-play after being finished, if you instead try seeking back and forth, it will crash also.

It seems one of things crashing is a redirect on video url (like http to https), but it's not the only condition, the first mentioned video crashes regardless even though it's served via http directly, and the dailymail mp4 video gets redirected from http to https without crashing Ultralight.

p0358 avatar Nov 21 '22 06:11 p0358