New issue
Advanced search Search tips

Issue 777636 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Feb 2018
Cc:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Feature

Blocking:
issue 737629



Sign in to add a comment

Add SkImageFilter serialization for oop raster

Project Member Reported by enne@chromium.org, Oct 23 2017

Issue description

Status: Started (was: Assigned)
Project Member

Comment 2 by bugdroid1@chromium.org, Nov 10 2017

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

commit 7b5465786451393d3a7e9614f4d83278bf36e03e
Author: Khushal <khushalsagar@chromium.org>
Date: Fri Nov 10 22:05:53 2017

cc: Add methods for complete serialization of PaintOpBuffers.

Add support for serializing complete PaintOpBuffers for records present
in PaintFlags (PaintShader, SkImageFilter, etc.).

R=enne@chromium.org

Bug:  777636 
Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel
Change-Id: Icbf853cae18b43c12ad9ada2b5826d689c52af81
Reviewed-on: https://chromium-review.googlesource.com/754362
Commit-Queue: Khushal <khushalsagar@chromium.org>
Reviewed-by: enne <enne@chromium.org>
Reviewed-by: Antoine Labour <piman@chromium.org>
Cr-Commit-Position: refs/heads/master@{#515707}
[modify] https://crrev.com/7b5465786451393d3a7e9614f4d83278bf36e03e/cc/paint/BUILD.gn
[modify] https://crrev.com/7b5465786451393d3a7e9614f4d83278bf36e03e/cc/paint/paint_op_buffer.cc
[modify] https://crrev.com/7b5465786451393d3a7e9614f4d83278bf36e03e/cc/paint/paint_op_buffer.h
[add] https://crrev.com/7b5465786451393d3a7e9614f4d83278bf36e03e/cc/paint/paint_op_buffer_serializer.cc
[add] https://crrev.com/7b5465786451393d3a7e9614f4d83278bf36e03e/cc/paint/paint_op_buffer_serializer.h
[modify] https://crrev.com/7b5465786451393d3a7e9614f4d83278bf36e03e/cc/paint/paint_op_buffer_unittest.cc
[modify] https://crrev.com/7b5465786451393d3a7e9614f4d83278bf36e03e/cc/paint/paint_op_reader.cc
[modify] https://crrev.com/7b5465786451393d3a7e9614f4d83278bf36e03e/cc/paint/paint_op_reader.h
[modify] https://crrev.com/7b5465786451393d3a7e9614f4d83278bf36e03e/gpu/command_buffer/client/BUILD.gn
[modify] https://crrev.com/7b5465786451393d3a7e9614f4d83278bf36e03e/gpu/command_buffer/client/gles2_implementation.cc

Project Member

Comment 3 by bugdroid1@chromium.org, Nov 22 2017

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

commit 7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e
Author: Khushal <khushalsagar@chromium.org>
Date: Wed Nov 22 03:12:06 2017

cc: Replace SkImageFilter with PaintFilter in paint recordings.

Add PaintFilter to be a cc/paint equivalent for SkImageFilter, stored in
PaintRecords. The purpose of PaintFilter is to provide a transparent
filter type that can be safely used for cross-process transport during
OOP raster. PaintFilters cache the parameters used to build
corresponding skia filters, which can be serialized and used to recreate
the filter graph on the GPU service.

A tricky bit here is cc::FilterOperation. FilterOperations are
converted to an SkImageFilter which can subsequently be used during
raster or on PaintFlags in a recording. In order to completely eliminate
SkImageFilter usage in recordings, this change switches FilterOperation
to use a PaintFilter. However, these operations can be present on
CompositorFrames and are currently serialized to the browser process, by
serializing SkImageFilters[1]. Since this change doesn't add PaintFilter
serialization, in the interim we still use SkImageFilters when
serializing FilterOperations.

[1] Note that this serialization respects the security constraint to
disable SkPictureImageFilters, since SkPictures are not safe to
serialize cross-process. Going forward this will be eliminated with
PaintFilters which uses PaintRecord backed filters instead.

R=enne@chromium.org, pdr@chromium.org, vmpstr@chromium.org
TBR=junov@chromium.org

Bug:  777636 
Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2
Change-Id: Ic790b80e088771f4186eaec62da959c4dd107572
Reviewed-on: https://chromium-review.googlesource.com/770522
Commit-Queue: Khushal <khushalsagar@chromium.org>
Reviewed-by: vmpstr <vmpstr@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Reviewed-by: David Trainor <dtrainor@chromium.org>
Reviewed-by: enne <enne@chromium.org>
Reviewed-by: Philip Rogers <pdr@chromium.org>
Reviewed-by: Antoine Labour <piman@chromium.org>
Cr-Commit-Position: refs/heads/master@{#518517}
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/BUILD.gn
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/animation/BUILD.gn
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/animation/animation_curve.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/animation/animation_events.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/animation/element_animations.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/base/BUILD.gn
[delete] https://crrev.com/edbfbe9e781882ac0f86d32ee32fe4ca4c20df55/cc/base/render_surface_filters.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/blink/web_display_item_list_impl.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/ipc/BUILD.gn
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/ipc/cc_param_traits.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/ipc/cc_param_traits.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/ipc/cc_param_traits_macros.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/ipc/cc_param_traits_unittest.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/ipc/cc_serialization_perftest.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/layers/layer.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/layers/layer_impl_test_properties.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/layers/layer_impl_unittest.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/layers/render_surface_impl.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/BUILD.gn
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/display_item_list.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/display_item_list_unittest.cc
[rename] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/filter_operation.cc
[rename] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/filter_operation.h
[rename] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/filter_operations.cc
[rename] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/filter_operations.h
[rename] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/filter_operations_unittest.cc
[add] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/paint_filter.cc
[add] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/paint_filter.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/paint_flags.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/paint_flags.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/paint_op_buffer_unittest.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/paint_op_reader.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/paint_op_writer.cc
[rename] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/render_surface_filters.cc
[add] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/render_surface_filters.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/paint/solid_color_analyzer_unittest.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/test/animation_test_common.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/test/animation_timelines_test_common.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/test/fake_recording_source.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/test/render_pass_test_utils.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/trees/damage_tracker.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/trees/damage_tracker_unittest.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/trees/effect_node.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/trees/layer_tree_host_common_unittest.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/trees/layer_tree_host_pixeltest_filters.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/trees/layer_tree_host_unittest_context.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/trees/occlusion_tracker_unittest.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/trees/property_tree.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/cc/trees/scroll_node.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/chrome/browser/android/compositor/layer/content_layer.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/chrome/browser/android/compositor/layer/layer.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/components/viz/common/quads/draw_quad_unittest.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/components/viz/common/quads/render_pass.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/components/viz/common/quads/render_pass_draw_quad.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/components/viz/service/display/direct_renderer.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/components/viz/service/display/gl_renderer.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/components/viz/service/display/gl_renderer_unittest.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/components/viz/service/display/renderer_pixeltest.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/components/viz/service/display/skia_renderer.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/components/viz/service/display/software_renderer.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/services/viz/public/cpp/compositing/filter_operation.typemap
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/services/viz/public/cpp/compositing/filter_operation_struct_traits.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/services/viz/public/cpp/compositing/filter_operations.typemap
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/services/viz/public/cpp/compositing/filter_operations_struct_traits.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/services/viz/public/cpp/compositing/struct_traits_unittest.cc
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/services/viz/public/interfaces/compositing/filter_operation.mojom
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/services/viz/public/interfaces/compositing/filter_operations.mojom
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/core/paint/FilterEffectBuilder.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/core/paint/FilterPainter.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/core/paint/FilterPainter.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/core/paint/PaintLayerPainter.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/core/paint/SVGFilterPainter.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/core/svg/graphics/filters/SVGFEImage.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/core/svg/graphics/filters/SVGFEImage.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/modules/canvas/canvas2d/BaseRenderingContext2D.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/modules/canvas/canvas2d/CanvasRenderingContext2D.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/modules/canvas/canvas2d/CanvasRenderingContext2D.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/modules/canvas/canvas2d/CanvasRenderingContext2DState.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/modules/canvas/canvas2d/CanvasRenderingContext2DState.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/modules/canvas/offscreencanvas2d/OffscreenCanvasRenderingContext2D.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/modules/canvas/offscreencanvas2d/OffscreenCanvasRenderingContext2D.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/modules/csspaint/PaintRenderingContext2D.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/modules/csspaint/PaintRenderingContext2D.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/BUILD.gn
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/animation/CompositorFilterAnimationCurve.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/CompositorFilterOperations.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/CompositorFilterOperations.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/GraphicsContext.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/GraphicsContext.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/VideoFrameSubmitter.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/compositing/PaintChunksToCcLayer.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/compositing/PropertyTreeManager.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEBlend.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEBlend.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEBoxReflect.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEBoxReflect.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEColorMatrix.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEColorMatrix.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEComponentTransfer.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEComponentTransfer.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEComposite.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEComposite.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEConvolveMatrix.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEConvolveMatrix.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEDisplacementMap.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEDisplacementMap.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEDropShadow.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEDropShadow.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEFlood.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEFlood.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEGaussianBlur.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEGaussianBlur.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FELighting.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FELighting.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEMerge.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEMerge.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEMorphology.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEMorphology.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEOffset.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FEOffset.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FETile.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FETile.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FETurbulence.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FETurbulence.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FilterEffect.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/FilterEffect.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/ImageFilterBuilderTest.cpp
[rename] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/PaintFilterBuilder.cpp
[rename] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/PaintFilterBuilder.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/PaintFilterEffect.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/PaintFilterEffect.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/SourceAlpha.cpp
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/filters/SourceAlpha.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/paint/FilterDisplayItem.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/paint/GeometryMapperTest.cpp
[add] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/third_party/WebKit/Source/platform/graphics/paint/PaintFilter.h
[modify] https://crrev.com/7865b5be0f6472b14ed7a30bc7e41896a8ec9e6e/ui/compositor/layer.cc

Project Member

Comment 4 by bugdroid1@chromium.org, Jan 5 2018

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

commit 6f33bc10473dc7e85e7aa425450f6a447368d7aa
Author: Vladimir Levin <vmpstr@chromium.org>
Date: Fri Jan 05 20:09:55 2018

oop: Serialize blur paint filter.

This patch adds the paint filter serialization plumbing. Most functions
still need to be implemented, but as a proof of concept, this serializes
the blur filter.

R=enne@chromium.org

Bug:  777636 
Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel
Change-Id: I9ad8859ea266e7d4a005ca1d66c846e7631d7037
Reviewed-on: https://chromium-review.googlesource.com/851269
Commit-Queue: vmpstr <vmpstr@chromium.org>
Reviewed-by: enne <enne@chromium.org>
Cr-Commit-Position: refs/heads/master@{#527365}
[modify] https://crrev.com/6f33bc10473dc7e85e7aa425450f6a447368d7aa/cc/paint/paint_filter.cc
[modify] https://crrev.com/6f33bc10473dc7e85e7aa425450f6a447368d7aa/cc/paint/paint_filter.h
[modify] https://crrev.com/6f33bc10473dc7e85e7aa425450f6a447368d7aa/cc/paint/paint_op_reader.cc
[modify] https://crrev.com/6f33bc10473dc7e85e7aa425450f6a447368d7aa/cc/paint/paint_op_reader.h
[modify] https://crrev.com/6f33bc10473dc7e85e7aa425450f6a447368d7aa/cc/paint/paint_op_writer.cc
[modify] https://crrev.com/6f33bc10473dc7e85e7aa425450f6a447368d7aa/cc/paint/paint_op_writer.h

Project Member

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

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

commit 184aac3a818a10c142ad8bcccd1ac0bd7372b4c3
Author: Vladimir Levin <vmpstr@chromium.org>
Date: Sat Jan 06 01:00:47 2018

oop: Serialize a few more PaintFilter.

This patch serializes some more paint filters, for which I could find
examples in svg.

The following patch should implement more.

R=enne@chromium.org

Bug:  777636 
Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel
Change-Id: Ic2001a74b829a820ac6f591ede7b92cad9b26378
Reviewed-on: https://chromium-review.googlesource.com/853136
Commit-Queue: vmpstr <vmpstr@chromium.org>
Reviewed-by: enne <enne@chromium.org>
Cr-Commit-Position: refs/heads/master@{#527465}
[modify] https://crrev.com/184aac3a818a10c142ad8bcccd1ac0bd7372b4c3/cc/paint/image_transfer_cache_entry.cc
[modify] https://crrev.com/184aac3a818a10c142ad8bcccd1ac0bd7372b4c3/cc/paint/paint_filter.cc
[modify] https://crrev.com/184aac3a818a10c142ad8bcccd1ac0bd7372b4c3/cc/paint/paint_filter.h
[modify] https://crrev.com/184aac3a818a10c142ad8bcccd1ac0bd7372b4c3/cc/paint/paint_op_buffer.cc
[modify] https://crrev.com/184aac3a818a10c142ad8bcccd1ac0bd7372b4c3/cc/paint/paint_op_reader.cc
[modify] https://crrev.com/184aac3a818a10c142ad8bcccd1ac0bd7372b4c3/cc/paint/paint_op_reader.h
[modify] https://crrev.com/184aac3a818a10c142ad8bcccd1ac0bd7372b4c3/cc/paint/paint_op_writer.cc
[modify] https://crrev.com/184aac3a818a10c142ad8bcccd1ac0bd7372b4c3/cc/paint/paint_op_writer.h

Cc: vmi...@chromium.org
I think we should be able to use filter serialization here for transporting filters on CompositorFrames before OOP raster. This is desired for removing quirks in skia for implementing security constraints (https://chromium-review.googlesource.com/c/chromium/src/+/759129) and a workaround that uses kSkImageFilter PaintFilter type for this use-case in the interim.

To have parity with current serialization of SkImageFilters, we only need to serialize filter types with primitives. The following ones which are security sensitive are handled as follows:

1) ImagePaintFilter: This has a PaintImage with encoded image data. We want to decode during serialization and serialize the bitmap.

2) RecordPaintFilter: Disabled as SkPictureImageFilter.

3) PaintFlagsPaintFilter: This actually warrants a security review, because it serializes the paint and thus potentially SkPictures with it.
Cc: -vmp...@chromium.org khushals...@chromium.org
Owner: vmp...@chromium.org
For ImagePaintFilter, this would be serialized via the transfer cache in the same way that we plan (or do) serialize images.

For RecordPaintFilter, I'm not sure what you mean that it's disabled? We have the ability to serialize a paint record, so why wouldn't we be able to serialize this filter?

PaintFlagsPaintFilter: this would serialize PaintFlags in the same way that we currently serialize PaintFlags for everything else, so I'm not sure why a separate review is warranted.
In #6 I was talking about filter serialization for existing use case of filters on CompositorFrames. Right now we serialize the underlying SkImageFilter and create a kSkImageFilter PaintFilter type in the browser. This serialization is already security constrained to drop SkPictures and decode images in the renderer during serialization. Finally for OOP, we will be able to drop the constraint above and use PaintRecords. Also, transfer cache is only used with OOP right now?

My point was that if we want to drop using skia serialization for the existing use-case sooner than when all of PaintRecord serialization is ready, we can do that by disabling the same filter types from PaintFilter. vmiura@, is this a priority?
> My point was that if we want to drop using skia serialization for the existing
> use-case sooner than when all of PaintRecord serialization is ready, we can do
> that by disabling the same filter types from PaintFilter. vmiura@, is this a
> priority?

Yes I think we should prioritize this to unblock Skia / OOP-Printing progress.  I don't think we need to support RecordPaintFilter in Compositor frames; it's unexpected in that context.

I'm concerned about what you mentioned of PaintFlagsPaintFilter serializing/deserializing SkPaints -- which would set us back to square 1 as far as allowing arbitrary SkPicture deserialization in the Browser process.  Could we switch this to serialize PaintFlags with no embedded SkPaints?
I'm sorry about being a bit vague in #8. I meant that currently the PaintFlagsPaintFilter's skia equivalent is SkPaintImageFilter which has an SkPaint, and I wasn't sure whether that is hardened enough. It can internally have SkPictures in objects other than SkPictureImageFilter (like SkPictureShaders). And I wasn't sure if we disable picture serialization altogether or just in filters. Looks like we disable it with picture shaders as well (https://cs.chromium.org/chromium/src/third_party/skia/src/shaders/SkPictureShader.cpp?sq=package:chromium&l=184). The #define here is kinda misleading (https://cs.chromium.org/chromium/src/third_party/skia/src/core/SkPicture.cpp?type=cs&l=19). It also has SkTypeface (web fonts?) which we do serialize with SkPaints.

Do we need to similarly drop all PaintRecords in PaintFlags when serializing PaintFlagsPaintFilter for CompositorFrames? Typefaces are already ignored.
Cc: senorblanco@chromium.org
Re #11: Hmm, yes I think we need to block deserialization of complex Sk types in PaintFlags, or finish converting those to cc::Paint types if they're required.

So we ignore the typeface; which other PaintFlags fields are a concern?  SkDrawLooper can be ignored too I think.
Ignoring PaintRecord, SkTypeface and SkDrawLooper (which has an SkPaint) should suffice I think, since these types can include font data which we definitely can not allow. At least for the purpose of switching away from skia here, we won't be increasing the serialization surface if we have these constraints.
Moved the tracking for removing use of SkImageFilter serialization to  Issue 800612 .
Project Member

Comment 16 by bugdroid1@chromium.org, Jan 10 2018

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

commit 22b01e0c8069d1ebf0ced27d5ccc037271ca60cc
Author: Vladimir Levin <vmpstr@chromium.org>
Date: Wed Jan 10 18:48:50 2018

oop: Serialize non-image filters.

This patch serializes the rest of the non-image filters.

R=khushalsagar@chromium.org, enne@chromium.org

Bug:  777636 
Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel
Change-Id: If3d17bd851ed2b012b23e2614fbeb45dd05fa973
Reviewed-on: https://chromium-review.googlesource.com/855587
Commit-Queue: vmpstr <vmpstr@chromium.org>
Reviewed-by: enne <enne@chromium.org>
Reviewed-by: Khushal <khushalsagar@chromium.org>
Cr-Commit-Position: refs/heads/master@{#528368}
[modify] https://crrev.com/22b01e0c8069d1ebf0ced27d5ccc037271ca60cc/cc/paint/paint_filter.cc
[modify] https://crrev.com/22b01e0c8069d1ebf0ced27d5ccc037271ca60cc/cc/paint/paint_filter.h
[modify] https://crrev.com/22b01e0c8069d1ebf0ced27d5ccc037271ca60cc/cc/paint/paint_flags.cc
[modify] https://crrev.com/22b01e0c8069d1ebf0ced27d5ccc037271ca60cc/cc/paint/paint_op_buffer.cc
[modify] https://crrev.com/22b01e0c8069d1ebf0ced27d5ccc037271ca60cc/cc/paint/paint_op_buffer.h
[modify] https://crrev.com/22b01e0c8069d1ebf0ced27d5ccc037271ca60cc/cc/paint/paint_op_buffer_unittest.cc
[modify] https://crrev.com/22b01e0c8069d1ebf0ced27d5ccc037271ca60cc/cc/paint/paint_op_reader.cc
[modify] https://crrev.com/22b01e0c8069d1ebf0ced27d5ccc037271ca60cc/cc/paint/paint_op_writer.cc

Project Member

Comment 17 by bugdroid1@chromium.org, Jan 12 2018

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

commit e6ad4f0f161700037d1ebfc7cce0bb967e7bb7e3
Author: Khushal <khushalsagar@chromium.org>
Date: Fri Jan 12 18:49:25 2018

cc: Serialize ImagePaintFilter.

R=enne@chromium.org, vmpstr@chromium.org

Bug:  777636 
Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel
Change-Id: Iac7daa6c7241ccbb43d475cc4acaf912a4f73731
Reviewed-on: https://chromium-review.googlesource.com/863105
Reviewed-by: enne <enne@chromium.org>
Commit-Queue: Khushal <khushalsagar@chromium.org>
Cr-Commit-Position: refs/heads/master@{#529007}
[modify] https://crrev.com/e6ad4f0f161700037d1ebfc7cce0bb967e7bb7e3/cc/paint/image_transfer_cache_entry.cc
[modify] https://crrev.com/e6ad4f0f161700037d1ebfc7cce0bb967e7bb7e3/cc/paint/image_transfer_cache_entry.h
[modify] https://crrev.com/e6ad4f0f161700037d1ebfc7cce0bb967e7bb7e3/cc/paint/paint_filter.cc
[modify] https://crrev.com/e6ad4f0f161700037d1ebfc7cce0bb967e7bb7e3/cc/paint/paint_op_buffer_unittest.cc
[modify] https://crrev.com/e6ad4f0f161700037d1ebfc7cce0bb967e7bb7e3/cc/paint/paint_op_reader.cc
[modify] https://crrev.com/e6ad4f0f161700037d1ebfc7cce0bb967e7bb7e3/cc/paint/paint_op_reader.h
[modify] https://crrev.com/e6ad4f0f161700037d1ebfc7cce0bb967e7bb7e3/cc/paint/paint_op_writer.cc
[modify] https://crrev.com/e6ad4f0f161700037d1ebfc7cce0bb967e7bb7e3/cc/paint/paint_op_writer.h
[modify] https://crrev.com/e6ad4f0f161700037d1ebfc7cce0bb967e7bb7e3/cc/test/transfer_cache_test_helper.h

Project Member

Comment 18 by bugdroid1@chromium.org, Jan 13 2018

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

commit 9a7924a2380ed828e99b4c0b3385dce7ad7560c9
Author: Khushal <khushalsagar@chromium.org>
Date: Sat Jan 13 02:13:44 2018

cc/paint: Follow up on image paint filter serialization.

Follow up patch for remaining comments on [1].

[1]: https://chromium-review.googlesource.com/c/chromium/src/+/863105

R=vmpstr@chromium.org

Bug:  777636 
Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel
Change-Id: I9b118e8fb097d6594879b334921299d340f4cc0a
Reviewed-on: https://chromium-review.googlesource.com/865464
Reviewed-by: vmpstr <vmpstr@chromium.org>
Commit-Queue: Khushal <khushalsagar@chromium.org>
Cr-Commit-Position: refs/heads/master@{#529148}
[modify] https://crrev.com/9a7924a2380ed828e99b4c0b3385dce7ad7560c9/cc/paint/paint_op_buffer_unittest.cc
[modify] https://crrev.com/9a7924a2380ed828e99b4c0b3385dce7ad7560c9/cc/paint/paint_op_reader.cc
[modify] https://crrev.com/9a7924a2380ed828e99b4c0b3385dce7ad7560c9/cc/test/transfer_cache_test_helper.h

Is there anything remaining on this?

Comment 20 by enne@chromium.org, Feb 7 2018

Status: Fixed (was: Started)
I think this is done.

Sign in to add a comment