webkit
2cdf99a9e3038c7e01b3c37e8ad903ecbe5eecf1
https://github.com/WebKit/webkit
|
Public Member Functions | |
ScreenCapturerAndroid (Intent mediaProjectionPermissionResultData, MediaProjection.Callback mediaProjectionCallback) | |
synchronized void | initialize (final SurfaceTextureHelper surfaceTextureHelper, final Context applicationContext, final VideoCapturer.CapturerObserver capturerObserver) |
synchronized void | startCapture (final int width, final int height, final int ignoredFramerate) |
synchronized void | stopCapture () |
synchronized void | dispose () |
synchronized void | changeCaptureFormat (final int width, final int height, final int ignoredFramerate) |
void | onTextureFrameAvailable (int oesTextureId, float[] transformMatrix, long timestampNs) |
boolean | isScreencast () |
long | getNumCapturedFrames () |
Public Member Functions inherited from org.webrtc.VideoCapturer | |
void | initialize (SurfaceTextureHelper surfaceTextureHelper, Context applicationContext, CapturerObserver capturerObserver) |
An implementation of VideoCapturer to capture the screen content as a video stream. Capturing is done by
on a
. We interact with this
using a
. The
is created by the native code and passed to this capturer in
. On receiving a new frame, this capturer passes it as a texture to the native code via
. This takes place on the HandlerThread of the given
. When done with each frame, the native code returns the buffer to the
to be used for new frames. At any time, at most one frame is being processed.
|
inline |
Constructs a new Screen Capturer.
mediaProjectionPermissionResultData | the result data of MediaProjection permission activity; the calling app must validate that result code is Activity.RESULT_OK before calling this method. |
mediaProjectionCallback | MediaProjection callback to implement application specific logic in events such as when the user revokes a previously granted capture permission. |
|
inline |
Changes output video format. This method can be used to scale the output video, or to change orientation when the captured screen is rotated for example.
width | new output video width |
height | new output video height |
ignoredFramerate | ignored |
Implements org.webrtc.VideoCapturer.
|
inline |
Perform any final cleanup here. No more capturing will be done after this call.
Implements org.webrtc.VideoCapturer.
|
inline |
|
inline |
|
inline |
Implements org.webrtc.VideoCapturer.
|
inline |
|
inline |
Start capturing frames in a format that is as close as possible to |width| x |height| and |framerate|.
Implements org.webrtc.VideoCapturer.
|
inline |
Stop capturing. This function should block until capture is actually stopped.
Implements org.webrtc.VideoCapturer.