Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(645)

Unified Diff: media/gpu/android_video_decode_accelerator.h

Issue 2692863011: Add ContentVideoViewOverlay to AVDA. (Closed)
Patch Set: keep |overlay| longer in UpdateSurface, comments Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: media/gpu/android_video_decode_accelerator.h
diff --git a/media/gpu/android_video_decode_accelerator.h b/media/gpu/android_video_decode_accelerator.h
index 97ce3878e2548611f57ebd7220fa20b7889db1dd..8c88ff4e7ae0027e4e725d8f4998e57552146dcd 100644
--- a/media/gpu/android_video_decode_accelerator.h
+++ b/media/gpu/android_video_decode_accelerator.h
@@ -76,9 +76,8 @@ class MEDIA_GPU_EXPORT AndroidVideoDecodeAccelerator
void NotifyError(Error error) override;
// AVDACodecAllocatorClient implementation:
- void OnSurfaceAvailable(bool success) override;
- void OnSurfaceDestroyed() override;
void OnCodecConfigured(
+ scoped_refptr<CodecConfig> codec_config,
std::unique_ptr<VideoCodecBridge> media_codec) override;
private:
@@ -117,6 +116,12 @@ class MEDIA_GPU_EXPORT AndroidVideoDecodeAccelerator
// gets the surface and the codec without waiting).
void StartSurfaceCreation();
+ // Called by AndroidOverlay when a surface becomes available.
+ void OnSurfaceAvailable();
+
+ // Called by AndroidOverlay when a surface is lost or initialization failed.
+ void OnSurfaceDestroyed();
+
// Initialize of the picture buffer manager to use the current surface, once
// it is available. This is not normally called directly, but rather via
// StartSurfaceCreation. If we have a media codec already, then this will
@@ -143,11 +148,6 @@ class MEDIA_GPU_EXPORT AndroidVideoDecodeAccelerator
// concern with modifying |codec_config_| after this returns.
void ConfigureMediaCodecSynchronously();
- // Instantiate a media codec using |codec_config|.
- // This may be called on any thread.
- static std::unique_ptr<VideoCodecBridge> ConfigureMediaCodecOnAnyThread(
- scoped_refptr<CodecConfig> codec_config);
-
// Sends the decoded frame specified by |codec_buffer_index| to the client.
void SendDecodedFrameToClient(int32_t codec_buffer_index,
int32_t bitstream_id);

Powered by Google App Engine
This is Rietveld 408576698