Bug 213699 - [GStreamer] ⛱ MediaRecorder implementation
Summary: [GStreamer] ⛱ MediaRecorder implementation
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Platform (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on: 236558
Blocks:
  Show dependency treegraph
 
Reported: 2020-06-28 08:45 PDT by Philippe Normand
Modified: 2023-02-01 15:43 PST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Philippe Normand 2020-06-28 08:45:29 PDT
Implement Source/WebCore/platform/mediarecorder/MediaRecorderPrivate.h for GTK/WPE.
Comment 1 Philippe Normand 2020-06-28 08:47:25 PDT
Demo: https://addpipe.com/media-recorder-api-demo/
Layout tests:

# MediaRecorder is not currently implemented
http/wpt/mediarecorder [ Skip ]
imported/w3c/web-platform-tests/mediacapture-record [ Skip ]
Comment 2 Philippe Normand 2022-02-23 03:44:31 PST
After landing the basic backend, the remaining failures are:

webkit.org/b/213699 http/wpt/mediarecorder/mimeType.html [ Failure ]
webkit.org/b/213699 http/wpt/mediarecorder/mute-tracks.html [ Failure ]
webkit.org/b/213699 http/wpt/mediarecorder/video-rotation.html [ Failure ]
webkit.org/b/213699 imported/w3c/web-platform-tests/mediacapture-record/MediaRecorder-mimetype.html [ Timeout ]
webkit.org/b/213699 imported/w3c/web-platform-tests/mediacapture-record/MediaRecorder-no-sink.https.html [ Failure ]
webkit.org/b/213699 imported/w3c/web-platform-tests/mediacapture-record/MediaRecorder-peerconnection.https.html [ Failure ]
webkit.org/b/213699 http/wpt/mediarecorder/set-srcObject-MediaStream-Blob.html [ Pass Failure ]
# Our WebRTC encoder doesn't support high h.264 profile yet.
webkit.org/b/213699 http/wpt/mediarecorder/MediaRecorder-video-h264-profiles.html [ Failure ]
# https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1017
webkit.org/b/213699 imported/w3c/web-platform-tests/mediacapture-record/MediaRecorder-bitrate.https.html [ Pass Crash ]
Comment 3 Diego Pino 2023-02-01 13:58:00 PST
http/wpt/mediarecorder/mute-tracks.html is now a flaky crash (but crashing most of the times):

https://results.webkit.org/?suite=layout-tests&test=http%2Fwpt%2Fmediarecorder%2Fmute-tracks.html&platform=GTK&platform=WPE&platform=mac&platform=win

The test is a flaky crash in other platforms too.

The test is also crashing in WPE Debug but the bot is not generating a stack trace, only stderr.

https://build.webkit.org/results/WPE-Linux-64-bit-Debug-Tests/259642@main%20(4377)/http/wpt/mediarecorder/mute-tracks-crash-log.txt

```
STDERR: 
STDERR: (WPEWebProcess:175549): GStreamer-Video-CRITICAL **: 19:31:04.279: gst_video_converter_new_with_pool: assertion 'in_info->fps_n == out_info->fps_n' failed
STDERR: WPEWebProcess terminated (pid 175549) for reason: crash
STDERR: LEAK: 44 WebPageProxy
```

Stack trace from WPE Release:

```
Thread 1 (Thread 0x7f71097fa640 (LWP 29642)):
#0  __pthread_kill_implementation (threadid=<optimized out>, signo=signo@entry=6, no_tid=no_tid@entry=0) at pthread_kill.c:44
#1  0x00007f71abcb91f3 in __pthread_kill_internal (signo=6, threadid=<optimized out>) at pthread_kill.c:78
#2  0x00007f71abc6700e in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
#3  0x00007f71abc507fc in __GI_abort () at abort.c:79
#4  0x00007f71ac3e0b43 in g_assertion_message (domain=<optimized out>, file=0x7f7128197738 "../gst/videorate/gstvideorate.c", line=<optimized out>, func=<optimized out>, message=<optimized out>) at ../glib/gtestutils.c:3253
#5  0x00007f71ac43c1a7 in g_assertion_message_expr (domain=domain@entry=0x0, file=file@entry=0x7f7128197738 "../gst/videorate/gstvideorate.c", line=line@entry=741, func=func@entry=0x7f7128198330 <__func__.6> "gst_video_rate_push_buffer", expr=expr@entry=0x7f71281979d8 "GST_BUFFER_DURATION (outbuf) != 0") at ../glib/gtestutils.c:3
#6  0x00007f7128192838 in gst_video_rate_push_buffer (videorate=videorate@entry=0x55751e5648f0 [GstVideoRate|videorate15], outbuf=0x7f6fc4015ea0 [None], duplicate=duplicate@entry=0, next_intime=next_intime@entry=97242462 [0:00:00.097242462], invalid_duration=invalid_duration@entry=0) at ../gst/videorate/gstvideorate.c:741
#7  0x00007f7128192a80 in gst_video_rate_flush_prev (videorate=videorate@entry=0x55751e5648f0 [GstVideoRate|videorate15], duplicate=duplicate@entry=0, next_intime=next_intime@entry=97242462 [0:00:00.097242462], invalid_duration=invalid_duration@entry=0) at ../gst/videorate/gstvideorate.c:777
#8  0x00007f7128194804 in gst_video_rate_transform_ip (trans=<optimized out>, buffer=0x7f6fb0051b40 [None]) at ../gst/videorate/gstvideorate.c:1902
#9  0x00007f71a922e31a in default_generate_output (trans=0x55751e5648f0 [GstBaseTransform|videorate15], outbuf=0x7f71097f9130) at ../libs/gst/base/gstbasetransform.c:2197
#10 0x00007f71a923c246 in gst_base_transform_chain (pad=<optimized out>, parent=0x55751e5648f0 [GstObject|videorate15], buffer=<optimized out>) at ../libs/gst/base/gstbasetransform.c:2355
#11 0x00007f71ac212775 in gst_pad_chain_data_unchecked (pad=pad@entry=0x55751e417870 [GstPad|sink], type=type@entry=4112, data=data@entry=0x7f6fb0051b40) at ../gst/gstpad.c:4463
#12 0x00007f71ac216114 in gst_pad_push_data (pad=pad@entry=0x55751e416f30 [GstPad|src], type=type@entry=4112, data=data@entry=0x7f6fb0051b40) at ../gst/gstpad.c:4739
#13 0x00007f71ac2164de in gst_pad_push (pad=0x55751e416f30 [GstPad|src], buffer=0x7f6fb0051b40 [None]) at ../gst/gstpad.c:4858
#14 0x00007f71a923c31b in gst_base_transform_chain (pad=<optimized out>, parent=0x55751e568100 [GstObject|videoconvert47], buffer=<optimized out>) at ../libs/gst/base/gstbasetransform.c:2391
#15 0x00007f71ac212775 in gst_pad_chain_data_unchecked (pad=pad@entry=0x55751e3c5900 [GstPad|sink], type=type@entry=4112, data=data@entry=0x7f6fb0051b40) at ../gst/gstpad.c:4463
#16 0x00007f71ac216114 in gst_pad_push_data (pad=pad@entry=0x55751e3c56b0 [GstPad|src], type=type@entry=4112, data=data@entry=0x7f6fb0051b40) at ../gst/gstpad.c:4739
#17 0x00007f71ac2164de in gst_pad_push (pad=0x55751e3c56b0 [GstPad|src], buffer=0x7f6fb0051b40 [None]) at ../gst/gstpad.c:4858
#18 0x00007f71a923c31b in gst_base_transform_chain (pad=<optimized out>, parent=0x55751e567c20 [GstObject|videoscale31], buffer=<optimized out>) at ../libs/gst/base/gstbasetransform.c:2391
#19 0x00007f71ac212775 in gst_pad_chain_data_unchecked (pad=pad@entry=0x55751e3c5da0 [GstPad|sink], type=type@entry=4112, data=data@entry=0x7f6fb0051b40) at ../gst/gstpad.c:4463
#20 0x00007f71ac216114 in gst_pad_push_data (pad=pad@entry=0x55751e3c5b50 [GstPad|src], type=type@entry=4112, data=data@entry=0x7f6fb0051b40) at ../gst/gstpad.c:4739
#21 0x00007f71ac2164de in gst_pad_push (pad=0x55751e3c5b50 [GstPad|src], buffer=0x7f6fb0051b40 [None]) at ../gst/gstpad.c:4858
#22 0x00007f71a923c31b in gst_base_transform_chain (pad=<optimized out>, parent=0x55751e564480 [GstObject|videoconvert46], buffer=<optimized out>) at ../libs/gst/base/gstbasetransform.c:2391
#23 0x00007f71ac212775 in gst_pad_chain_data_unchecked (pad=pad@entry=0x55751e3c4b20 [GstPad|sink], type=type@entry=4112, data=data@entry=0x7f6fc40117e0) at ../gst/gstpad.c:4463
#24 0x00007f71ac216114 in gst_pad_push_data (pad=pad@entry=0x55751e3f49a0 [GstPad|encodingsrc], type=type@entry=4112, data=data@entry=0x7f6fc40117e0) at ../gst/gstpad.c:4739
#25 0x00007f71ac2164de in gst_pad_push (pad=pad@entry=0x55751e3f49a0 [GstPad|encodingsrc], buffer=buffer@entry=0x7f6fc40117e0 [None]) at ../gst/gstpad.c:4858
#26 0x00007f713c01b995 in gst_stream_splitter_chain (pad=<optimized out>, parent=0x55751e658550 [GstObject|streamsplitter32], buf=0x7f6fc40117e0 [None]) at ../gst/encoding/gststreamsplitter.c:141
#27 0x00007f71ac212775 in gst_pad_chain_data_unchecked (pad=pad@entry=0x55751e2f28d0 [GstPad|sink], type=type@entry=4112, data=data@entry=0x7f6fc40117e0) at ../gst/gstpad.c:4463
#28 0x00007f71ac216114 in gst_pad_push_data (pad=pad@entry=0x55751e3cf760 [GstPad|src], type=type@entry=4112, data=data@entry=0x7f6fc40117e0) at ../gst/gstpad.c:4739
#29 0x00007f71ac2164de in gst_pad_push (pad=0x55751e3cf760 [GstPad|src], buffer=buffer@entry=0x7f6fc40117e0 [None]) at ../gst/gstpad.c:4858
#30 0x00007f71480985ec in gst_queue_push_one (queue=0x55751e343b00 [GstQueue|queue68]) at ../plugins/elements/gstqueue.c:1388
#31 gst_queue_loop (pad=<optimized out>) at ../plugins/elements/gstqueue.c:1541
#32 0x00007f71ac23ed41 in gst_task_func (task=0x7f6fc400c5f0 [GstTask|queue68:src]) at ../gst/gsttask.c:384
#33 0x00007f71ac44b692 in g_thread_pool_thread_proxy (data=<optimized out>) at ../glib/gthreadpool.c:350
#34 0x00007f71ac448722 in g_thread_proxy (data=0x7f6f80001de0) at ../glib/gthread.c:827
#35 0x00007f71abcb71da in start_thread (arg=<optimized out>) at pthread_create.c:442
#36 0x00007f71abd3ff44 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:100
```