Changeset 269764 in webkit
- Timestamp:
- Nov 12, 2020 11:20:19 PM (20 months ago)
- Location:
- trunk
- Files:
-
- 14 added
- 34 edited
- 7 copied
-
LayoutTests/ChangeLog (modified) (1 diff)
-
LayoutTests/webrtc/webrtc-transform-expected.txt (added)
-
LayoutTests/webrtc/webrtc-transform.html (added)
-
Source/ThirdParty/libwebrtc/ChangeLog (modified) (1 diff)
-
Source/ThirdParty/libwebrtc/Configurations/libwebrtc.iOS.exp (modified) (1 diff)
-
Source/ThirdParty/libwebrtc/Configurations/libwebrtc.iOSsim.exp (modified) (1 diff)
-
Source/ThirdParty/libwebrtc/Configurations/libwebrtc.mac.exp (modified) (1 diff)
-
Source/ThirdParty/libwebrtc/Source/webrtc/sdk/WebKit/WebKitEncoder.h (modified) (1 diff)
-
Source/ThirdParty/libwebrtc/Source/webrtc/sdk/WebKit/WebKitEncoder.mm (modified) (1 diff)
-
Source/WTF/ChangeLog (modified) (1 diff)
-
Source/WTF/Scripts/Preferences/WebPreferencesExperimental.yaml (modified) (1 diff)
-
Source/WebCore/CMakeLists.txt (modified) (3 diffs)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/DerivedSources-input.xcfilelist (modified) (5 diffs)
-
Source/WebCore/DerivedSources-output.xcfilelist (modified) (5 diffs)
-
Source/WebCore/DerivedSources.make (modified) (2 diffs)
-
Source/WebCore/Modules/mediastream/RTCRtpReceiver+Transform.idl (added)
-
Source/WebCore/Modules/mediastream/RTCRtpReceiver.cpp (modified) (2 diffs)
-
Source/WebCore/Modules/mediastream/RTCRtpReceiver.h (modified) (4 diffs)
-
Source/WebCore/Modules/mediastream/RTCRtpReceiverBackend.h (modified) (2 diffs)
-
Source/WebCore/Modules/mediastream/RTCRtpReceiverWithTransform.h (added)
-
Source/WebCore/Modules/mediastream/RTCRtpSender+Transform.idl (added)
-
Source/WebCore/Modules/mediastream/RTCRtpSender.cpp (modified) (3 diffs)
-
Source/WebCore/Modules/mediastream/RTCRtpSender.h (modified) (3 diffs)
-
Source/WebCore/Modules/mediastream/RTCRtpSenderBackend.h (modified) (2 diffs)
-
Source/WebCore/Modules/mediastream/RTCRtpSenderWithTransform.h (added)
-
Source/WebCore/Modules/mediastream/RTCRtpTransform.cpp (added)
-
Source/WebCore/Modules/mediastream/RTCRtpTransform.h (added)
-
Source/WebCore/Modules/mediastream/RTCRtpTransform.idl (added)
-
Source/WebCore/Modules/mediastream/RTCRtpTransformBackend.h (copied) (copied from trunk/Source/WebCore/Modules/mediastream/RTCRtpSenderBackend.h) (2 diffs)
-
Source/WebCore/Modules/mediastream/RTCRtpTransformableFrame.h (copied) (copied from trunk/Source/WebCore/Modules/mediastream/RTCRtpReceiverBackend.h) (2 diffs)
-
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverBackend.cpp (modified) (2 diffs)
-
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverBackend.h (modified) (1 diff)
-
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverTransformBackend.cpp (copied) (copied from trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverBackend.h) (2 diffs)
-
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverTransformBackend.h (copied) (copied from trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverBackend.h) (3 diffs)
-
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpSenderBackend.cpp (modified) (2 diffs)
-
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpSenderBackend.h (modified) (1 diff)
-
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpSenderTransformBackend.cpp (copied) (copied from trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverBackend.h) (2 diffs)
-
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpSenderTransformBackend.h (copied) (copied from trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverBackend.h) (2 diffs)
-
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpTransformBackend.cpp (added)
-
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpTransformBackend.h (added)
-
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpTransformableFrame.h (copied) (copied from trunk/Source/WebCore/Modules/mediastream/RTCRtpSenderBackend.h) (2 diffs)
-
Source/WebCore/Sources.txt (modified) (3 diffs)
-
Source/WebCore/WebCore.xcodeproj/project.pbxproj (modified) (15 diffs)
-
Source/WebCore/bindings/js/WebCoreBuiltinNames.h (modified) (2 diffs)
-
Source/WebCore/bindings/scripts/CodeGeneratorJS.pm (modified) (1 diff)
-
Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h (modified) (1 diff)
-
Source/WebCore/testing/Internals.cpp (modified) (2 diffs)
-
Source/WebCore/testing/Internals.h (modified) (2 diffs)
-
Source/WebCore/testing/Internals.idl (modified) (1 diff)
-
Source/WebCore/testing/MockRTCRtpTransform.cpp (added)
-
Source/WebCore/testing/MockRTCRtpTransform.h (added)
-
Source/WebCore/testing/MockRTCRtpTransform.idl (added)
-
Source/WebKit/ChangeLog (modified) (1 diff)
-
Source/WebKit/WebProcess/GPU/webrtc/LibWebRTCCodecs.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r269761 r269764 1 2020-11-12 Youenn Fablet <youenn@apple.com> 2 3 Add infrastructure for WebRTC transforms 4 https://bugs.webkit.org/show_bug.cgi?id=218750 5 6 Reviewed by Eric Carlson. 7 8 * webrtc/webrtc-transform-expected.txt: Added. 9 * webrtc/webrtc-transform.html: Added. 10 1 11 2020-11-12 Truitt Savell <tsavell@apple.com> 2 12 -
trunk/Source/ThirdParty/libwebrtc/ChangeLog
r269642 r269764 1 2020-11-12 Youenn Fablet <youenn@apple.com> 2 3 Add infrastructure for WebRTC transforms 4 https://bugs.webkit.org/show_bug.cgi?id=218750 5 6 Reviewed by Eric Carlson. 7 8 Make sure buffer is owned by the encoded image object. 9 10 * Configurations/libwebrtc.mac.exp: 11 * Source/webrtc/sdk/WebKit/WebKitEncoder.h: 12 * Source/webrtc/sdk/WebKit/WebKitEncoder.mm: 13 (webrtc::encoderVideoTaskComplete): 14 1 15 2020-11-10 Youenn Fablet <youenn@apple.com> and Victor M Jaquez <vjaquez@igalia.com> 2 16 -
trunk/Source/ThirdParty/libwebrtc/Configurations/libwebrtc.iOS.exp
r269642 r269764 230 230 __ZN6webrtc19setDecoderFrameSizeEPvtt 231 231 __ZN6webrtc18RtpCodecCapabilityC1Ev 232 __ZN6webrtc24encoderVideoTaskCompleteEPvNS_14VideoCodecTypeEP hmRKNS_22WebKitEncodedFrameInfoE232 __ZN6webrtc24encoderVideoTaskCompleteEPvNS_14VideoCodecTypeEPKhmRKNS_22WebKitEncodedFrameInfoE 233 233 __ZN6webrtc24setVideoEncoderCallbacksEPFPvRKNS_14SdpVideoFormatEEPFiS0_EPFiS0_RKNS_10VideoCodecEEPFiS0_RKNS_10VideoFrameEbEPFiS0_S0_EPFvS0_RKNS_12VideoEncoder21RateControlParametersEE 234 234 __ZN6webrtc20setLocalEncoderRatesEPvjj -
trunk/Source/ThirdParty/libwebrtc/Configurations/libwebrtc.iOSsim.exp
r269642 r269764 230 230 __ZN6webrtc19setDecoderFrameSizeEPvtt 231 231 __ZN6webrtc18RtpCodecCapabilityC1Ev 232 __ZN6webrtc24encoderVideoTaskCompleteEPvNS_14VideoCodecTypeEP hmRKNS_22WebKitEncodedFrameInfoE232 __ZN6webrtc24encoderVideoTaskCompleteEPvNS_14VideoCodecTypeEPKhmRKNS_22WebKitEncodedFrameInfoE 233 233 __ZN6webrtc24setVideoEncoderCallbacksEPFPvRKNS_14SdpVideoFormatEEPFiS0_EPFiS0_RKNS_10VideoCodecEEPFiS0_RKNS_10VideoFrameEbEPFiS0_S0_EPFvS0_RKNS_12VideoEncoder21RateControlParametersEE 234 234 __ZN6webrtc20setLocalEncoderRatesEPvjj -
trunk/Source/ThirdParty/libwebrtc/Configurations/libwebrtc.mac.exp
r269642 r269764 230 230 __ZN6webrtc19setDecoderFrameSizeEPvtt 231 231 __ZN6webrtc18RtpCodecCapabilityC1Ev 232 __ZN6webrtc24encoderVideoTaskCompleteEPvNS_14VideoCodecTypeEP hmRKNS_22WebKitEncodedFrameInfoE232 __ZN6webrtc24encoderVideoTaskCompleteEPvNS_14VideoCodecTypeEPKhmRKNS_22WebKitEncodedFrameInfoE 233 233 __ZN6webrtc24setVideoEncoderCallbacksEPFPvRKNS_14SdpVideoFormatEEPFiS0_EPFiS0_RKNS_10VideoCodecEEPFiS0_RKNS_10VideoFrameEbEPFiS0_S0_EPFvS0_RKNS_12VideoEncoder21RateControlParametersEE 234 234 __ZN6webrtc20setLocalEncoderRatesEPvjj -
trunk/Source/ThirdParty/libwebrtc/Source/webrtc/sdk/WebKit/WebKitEncoder.h
r269642 r269764 81 81 void setLocalEncoderRates(LocalEncoder, uint32_t bitRate, uint32_t frameRate); 82 82 void setLocalEncoderLowLatency(LocalEncoder, bool isLowLatencyEnabled); 83 void encoderVideoTaskComplete(void*, webrtc::VideoCodecType, uint8_t* buffer, size_t length, const WebKitEncodedFrameInfo&);83 void encoderVideoTaskComplete(void*, webrtc::VideoCodecType, const uint8_t* buffer, size_t length, const WebKitEncodedFrameInfo&); 84 84 85 85 template<class Decoder> -
trunk/Source/ThirdParty/libwebrtc/Source/webrtc/sdk/WebKit/WebKitEncoder.mm
r269642 r269764 291 291 } 292 292 293 void encoderVideoTaskComplete(void* callback, webrtc::VideoCodecType codecType, uint8_t* buffer, size_t length, const WebKitEncodedFrameInfo& info) 294 { 295 webrtc::EncodedImage encodedImage(buffer, length, length); 293 void encoderVideoTaskComplete(void* callback, webrtc::VideoCodecType codecType, const uint8_t* buffer, size_t length, const WebKitEncodedFrameInfo& info) 294 { 295 webrtc::EncodedImage encodedImage; 296 encodedImage.SetEncodedData(EncodedImageBuffer::Create(buffer, length)); 297 296 298 encodedImage._encodedWidth = info.width; 297 299 encodedImage._encodedHeight = info.height; -
trunk/Source/WTF/ChangeLog
r269760 r269764 1 2020-11-12 Youenn Fablet <youenn@apple.com> 2 3 Add infrastructure for WebRTC transforms 4 https://bugs.webkit.org/show_bug.cgi?id=218750 5 6 Reviewed by Eric Carlson. 7 8 Add an experimental preference for WebRTC transforms. 9 10 * Scripts/Preferences/WebPreferencesExperimental.yaml: 11 1 12 2020-11-12 Sam Weinig <weinig@apple.com> 2 13 -
trunk/Source/WTF/Scripts/Preferences/WebPreferencesExperimental.yaml
r269712 r269764 985 985 default: false 986 986 987 WebRTCInsertableStreamsEnabled: 988 type: bool 989 condition: ENABLE(WEB_RTC) 990 humanReadableName: "WebRTC Insertable Streams API" 991 humanReadableDescription: "Enable WebRTC Insertable Streams API" 992 defaultValue: 993 WebKitLegacy: 994 default: false 995 WebKit: 996 default: false 997 WebCore: 998 default: false 999 987 1000 # FIXME: This is not relevent for WebKitLegacy, so should be excluded from WebKitLegacy entirely. 988 1001 WebRTCPlatformCodecsInGPUProcessEnabled: -
trunk/Source/WebCore/CMakeLists.txt
r269612 r269764 400 400 Modules/mediastream/RTCRtpHeaderExtensionParameters.idl 401 401 Modules/mediastream/RTCRtpParameters.idl 402 Modules/mediastream/RTCRtpReceiver+Transform.idl 402 403 Modules/mediastream/RTCRtpReceiver.idl 403 404 Modules/mediastream/RTCRtpRtxParameters.idl 404 405 Modules/mediastream/RTCRtpSendParameters.idl 406 Modules/mediastream/RTCRtpSender+Transform.idl 405 407 Modules/mediastream/RTCRtpSender.idl 406 408 Modules/mediastream/RTCRtpSynchronizationSource.idl 407 409 Modules/mediastream/RTCRtpTransceiver.idl 408 410 Modules/mediastream/RTCRtpTransceiverDirection.idl 411 Modules/mediastream/RTCRtpTransform.idl 409 412 Modules/mediastream/RTCSdpType.idl 410 413 Modules/mediastream/RTCSessionDescription.idl … … 1750 1753 testing/MockContentFilterSettings.idl 1751 1754 testing/MockPageOverlay.idl 1755 testing/MockRTCRtpTransform.idl 1752 1756 testing/ServiceWorkerInternals.idl 1753 1757 testing/TypeConversions.idl … … 1773 1777 testing/MockPageOverlay.cpp 1774 1778 testing/MockPageOverlayClient.cpp 1779 testing/MockRTCRtpTransform.cpp 1775 1780 testing/ServiceWorkerInternals.cpp 1776 1781 testing/js/WebCoreTestSupport.cpp -
trunk/Source/WebCore/ChangeLog
r269762 r269764 1 2020-11-12 Youenn Fablet <youenn@apple.com> 2 3 Add infrastructure for WebRTC transforms 4 https://bugs.webkit.org/show_bug.cgi?id=218750 5 6 Reviewed by Eric Carlson. 7 8 Introduce RTCRtpTransform behind a preference. 9 Add binding code with libwebrtc to be able to process encoded content in sender and receiver sides. 10 Add a mock transform to validate the infrastructure is working. 11 12 Test: webrtc/webrtc-transform.html 13 14 * CMakeLists.txt: 15 * DerivedSources-input.xcfilelist: 16 * DerivedSources-output.xcfilelist: 17 * DerivedSources.make: 18 * Modules/mediastream/RTCRtpReceiver+Transform.idl: Added. 19 * Modules/mediastream/RTCRtpReceiver.cpp: 20 (WebCore::RTCRtpReceiver::~RTCRtpReceiver): 21 (WebCore::RTCRtpReceiver::stop): 22 (WebCore::RTCRtpReceiver::setTransform): 23 * Modules/mediastream/RTCRtpReceiver.h: 24 * Modules/mediastream/RTCRtpReceiverBackend.h: 25 * Modules/mediastream/RTCRtpReceiverWithTransform.h: Added. 26 (WebCore::RTCRtpReceiverWithTransform::transform): 27 (WebCore::RTCRtpReceiverWithTransform::setTransform): 28 * Modules/mediastream/RTCRtpSender+Transform.idl: Added. 29 * Modules/mediastream/RTCRtpSender.cpp: 30 (WebCore::RTCRtpSender::~RTCRtpSender): 31 (WebCore::RTCRtpSender::stop): 32 (WebCore::RTCRtpSender::setTransform): 33 * Modules/mediastream/RTCRtpSender.h: 34 * Modules/mediastream/RTCRtpSenderBackend.h: 35 * Modules/mediastream/RTCRtpSenderWithTransform.h: Added. 36 (WebCore::RTCRtpSenderWithTransform::transform): 37 (WebCore::RTCRtpSenderWithTransform::setTransform): 38 * Modules/mediastream/RTCRtpTransform.cpp: Added. 39 (WebCore::RTCRtpTransform::~RTCRtpTransform): 40 (WebCore::RTCRtpTransform::attachToReceiver): 41 (WebCore::RTCRtpTransform::attachToSender): 42 (WebCore::RTCRtpTransform::detachFromReceiver): 43 (WebCore::RTCRtpTransform::detachFromSender): 44 * Modules/mediastream/RTCRtpTransform.h: Added. 45 * Modules/mediastream/RTCRtpTransform.idl: Added. 46 * Modules/mediastream/RTCRtpTransformBackend.h: Added. 47 * Modules/mediastream/RTCRtpTransformableFrame.h: Added. 48 * Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverBackend.cpp: 49 (WebCore::LibWebRTCRtpReceiverBackend::createRTCRtpTransformBackend): 50 * Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverBackend.h: 51 * Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverTransformBackend.cpp: Added. 52 (WebCore::mediaTypeFromReceiver): 53 (WebCore::LibWebRTCRtpReceiverTransformBackend::LibWebRTCRtpReceiverTransformBackend): 54 (WebCore::LibWebRTCRtpReceiverTransformBackend::~LibWebRTCRtpReceiverTransformBackend): 55 (WebCore::LibWebRTCRtpReceiverTransformBackend::setTransformableFrameCallback): 56 * Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverTransformBackend.h: Added. 57 * Modules/mediastream/libwebrtc/LibWebRTCRtpSenderBackend.cpp: 58 (WebCore::LibWebRTCRtpSenderBackend::createRTCRtpTransformBackend): 59 * Modules/mediastream/libwebrtc/LibWebRTCRtpSenderBackend.h: 60 * Modules/mediastream/libwebrtc/LibWebRTCRtpSenderTransformBackend.cpp: Added. 61 (WebCore::mediaTypeFromSender): 62 (WebCore::LibWebRTCRtpSenderTransformBackend::LibWebRTCRtpSenderTransformBackend): 63 (WebCore::LibWebRTCRtpSenderTransformBackend::~LibWebRTCRtpSenderTransformBackend): 64 (WebCore::LibWebRTCRtpSenderTransformBackend::setTransformableFrameCallback): 65 * Modules/mediastream/libwebrtc/LibWebRTCRtpSenderTransformBackend.h: Added. 66 * Modules/mediastream/libwebrtc/LibWebRTCRtpTransformBackend.cpp: Added. 67 (WebCore::LibWebRTCRtpTransformBackend::setInputCallback): 68 (WebCore::LibWebRTCRtpTransformBackend::clearTransformableFrameCallback): 69 (WebCore::LibWebRTCRtpTransformBackend::setOutputCallback): 70 (WebCore::LibWebRTCRtpTransformBackend::processTransformedFrame): 71 (WebCore::LibWebRTCRtpTransformBackend::Transform): 72 (WebCore::LibWebRTCRtpTransformBackend::RegisterTransformedFrameCallback): 73 (WebCore::LibWebRTCRtpTransformBackend::RegisterTransformedFrameSinkCallback): 74 (WebCore::LibWebRTCRtpTransformBackend::UnregisterTransformedFrameCallback): 75 (WebCore::LibWebRTCRtpTransformBackend::UnregisterTransformedFrameSinkCallback): 76 * Modules/mediastream/libwebrtc/LibWebRTCRtpTransformBackend.h: Added. 77 (WebCore::LibWebRTCRtpTransformBackend::LibWebRTCRtpTransformBackend): 78 (WebCore::LibWebRTCRtpTransformBackend::Release const): 79 * Modules/mediastream/libwebrtc/LibWebRTCRtpTransformableFrame.h: Added. 80 (WebCore::LibWebRTCRtpTransformableFrame::LibWebRTCRtpTransformableFrame): 81 (WebCore::LibWebRTCRtpTransformableFrame::toRTCFrame): 82 (WebCore::LibWebRTCRtpTransformableFrame::data const): 83 * Sources.txt: 84 * WebCore.xcodeproj/project.pbxproj: 85 * bindings/js/WebCoreBuiltinNames.h: 86 * bindings/scripts/CodeGeneratorJS.pm: 87 (GenerateHeader): 88 * bindings/scripts/test/JS/JSTestInterface.h: 89 * testing/Internals.cpp: 90 (WebCore::Internals::createMockRTCRtpTransform): 91 * testing/Internals.h: 92 * testing/Internals.idl: 93 * testing/MockRTCRtpTransform.cpp: Added. 94 (WebCore::MockRTCRtpTransformer::create): 95 (WebCore::MockRTCRtpTransformer::clear): 96 (WebCore::MockRTCRtpTransformer::transform): 97 (WebCore::MockRTCRtpTransformer::isProcessing const): 98 (WebCore::MockRTCRtpTransformer::MockRTCRtpTransformer): 99 (WebCore::MockRTCRtpTransform::MockRTCRtpTransform): 100 (WebCore::MockRTCRtpTransform::~MockRTCRtpTransform): 101 (WebCore::MockRTCRtpTransform::isProcessing const): 102 (WebCore::MockRTCRtpTransform::initializeBackendForReceiver): 103 (WebCore::MockRTCRtpTransform::initializeBackendForSender): 104 (WebCore::MockRTCRtpTransform::willClearBackend): 105 * testing/MockRTCRtpTransform.h: Added. 106 * testing/MockRTCRtpTransform.idl: Added. 107 1 108 2020-11-12 Joonghun Park <jh718.park@samsung.com> 2 109 -
trunk/Source/WebCore/DerivedSources-input.xcfilelist
r269612 r269764 130 130 $(PROJECT_DIR)/Modules/geolocation/PositionErrorCallback.idl 131 131 $(PROJECT_DIR)/Modules/geolocation/PositionOptions.idl 132 $(PROJECT_DIR)/Modules/highlight/Highlight.idl 132 133 $(PROJECT_DIR)/Modules/highlight/HighlightRegister.idl 133 $(PROJECT_DIR)/Modules/highlight/Highlight.idl134 134 $(PROJECT_DIR)/Modules/indexeddb/DOMWindow+IndexedDatabase.idl 135 135 $(PROJECT_DIR)/Modules/indexeddb/IDBCursor.idl … … 234 234 $(PROJECT_DIR)/Modules/mediastream/RTCRtpHeaderExtensionParameters.idl 235 235 $(PROJECT_DIR)/Modules/mediastream/RTCRtpParameters.idl 236 $(PROJECT_DIR)/Modules/mediastream/RTCRtpReceiver+Transform.idl 236 237 $(PROJECT_DIR)/Modules/mediastream/RTCRtpReceiver.idl 237 238 $(PROJECT_DIR)/Modules/mediastream/RTCRtpRtxParameters.idl 238 239 $(PROJECT_DIR)/Modules/mediastream/RTCRtpSendParameters.idl 240 $(PROJECT_DIR)/Modules/mediastream/RTCRtpSender+Transform.idl 239 241 $(PROJECT_DIR)/Modules/mediastream/RTCRtpSender.idl 240 242 $(PROJECT_DIR)/Modules/mediastream/RTCRtpSynchronizationSource.idl 241 243 $(PROJECT_DIR)/Modules/mediastream/RTCRtpTransceiver.idl 242 244 $(PROJECT_DIR)/Modules/mediastream/RTCRtpTransceiverDirection.idl 245 $(PROJECT_DIR)/Modules/mediastream/RTCRtpTransform.idl 243 246 $(PROJECT_DIR)/Modules/mediastream/RTCSdpType.idl 244 247 $(PROJECT_DIR)/Modules/mediastream/RTCSessionDescription.idl … … 290 293 $(PROJECT_DIR)/Modules/remoteplayback/RemotePlayback.idl 291 294 $(PROJECT_DIR)/Modules/remoteplayback/RemotePlaybackAvailabilityCallback.idl 295 $(PROJECT_DIR)/Modules/speech/DOMWindow+SpeechSynthesis.idl 292 296 $(PROJECT_DIR)/Modules/speech/SpeechRecognition.idl 293 297 $(PROJECT_DIR)/Modules/speech/SpeechRecognitionAlternative.idl … … 297 301 $(PROJECT_DIR)/Modules/speech/SpeechRecognitionResult.idl 298 302 $(PROJECT_DIR)/Modules/speech/SpeechRecognitionResultList.idl 299 $(PROJECT_DIR)/Modules/speech/DOMWindow+SpeechSynthesis.idl300 303 $(PROJECT_DIR)/Modules/speech/SpeechSynthesis.idl 301 304 $(PROJECT_DIR)/Modules/speech/SpeechSynthesisEvent.idl … … 1302 1305 $(PROJECT_DIR)/testing/MockPaymentCoordinator.idl 1303 1306 $(PROJECT_DIR)/testing/MockPaymentError.idl 1307 $(PROJECT_DIR)/testing/MockRTCRtpTransform.idl 1304 1308 $(PROJECT_DIR)/testing/MockWebAuthenticationConfiguration.idl 1305 1309 $(PROJECT_DIR)/testing/ServiceWorkerInternals.idl -
trunk/Source/WebCore/DerivedSources-output.xcfilelist
r269612 r269764 1106 1106 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSHdrMetadataType.cpp 1107 1107 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSHdrMetadataType.h 1108 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSHighlight.cpp 1109 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSHighlight.h 1108 1110 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSHighlightRegister.cpp 1109 1111 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSHighlightRegister.h 1110 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSHighlight.cpp1111 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSHighlight.h1112 1112 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSHistory.cpp 1113 1113 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSHistory.h … … 1342 1342 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSMockPaymentError.cpp 1343 1343 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSMockPaymentError.h 1344 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSMockRTCRtpTransform.cpp 1345 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSMockRTCRtpTransform.h 1344 1346 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSMockWebAuthenticationConfiguration.cpp 1345 1347 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSMockWebAuthenticationConfiguration.h … … 1698 1700 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpParameters.cpp 1699 1701 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpParameters.h 1702 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpReceiver+Transform.cpp 1703 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpReceiver+Transform.h 1700 1704 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpReceiver.cpp 1701 1705 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpReceiver.h … … 1704 1708 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpSendParameters.cpp 1705 1709 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpSendParameters.h 1710 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpSender+Transform.cpp 1711 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpSender+Transform.h 1706 1712 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpSender.cpp 1707 1713 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpSender.h … … 1712 1718 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpTransceiverDirection.cpp 1713 1719 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpTransceiverDirection.h 1720 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpTransform.cpp 1721 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpTransform.h 1714 1722 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCSdpType.cpp 1715 1723 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCSdpType.h -
trunk/Source/WebCore/DerivedSources.make
r269612 r269764 259 259 $(WebCore)/Modules/mediastream/RTCRtpParameters.idl \ 260 260 $(WebCore)/Modules/mediastream/RTCRtpReceiver.idl \ 261 $(WebCore)/Modules/mediastream/RTCRtpReceiver+Transform.idl \ 261 262 $(WebCore)/Modules/mediastream/RTCRtpRtxParameters.idl \ 262 263 $(WebCore)/Modules/mediastream/RTCRtpSendParameters.idl \ 263 264 $(WebCore)/Modules/mediastream/RTCRtpSender.idl \ 265 $(WebCore)/Modules/mediastream/RTCRtpSender+Transform.idl \ 264 266 $(WebCore)/Modules/mediastream/RTCRtpSynchronizationSource.idl \ 265 267 $(WebCore)/Modules/mediastream/RTCRtpTransceiver.idl \ 266 268 $(WebCore)/Modules/mediastream/RTCRtpTransceiverDirection.idl \ 269 $(WebCore)/Modules/mediastream/RTCRtpTransform.idl \ 267 270 $(WebCore)/Modules/mediastream/RTCSdpType.idl \ 268 271 $(WebCore)/Modules/mediastream/RTCSessionDescription.idl \ … … 1227 1230 $(WebCore)/testing/MockPaymentCoordinator.idl \ 1228 1231 $(WebCore)/testing/MockPaymentError.idl \ 1232 $(WebCore)/testing/MockRTCRtpTransform.idl \ 1229 1233 $(WebCore)/testing/MockWebAuthenticationConfiguration.idl \ 1230 1234 $(WebCore)/testing/ServiceWorkerInternals.idl \ -
trunk/Source/WebCore/Modules/mediastream/RTCRtpReceiver.cpp
r251134 r269764 50 50 } 51 51 52 RTCRtpReceiver::~RTCRtpReceiver() 53 { 54 if (m_transform) 55 m_transform->detachFromReceiver(*this); 56 } 57 52 58 void RTCRtpReceiver::stop() 53 59 { 54 60 if (!m_backend) 55 61 return; 62 63 if (m_transform) 64 m_transform->detachFromReceiver(*this); 56 65 57 66 m_backend = nullptr; … … 73 82 } 74 83 84 ExceptionOr<void> RTCRtpReceiver::setTransform(RefPtr<RTCRtpTransform>&& transform) 85 { 86 if (transform && transform->isAttached()) 87 return Exception { InvalidStateError, "transform is already in use"_s }; 88 89 if (m_transform) 90 m_transform->detachFromReceiver(*this); 91 m_transform = WTFMove(transform); 92 if (m_transform) 93 m_transform->attachToReceiver(*this); 94 95 return { }; 96 } 97 75 98 } // namespace WebCore 76 99 -
trunk/Source/WebCore/Modules/mediastream/RTCRtpReceiver.h
r250735 r269764 36 36 #include "RTCRtpReceiverBackend.h" 37 37 #include "RTCRtpSynchronizationSource.h" 38 #include "RTCRtpTransform.h" 38 39 #include "ScriptWrappable.h" 39 40 … … 51 52 return adoptRef(*new RTCRtpReceiver(connection, WTFMove(track), WTFMove(backend))); 52 53 } 54 ~RTCRtpReceiver(); 53 55 54 56 static Optional<RTCRtpCapabilities> getCapabilities(ScriptExecutionContext&, const String& kind); … … 66 68 void getStats(Ref<DeferredPromise>&&); 67 69 70 RTCRtpTransform* transform() { return m_transform.get(); } 71 ExceptionOr<void> setTransform(RefPtr<RTCRtpTransform>&&); 72 68 73 private: 69 74 RTCRtpReceiver(PeerConnectionBackend&, Ref<MediaStreamTrack>&&, std::unique_ptr<RTCRtpReceiverBackend>&&); … … 72 77 std::unique_ptr<RTCRtpReceiverBackend> m_backend; 73 78 WeakPtr<PeerConnectionBackend> m_connection; 79 RefPtr<RTCRtpTransform> m_transform; 74 80 }; 75 81 -
trunk/Source/WebCore/Modules/mediastream/RTCRtpReceiverBackend.h
r236147 r269764 32 32 namespace WebCore { 33 33 34 class RTCRtpTransformBackend; 35 34 36 class RTCRtpReceiverBackend { 35 37 public: … … 38 40 virtual Vector<RTCRtpContributingSource> getContributingSources() const { return { }; } 39 41 virtual Vector<RTCRtpSynchronizationSource> getSynchronizationSources() const { return { }; } 42 virtual Ref<RTCRtpTransformBackend> createRTCRtpTransformBackend() = 0; 40 43 }; 41 44 -
trunk/Source/WebCore/Modules/mediastream/RTCRtpSender.cpp
r266468 r269764 67 67 } 68 68 69 RTCRtpSender::~RTCRtpSender() = default; 69 RTCRtpSender::~RTCRtpSender() 70 { 71 if (m_transform) 72 m_transform->detachFromSender(*this); 73 } 70 74 71 75 void RTCRtpSender::setTrackToNull() … … 78 82 void RTCRtpSender::stop() 79 83 { 84 if (m_transform) 85 m_transform->detachFromSender(*this); 86 80 87 m_trackId = { }; 81 88 m_track = nullptr; … … 187 194 } 188 195 196 ExceptionOr<void> RTCRtpSender::setTransform(RefPtr<RTCRtpTransform>&& transform) 197 { 198 if (transform && transform->isAttached()) 199 return Exception { InvalidStateError, "transform is already in use"_s }; 200 201 if (m_transform) 202 m_transform->detachFromSender(*this); 203 m_transform = WTFMove(transform); 204 if (m_transform) 205 m_transform->attachToSender(*this); 206 207 return { }; 208 } 209 189 210 } // namespace WebCore 190 211 -
trunk/Source/WebCore/Modules/mediastream/RTCRtpSender.h
r266468 r269764 37 37 #include "RTCRtpSenderBackend.h" 38 38 #include "RTCRtpTransceiverDirection.h" 39 #include "RTCRtpTransform.h" 39 40 #include "ScriptWrappable.h" 40 41 #include <wtf/WeakPtr.h> … … 82 83 Optional<RTCRtpTransceiverDirection> currentTransceiverDirection() const; 83 84 85 RTCRtpTransform* transform() { return m_transform.get(); } 86 ExceptionOr<void> setTransform(RefPtr<RTCRtpTransform>&&); 87 84 88 private: 85 89 RTCRtpSender(RTCPeerConnection&, String&& trackKind, Vector<String>&& mediaStreamIds, std::unique_ptr<RTCRtpSenderBackend>&&); … … 92 96 WeakPtr<RTCPeerConnection> m_connection; 93 97 RefPtr<RTCDTMFSender> m_dtmfSender; 98 RefPtr<RTCRtpTransform> m_transform; 94 99 }; 95 100 -
trunk/Source/WebCore/Modules/mediastream/RTCRtpSenderBackend.h
r266468 r269764 32 32 class RTCDTMFSenderBackend; 33 33 class RTCRtpSender; 34 class RTCRtpTransformBackend; 34 35 class ScriptExecutionContext; 35 36 … … 40 41 class RTCRtpSenderBackend { 41 42 public: 43 virtual ~RTCRtpSenderBackend() = default; 44 42 45 virtual bool replaceTrack(RTCRtpSender&, MediaStreamTrack*) = 0; 43 46 virtual RTCRtpSendParameters getParameters() const = 0; 44 47 virtual void setParameters(const RTCRtpSendParameters&, DOMPromiseDeferred<void>&&) = 0; 45 48 virtual std::unique_ptr<RTCDTMFSenderBackend> createDTMFBackend() = 0; 46 virtual ~RTCRtpSenderBackend() = default;49 virtual Ref<RTCRtpTransformBackend> createRTCRtpTransformBackend() = 0; 47 50 }; 48 51 -
trunk/Source/WebCore/Modules/mediastream/RTCRtpTransformBackend.h
r269763 r269764 1 1 /* 2 * Copyright (C) 20 18Apple Inc.2 * Copyright (C) 2020 Apple Inc. 3 3 * 4 4 * Redistribution and use in source and binary forms, with or without … … 27 27 #if ENABLE(WEB_RTC) 28 28 29 #include <wtf/ThreadSafeRefCounted.h> 30 29 31 namespace WebCore { 30 32 31 class MediaStreamTrack; 32 class RTCDTMFSenderBackend; 33 class RTCRtpSender; 34 class ScriptExecutionContext; 33 class RTCRtpTransformableFrame; 35 34 36 struct RTCRtpSendParameters; 35 class RTCRtpTransformBackend : public ThreadSafeRefCounted<RTCRtpTransformBackend, WTF::DestructionThread::Main> { 36 public: 37 virtual ~RTCRtpTransformBackend() = default; 37 38 38 template<typename IDLType> class DOMPromiseDeferred; 39 using Callback = Function<void(RTCRtpTransformableFrame&&)>; 40 virtual void setTransformableFrameCallback(Callback&&) = 0; 41 virtual void clearTransformableFrameCallback() = 0; 42 virtual void processTransformedFrame(RTCRtpTransformableFrame&&) = 0; 39 43 40 class RTCRtpSenderBackend { 41 public: 42 virtual bool replaceTrack(RTCRtpSender&, MediaStreamTrack*) = 0; 43 virtual RTCRtpSendParameters getParameters() const = 0; 44 virtual void setParameters(const RTCRtpSendParameters&, DOMPromiseDeferred<void>&&) = 0; 45 virtual std::unique_ptr<RTCDTMFSenderBackend> createDTMFBackend() = 0; 46 virtual ~RTCRtpSenderBackend() = default; 44 enum class MediaType { Audio, Video }; 45 virtual MediaType mediaType() const = 0; 46 47 enum class Side { Sender, Receiver }; 48 virtual Side side() const = 0; 47 49 }; 48 50 -
trunk/Source/WebCore/Modules/mediastream/RTCRtpTransformableFrame.h
r269763 r269764 1 1 /* 2 * Copyright (C) 20 18Apple Inc.2 * Copyright (C) 2020 Apple Inc. 3 3 * 4 4 * Redistribution and use in source and binary forms, with or without … … 27 27 #if ENABLE(WEB_RTC) 28 28 29 #include "RTCRtpParameters.h"30 #include "RTCRtpSynchronizationSource.h"31 32 29 namespace WebCore { 33 30 34 class RTCRtp ReceiverBackend{31 class RTCRtpTransformableFrame { 35 32 public: 36 virtual ~RTCRtpReceiverBackend() = default; 37 virtual RTCRtpParameters getParameters() { return { }; } 38 virtual Vector<RTCRtpContributingSource> getContributingSources() const { return { }; } 39 virtual Vector<RTCRtpSynchronizationSource> getSynchronizationSources() const { return { }; } 33 virtual ~RTCRtpTransformableFrame() = default; 34 35 struct Data { 36 const uint8_t* data; 37 size_t size; 38 }; 39 virtual Data data() const = 0; 40 virtual void setData(Data) = 0; 40 41 }; 41 42 -
trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverBackend.cpp
r267566 r269764 26 26 #include "LibWebRTCRtpReceiverBackend.h" 27 27 28 #include "LibWebRTCRtpReceiverTransformBackend.h" 28 29 #include "LibWebRTCUtils.h" 30 #include "RTCRtpTransformBackend.h" 29 31 #include "RealtimeIncomingAudioSource.h" 30 32 #include "RealtimeIncomingVideoSource.h" … … 115 117 } 116 118 119 Ref<RTCRtpTransformBackend> LibWebRTCRtpReceiverBackend::createRTCRtpTransformBackend() 120 { 121 return LibWebRTCRtpReceiverTransformBackend::create(m_rtcReceiver); 122 } 117 123 118 124 } // namespace WebCore -
trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverBackend.h
r267566 r269764 53 53 Vector<RTCRtpContributingSource> getContributingSources() const final; 54 54 Vector<RTCRtpSynchronizationSource> getSynchronizationSources() const final; 55 Ref<RTCRtpTransformBackend> createRTCRtpTransformBackend() final; 55 56 56 57 rtc::scoped_refptr<webrtc::RtpReceiverInterface> m_rtcReceiver; -
trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverTransformBackend.cpp
r269763 r269764 1 1 /* 2 * Copyright (C) 20 18Apple Inc.2 * Copyright (C) 2020 Apple Inc. 3 3 * 4 4 * Redistribution and use in source and binary forms, with or without … … 23 23 */ 24 24 25 #pragma once 25 #include "config.h" 26 #include "LibWebRTCRtpReceiverTransformBackend.h" 26 27 27 28 #if ENABLE(WEB_RTC) && USE(LIBWEBRTC) 28 29 29 #include "LibWebRTCMacros.h" 30 #include "RTCRtpReceiverBackend.h" 31 #include <webrtc/api/scoped_refptr.h> 32 33 namespace webrtc { 34 class RtpReceiverInterface; 35 } 30 #include "LibWebRTCRtpTransformableFrame.h" 36 31 37 32 namespace WebCore { 38 33 39 class RealtimeMediaSource; 34 static inline LibWebRTCRtpReceiverTransformBackend::MediaType mediaTypeFromReceiver(const webrtc::RtpReceiverInterface& receiver) 35 { 36 return receiver.media_type() == cricket::MEDIA_TYPE_AUDIO ? RTCRtpTransformBackend::MediaType::Audio : RTCRtpTransformBackend::MediaType::Video; 37 } 40 38 41 class LibWebRTCRtpReceiverBackend final : public RTCRtpReceiverBackend { 42 WTF_MAKE_FAST_ALLOCATED;43 public: 44 explicit LibWebRTCRtpReceiverBackend(rtc::scoped_refptr<webrtc::RtpReceiverInterface>&&); 45 ~LibWebRTCRtpReceiverBackend(); 39 LibWebRTCRtpReceiverTransformBackend::LibWebRTCRtpReceiverTransformBackend(rtc::scoped_refptr<webrtc::RtpReceiverInterface> rtcReceiver) 40 : LibWebRTCRtpTransformBackend(mediaTypeFromReceiver(*rtcReceiver), Side::Receiver) 41 , m_rtcReceiver(WTFMove(rtcReceiver)) 42 { 43 } 46 44 47 webrtc::RtpReceiverInterface* rtcReceiver() { return m_rtcReceiver.get(); } 45 LibWebRTCRtpReceiverTransformBackend::~LibWebRTCRtpReceiverTransformBackend() 46 { 47 } 48 48 49 Ref<RealtimeMediaSource> createSource(); 50 51 private: 52 RTCRtpParameters getParameters() final; 53 Vector<RTCRtpContributingSource> getContributingSources() const final; 54 Vector<RTCRtpSynchronizationSource> getSynchronizationSources() const final; 55 56 rtc::scoped_refptr<webrtc::RtpReceiverInterface> m_rtcReceiver; 57 }; 49 void LibWebRTCRtpReceiverTransformBackend::setTransformableFrameCallback(Callback&& callback) 50 { 51 setInputCallback(WTFMove(callback)); 52 m_rtcReceiver->SetDepacketizerToDecoderFrameTransformer(this); 53 } 58 54 59 55 } // namespace WebCore -
trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverTransformBackend.h
r269763 r269764 1 1 /* 2 * Copyright (C) 20 18Apple Inc.2 * Copyright (C) 2020 Apple Inc. 3 3 * 4 4 * Redistribution and use in source and binary forms, with or without … … 27 27 #if ENABLE(WEB_RTC) && USE(LIBWEBRTC) 28 28 29 #include "LibWebRTCMacros.h" 30 #include "RTCRtpReceiverBackend.h" 31 #include <webrtc/api/scoped_refptr.h> 29 #include "LibWebRTCRtpTransformBackend.h" 30 31 ALLOW_UNUSED_PARAMETERS_BEGIN 32 ALLOW_DEPRECATED_DECLARATIONS_BEGIN 33 34 #include <webrtc/api/rtp_receiver_interface.h> 35 36 ALLOW_DEPRECATED_DECLARATIONS_END 37 ALLOW_UNUSED_PARAMETERS_END 32 38 33 39 namespace webrtc { … … 37 43 namespace WebCore { 38 44 39 class RealtimeMediaSource; 40 41 class LibWebRTCRtpReceiverBackend final : public RTCRtpReceiverBackend { 42 WTF_MAKE_FAST_ALLOCATED; 45 class LibWebRTCRtpReceiverTransformBackend final : public LibWebRTCRtpTransformBackend { 43 46 public: 44 explicit LibWebRTCRtpReceiverBackend(rtc::scoped_refptr<webrtc::RtpReceiverInterface>&&); 45 ~LibWebRTCRtpReceiverBackend(); 46 47 webrtc::RtpReceiverInterface* rtcReceiver() { return m_rtcReceiver.get(); } 48 49 Ref<RealtimeMediaSource> createSource(); 47 static Ref<LibWebRTCRtpReceiverTransformBackend> create(rtc::scoped_refptr<webrtc::RtpReceiverInterface> receiver) { return adoptRef(*new LibWebRTCRtpReceiverTransformBackend(WTFMove(receiver))); } 48 ~LibWebRTCRtpReceiverTransformBackend(); 50 49 51 50 private: 52 RTCRtpParameters getParameters() final; 53 Vector<RTCRtpContributingSource> getContributingSources() const final; 54 Vector<RTCRtpSynchronizationSource> getSynchronizationSources() const final; 51 explicit LibWebRTCRtpReceiverTransformBackend(rtc::scoped_refptr<webrtc::RtpReceiverInterface>); 52 53 // RTCRtpTransformBackend 54 void setTransformableFrameCallback(Callback&&) final; 55 55 56 56 rtc::scoped_refptr<webrtc::RtpReceiverInterface> m_rtcReceiver; -
trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpSenderBackend.cpp
r266468 r269764 31 31 #include "LibWebRTCDTMFSenderBackend.h" 32 32 #include "LibWebRTCPeerConnectionBackend.h" 33 #include "LibWebRTCRtpSenderTransformBackend.h" 33 34 #include "LibWebRTCUtils.h" 34 35 #include "RTCPeerConnection.h" 35 36 #include "RTCRtpSender.h" 37 #include "RTCRtpTransformBackend.h" 36 38 #include "ScriptExecutionContext.h" 37 39 … … 137 139 } 138 140 141 Ref<RTCRtpTransformBackend> LibWebRTCRtpSenderBackend::createRTCRtpTransformBackend() 142 { 143 return LibWebRTCRtpSenderTransformBackend::create(m_rtcSender); 144 } 145 139 146 RealtimeOutgoingVideoSource* LibWebRTCRtpSenderBackend::videoSource() 140 147 { -
trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpSenderBackend.h
r266468 r269764 71 71 void setParameters(const RTCRtpSendParameters&, DOMPromiseDeferred<void>&&) final; 72 72 std::unique_ptr<RTCDTMFSenderBackend> createDTMFBackend() final; 73 Ref<RTCRtpTransformBackend> createRTCRtpTransformBackend() final; 73 74 74 75 void startSource(); -
trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpSenderTransformBackend.cpp
r269763 r269764 1 1 /* 2 * Copyright (C) 20 18Apple Inc.2 * Copyright (C) 2020 Apple Inc. 3 3 * 4 4 * Redistribution and use in source and binary forms, with or without … … 23 23 */ 24 24 25 #pragma once 25 #include "config.h" 26 #include "LibWebRTCRtpSenderTransformBackend.h" 26 27 27 28 #if ENABLE(WEB_RTC) && USE(LIBWEBRTC) 28 29 29 #include "LibWebRTCMacros.h" 30 #include "RTCRtpReceiverBackend.h" 31 #include <webrtc/api/scoped_refptr.h> 32 33 namespace webrtc { 34 class RtpReceiverInterface; 35 } 30 #include "LibWebRTCRtpTransformableFrame.h" 36 31 37 32 namespace WebCore { 38 33 39 class RealtimeMediaSource; 34 static inline LibWebRTCRtpSenderTransformBackend::MediaType mediaTypeFromSender(const webrtc::RtpSenderInterface& sender) 35 { 36 return sender.media_type() == cricket::MEDIA_TYPE_AUDIO ? RTCRtpTransformBackend::MediaType::Audio : RTCRtpTransformBackend::MediaType::Video; 37 } 40 38 41 class LibWebRTCRtpReceiverBackend final : public RTCRtpReceiverBackend { 42 WTF_MAKE_FAST_ALLOCATED;43 public: 44 explicit LibWebRTCRtpReceiverBackend(rtc::scoped_refptr<webrtc::RtpReceiverInterface>&&); 45 ~LibWebRTCRtpReceiverBackend(); 39 LibWebRTCRtpSenderTransformBackend::LibWebRTCRtpSenderTransformBackend(rtc::scoped_refptr<webrtc::RtpSenderInterface> rtcSender) 40 : LibWebRTCRtpTransformBackend(mediaTypeFromSender(*rtcSender), Side::Sender) 41 , m_rtcSender(WTFMove(rtcSender)) 42 { 43 } 46 44 47 webrtc::RtpReceiverInterface* rtcReceiver() { return m_rtcReceiver.get(); } 45 LibWebRTCRtpSenderTransformBackend::~LibWebRTCRtpSenderTransformBackend() 46 { 47 } 48 48 49 Ref<RealtimeMediaSource> createSource(); 49 void LibWebRTCRtpSenderTransformBackend::setTransformableFrameCallback(Callback&& callback) 50 { 51 setInputCallback(WTFMove(callback)); 52 m_rtcSender->SetEncoderToPacketizerFrameTransformer(this); 53 } 50 54 51 private:52 RTCRtpParameters getParameters() final;53 Vector<RTCRtpContributingSource> getContributingSources() const final;54 Vector<RTCRtpSynchronizationSource> getSynchronizationSources() const final;55 56 rtc::scoped_refptr<webrtc::RtpReceiverInterface> m_rtcReceiver;57 };58 55 59 56 } // namespace WebCore -
trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpSenderTransformBackend.h
r269763 r269764 1 1 /* 2 * Copyright (C) 20 18Apple Inc.2 * Copyright (C) 2020 Apple Inc. 3 3 * 4 4 * Redistribution and use in source and binary forms, with or without … … 27 27 #if ENABLE(WEB_RTC) && USE(LIBWEBRTC) 28 28 29 #include "LibWebRTCMacros.h" 30 #include "RTCRtpReceiverBackend.h" 31 #include <webrtc/api/scoped_refptr.h> 29 #include "LibWebRTCRtpTransformBackend.h" 30 31 ALLOW_UNUSED_PARAMETERS_BEGIN 32 ALLOW_DEPRECATED_DECLARATIONS_BEGIN 33 34 #include <webrtc/api/rtp_sender_interface.h> 35 36 ALLOW_DEPRECATED_DECLARATIONS_END 37 ALLOW_UNUSED_PARAMETERS_END 32 38 33 39 namespace webrtc { 34 class Rtp ReceiverInterface;40 class RtpSenderInterface; 35 41 } 36 42 37 43 namespace WebCore { 38 44 39 class RealtimeMediaSource;45 class LibWebRTCSenderTransformer; 40 46 41 class LibWebRTCRtp ReceiverBackend final : public RTCRtpReceiverBackend {47 class LibWebRTCRtpSenderTransformBackend final : public LibWebRTCRtpTransformBackend { 42 48 WTF_MAKE_FAST_ALLOCATED; 43 49 public: 44 explicit LibWebRTCRtpReceiverBackend(rtc::scoped_refptr<webrtc::RtpReceiverInterface>&&); 45 ~LibWebRTCRtpReceiverBackend(); 46 47 webrtc::RtpReceiverInterface* rtcReceiver() { return m_rtcReceiver.get(); } 48 49 Ref<RealtimeMediaSource> createSource(); 50 static Ref<LibWebRTCRtpSenderTransformBackend> create(rtc::scoped_refptr<webrtc::RtpSenderInterface> sender) { return adoptRef(*new LibWebRTCRtpSenderTransformBackend(WTFMove(sender))); } 51 ~LibWebRTCRtpSenderTransformBackend(); 50 52 51 53 private: 52 RTCRtpParameters getParameters() final; 53 Vector<RTCRtpContributingSource> getContributingSources() const final; 54 Vector<RTCRtpSynchronizationSource> getSynchronizationSources() const final; 54 explicit LibWebRTCRtpSenderTransformBackend(rtc::scoped_refptr<webrtc::RtpSenderInterface>); 55 55 56 rtc::scoped_refptr<webrtc::RtpReceiverInterface> m_rtcReceiver; 56 // RTCRtpTransformBackend 57 void setTransformableFrameCallback(Callback&&) final; 58 59 rtc::scoped_refptr<webrtc::RtpSenderInterface> m_rtcSender; 57 60 }; 58 61 -
trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCRtpTransformableFrame.h
r269763 r269764 1 1 /* 2 * Copyright (C) 20 18Apple Inc.2 * Copyright (C) 2020 Apple Inc. 3 3 * 4 4 * Redistribution and use in source and binary forms, with or without … … 27 27 #if ENABLE(WEB_RTC) 28 28 29 #include "RTCRtpTransformableFrame.h" 30 29 31 namespace WebCore { 30 32 31 class MediaStreamTrack; 32 class RTCDTMFSenderBackend; 33 class RTCRtpSender; 34 class ScriptExecutionContext; 33 class LibWebRTCRtpTransformableFrame final : public RTCRtpTransformableFrame { 34 WTF_MAKE_FAST_ALLOCATED; 35 public: 36 explicit LibWebRTCRtpTransformableFrame(std::unique_ptr<webrtc::TransformableFrameInterface>&&); 37 virtual ~LibWebRTCRtpTransformableFrame() = default; 35 38 36 struct RTCRtpSendParameters;39 static std::unique_ptr<webrtc::TransformableFrameInterface> toRTCFrame(LibWebRTCRtpTransformableFrame&&); 37 40 38 template<typename IDLType> class DOMPromiseDeferred; 41 private: 42 Data data() const final; 43 void setData(Data data) final { m_rtcFrame->SetData({ data.data, data.size }); } 39 44 40 class RTCRtpSenderBackend { 41 public: 42 virtual bool replaceTrack(RTCRtpSender&, MediaStreamTrack*) = 0; 43 virtual RTCRtpSendParameters getParameters() const = 0; 44 virtual void setParameters(const RTCRtpSendParameters&, DOMPromiseDeferred<void>&&) = 0; 45 virtual std::unique_ptr<RTCDTMFSenderBackend> createDTMFBackend() = 0; 46 virtual ~RTCRtpSenderBackend() = default; 45 std::unique_ptr<webrtc::TransformableFrameInterface> m_rtcFrame; 47 46 }; 47 48 inline LibWebRTCRtpTransformableFrame::LibWebRTCRtpTransformableFrame(std::unique_ptr<webrtc::TransformableFrameInterface>&& frame) 49 : m_rtcFrame(WTFMove(frame)) 50 { 51 } 52 53 inline std::unique_ptr<webrtc::TransformableFrameInterface> LibWebRTCRtpTransformableFrame::toRTCFrame(LibWebRTCRtpTransformableFrame&& frame) 54 { 55 return WTFMove(frame.m_rtcFrame); 56 } 57 58 inline RTCRtpTransformableFrame::Data LibWebRTCRtpTransformableFrame::data() const 59 { 60 auto data = m_rtcFrame->GetData(); 61 return { data.begin(), data.size() }; 62 } 48 63 49 64 } // namespace WebCore -
trunk/Source/WebCore/Sources.txt
r269712 r269764 165 165 Modules/mediastream/RTCRtpReceiver.cpp 166 166 Modules/mediastream/RTCRtpSender.cpp 167 Modules/mediastream/RTCRtpTransform.cpp 167 168 Modules/mediastream/RTCRtpTransceiver.cpp 168 169 Modules/mediastream/RTCSessionDescription.cpp … … 171 172 Modules/mediastream/UserMediaRequest.cpp 172 173 Modules/mediastream/libwebrtc/LibWebRTCCertificateGenerator.cpp 174 Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverTransformBackend.cpp 175 Modules/mediastream/libwebrtc/LibWebRTCRtpSenderTransformBackend.cpp 176 Modules/mediastream/libwebrtc/LibWebRTCRtpTransformBackend.cpp 173 177 Modules/notifications/Notification.cpp 174 178 Modules/notifications/NotificationController.cpp … … 3322 3326 JSRTCRtpTransceiver.cpp 3323 3327 JSRTCRtpTransceiverDirection.cpp 3328 JSRTCRtpTransform.cpp 3324 3329 JSRTCSdpType.cpp 3325 3330 JSRTCSessionDescription.cpp -
trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj
r269712 r269764 1047 1047 413A1AA22371A8B4007EF3A5 /* JSDOMSetLike.h in Headers */ = {isa = PBXBuildFile; fileRef = 413A1A9F2371A8A8007EF3A5 /* JSDOMSetLike.h */; }; 1048 1048 413C2C341BC29A8F0075204C /* JSDOMConstructor.h in Headers */ = {isa = PBXBuildFile; fileRef = 413C2C331BC29A7B0075204C /* JSDOMConstructor.h */; }; 1049 413C8B332552F27D00E65055 /* RTCRtpSenderWithTransform.h in Headers */ = {isa = PBXBuildFile; fileRef = 413C8B2E2552F27B00E65055 /* RTCRtpSenderWithTransform.h */; }; 1050 413C8B342552F27D00E65055 /* RTCRtpTransform.h in Headers */ = {isa = PBXBuildFile; fileRef = 413C8B2F2552F27B00E65055 /* RTCRtpTransform.h */; }; 1051 413C8B352552F27D00E65055 /* RTCRtpReceiverWithTransform.h in Headers */ = {isa = PBXBuildFile; fileRef = 413C8B302552F27C00E65055 /* RTCRtpReceiverWithTransform.h */; }; 1049 1052 413CCD4A20DE034F0065A21A /* MockMediaDevice.h in Headers */ = {isa = PBXBuildFile; fileRef = 413CCD4820DE013C0065A21A /* MockMediaDevice.h */; settings = {ATTRIBUTES = (Private, ); }; }; 1050 1053 413E00791DB0E4F2002341D2 /* MemoryRelease.h in Headers */ = {isa = PBXBuildFile; fileRef = 413E00781DB0E4DE002341D2 /* MemoryRelease.h */; settings = {ATTRIBUTES = (Private, ); }; }; … … 1099 1102 41815C1E138319830057AAA4 /* WebCoreTestSupport.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 41815C1C138319830057AAA4 /* WebCoreTestSupport.cpp */; }; 1100 1103 41815C1F138319830057AAA4 /* WebCoreTestSupport.h in Headers */ = {isa = PBXBuildFile; fileRef = 41815C1D138319830057AAA4 /* WebCoreTestSupport.h */; settings = {ATTRIBUTES = (Private, ); }; }; 1104 4181C5C9255573DF00AEB0FF /* RTCRtpTransformBackend.h in Headers */ = {isa = PBXBuildFile; fileRef = 4181C5C8255573DF00AEB0FF /* RTCRtpTransformBackend.h */; }; 1105 4181C5CB255582E400AEB0FF /* RTCRtpTransformableFrame.h in Headers */ = {isa = PBXBuildFile; fileRef = 4181C5CA255582E300AEB0FF /* RTCRtpTransformableFrame.h */; }; 1106 4181C5CD2555836900AEB0FF /* LibWebRTCRtpTransformableFrame.h in Headers */ = {isa = PBXBuildFile; fileRef = 4181C5CC2555836800AEB0FF /* LibWebRTCRtpTransformableFrame.h */; }; 1107 4181C5D12555895600AEB0FF /* LibWebRTCRtpTransformBackend.h in Headers */ = {isa = PBXBuildFile; fileRef = 4181C5CF2555895600AEB0FF /* LibWebRTCRtpTransformBackend.h */; }; 1108 4181C5D62555C1B900AEB0FF /* MockRTCRtpTransform.h in Headers */ = {isa = PBXBuildFile; fileRef = 4181C5D52555C1B900AEB0FF /* MockRTCRtpTransform.h */; }; 1109 4181C5D72555C49A00AEB0FF /* MockRTCRtpTransform.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4181C5D32555C1B100AEB0FF /* MockRTCRtpTransform.cpp */; }; 1110 4181C639255AE90F00AEB0FF /* JSMockRTCRtpTransform.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2D6F3E921C1F85550061DBE4 /* JSMockRTCRtpTransform.cpp */; }; 1101 1111 418205471E53E98C00D62207 /* RTCController.h in Headers */ = {isa = PBXBuildFile; fileRef = 418205451E53C8CD00D62207 /* RTCController.h */; settings = {ATTRIBUTES = (Private, ); }; }; 1102 1112 41826BF223FB597700B922B1 /* DocumentIdentifier.h in Headers */ = {isa = PBXBuildFile; fileRef = 41826BF123FB597000B922B1 /* DocumentIdentifier.h */; settings = {ATTRIBUTES = (Private, ); }; }; … … 7035 7045 2D6F3E921C1F85550061DBD5 /* JSInternalsSetLike.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSInternalsSetLike.cpp; sourceTree = "<group>"; }; 7036 7046 2D6F3E921C1F85550061DBD6 /* JSInternalsMapLike.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSInternalsMapLike.cpp; sourceTree = "<group>"; }; 7047 2D6F3E921C1F85550061DBE4 /* JSMockRTCRtpTransform.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSMockRTCRtpTransform.cpp; sourceTree = "<group>"; }; 7037 7048 2D6F3E931C1F85550061DBD4 /* JSMockPageOverlay.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSMockPageOverlay.h; sourceTree = "<group>"; }; 7038 7049 2D70BA1218074DDF0001908A /* PlatformCALayerCocoa.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PlatformCALayerCocoa.h; sourceTree = "<group>"; }; … … 7563 7574 413A1AA12371A8A9007EF3A5 /* JSDOMSetLike.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = JSDOMSetLike.cpp; sourceTree = "<group>"; }; 7564 7575 413C2C331BC29A7B0075204C /* JSDOMConstructor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSDOMConstructor.h; sourceTree = "<group>"; }; 7576 413C8B242552EEA900E65055 /* RTCRtpReceiver+Transform.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = "RTCRtpReceiver+Transform.idl"; sourceTree = "<group>"; }; 7577 413C8B262552EEA900E65055 /* RTCRtpSender+Transform.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = "RTCRtpSender+Transform.idl"; sourceTree = "<group>"; }; 7578 413C8B292552F01300E65055 /* RTCRtpTransform.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = RTCRtpTransform.idl; sourceTree = "<group>"; }; 7579 413C8B2E2552F27B00E65055 /* RTCRtpSenderWithTransform.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RTCRtpSenderWithTransform.h; sourceTree = "<group>"; }; 7580 413C8B2F2552F27B00E65055 /* RTCRtpTransform.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RTCRtpTransform.h; sourceTree = "<group>"; }; 7581 413C8B302552F27C00E65055 /* RTCRtpReceiverWithTransform.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RTCRtpReceiverWithTransform.h; sourceTree = "<group>"; }; 7565 7582 413CCD4820DE013C0065A21A /* MockMediaDevice.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MockMediaDevice.h; sourceTree = "<group>"; }; 7566 7583 413E00771DB0E4DE002341D2 /* MemoryRelease.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MemoryRelease.cpp; sourceTree = "<group>"; }; … … 7673 7690 41815C1D138319830057AAA4 /* WebCoreTestSupport.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebCoreTestSupport.h; sourceTree = "<group>"; }; 7674 7691 4181707D1386EDF20057AAA4 /* WebCoreTestSupport.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = WebCoreTestSupport.xcconfig; sourceTree = "<group>"; }; 7692 4181C5BE2553EB6E00AEB0FF /* LibWebRTCRtpSenderTransformBackend.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = LibWebRTCRtpSenderTransformBackend.h; path = libwebrtc/LibWebRTCRtpSenderTransformBackend.h; sourceTree = "<group>"; }; 7693 4181C5C02553EB6E00AEB0FF /* LibWebRTCRtpReceiverTransformBackend.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = LibWebRTCRtpReceiverTransformBackend.cpp; path = libwebrtc/LibWebRTCRtpReceiverTransformBackend.cpp; sourceTree = "<group>"; }; 7694 4181C5C12553EB6E00AEB0FF /* LibWebRTCRtpSenderTransformBackend.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = LibWebRTCRtpSenderTransformBackend.cpp; path = libwebrtc/LibWebRTCRtpSenderTransformBackend.cpp; sourceTree = "<group>"; }; 7695 4181C5C22553EB6F00AEB0FF /* LibWebRTCRtpReceiverTransformBackend.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = LibWebRTCRtpReceiverTransformBackend.h; path = libwebrtc/LibWebRTCRtpReceiverTransformBackend.h; sourceTree = "<group>"; }; 7696 4181C5C62555735100AEB0FF /* RTCRtpTransform.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RTCRtpTransform.cpp; sourceTree = "<group>"; }; 7697 4181C5C8255573DF00AEB0FF /* RTCRtpTransformBackend.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RTCRtpTransformBackend.h; sourceTree = "<group>"; }; 7698 4181C5CA255582E300AEB0FF /* RTCRtpTransformableFrame.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RTCRtpTransformableFrame.h; sourceTree = "<group>"; }; 7699 4181C5CC2555836800AEB0FF /* LibWebRTCRtpTransformableFrame.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = LibWebRTCRtpTransformableFrame.h; path = libwebrtc/LibWebRTCRtpTransformableFrame.h; sourceTree = "<group>"; }; 7700 4181C5CE2555895500AEB0FF /* LibWebRTCRtpTransformBackend.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = LibWebRTCRtpTransformBackend.cpp; path = libwebrtc/LibWebRTCRtpTransformBackend.cpp; sourceTree = "<group>"; }; 7701 4181C5CF2555895600AEB0FF /* LibWebRTCRtpTransformBackend.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = LibWebRTCRtpTransformBackend.h; path = libwebrtc/LibWebRTCRtpTransformBackend.h; sourceTree = "<group>"; }; 7702 4181C5D32555C1B100AEB0FF /* MockRTCRtpTransform.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MockRTCRtpTransform.cpp; sourceTree = "<group>"; }; 7703 4181C5D52555C1B900AEB0FF /* MockRTCRtpTransform.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MockRTCRtpTransform.h; sourceTree = "<group>"; }; 7704 4181C636255AE26100AEB0FF /* MockRTCRtpTransform.idl */ = {isa = PBXFileReference; lastKnownFileType = text; path = MockRTCRtpTransform.idl; sourceTree = "<group>"; }; 7675 7705 418205451E53C8CD00D62207 /* RTCController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RTCController.h; sourceTree = "<group>"; }; 7676 7706 418205481E53EAAD00D62207 /* RTCController.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RTCController.cpp; sourceTree = "<group>"; }; … … 17047 17077 41A48AA81E84AF1D00D2AC2D /* RTCRtpParameters.h */, 17048 17078 41A48AA71E84AEEC00D2AC2D /* RTCRtpParameters.idl */, 17079 413C8B242552EEA900E65055 /* RTCRtpReceiver+Transform.idl */, 17049 17080 5E2C43561BCEE30D0001E2BC /* RTCRtpReceiver.cpp */, 17050 17081 5E2C43571BCEE30D0001E2BC /* RTCRtpReceiver.h */, 17051 17082 5E2C43581BCEE30D0001E2BC /* RTCRtpReceiver.idl */, 17052 17083 41D1A048213EDDEB0063FB6B /* RTCRtpReceiverBackend.h */, 17084 413C8B302552F27C00E65055 /* RTCRtpReceiverWithTransform.h */, 17053 17085 41FCB760214867000038ADC6 /* RTCRtpRtxParameters.h */, 17054 17086 41FCB758214865D20038ADC6 /* RTCRtpRtxParameters.idl */, 17087 413C8B262552EEA900E65055 /* RTCRtpSender+Transform.idl */, 17055 17088 5E2C43591BCEE30D0001E2BC /* RTCRtpSender.cpp */, 17056 17089 5E2C435A1BCEE30D0001E2BC /* RTCRtpSender.h */, 17057 17090 5E2C435B1BCEE30D0001E2BC /* RTCRtpSender.idl */, 17058 17091 41D1A046213EDDEB0063FB6B /* RTCRtpSenderBackend.h */, 17092 413C8B2E2552F27B00E65055 /* RTCRtpSenderWithTransform.h */, 17059 17093 414AD3FC2149842000521676 /* RTCRtpSendParameters.h */, 17060 17094 414AD3FE2149842000521676 /* RTCRtpSendParameters.idl */, … … 17066 17100 4186BD46214072B60001826F /* RTCRtpTransceiverBackend.h */, 17067 17101 316DCB171E78C330001B5F87 /* RTCRtpTransceiverDirection.idl */, 17102 4181C5C62555735100AEB0FF /* RTCRtpTransform.cpp */, 17103 413C8B2F2552F27B00E65055 /* RTCRtpTransform.h */, 17104 413C8B292552F01300E65055 /* RTCRtpTransform.idl */, 17105 4181C5CA255582E300AEB0FF /* RTCRtpTransformableFrame.h */, 17106 4181C5C8255573DF00AEB0FF /* RTCRtpTransformBackend.h */, 17068 17107 410F565824FCF85400A2E50C /* RTCSdpType.idl */, 17069 17108 07221B7A17CEC32700848E51 /* RTCSessionDescription.cpp */, … … 19127 19166 41D1A04A213EDDFE0063FB6B /* LibWebRTCRtpReceiverBackend.cpp */, 19128 19167 4186BD3B213EDE380001826F /* LibWebRTCRtpReceiverBackend.h */, 19168 4181C5C02553EB6E00AEB0FF /* LibWebRTCRtpReceiverTransformBackend.cpp */, 19169 4181C5C22553EB6F00AEB0FF /* LibWebRTCRtpReceiverTransformBackend.h */, 19129 19170 41D1A04B213EDDFE0063FB6B /* LibWebRTCRtpSenderBackend.cpp */, 19130 19171 4186BD3D213EDE390001826F /* LibWebRTCRtpSenderBackend.h */, 19172 4181C5C12553EB6E00AEB0FF /* LibWebRTCRtpSenderTransformBackend.cpp */, 19173 4181C5BE2553EB6E00AEB0FF /* LibWebRTCRtpSenderTransformBackend.h */, 19131 19174 4186BD4D2140B9E80001826F /* LibWebRTCRtpTransceiverBackend.cpp */, 19132 19175 4186BD4B2140A8050001826F /* LibWebRTCRtpTransceiverBackend.h */, 19176 4181C5CC2555836800AEB0FF /* LibWebRTCRtpTransformableFrame.h */, 19177 4181C5CE2555895500AEB0FF /* LibWebRTCRtpTransformBackend.cpp */, 19178 4181C5CF2555895600AEB0FF /* LibWebRTCRtpTransformBackend.h */, 19133 19179 41D28D0B2139E01D00F4206F /* LibWebRTCStatsCollector.cpp */, 19134 19180 41D28D0C2139E01E00F4206F /* LibWebRTCStatsCollector.h */, … … 19211 19257 A14061891E2ECA0A0032B34E /* MockPreviewLoaderClient.cpp */, 19212 19258 A140618A1E2ECA0A0032B34E /* MockPreviewLoaderClient.h */, 19259 4181C5D32555C1B100AEB0FF /* MockRTCRtpTransform.cpp */, 19260 4181C5D52555C1B900AEB0FF /* MockRTCRtpTransform.h */, 19261 4181C636255AE26100AEB0FF /* MockRTCRtpTransform.idl */, 19213 19262 57156108234C1B31008FC7AB /* MockWebAuthenticationConfiguration.h */, 19214 19263 5715610D234C7481008FC7AB /* MockWebAuthenticationConfiguration.idl */, … … 19266 19315 A1BB85B42159B3890067E07D /* JSMockPaymentError.cpp */, 19267 19316 A1BB85B52159B38A0067E07D /* JSMockPaymentError.h */, 19317 2D6F3E921C1F85550061DBE4 /* JSMockRTCRtpTransform.cpp */, 19268 19318 57156111234C7FBC008FC7AB /* JSMockWebAuthenticationConfiguration.cpp */, 19269 19319 57156110234C7FBC008FC7AB /* JSMockWebAuthenticationConfiguration.h */, … … 33224 33274 415747481E3869A700E914D8 /* LibWebRTCProvider.h in Headers */, 33225 33275 41B28B3D1F860EF300FB52AC /* LibWebRTCProviderCocoa.h in Headers */, 33276 4181C5CD2555836900AEB0FF /* LibWebRTCRtpTransformableFrame.h in Headers */, 33277 4181C5D12555895600AEB0FF /* LibWebRTCRtpTransformBackend.h in Headers */, 33226 33278 410E4461234373E9000173D4 /* LibWebRTCSocketIdentifier.h in Headers */, 33227 33279 84730D911248F0B300D3A9C9 /* LightSource.h in Headers */, … … 33418 33470 07EE76EC1BE96DB000F89133 /* MockRealtimeVideoSource.h in Headers */, 33419 33471 07EE76EF1BEA619800F89133 /* MockRealtimeVideoSourceMac.h in Headers */, 33472 4181C5D62555C1B900AEB0FF /* MockRTCRtpTransform.h in Headers */, 33420 33473 CDF2B0171820540700F2B424 /* MockSourceBufferPrivate.h in Headers */, 33421 33474 CDF2B0191820540700F2B424 /* MockTracks.h in Headers */, … … 34046 34099 412DE4B8219285C00075F3A7 /* RTCRtpCapabilities.h in Headers */, 34047 34100 5E2C43631BCEE32B0001E2BC /* RTCRtpReceiver.h in Headers */, 34101 413C8B352552F27D00E65055 /* RTCRtpReceiverWithTransform.h in Headers */, 34048 34102 5E2C43611BCEE3230001E2BC /* RTCRtpSender.h in Headers */, 34103 413C8B332552F27D00E65055 /* RTCRtpSenderWithTransform.h in Headers */, 34049 34104 5E5E2B141CFC3E75000C0D85 /* RTCRtpTransceiver.h in Headers */, 34050 34105 31EB54DF1E7DC74400C1623B /* RTCRtpTransceiverDirection.h in Headers */, 34106 413C8B342552F27D00E65055 /* RTCRtpTransform.h in Headers */, 34107 4181C5CB255582E400AEB0FF /* RTCRtpTransformableFrame.h in Headers */, 34108 4181C5C9255573DF00AEB0FF /* RTCRtpTransformBackend.h in Headers */, 34051 34109 3135910A1E7DDC7300F30630 /* RTCSdpType.h in Headers */, 34052 34110 078E092617D14D1C00420AA1 /* RTCSessionDescription.h in Headers */, … … 35502 35560 A146D31A1F99BCF800D29196 /* JSMockPaymentCoordinator.cpp in Sources */, 35503 35561 A1BB85B82159B3A40067E07D /* JSMockPaymentError.cpp in Sources */, 35562 4181C639255AE90F00AEB0FF /* JSMockRTCRtpTransform.cpp in Sources */, 35504 35563 57156114234C7FD6008FC7AB /* JSMockWebAuthenticationConfiguration.cpp in Sources */, 35505 35564 427DA71D13735DFA007C57FB /* JSServiceWorkerInternals.cpp in Sources */, … … 35517 35576 A1AFEDE71F8BFF6D0087013F /* MockPaymentCoordinator.cpp in Sources */, 35518 35577 A140618B1E2ECA0A0032B34E /* MockPreviewLoaderClient.cpp in Sources */, 35578 4181C5D72555C49A00AEB0FF /* MockRTCRtpTransform.cpp in Sources */, 35519 35579 AA5F3B8F16CC4B3900455EB0 /* PlatformSpeechSynthesizerMock.cpp in Sources */, 35520 35580 417F0D821FFEE979008EF303 /* ServiceWorkerInternals.cpp in Sources */, -
trunk/Source/WebCore/bindings/js/WebCoreBuiltinNames.h
r268774 r269764 175 175 macro(MediaStreamTrack) \ 176 176 macro(MerchantValidationEvent) \ 177 macro(MockRTCRtpTransform) \ 177 178 macro(ModernMediaControls) \ 178 179 macro(NavigatorCredentials) \ … … 221 222 macro(RTCRtpSender) \ 222 223 macro(RTCRtpTransceiver) \ 224 macro(RTCRtpTransform) \ 223 225 macro(RTCSessionDescription) \ 224 226 macro(RTCStatsReport) \ -
trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm
r269314 r269764 3223 3223 if ($interfaceName ne "Node" && $codeGenerator->InheritsInterface($interface, "Node")) { 3224 3224 $headerIncludes{"JSNode.h"} = 1; 3225 push(@headerContent, "class JS${interfaceName}Owner : public JSNodeOwner {\n");3225 push(@headerContent, "class ${exportMacro}JS${interfaceName}Owner : public JSNodeOwner {\n"); 3226 3226 } else { 3227 push(@headerContent, "class JS${interfaceName}Owner : public JSC::WeakHandleOwner {\n");3227 push(@headerContent, "class ${exportMacro}JS${interfaceName}Owner : public JSC::WeakHandleOwner {\n"); 3228 3228 } 3229 3229 $headerIncludes{"<wtf/NeverDestroyed.h>"} = 1; -
trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h
r266753 r269764 90 90 }; 91 91 92 class JSTestInterfaceOwner : public JSC::WeakHandleOwner {92 class WEBCORE_EXPORT JSTestInterfaceOwner : public JSC::WeakHandleOwner { 93 93 public: 94 94 virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**); -
trunk/Source/WebCore/testing/Internals.cpp
r269662 r269764 139 139 #include "MockPageOverlay.h" 140 140 #include "MockPageOverlayClient.h" 141 #include "MockRTCRtpTransform.h" 141 142 #include "NavigatorBeacon.h" 142 143 #include "NavigatorMediaDevices.h" … … 1580 1581 } 1581 1582 1583 Ref<MockRTCRtpTransform> Internals::createMockRTCRtpTransform() 1584 { 1585 return MockRTCRtpTransform::create(); 1586 } 1587 1582 1588 void Internals::setEnableWebRTCEncryption(bool value) 1583 1589 { -
trunk/Source/WebCore/testing/Internals.h
r269662 r269764 33 33 #include "HEVCUtilities.h" 34 34 #include "IDLTypes.h" 35 #include "MockRTCRtpTransform.h" 35 36 #include "OrientationNotifier.h" 36 37 #include "PageConsoleClient.h" … … 607 608 void setWebRTCVP9Support(bool); 608 609 void setWebRTCVP9VTBSupport(bool); 610 Ref<MockRTCRtpTransform> createMockRTCRtpTransform(); 609 611 void setEnableWebRTCEncryption(bool); 610 612 void setUseDTLS10(bool); -
trunk/Source/WebCore/testing/Internals.idl
r269662 r269764 803 803 [Conditional=WEB_RTC] undefined setWebRTCVP9Support(boolean allowed); 804 804 [Conditional=WEB_RTC] undefined setWebRTCVP9VTBSupport(boolean allowed); 805 [Conditional=WEB_RTC] MockRTCRtpTransform createMockRTCRtpTransform(); 805 806 806 807 [Conditional=MEDIA_STREAM] undefined setMockAudioTrackChannelNumber(MediaStreamTrack track, unsigned short count); -
trunk/Source/WebKit/ChangeLog
r269763 r269764 1 2020-11-12 Youenn Fablet <youenn@apple.com> 2 3 Add infrastructure for WebRTC transforms 4 https://bugs.webkit.org/show_bug.cgi?id=218750 5 6 Reviewed by Eric Carlson. 7 8 Remove no longer needed const casting. 9 10 * Configurations/WebKit.xcconfig: 11 * WebProcess/GPU/webrtc/LibWebRTCCodecs.cpp: 12 (WebKit::LibWebRTCCodecs::completedEncoding): 13 1 14 2020-11-12 Alex Christensen <achristensen@webkit.org> 2 15 -
trunk/Source/WebKit/WebProcess/GPU/webrtc/LibWebRTCCodecs.cpp
r269739 r269764 442 442 return; 443 443 444 webrtc::encoderVideoTaskComplete(encoder->encodedImageCallback, encoder->codecType, const_cast<uint8_t*>(data.data()), data.size(), info);444 webrtc::encoderVideoTaskComplete(encoder->encodedImageCallback, encoder->codecType, data.data(), data.size(), info); 445 445 } 446 446
Note: See TracChangeset
for help on using the changeset viewer.