New issue
Advanced search Search tips

Issue 824382 link

Starred by 3 users

Issue metadata

Status: Fixed
Owner:
Closed: Oct 29
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 3
Type: Bug

Blocked on:
issue 825901

Blocking:
issue 644851
issue 899750



Sign in to add a comment

Use Skia DDL in SkiaRenderer to render frames

Project Member Reported by penghuang@chromium.org, Mar 21 2018

Issue description

Use Skia DDL in SkiaRenderer to render frames 
 
Project Member

Comment 1 by bugdroid1@chromium.org, Mar 21 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/1eab1994ee10fe58b342d8d89cb0b22e9f72201c

commit 1eab1994ee10fe58b342d8d89cb0b22e9f72201c
Author: Peng Huang <penghuang@chromium.org>
Date: Wed Mar 21 22:49:21 2018

Add flag --use-skia-deferred-display-list

Also pass the flag to viz via RendererSettings.

This CL is part of CL https://crrev.com/c/947047 which makes
SkiaRenderer use Skia DDL to render frames.

Bug:  824382 
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel
Change-Id: I1d9487afd4fd15925acad234916ebedf6292e7bb
Reviewed-on: https://chromium-review.googlesource.com/973802
Commit-Queue: Peng Huang <penghuang@chromium.org>
Reviewed-by: Sadrul Chowdhury <sadrul@chromium.org>
Reviewed-by: Robert Kroeger <rjkroege@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Cr-Commit-Position: refs/heads/master@{#544887}
[modify] https://crrev.com/1eab1994ee10fe58b342d8d89cb0b22e9f72201c/components/viz/common/display/renderer_settings.h
[modify] https://crrev.com/1eab1994ee10fe58b342d8d89cb0b22e9f72201c/components/viz/host/renderer_settings_creation.cc
[modify] https://crrev.com/1eab1994ee10fe58b342d8d89cb0b22e9f72201c/services/viz/privileged/interfaces/compositing/renderer_settings.mojom
[modify] https://crrev.com/1eab1994ee10fe58b342d8d89cb0b22e9f72201c/services/viz/privileged/interfaces/compositing/renderer_settings_struct_traits.cc
[modify] https://crrev.com/1eab1994ee10fe58b342d8d89cb0b22e9f72201c/services/viz/privileged/interfaces/compositing/renderer_settings_struct_traits.h
[modify] https://crrev.com/1eab1994ee10fe58b342d8d89cb0b22e9f72201c/ui/base/ui_base_switches.cc
[modify] https://crrev.com/1eab1994ee10fe58b342d8d89cb0b22e9f72201c/ui/base/ui_base_switches.h

Project Member

Comment 2 by bugdroid1@chromium.org, Mar 22 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/fb0cf370e97f82d3419cfab61eec4fa59120479b

commit fb0cf370e97f82d3419cfab61eec4fa59120479b
Author: Peng Huang <penghuang@chromium.org>
Date: Thu Mar 22 17:29:27 2018

GpuServiceImpl: add a GLContext and a GrContext

This CL adds a GLContext and a GrContext in GpuServiceImpl. They are
created when viz::SkiaOutputSurface needs a GrContext to create a SkSurface
for the framebuffer. This CL also creates a SequenceId for
viz::SkiaOutputSurface to play back Skia DDLs on the GPU thread.

This CL is part of CL https://crrev.com/c/947047 which makes
SkiaRenderer use Skia DDL to render frames.

Bug:  824382 
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel
Change-Id: I9091fd46cbaafe0ace363bfe63e61b5a0d9fe32d
Reviewed-on: https://chromium-review.googlesource.com/973757
Commit-Queue: Peng Huang <penghuang@chromium.org>
Reviewed-by: Robert Kroeger <rjkroege@chromium.org>
Cr-Commit-Position: refs/heads/master@{#545129}
[modify] https://crrev.com/fb0cf370e97f82d3419cfab61eec4fa59120479b/components/viz/service/gl/gpu_service_impl.cc
[modify] https://crrev.com/fb0cf370e97f82d3419cfab61eec4fa59120479b/components/viz/service/gl/gpu_service_impl.h

Project Member

Comment 3 by bugdroid1@chromium.org, Mar 22 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/1f5d22cad136d4880ce1af4f886883d395d6d86b

commit 1f5d22cad136d4880ce1af4f886883d395d6d86b
Author: Peng Huang <penghuang@chromium.org>
Date: Thu Mar 22 17:51:17 2018

cc::DisplayResourceProivder: Add method GetResourceMetadataForExternalUse

This method will be used by viz::SkiaRenderer to get a resource
metadata, and then the viz::SkiaRenderer will make a SkImage by
SkDeferredDisplayListRecorder::makePromiseTexture(), and then draw the
SkImage to a Skia DDL which will be played back on GPU thread later.

This CL is part of CL https://crrev.com/c/947047 which makes
SkiaRenderer use Skia DDL to render frames.

Bug:  824382 
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: Ie182ee9f8ebba0f6f838e6fb191f84b97ee43545
Reviewed-on: https://chromium-review.googlesource.com/973806
Reviewed-by: Robert Kroeger <rjkroege@chromium.org>
Reviewed-by: danakj <danakj@chromium.org>
Commit-Queue: Peng Huang <penghuang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#545145}
[modify] https://crrev.com/1f5d22cad136d4880ce1af4f886883d395d6d86b/cc/resources/display_resource_provider.cc
[modify] https://crrev.com/1f5d22cad136d4880ce1af4f886883d395d6d86b/cc/resources/display_resource_provider.h
[modify] https://crrev.com/1f5d22cad136d4880ce1af4f886883d395d6d86b/components/viz/common/BUILD.gn
[add] https://crrev.com/1f5d22cad136d4880ce1af4f886883d395d6d86b/components/viz/common/resources/resource_metadata.cc
[add] https://crrev.com/1f5d22cad136d4880ce1af4f886883d395d6d86b/components/viz/common/resources/resource_metadata.h

Blockedon: 825901
Project Member

Comment 5 by bugdroid1@chromium.org, Apr 6 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/97ba9e6ba455c36022dcb344e6d6c46d4acd4e93

commit 97ba9e6ba455c36022dcb344e6d6c46d4acd4e93
Author: Peng Huang <penghuang@chromium.org>
Date: Fri Apr 06 02:17:30 2018

cc::DisplayResourceProvider: Add {Lock,Unlock}ForExternalUse.

Add {Lock,Unlock}ForExternalUse to replace
GetResourceMetadataForExternalUse. It is because the sync_token for
GetResourceMetadataForExternalUse should be considered as unverified sync
token due to the task (which will release the token) is not scheduled
when calling GetResourceMetadataForExternalUse. It will cause
problems, if the we return resources with the token to child before
calling the SwapBuffers(which will schedule a GPU task to SwapBuffers
and release the sync token). This case will not happen right now, but it
is better to not assume it will not happen in future.

Bug:  824382 
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: I59de9191d3405ca64704b00bedd71564812394a4
Reviewed-on: https://chromium-review.googlesource.com/986505
Reviewed-by: enne <enne@chromium.org>
Commit-Queue: Peng Huang <penghuang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#548641}
[modify] https://crrev.com/97ba9e6ba455c36022dcb344e6d6c46d4acd4e93/cc/BUILD.gn
[modify] https://crrev.com/97ba9e6ba455c36022dcb344e6d6c46d4acd4e93/cc/resources/display_resource_provider.cc
[modify] https://crrev.com/97ba9e6ba455c36022dcb344e6d6c46d4acd4e93/cc/resources/display_resource_provider.h
[add] https://crrev.com/97ba9e6ba455c36022dcb344e6d6c46d4acd4e93/cc/resources/display_resource_provider_unittest.cc
[modify] https://crrev.com/97ba9e6ba455c36022dcb344e6d6c46d4acd4e93/components/viz/common/resources/resource.cc
[modify] https://crrev.com/97ba9e6ba455c36022dcb344e6d6c46d4acd4e93/components/viz/common/resources/resource.h

Comment 6 by xing...@intel.com, Apr 24 2018

Cc: xing...@intel.com
Project Member

Comment 7 by bugdroid1@chromium.org, Apr 25 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa

commit b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa
Author: Peng Huang <penghuang@chromium.org>
Date: Wed Apr 25 23:23:06 2018

SkiaRenderer: Add SkiaOutputSurface to allow SkiaRenderer to use SkDDL

This CL adds a new interface viz::SkiaOutputSurface which extends
viz::OutputSurface for SkiaRenderer to support compositing with SkDDL
(skia deferred display list). SkiaRenderer draws quads into a DDL SkCanvas,
and draw operations will be recorded into a DDL.
In OutputSurface::SwapBuffers(), a GPU task will be scheduled with
gpu::Schduler. The task will be executed on the GPU thread when all resource
sync tokes are satisfied. The task will play the DDL back on a GrContext
which is backed by a native platform GL context.

We have a goal to use SkiaRenderer everywhere, and remove GLRenderer and
Software Compositor. The new viz::SkiaOutputSurface interface and
viz::OutputSurface interface will be merged into one interface when DirectRenderer
subclasses are removed. The new interface is for making development
faster because when we change methods in viz::SkiaOutputSurface, we will not break
all other existing OutputSurface implementations.

Bug:  824382 
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel;master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2;luci.chromium.try:win_optional_gpu_tests_rel
Change-Id: I776a76dc8496d40f88950856867596f5c44f735f
Reviewed-on: https://chromium-review.googlesource.com/978366
Commit-Queue: Peng Huang <penghuang@chromium.org>
Reviewed-by: Antoine Labour <piman@chromium.org>
Reviewed-by: Robert Kroeger <rjkroege@chromium.org>
Cr-Commit-Position: refs/heads/master@{#553815}
[modify] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/components/viz/service/BUILD.gn
[modify] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/components/viz/service/display/display.cc
[modify] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/components/viz/service/display/display.h
[add] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/components/viz/service/display/skia_output_surface.cc
[add] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/components/viz/service/display/skia_output_surface.h
[modify] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/components/viz/service/display/skia_renderer.cc
[modify] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/components/viz/service/display/skia_renderer.h
[modify] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/components/viz/service/display_embedder/DEPS
[modify] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/components/viz/service/display_embedder/gpu_display_provider.cc
[modify] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/components/viz/service/display_embedder/gpu_display_provider.h
[add] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/components/viz/service/display_embedder/skia_output_surface_impl.cc
[add] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/components/viz/service/display_embedder/skia_output_surface_impl.h
[modify] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/components/viz/service/main/viz_main_impl.cc
[modify] https://crrev.com/b0478d0c86e6c90c497a8c3cffd0dc4077ae0efa/gpu/command_buffer/common/constants.h

Project Member

Comment 8 by bugdroid1@chromium.org, May 8 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/eb61ee645a5061d91b115661d3774b7be7cf97a4

commit eb61ee645a5061d91b115661d3774b7be7cf97a4
Author: Peng Huang <penghuang@chromium.org>
Date: Tue May 08 17:29:38 2018

SkiaOutputSurface: Move GPU related code into SkiaOutputSurfaceImplOnGpu

This CL moves GPU related code in SkiaOutputSurfaceImpl into a new class
SkiaOutputSurfaceImplOnGpu. This new class is created, used and destroyed
on the GPU thread.

Bug:  824382 
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel
Change-Id: Ib5809b1b42b73e296344be4459058b52b36fee6a
Reviewed-on: https://chromium-review.googlesource.com/1017237
Commit-Queue: Peng Huang <penghuang@chromium.org>
Reviewed-by: Robert Kroeger <rjkroege@chromium.org>
Cr-Commit-Position: refs/heads/master@{#556851}
[modify] https://crrev.com/eb61ee645a5061d91b115661d3774b7be7cf97a4/components/viz/service/BUILD.gn
[modify] https://crrev.com/eb61ee645a5061d91b115661d3774b7be7cf97a4/components/viz/service/display_embedder/skia_output_surface_impl.cc
[modify] https://crrev.com/eb61ee645a5061d91b115661d3774b7be7cf97a4/components/viz/service/display_embedder/skia_output_surface_impl.h
[add] https://crrev.com/eb61ee645a5061d91b115661d3774b7be7cf97a4/components/viz/service/display_embedder/skia_output_surface_impl_on_gpu.cc
[add] https://crrev.com/eb61ee645a5061d91b115661d3774b7be7cf97a4/components/viz/service/display_embedder/skia_output_surface_impl_on_gpu.h

Project Member

Comment 9 by bugdroid1@chromium.org, Jun 7 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/fecdf6686aa73e4fc3d1f6335e1ca7ab931654ce

commit fecdf6686aa73e4fc3d1f6335e1ca7ab931654ce
Author: Peng Huang <penghuang@chromium.org>
Date: Thu Jun 07 16:34:58 2018

SkiaOutputSurface: Fix a crash related to presnetation feedback

Bug:  824382 ,  727775 
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel
Change-Id: If75f42895bfc2a41ec3c4cf1bbe0e24b37743c36
Reviewed-on: https://chromium-review.googlesource.com/1089041
Reviewed-by: Sadrul Chowdhury <sadrul@chromium.org>
Commit-Queue: Peng Huang <penghuang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#565292}
[modify] https://crrev.com/fecdf6686aa73e4fc3d1f6335e1ca7ab931654ce/components/viz/service/display_embedder/skia_output_surface_impl_on_gpu.cc

Project Member

Comment 10 by bugdroid1@chromium.org, Jun 20 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/71f313defc2622c2a2ec917ac95bd9a2eddd3136

commit 71f313defc2622c2a2ec917ac95bd9a2eddd3136
Author: Peng Huang <penghuang@chromium.org>
Date: Wed Jun 20 14:59:42 2018

Implement SkiaRenderer::CopyDrawnRenderPass() for SkDDL and enable pixel tests.

Implement SkiaRenderer::CopyDrawnRenderPass() by posting a task to GPU main
thread to copy output from offscreen SkSurface for render passes or the
framebuffer SkSurface for the frame.

This CL also enable all existing pixel tests with SkaRenderer + SkDDL code path.


Bug:  824382 
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: I707d555c2973eb81294b29b813d4538ab671a3c0
Reviewed-on: https://chromium-review.googlesource.com/1089451
Reviewed-by: Ken Rockot <rockot@chromium.org>
Reviewed-by: Antoine Labour <piman@chromium.org>
Reviewed-by: danakj <danakj@chromium.org>
Reviewed-by: Robert Kroeger <rjkroege@chromium.org>
Commit-Queue: Peng Huang <penghuang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#568841}
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/cc/BUILD.gn
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/cc/test/DEPS
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/cc/test/pixel_test.cc
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/cc/test/pixel_test.h
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/components/viz/service/display/display.cc
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/components/viz/service/display/display_resource_provider.cc
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/components/viz/service/display/gl_renderer_unittest.cc
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/components/viz/service/display/renderer_pixeltest.cc
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/components/viz/service/display/skia_output_surface.h
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/components/viz/service/display/skia_renderer.cc
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/components/viz/service/display/skia_renderer.h
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/components/viz/service/display_embedder/in_process_gpu_memory_buffer_manager.h
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/components/viz/service/display_embedder/skia_output_surface_impl.cc
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/components/viz/service/display_embedder/skia_output_surface_impl.h
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/components/viz/service/display_embedder/skia_output_surface_impl_on_gpu.cc
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/components/viz/service/display_embedder/skia_output_surface_impl_on_gpu.h
[modify] https://crrev.com/71f313defc2622c2a2ec917ac95bd9a2eddd3136/components/viz/service/gl/gpu_service_impl.cc

Project Member

Comment 11 by bugdroid1@chromium.org, Jun 25 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/cf21788eb258f590f4180773922e0a6d7f141f23

commit cf21788eb258f590f4180773922e0a6d7f141f23
Author: Peng Huang <penghuang@chromium.org>
Date: Mon Jun 25 19:20:50 2018

Do not create a temp offscreen surface during shutdown

Bug:  824382 
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel
Change-Id: If3d967a2b90f8910fd696ddd8bddc741d4f9ecc5
Reviewed-on: https://chromium-review.googlesource.com/1110020
Reviewed-by: Antoine Labour <piman@chromium.org>
Commit-Queue: Peng Huang <penghuang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#570127}
[modify] https://crrev.com/cf21788eb258f590f4180773922e0a6d7f141f23/components/viz/service/gl/gpu_service_impl.cc

Project Member

Comment 12 by bugdroid1@chromium.org, Oct 12

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/33ca177f048a1d593c5486b46f09ac9ea91071a9

commit 33ca177f048a1d593c5486b46f09ac9ea91071a9
Author: Peng Huang <penghuang@chromium.org>
Date: Fri Oct 12 13:39:05 2018

Hook up skia makeYUVAPromiseTexture API

Know issues:
 * Skia only draws Y plane.
 * makeYUVAPromiseTexture() will release context, even if it failed.
 * Skia doesn't accept GL_RGBA8 format for a yuva plane

Bug:  824382 
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel
Change-Id: Ic8da2b3de574ef2a0d527c79f34d383a676a3bc0
Reviewed-on: https://chromium-review.googlesource.com/c/1262421
Reviewed-by: Antoine Labour <piman@chromium.org>
Commit-Queue: Peng Huang <penghuang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#599193}
[modify] https://crrev.com/33ca177f048a1d593c5486b46f09ac9ea91071a9/components/viz/service/display/skia_output_surface.h
[modify] https://crrev.com/33ca177f048a1d593c5486b46f09ac9ea91071a9/components/viz/service/display/skia_renderer.cc
[modify] https://crrev.com/33ca177f048a1d593c5486b46f09ac9ea91071a9/components/viz/service/display_embedder/skia_output_surface_impl.cc
[modify] https://crrev.com/33ca177f048a1d593c5486b46f09ac9ea91071a9/components/viz/service/display_embedder/skia_output_surface_impl.h
[modify] https://crrev.com/33ca177f048a1d593c5486b46f09ac9ea91071a9/components/viz/service/display_embedder/skia_output_surface_impl_on_gpu.cc
[modify] https://crrev.com/33ca177f048a1d593c5486b46f09ac9ea91071a9/components/viz/service/display_embedder/skia_output_surface_impl_on_gpu.h

Blockedon: 895568
Blockedon: 895874
Blocking: 898270
Blocking:
Labels: vulkanize
Labels: -vulkanize Proj-Vulkanize
Blocking: -898270 899750
Can you update this bug's description to make it clear what else needs to be done?
Blockedon: -895568 -895874
Status: Fixed (was: Assigned)
I think this issue can be considered as done. 
 issue 895568  issue 895874 can be tracked by the new mate issue.
Blocking: 644851

Sign in to add a comment