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

Issue 22824009: Remove StreamTextureManager (Closed)

Created:
7 years, 4 months ago by no sievers
Modified:
7 years, 4 months ago
Reviewers:
reveman, piman
CC:
chromium-reviews, rjkroege, jam, apatrick_chromium, joi+watch-content_chromium.org, feature-media-reviews_chromium.org, darin-cc_chromium.org, boliu, qinmin
Visibility:
Public.

Description

Remove StreamTextureManager Remove stream texture manager and ties as well as special logic (IsStreamTexture, IsStreamTextureOwner) from the decoder. Instead attach a GLImage to the texture and track it im ImageManager. BUG=239760

Patch Set 1 #

Total comments: 10

Patch Set 2 : #

Total comments: 9

Patch Set 3 : address comments #

Total comments: 4

Patch Set 4 : address comments #

Total comments: 11

Patch Set 5 : address comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+725 lines, -1077 lines) Patch
M .gitmodules View 1 2 3 19 chunks +84 lines, -96 lines 0 comments Download
M content/common/gpu/gpu_channel.h View 4 chunks +0 lines, -19 lines 0 comments Download
M content/common/gpu/gpu_channel.cc View 1 2 3 chunks +59 lines, -11 lines 0 comments Download
M content/common/gpu/gpu_command_buffer_stub.cc View 2 chunks +0 lines, -9 lines 0 comments Download
M content/common/gpu/media/android_video_decode_accelerator.cc View 1 chunk +1 line, -2 lines 0 comments Download
D content/common/gpu/stream_texture_manager_android.h View 1 chunk +0 lines, -112 lines 0 comments Download
D content/common/gpu/stream_texture_manager_android.cc View 1 chunk +0 lines, -149 lines 0 comments Download
M content/content_common.gypi View 1 chunk +0 lines, -2 lines 0 comments Download
M content/renderer/media/android/stream_texture_factory_android.h View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M content/renderer/media/android/stream_texture_factory_android.cc View 1 2 3 4 1 chunk +3 lines, -2 lines 0 comments Download
M content/renderer/media/android/webmediaplayer_android.cc View 1 2 3 3 chunks +8 lines, -4 lines 0 comments Download
M gpu/command_buffer/service/context_group.h View 4 chunks +0 lines, -7 lines 0 comments Download
M gpu/command_buffer/service/context_group.cc View 3 chunks +0 lines, -4 lines 0 comments Download
M gpu/command_buffer/service/context_group_unittest.cc View 1 chunk +1 line, -1 line 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder.h View 1 chunk +0 lines, -1 line 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder.cc View 1 2 3 4 16 chunks +86 lines, -80 lines 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder_mock.h View 1 1 chunk +0 lines, -2 lines 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc View 1 2 3 4 4 chunks +134 lines, -315 lines 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.h View 3 chunks +0 lines, -8 lines 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.cc View 1 chunk +0 lines, -4 lines 0 comments Download
M gpu/command_buffer/service/in_process_command_buffer.cc View 1 chunk +1 line, -1 line 0 comments Download
D gpu/command_buffer/service/stream_texture.h View 1 chunk +0 lines, -32 lines 0 comments Download
D gpu/command_buffer/service/stream_texture_manager.h View 1 chunk +0 lines, -38 lines 0 comments Download
D gpu/command_buffer/service/stream_texture_manager_mock.h View 1 chunk +0 lines, -32 lines 0 comments Download
D gpu/command_buffer/service/stream_texture_manager_mock.cc View 1 chunk +0 lines, -15 lines 0 comments Download
D gpu/command_buffer/service/stream_texture_mock.h View 1 chunk +0 lines, -28 lines 0 comments Download
D gpu/command_buffer/service/stream_texture_mock.cc View 1 chunk +0 lines, -15 lines 0 comments Download
M gpu/command_buffer/service/texture_manager.h View 1 10 chunks +1 line, -39 lines 0 comments Download
M gpu/command_buffer/service/texture_manager.cc View 7 chunks +2 lines, -23 lines 0 comments Download
M gpu/command_buffer/service/texture_manager_unittest.cc View 1 2 3 chunks +49 lines, -9 lines 0 comments Download
M gpu/command_buffer/tests/gl_manager.cc View 1 chunk +0 lines, -1 line 0 comments Download
M gpu/command_buffer_service.gypi View 1 chunk +0 lines, -2 lines 0 comments Download
M gpu/gles2_conform_support/egl/display.cc View 1 chunk +1 line, -1 line 0 comments Download
M gpu/gpu.gyp View 1 chunk +0 lines, -4 lines 0 comments Download
A ui/gl/android/gl_image_stream.h View 1 2 3 4 1 chunk +67 lines, -0 lines 0 comments Download
A ui/gl/android/gl_image_stream.cc View 1 2 3 4 1 chunk +88 lines, -0 lines 0 comments Download
M ui/gl/gl.gyp View 2 chunks +4 lines, -0 lines 0 comments Download
M ui/gl/gl_image.h View 1 2 3 4 3 chunks +16 lines, -2 lines 0 comments Download
M ui/gl/gl_image.cc View 1 2 3 1 chunk +8 lines, -0 lines 0 comments Download
M ui/gl/gl_image_android.cc View 1 2 3 4 2 chunks +14 lines, -0 lines 0 comments Download
M ui/gl/gl_image_mac.cc View 1 2 3 4 1 chunk +15 lines, -0 lines 0 comments Download
A ui/gl/gl_image_mock.h View 1 2 3 4 1 chunk +32 lines, -0 lines 0 comments Download
A + ui/gl/gl_image_mock.cc View 1 chunk +6 lines, -6 lines 0 comments Download
M ui/gl/gl_image_ozone.cc View 1 2 3 4 1 chunk +14 lines, -0 lines 0 comments Download
M ui/gl/gl_image_win.cc View 1 2 3 4 1 chunk +15 lines, -0 lines 0 comments Download
M ui/gl/gl_image_x11.cc View 1 2 3 4 1 chunk +15 lines, -0 lines 0 comments Download

Messages

Total messages: 8 (0 generated)
no sievers
ptal Seems to simplify things a lot and removes a bunch of indirections. Also gets ...
7 years, 4 months ago (2013-08-12 22:58:26 UTC) #1
piman
https://codereview.chromium.org/22824009/diff/1/content/common/gpu/gpu_channel.cc File content/common/gpu/gpu_channel.cc (right): https://codereview.chromium.org/22824009/diff/1/content/common/gpu/gpu_channel.cc#newcode927 content/common/gpu/gpu_channel.cc:927: scoped_refptr<gfx::GLImage> image(image_manager_->LookupImage(stream_id)); I assume the lookup can fail and ...
7 years, 4 months ago (2013-08-12 23:22:07 UTC) #2
no sievers
https://codereview.chromium.org/22824009/diff/1/content/common/gpu/gpu_channel.cc File content/common/gpu/gpu_channel.cc (right): https://codereview.chromium.org/22824009/diff/1/content/common/gpu/gpu_channel.cc#newcode927 content/common/gpu/gpu_channel.cc:927: scoped_refptr<gfx::GLImage> image(image_manager_->LookupImage(stream_id)); On 2013/08/12 23:22:07, piman wrote: > I ...
7 years, 4 months ago (2013-08-13 00:21:35 UTC) #3
reveman
https://codereview.chromium.org/22824009/diff/4001/gpu/command_buffer/service/gles2_cmd_decoder.cc File gpu/command_buffer/service/gles2_cmd_decoder.cc (right): https://codereview.chromium.org/22824009/diff/4001/gpu/command_buffer/service/gles2_cmd_decoder.cc#newcode9450 gpu/command_buffer/service/gles2_cmd_decoder.cc:9450: error::Error GLES2DecoderImpl::HandleCreateStreamTextureCHROMIUM( Could this become CreateStreamImageCHROMIUM and require BindTexImageCHROMIUM ...
7 years, 4 months ago (2013-08-13 00:48:13 UTC) #4
piman
https://codereview.chromium.org/22824009/diff/5044/ui/gl/android/gl_image_stream.cc File ui/gl/android/gl_image_stream.cc (right): https://codereview.chromium.org/22824009/diff/5044/ui/gl/android/gl_image_stream.cc#newcode46 ui/gl/android/gl_image_stream.cc:46: { nit: { on previous line https://codereview.chromium.org/22824009/diff/5044/ui/gl/android/gl_image_stream.cc#newcode53 ui/gl/android/gl_image_stream.cc:53: surface_texture_bridge_->SetFrameAvailableCallback(frame_cb); ...
7 years, 4 months ago (2013-08-13 00:52:04 UTC) #5
no sievers
https://codereview.chromium.org/22824009/diff/4001/gpu/command_buffer/service/gles2_cmd_decoder.cc File gpu/command_buffer/service/gles2_cmd_decoder.cc (right): https://codereview.chromium.org/22824009/diff/4001/gpu/command_buffer/service/gles2_cmd_decoder.cc#newcode9450 gpu/command_buffer/service/gles2_cmd_decoder.cc:9450: error::Error GLES2DecoderImpl::HandleCreateStreamTextureCHROMIUM( On 2013/08/13 00:48:13, David Reveman wrote: > ...
7 years, 4 months ago (2013-08-14 04:01:23 UTC) #6
reveman
https://codereview.chromium.org/22824009/diff/39001/content/common/gpu/gpu_channel.cc File content/common/gpu/gpu_channel.cc (right): https://codereview.chromium.org/22824009/diff/39001/content/common/gpu/gpu_channel.cc#newcode924 content/common/gpu/gpu_channel.cc:924: scoped_refptr<gfx::GLImage> image(image_manager_->LookupImage(stream_id)); LookupStreamImage? to remove the need for AsGLImageStream.. ...
7 years, 4 months ago (2013-08-14 15:22:43 UTC) #7
no sievers
7 years, 4 months ago (2013-08-14 18:16:48 UTC) #8
https://codereview.chromium.org/22824009/diff/39001/content/common/gpu/gpu_ch...
File content/common/gpu/gpu_channel.cc (right):

https://codereview.chromium.org/22824009/diff/39001/content/common/gpu/gpu_ch...
content/common/gpu/gpu_channel.cc:924: scoped_refptr<gfx::GLImage>
image(image_manager_->LookupImage(stream_id));
On 2013/08/14 15:22:44, David Reveman wrote:
> LookupStreamImage? to remove the need for AsGLImageStream..

AsGLImageStream allows me to limit the visibility of derived type to here though
(and hopefully I'll be able to remove the need for it in general).

The common base class in the rest of the code works better with the unit tests.

https://codereview.chromium.org/22824009/diff/39001/gpu/command_buffer/servic...
File gpu/command_buffer/service/gles2_cmd_decoder.cc (right):

https://codereview.chromium.org/22824009/diff/39001/gpu/command_buffer/servic...
gpu/command_buffer/service/gles2_cmd_decoder.cc:1401: void
PrepareTexImageForDraw(Texture* texture);
On 2013/08/14 15:22:44, David Reveman wrote:
> PrepareTextureForRender? and maybe not be specific to textures with GLImage
> attached but include all the logic from PrepareTexturesForRender.

Done.

https://codereview.chromium.org/22824009/diff/39001/gpu/command_buffer/servic...
gpu/command_buffer/service/gles2_cmd_decoder.cc:9492:
image_manager()->AddImage(image, image_id);
On 2013/08/14 15:22:44, David Reveman wrote:
> I thought we decided to track these separably from standard GLImages and use a
> different Id namespace until the usage matches the basic concept of GLImage.
I'm
> ok with using the image manager in the meantime if you just add something like
> ImageManager::Add/RemoveStreamImage() and LookupStreamImage().

See change above. Now that the pattern matches better, can we track them
together?

https://codereview.chromium.org/22824009/diff/39001/ui/gl/gl_image.h
File ui/gl/gl_image.h (right):

https://codereview.chromium.org/22824009/diff/39001/ui/gl/gl_image.h#newcode44
ui/gl/gl_image.h:44: virtual void WillUseTexImage();
On 2013/08/14 15:22:44, David Reveman wrote:
> please move this above all static methods.

Done.

https://codereview.chromium.org/22824009/diff/39001/ui/gl/gl_image.h#newcode52
ui/gl/gl_image.h:52: unsigned int texture_id);
On 2013/08/14 15:22:44, David Reveman wrote:
> I prefer if you didn't add this until the usage matches existing GLImage
usage.

Done.

Powered by Google App Engine
This is Rietveld 408576698