[MediaSource] Push capabilities across process boundary during UIProcess capture.
[WebKit-https.git] / Source / WebCore / platform / mediastream / mac / RealtimeIncomingAudioSource.h
index 2178204..852ce97 100644 (file)
@@ -48,6 +48,8 @@ class RealtimeIncomingAudioSource final : public RealtimeMediaSource, private we
 public:
     static Ref<RealtimeIncomingAudioSource> create(rtc::scoped_refptr<webrtc::AudioTrackInterface>&&, String&&);
 
+    void setSourceTrack(rtc::scoped_refptr<webrtc::AudioTrackInterface>&&);
+
 private:
     RealtimeIncomingAudioSource(rtc::scoped_refptr<webrtc::AudioTrackInterface>&&, String&&);
     ~RealtimeIncomingAudioSource();
@@ -59,7 +61,7 @@ private:
     void startProducingData() final;
     void stopProducingData()  final;
 
-    RefPtr<RealtimeMediaSourceCapabilities> capabilities() const final;
+    const RealtimeMediaSourceCapabilities& capabilities() const final;
     const RealtimeMediaSourceSettings& settings() const final;
 
     MediaConstraints& constraints() { return *m_constraints.get(); }
@@ -71,14 +73,13 @@ private:
 
     RealtimeMediaSourceSettings m_currentSettings;
     RealtimeMediaSourceSupportedConstraints m_supportedConstraints;
-    RefPtr<RealtimeMediaSourceCapabilities> m_capabilities;
     RefPtr<MediaConstraints> m_constraints;
     bool m_isProducingData { false };
     rtc::scoped_refptr<webrtc::AudioTrackInterface> m_audioTrack;
 
     RefPtr<WebAudioSourceProviderAVFObjC> m_audioSourceProvider;
-    AudioStreamBasicDescription m_streamFormat;
-    uint64_t m_numberOfFrames;
+    AudioStreamBasicDescription m_streamFormat { };
+    uint64_t m_numberOfFrames { 0 };
 };
 
 } // namespace WebCore