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

Unified Diff: content/common/gpu/media/omx_video_decode_accelerator.cc

Issue 7311004: Destroy egl image handles in the end of playback. (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 9 years, 5 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
« no previous file with comments | « content/common/gpu/media/omx_video_decode_accelerator.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/gpu/media/omx_video_decode_accelerator.cc
===================================================================
--- content/common/gpu/media/omx_video_decode_accelerator.cc (revision 91551)
+++ content/common/gpu/media/omx_video_decode_accelerator.cc (working copy)
@@ -700,6 +700,7 @@
DCHECK(!*omx_buffer);
void* egl = texture2eglImage_translator.TranslateToEglImage(
egl_display_, egl_context_, gles_buffer.texture_id());
+ egl_images_.push_back(egl);
OMX_ERRORTYPE result = OMX_UseEGLImage(
component_handle_, omx_buffer, output_port_, &gles_buffer, egl);
if (result != OMX_ErrorNone) {
@@ -750,6 +751,11 @@
client_->DismissPictureBuffer(it->first);
}
pictures_.clear();
+
+ static Gles2TextureToEglImageTranslator texture2eglImage_translator;
+ for (size_t i = 0; i < egl_images_.size(); ++i) {
+ texture2eglImage_translator.DestroyEglImage(egl_display_, egl_images_[i]);
Ami GONE FROM CHROMIUM 2011/07/06 15:52:38 This is a bit late to delete the image, as the und
vhiremath 2011/07/07 06:00:37 Done.
+ }
}
void OmxVideoDecodeAccelerator::OnIndexParamPortDefinitionChanged(int port) {
« no previous file with comments | « content/common/gpu/media/omx_video_decode_accelerator.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698