Index: webrtc/api/java/src/org/webrtc/PeerConnectionFactory.java |
diff --git a/webrtc/api/java/src/org/webrtc/PeerConnectionFactory.java b/webrtc/api/java/src/org/webrtc/PeerConnectionFactory.java |
index e71c12f38a9524fa8c8a561f909ec535e2bab776..ff6e89f80920d0f3333ef5982cd067fb20784a04 100644 |
--- a/webrtc/api/java/src/org/webrtc/PeerConnectionFactory.java |
+++ b/webrtc/api/java/src/org/webrtc/PeerConnectionFactory.java |
@@ -108,12 +108,10 @@ |
nativeCreateLocalMediaStream(nativeFactory, label)); |
} |
- // The VideoSource takes ownership of |capturer|, so capturer.release() should not be called |
- // manually after this. |
public VideoSource createVideoSource( |
- VideoCapturerAndroid capturer, MediaConstraints constraints) { |
+ VideoCapturer capturer, MediaConstraints constraints) { |
return new VideoSource(nativeCreateVideoSource( |
- nativeFactory, capturer, constraints)); |
+ nativeFactory, capturer.takeNativeVideoCapturer(), constraints)); |
} |
public VideoTrack createVideoTrack(String id, VideoSource source) { |
@@ -223,7 +221,7 @@ |
long nativeFactory, String label); |
private static native long nativeCreateVideoSource( |
- long nativeFactory, VideoCapturerAndroid videoCapturer, |
+ long nativeFactory, long nativeVideoCapturer, |
MediaConstraints constraints); |
private static native long nativeCreateVideoTrack( |