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

Issue 938873002: Add a new API to create a surfaceless GLSurface for Ozone (Closed)

Created:
5 years, 10 months ago by achaulk
Modified:
5 years, 9 months ago
CC:
chromium-reviews, ozone-reviews_chromium.org, posciak+watch_chromium.org, jam, mcasas+watch_chromium.org, feature-media-reviews_chromium.org, darin-cc_chromium.org, kalyank, piman+watch_chromium.org, wjia+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Add a new API to create a surfaceless GLSurface for Ozone Reverting CreateViewGLSurface to creating a surface that works as expected Chrome uses the new surfaceless API, all others use the old one BUG=447798 Committed: https://crrev.com/e86e411c3038fd5be67438da29f0ff17828f226f Cr-Commit-Position: refs/heads/master@{#318786}

Patch Set 1 #

Patch Set 2 : #

Total comments: 4

Patch Set 3 : #

Patch Set 4 : #

Total comments: 7

Patch Set 5 : remove deps, add some missing EXTs #

Total comments: 4

Patch Set 6 : move dtor to Destroy(), fix binding #

Patch Set 7 : #

Total comments: 1

Patch Set 8 : fix swapbuffers & overlay scheduling #

Total comments: 34

Patch Set 9 : #

Patch Set 10 : switch to ScopedTextureBinder #

Patch Set 11 : rebase #

Patch Set 12 : synchronous swapbuffers #

Total comments: 4

Patch Set 13 : #

Patch Set 14 : revert vsyncprovider change, change renderinghelper to not rely on the vsync cb #

Patch Set 15 : add missing #if USE_OZONE #

Patch Set 16 : dont need to modify vsync update path with synchronous swapbuffers now #

Unified diffs Side-by-side diffs Delta from patch set Stats (+210 lines, -9 lines) Patch
M content/common/gpu/image_transport_surface_linux.cc View 1 2 3 4 5 6 7 8 1 chunk +7 lines, -3 lines 0 comments Download
M content/common/gpu/media/rendering_helper.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 6 chunks +17 lines, -4 lines 0 comments Download
M ui/gl/gl_surface.h View 1 2 3 4 5 6 7 8 1 chunk +9 lines, -0 lines 0 comments Download
M ui/gl/gl_surface_ozone.cc View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +177 lines, -2 lines 0 comments Download

Messages

Total messages: 39 (6 generated)
achaulk
This should fix the VDA test breakage
5 years, 10 months ago (2015-02-18 23:56:49 UTC) #2
dnicoara
https://codereview.chromium.org/938873002/diff/20001/ui/gl/gl_surface_ozone.cc File ui/gl/gl_surface_ozone.cc (right): https://codereview.chromium.org/938873002/diff/20001/ui/gl/gl_surface_ozone.cc#newcode214 ui/gl/gl_surface_ozone.cc:214: void BindFB() { I think this can be private, ...
5 years, 10 months ago (2015-02-19 00:10:13 UTC) #3
achaulk
https://codereview.chromium.org/938873002/diff/20001/ui/gl/gl_surface_ozone.cc File ui/gl/gl_surface_ozone.cc (right): https://codereview.chromium.org/938873002/diff/20001/ui/gl/gl_surface_ozone.cc#newcode214 ui/gl/gl_surface_ozone.cc:214: void BindFB() { On 2015/02/19 00:10:13, dnicoara wrote: > ...
5 years, 10 months ago (2015-02-19 00:19:06 UTC) #4
dnicoara
lgtm
5 years, 10 months ago (2015-02-19 00:32:06 UTC) #5
Pawel Osciak
content/common/gpu/media LGTM
5 years, 10 months ago (2015-02-19 00:33:24 UTC) #7
achaulk
+piman for ui/gl, content
5 years, 10 months ago (2015-02-19 00:34:56 UTC) #9
spang
https://codereview.chromium.org/938873002/diff/60001/content/common/gpu/image_transport_surface_linux.cc File content/common/gpu/image_transport_surface_linux.cc (right): https://codereview.chromium.org/938873002/diff/60001/content/common/gpu/image_transport_surface_linux.cc#newcode17 content/common/gpu/image_transport_surface_linux.cc:17: #if USE_OZONE Don't you need to take the flag ...
5 years, 10 months ago (2015-02-19 00:42:04 UTC) #10
achaulk
https://codereview.chromium.org/938873002/diff/60001/content/common/gpu/image_transport_surface_linux.cc File content/common/gpu/image_transport_surface_linux.cc (right): https://codereview.chromium.org/938873002/diff/60001/content/common/gpu/image_transport_surface_linux.cc#newcode17 content/common/gpu/image_transport_surface_linux.cc:17: #if USE_OZONE On 2015/02/19 00:42:04, spang wrote: > Don't ...
5 years, 10 months ago (2015-02-19 00:43:07 UTC) #11
spang
https://codereview.chromium.org/938873002/diff/60001/content/common/gpu/image_transport_surface_linux.cc File content/common/gpu/image_transport_surface_linux.cc (right): https://codereview.chromium.org/938873002/diff/60001/content/common/gpu/image_transport_surface_linux.cc#newcode17 content/common/gpu/image_transport_surface_linux.cc:17: #if USE_OZONE On 2015/02/19 00:43:07, achaulk wrote: > On ...
5 years, 10 months ago (2015-02-19 00:49:27 UTC) #12
spang
5 years, 10 months ago (2015-02-19 00:49:28 UTC) #13
achaulk
https://codereview.chromium.org/938873002/diff/60001/content/common/gpu/media/rendering_helper.cc File content/common/gpu/media/rendering_helper.cc (right): https://codereview.chromium.org/938873002/diff/60001/content/common/gpu/media/rendering_helper.cc#newcode710 content/common/gpu/media/rendering_helper.cc:710: tex_flip = 0; On 2015/02/19 00:49:26, spang wrote: > ...
5 years, 10 months ago (2015-02-19 00:54:51 UTC) #14
piman
https://codereview.chromium.org/938873002/diff/80001/ui/gl/gl_surface_ozone.cc File ui/gl/gl_surface_ozone.cc (right): https://codereview.chromium.org/938873002/diff/80001/ui/gl/gl_surface_ozone.cc#newcode248 ui/gl/gl_surface_ozone.cc:248: glBindFramebufferEXT(GL_FRAMEBUFFER, 0); This is too late to do GL ...
5 years, 10 months ago (2015-02-19 23:21:19 UTC) #16
Pawel Osciak
On 2015/02/18 23:56:49, achaulk wrote: > This should fix the VDA test breakage I applied ...
5 years, 10 months ago (2015-02-20 04:07:20 UTC) #17
achaulk
On 2015/02/20 04:07:20, Pawel Osciak wrote: > On 2015/02/18 23:56:49, achaulk wrote: > > This ...
5 years, 10 months ago (2015-02-20 08:00:34 UTC) #18
achaulk
There were a couple issues yeah, I was using the old EGL binding when it ...
5 years, 10 months ago (2015-02-23 20:43:10 UTC) #19
dnicoara
https://codereview.chromium.org/938873002/diff/120001/content/common/gpu/media/rendering_helper.cc File content/common/gpu/media/rendering_helper.cc (right): https://codereview.chromium.org/938873002/diff/120001/content/common/gpu/media/rendering_helper.cc#newcode316 content/common/gpu/media/rendering_helper.cc:316: gl_surface_->Resize(platform_window_delegate_->GetSize()); You shouldn't access the |platform_window_delegate_| from here since ...
5 years, 10 months ago (2015-02-23 22:48:27 UTC) #20
achaulk
https://codereview.chromium.org/938873002/diff/140001/content/common/gpu/media/rendering_helper.cc File content/common/gpu/media/rendering_helper.cc (right): https://codereview.chromium.org/938873002/diff/140001/content/common/gpu/media/rendering_helper.cc#newcode508 content/common/gpu/media/rendering_helper.cc:508: gl_surface_->Destroy(); On 2015/02/23 22:48:26, dnicoara wrote: > This shouldn't ...
5 years, 10 months ago (2015-02-23 22:50:17 UTC) #21
Pawel Osciak
On 2015/02/23 20:43:10, achaulk wrote: > There were a couple issues yeah, I was using ...
5 years, 10 months ago (2015-02-23 23:43:44 UTC) #22
Pawel Osciak
Was this compiled and tested for x86 when USE_OZONE is not defined and also for ...
5 years, 10 months ago (2015-02-24 00:13:47 UTC) #23
piman
https://codereview.chromium.org/938873002/diff/140001/ui/gl/gl_surface_ozone.cc File ui/gl/gl_surface_ozone.cc (right): https://codereview.chromium.org/938873002/diff/140001/ui/gl/gl_surface_ozone.cc#newcode328 ui/gl/gl_surface_ozone.cc:328: GLuint textures_[2]; On 2015/02/24 00:13:47, Pawel Osciak wrote: > ...
5 years, 10 months ago (2015-02-24 02:57:32 UTC) #24
piman
https://codereview.chromium.org/938873002/diff/140001/ui/gl/gl_surface_ozone.cc File ui/gl/gl_surface_ozone.cc (right): https://codereview.chromium.org/938873002/diff/140001/ui/gl/gl_surface_ozone.cc#newcode241 ui/gl/gl_surface_ozone.cc:241: return SwapBuffersAsync(base::Bind(&EmptyCallback)); On 2015/02/23 22:48:26, dnicoara wrote: > This ...
5 years, 10 months ago (2015-02-24 03:00:57 UTC) #25
Pawel Osciak
On 2015/02/24 02:57:32, piman (Very slow to review) wrote: > https://codereview.chromium.org/938873002/diff/140001/ui/gl/gl_surface_ozone.cc > File ui/gl/gl_surface_ozone.cc (right): ...
5 years, 10 months ago (2015-02-24 03:40:16 UTC) #26
dnicoara
https://codereview.chromium.org/938873002/diff/140001/ui/gl/gl_surface_ozone.cc File ui/gl/gl_surface_ozone.cc (right): https://codereview.chromium.org/938873002/diff/140001/ui/gl/gl_surface_ozone.cc#newcode258 ui/gl/gl_surface_ozone.cc:258: if (fbo_) { Should probably reset these values and ...
5 years, 10 months ago (2015-02-24 16:46:53 UTC) #27
achaulk
https://codereview.chromium.org/938873002/diff/140001/content/common/gpu/image_transport_surface_linux.cc File content/common/gpu/image_transport_surface_linux.cc (right): https://codereview.chromium.org/938873002/diff/140001/content/common/gpu/image_transport_surface_linux.cc#newcode20 content/common/gpu/image_transport_surface_linux.cc:20: if (!surface.get()) On 2015/02/24 00:13:46, Pawel Osciak wrote: > ...
5 years, 10 months ago (2015-02-24 19:07:21 UTC) #28
achaulk
With lionel's recent ozone change we should be able to use the synchronous SwapBuffers here
5 years, 9 months ago (2015-02-27 20:37:31 UTC) #29
piman
One thing, and LGTM after that. https://codereview.chromium.org/938873002/diff/220001/ui/gl/gl_surface_ozone.cc File ui/gl/gl_surface_ozone.cc (right): https://codereview.chromium.org/938873002/diff/220001/ui/gl/gl_surface_ozone.cc#newcode275 ui/gl/gl_surface_ozone.cc:275: for (size_t i ...
5 years, 9 months ago (2015-02-27 21:53:26 UTC) #30
achaulk
https://codereview.chromium.org/938873002/diff/220001/ui/gl/gl_surface_ozone.cc File ui/gl/gl_surface_ozone.cc (right): https://codereview.chromium.org/938873002/diff/220001/ui/gl/gl_surface_ozone.cc#newcode275 ui/gl/gl_surface_ozone.cc:275: for (size_t i = 0; i < arraysize(textures_); i++) ...
5 years, 9 months ago (2015-02-27 22:00:10 UTC) #31
piman
On Fri, Feb 27, 2015 at 2:00 PM, <achaulk@chromium.org> wrote: > > https://codereview.chromium.org/938873002/diff/220001/ui/ > gl/gl_surface_ozone.cc ...
5 years, 9 months ago (2015-02-27 22:33:30 UTC) #32
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/938873002/300001
5 years, 9 months ago (2015-03-02 22:41:36 UTC) #35
commit-bot: I haz the power
Committed patchset #16 (id:300001)
5 years, 9 months ago (2015-03-02 22:45:50 UTC) #36
commit-bot: I haz the power
Patchset 16 (id:??) landed as https://crrev.com/e86e411c3038fd5be67438da29f0ff17828f226f Cr-Commit-Position: refs/heads/master@{#318786}
5 years, 9 months ago (2015-03-02 22:46:30 UTC) #37
gunsch
On 2015/03/02 22:46:30, I haz the power (commit-bot) wrote: > Patchset 16 (id:??) landed as ...
5 years, 9 months ago (2015-03-02 23:43:11 UTC) #38
gunsch
5 years, 9 months ago (2015-03-03 00:31:12 UTC) #39
Message was sent while issue was closed.
On 2015/03/02 23:43:11, gunsch wrote:
> On 2015/03/02 22:46:30, I haz the power (commit-bot) wrote:
> > Patchset 16 (id:??) landed as
> > https://crrev.com/e86e411c3038fd5be67438da29f0ff17828f226f
> > Cr-Commit-Position: refs/heads/master@{#318786}
> 
> Broke clang ozone build for Chromecast. trybot not yet automatic, but can see
> failure at
>
http://build.chromium.org/p/tryserver.chromium.linux/builders/cast_shell/buil...
> 
> 
> FAILED: /b/build/goma/gomacc
> ../../third_party/llvm-build/Release+Asserts/bin/clang++ -MMD -MF
> obj/ui/gl/gl.gl_surface_ozone.o.d -DV8_DEPRECATION_WARNINGS
> -D_FILE_OFFSET_BITS=64 -DCHROMIUM_BUILD -DCR_CLANG_REVISION=223108
> -DUI_COMPOSITOR_IMAGE_TRANSPORT -DUSE_AURA=1 -DUSE_OZONE=1
> -DUSE_DEFAULT_RENDER_THEME=1 -DUSE_LIBJPEG_TURBO=1 -DENABLE_ONE_CLICK_SIGNIN
> -DENABLE_PRE_SYNC_BACKUP -DENABLE_WEBRTC=1 -DUSE_PROPRIETARY_CODECS
> -DENABLE_MPEG2TS_STREAM_PARSER -DENABLE_BROWSER_CDMS
> -DENABLE_CONFIGURATION_POLICY -DENABLE_NOTIFICATIONS
-DDONT_EMBED_BUILD_METADATA
> -DLOG_DISABLED=0 -DENABLE_TASK_MANAGER=1 -DENABLE_EXTENSIONS=1
> -DENABLE_SESSION_SERVICE=1 -DENABLE_THEMES=1 -DENABLE_BACKGROUND=1
> -DENABLE_GOOGLE_NOW=1 -DCLD_VERSION=2 -DENABLE_SPELLCHECK=1
> -DENABLE_CAPTIVE_PORTAL_DETECTION=1 -DENABLE_APP_LIST=1
-DENABLE_SETTINGS_APP=1
> -DENABLE_SUPERVISED_USERS=1 -DENABLE_MDNS=1 -DENABLE_SERVICE_DISCOVERY=1
> -DGL_IMPLEMENTATION -DSK_SUPPORT_GPU=1 -DSK_LEGACY_DRAWPICTURECALLBACK
> -DMESA_EGL_NO_X11_HEADERS -DU_USING_ICU_NAMESPACE=0 -DU_ENABLE_DYLOAD=0
> -DU_STATIC_IMPLEMENTATION -DUSE_LIBPCI=1 -DUSE_NSS=1 -D__STDC_CONSTANT_MACROS
> -D__STDC_FORMAT_MACROS -DDYNAMIC_ANNOTATIONS_ENABLED=1
> -DWTF_USE_DYNAMIC_ANNOTATIONS=1 -D_DEBUG -D_GLIBCXX_DEBUG=1 -Igen
> -I../../third_party/swiftshader/include -I../../third_party/khronos
-I../../gpu
> -I../.. -I../../skia/config -I../../third_party/skia/src/core
> -I../../third_party/skia/include/core -I../../third_party/skia/include/effects
> -I../../third_party/skia/include/pdf -I../../third_party/skia/include/gpu
> -I../../third_party/skia/include/lazy -I../../third_party/skia/include/pathops
> -I../../third_party/skia/include/pipe -I../../third_party/skia/include/ports
> -I../../third_party/skia/include/utils -I../../skia/ext
> -I../../third_party/mesa/src/include -I../../third_party/icu/source/i18n
> -I../../third_party/icu/source/common -fstack-protector
> --param=ssp-buffer-size=4 -Werror -pthread -fno-strict-aliasing -Wall
> -Wno-unused-parameter -Wno-missing-field-initializers -fvisibility=hidden
-pipe
> -fPIC -Wno-reserved-user-defined-literal -Xclang -load -Xclang
>
/b/build/slave/cast_shell/build/src/third_party/llvm-build/Release+Asserts/lib/libFindBadConstructs.so
> -Xclang -add-plugin -Xclang find-bad-constructs -Xclang
> -plugin-arg-find-bad-constructs -Xclang check-weak-ptr-factory-order -Xclang
> -plugin-arg-find-bad-constructs -Xclang strict-virtual-specifiers
> -fcolor-diagnostics
>
-B/b/build/slave/cast_shell/build/src/third_party/binutils/Linux_x64/Release/bin
> -Wheader-hygiene -Wno-char-subscripts -Wno-unneeded-internal-declaration
> -Wno-covered-switch-default -Wstring-conversion -Wno-c++11-narrowing
> -Wno-deprecated-register -Wno-inconsistent-missing-override -m64 -march=x86-64
> -O0 -g -gdwarf-4 -funwind-tables -gsplit-dwarf -Wno-undefined-bool-conversion
> -Wno-tautological-undefined-compare -fno-exceptions -fno-rtti
> -fno-threadsafe-statics -fvisibility-inlines-hidden -Wsign-compare
-std=gnu++11 
> -c ../../ui/gl/gl_surface_ozone.cc -o obj/ui/gl/gl.gl_surface_ozone.o
> ../../ui/gl/gl_surface_ozone.cc:284:9: error: [chromium-style] Classes that
are
> ref-counted should have explicit destructors that are declared protected or
> private.
>   class SurfaceImage : public GLImageLinuxDMABuffer {
>         ^
> ../../ui/gl/gl_surface_ozone.cc:284:24: note: [chromium-style] 'SurfaceImage'
> inherits from 'gfx::GLImageLinuxDMABuffer' here
>   class SurfaceImage : public GLImageLinuxDMABuffer {
>                        ^
> ../../ui/gl/gl_image_linux_dma_buffer.h:13:41: note: [chromium-style]
> 'GLImageLinuxDMABuffer' inherits from 'gfx::GLImageEGL' here
> class GL_EXPORT GLImageLinuxDMABuffer : public GLImageEGL {
>                                         ^
> ../../ui/gl/gl_image_egl.h:13:30: note: [chromium-style] 'GLImageEGL' inherits
> from 'gfx::GLImage' here
> class GL_EXPORT GLImageEGL : public GLImage {
>                              ^
> ../../ui/gl/gl_image.h:20:27: note: [chromium-style] 'GLImage' inherits from
> 'base::RefCounted<GLImage>' here
> class GL_EXPORT GLImage : public base::RefCounted<GLImage> {
>                           ^
> 1 error generated.

I mailed a fix at https://codereview.chromium.org/967343003

Powered by Google App Engine
This is Rietveld 408576698