haikuwebkit/LayoutTests/webrtc/video-replace-track-to-null...

7 lines
146 B
Plaintext
Raw Permalink Normal View History

Add libwebrtc backend support for RTCRtpSender::replaceTrack https://bugs.webkit.org/show_bug.cgi?id=169841 Patch by Youenn Fablet <youenn@apple.com> on 2017-03-24 Reviewed by Alex Christensen. Source/WebCore: Tests: webrtc/audio-replace-track.html webrtc/video-replace-track.html Adding support for replaceTrack for audio and video sources. Replacing tracks will always succeed for audio sources. For video tracks, it will only succeed if the video resolution is not greater. LibWebRTCPeerConnectionBackend will delegate the track replacing by replacing the source of the outgoing sources with the source wrapped in the replacing track. Video test is not fully passing as size constraints for mock video sources are not providing the right video stream resolution. * Modules/mediastream/RTCRtpSender.cpp: (WebCore::RTCRtpSender::replaceTrack): * Modules/mediastream/RTCRtpSender.h: * Modules/mediastream/RTCRtpSender.idl: * Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp: (WebCore::LibWebRTCPeerConnectionBackend::replaceTrack): * Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.h: * platform/mediastream/mac/RealtimeOutgoingAudioSource.cpp: (WebCore::RealtimeOutgoingAudioSource::setSource): * platform/mediastream/mac/RealtimeOutgoingAudioSource.h: * platform/mediastream/mac/RealtimeOutgoingVideoSource.cpp: (WebCore::RealtimeOutgoingVideoSource::setSource): * platform/mediastream/mac/RealtimeOutgoingVideoSource.h: * platform/mock/MockRealtimeVideoSource.cpp: (WebCore::MockRealtimeVideoSource::drawText): (WebCore::MockRealtimeVideoSource::generateFrame): LayoutTests: * webrtc/audio-replace-track-expected.txt: Added. * webrtc/audio-replace-track.html: Added. * webrtc/video-replace-track-expected.txt: Added. * webrtc/video-replace-track.html: Added. * webrtc/video-replace-track-to-null-expected.txt: Added. * webrtc/video-replace-track-to-null.html: Added. Canonical link: https://commits.webkit.org/186982@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@214357 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-03-24 18:01:18 +00:00
PASS Set-up test
PASS Test that frame counter increases
PASS Test replaceTrack with null track
PASS Test that frame counter no longer increases
Add libwebrtc backend support for RTCRtpSender::replaceTrack https://bugs.webkit.org/show_bug.cgi?id=169841 Patch by Youenn Fablet <youenn@apple.com> on 2017-03-24 Reviewed by Alex Christensen. Source/WebCore: Tests: webrtc/audio-replace-track.html webrtc/video-replace-track.html Adding support for replaceTrack for audio and video sources. Replacing tracks will always succeed for audio sources. For video tracks, it will only succeed if the video resolution is not greater. LibWebRTCPeerConnectionBackend will delegate the track replacing by replacing the source of the outgoing sources with the source wrapped in the replacing track. Video test is not fully passing as size constraints for mock video sources are not providing the right video stream resolution. * Modules/mediastream/RTCRtpSender.cpp: (WebCore::RTCRtpSender::replaceTrack): * Modules/mediastream/RTCRtpSender.h: * Modules/mediastream/RTCRtpSender.idl: * Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp: (WebCore::LibWebRTCPeerConnectionBackend::replaceTrack): * Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.h: * platform/mediastream/mac/RealtimeOutgoingAudioSource.cpp: (WebCore::RealtimeOutgoingAudioSource::setSource): * platform/mediastream/mac/RealtimeOutgoingAudioSource.h: * platform/mediastream/mac/RealtimeOutgoingVideoSource.cpp: (WebCore::RealtimeOutgoingVideoSource::setSource): * platform/mediastream/mac/RealtimeOutgoingVideoSource.h: * platform/mock/MockRealtimeVideoSource.cpp: (WebCore::MockRealtimeVideoSource::drawText): (WebCore::MockRealtimeVideoSource::generateFrame): LayoutTests: * webrtc/audio-replace-track-expected.txt: Added. * webrtc/audio-replace-track.html: Added. * webrtc/video-replace-track-expected.txt: Added. * webrtc/video-replace-track.html: Added. * webrtc/video-replace-track-to-null-expected.txt: Added. * webrtc/video-replace-track-to-null.html: Added. Canonical link: https://commits.webkit.org/186982@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@214357 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-03-24 18:01:18 +00:00