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

Issue 1287023009: Added tree structure to GrGLFragmentProcessor, i.e. GL instances (Closed)

Created:
5 years, 4 months ago by wangyix
Modified:
5 years, 4 months ago
CC:
reviews_skia.org
Base URL:
https://skia.googlesource.com/skia@cs3_isequal_nonrecursive
Target Ref:
refs/heads/master
Project:
skia
Visibility:
Public.

Description

When getGLInstance is called on a frag proc, the resulting GrGLFragmentProcessor will be the root of a tree of GrGLFragmentProcessors that mirrors the GrFragmentProcessor's tree. This allows setData() to be called recursively (removing the responsibility from compose shader) and allows gl instances direct access to their children gl instances so they can emit their code. BUG=skia:4182 Committed: https://skia.googlesource.com/skia/+/b1daa86732fe70aa4630c89d75ff0fd619d77c77

Patch Set 1 : added fChildProcessors to GrGLFragmentProcessor #

Patch Set 2 : refactored setData() to onSetData() #

Patch Set 3 : added recursive setData() that calls onSetData() #

Patch Set 4 : refactored createGLInstance to onCreateGLInstance #

Patch Set 5 : added recursive createGLInstance #

Patch Set 6 : moved onSetData from public to protected, onCreateGLInstance from public to private in subclasses #

Unified diffs Side-by-side diffs Delta from patch set Stats (+320 lines, -235 lines) Patch
M gm/dcshader.cpp View 1 2 3 4 2 chunks +2 lines, -2 lines 0 comments Download
M gyp/gpu.gypi View 1 2 3 4 1 chunk +2 lines, -0 lines 0 comments Download
M include/gpu/GrFragmentProcessor.h View 1 2 3 4 5 2 chunks +6 lines, -4 lines 0 comments Download
M include/gpu/effects/GrConstColorProcessor.h View 1 2 3 4 5 2 chunks +2 lines, -2 lines 0 comments Download
M src/effects/SkAlphaThresholdFilter.cpp View 1 2 3 4 5 5 chunks +6 lines, -5 lines 0 comments Download
M src/effects/SkArithmeticMode_gpu.h View 1 2 3 4 5 2 chunks +2 lines, -2 lines 0 comments Download
M src/effects/SkArithmeticMode_gpu.cpp View 1 2 3 4 5 2 chunks +8 lines, -7 lines 0 comments Download
M src/effects/SkBlurMaskFilter.cpp View 1 2 3 4 5 9 chunks +12 lines, -10 lines 0 comments Download
M src/effects/SkColorCubeFilter.cpp View 1 2 3 4 5 5 chunks +6 lines, -4 lines 0 comments Download
M src/effects/SkColorFilters.cpp View 1 2 3 4 5 3 chunks +6 lines, -5 lines 0 comments Download
M src/effects/SkColorMatrixFilter.cpp View 1 2 3 4 5 3 chunks +6 lines, -6 lines 0 comments Download
M src/effects/SkDisplacementMapEffect.cpp View 1 2 3 4 5 4 chunks +8 lines, -6 lines 0 comments Download
M src/effects/SkLightingImageFilter.cpp View 1 2 3 4 5 10 chunks +19 lines, -15 lines 0 comments Download
M src/effects/SkLightingShader.cpp View 1 2 3 4 5 4 chunks +11 lines, -10 lines 0 comments Download
M src/effects/SkLumaColorFilter.cpp View 1 2 3 4 5 2 chunks +4 lines, -4 lines 0 comments Download
M src/effects/SkMagnifierImageFilter.cpp View 1 2 3 4 5 5 chunks +6 lines, -5 lines 0 comments Download
M src/effects/SkMorphologyImageFilter.cpp View 1 2 3 4 5 5 chunks +6 lines, -5 lines 0 comments Download
M src/effects/SkPerlinNoiseShader.cpp View 1 2 3 4 5 4 chunks +9 lines, -8 lines 0 comments Download
M src/effects/SkTableColorFilter.cpp View 1 2 3 4 5 4 chunks +7 lines, -6 lines 0 comments Download
M src/effects/gradients/SkGradientShader.cpp View 1 1 chunk +1 line, -1 line 0 comments Download
M src/effects/gradients/SkGradientShaderPriv.h View 1 2 3 4 5 1 chunk +2 lines, -1 line 0 comments Download
M src/effects/gradients/SkLinearGradient.cpp View 1 2 3 4 5 2 chunks +4 lines, -4 lines 0 comments Download
M src/effects/gradients/SkRadialGradient.cpp View 1 2 3 4 5 2 chunks +4 lines, -4 lines 0 comments Download
M src/effects/gradients/SkSweepGradient.cpp View 1 2 3 4 5 2 chunks +4 lines, -4 lines 0 comments Download
M src/effects/gradients/SkTwoPointConicalGradient_gpu.cpp View 1 2 3 4 5 22 chunks +35 lines, -30 lines 0 comments Download
M src/gpu/GrProcessor.cpp View 1 2 3 4 2 chunks +10 lines, -0 lines 0 comments Download
M src/gpu/effects/GrBicubicEffect.h View 1 2 3 4 5 2 chunks +2 lines, -2 lines 0 comments Download
M src/gpu/effects/GrBicubicEffect.cpp View 1 2 3 4 5 3 chunks +5 lines, -4 lines 0 comments Download
M src/gpu/effects/GrConfigConversionEffect.h View 1 2 3 4 5 2 chunks +2 lines, -2 lines 0 comments Download
M src/gpu/effects/GrConfigConversionEffect.cpp View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M src/gpu/effects/GrConstColorProcessor.cpp View 1 2 3 4 5 2 chunks +3 lines, -2 lines 0 comments Download
M src/gpu/effects/GrConvexPolyEffect.h View 1 2 3 4 5 1 chunk +2 lines, -2 lines 0 comments Download
M src/gpu/effects/GrConvexPolyEffect.cpp View 1 2 3 4 5 8 chunks +10 lines, -8 lines 0 comments Download
M src/gpu/effects/GrConvolutionEffect.h View 1 2 3 4 5 2 chunks +2 lines, -2 lines 0 comments Download
M src/gpu/effects/GrConvolutionEffect.cpp View 1 2 3 4 5 3 chunks +5 lines, -4 lines 0 comments Download
M src/gpu/effects/GrCustomXfermode.cpp View 1 2 3 4 5 4 chunks +5 lines, -4 lines 0 comments Download
M src/gpu/effects/GrCustomXfermodePriv.h View 1 2 3 4 5 1 chunk +2 lines, -2 lines 0 comments Download
M src/gpu/effects/GrDitherEffect.cpp View 1 2 3 4 5 2 chunks +3 lines, -3 lines 0 comments Download
M src/gpu/effects/GrMatrixConvolutionEffect.h View 1 2 3 4 5 2 chunks +2 lines, -2 lines 0 comments Download
M src/gpu/effects/GrMatrixConvolutionEffect.cpp View 1 2 3 4 5 3 chunks +4 lines, -3 lines 0 comments Download
M src/gpu/effects/GrOvalEffect.cpp View 1 2 3 4 5 10 chunks +12 lines, -10 lines 0 comments Download
M src/gpu/effects/GrRRectEffect.cpp View 1 2 3 4 5 10 chunks +12 lines, -10 lines 0 comments Download
M src/gpu/effects/GrSimpleTextureEffect.h View 1 2 3 4 5 2 chunks +2 lines, -2 lines 0 comments Download
M src/gpu/effects/GrSimpleTextureEffect.cpp View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M src/gpu/effects/GrTextureDomain.h View 1 2 3 4 5 2 chunks +2 lines, -2 lines 0 comments Download
M src/gpu/effects/GrTextureDomain.cpp View 1 2 3 4 5 3 chunks +5 lines, -4 lines 0 comments Download
M src/gpu/effects/GrYUVtoRGBEffect.cpp View 1 2 3 4 5 3 chunks +6 lines, -5 lines 0 comments Download
M src/gpu/gl/GrGLFragmentProcessor.h View 1 2 3 4 2 chunks +24 lines, -8 lines 0 comments Download
A src/gpu/gl/GrGLFragmentProcessor.cpp View 1 2 3 4 1 chunk +18 lines, -0 lines 0 comments Download
M src/gpu/gl/GrGLProgram.cpp View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M tests/GLProgramsTest.cpp View 1 2 3 1 chunk +1 line, -1 line 0 comments Download

Depends on Patchset:

Dependent Patchsets:

Messages

Total messages: 10 (3 generated)
wangyix
I tried to split up the non-interesting changes that affected many files (i.e. refactoring) and ...
5 years, 4 months ago (2015-08-14 21:21:45 UTC) #2
joshualitt
On 2015/08/14 21:21:45, wangyix wrote: > I tried to split up the non-interesting changes that ...
5 years, 4 months ago (2015-08-17 18:05:18 UTC) #3
bsalomon
https://codereview.chromium.org/1287023009/diff/100001/src/effects/SkAlphaThresholdFilter.cpp File src/effects/SkAlphaThresholdFilter.cpp (right): https://codereview.chromium.org/1287023009/diff/100001/src/effects/SkAlphaThresholdFilter.cpp#newcode134 src/effects/SkAlphaThresholdFilter.cpp:134: void onSetData(const GrGLProgramDataManager&, const GrProcessor&) override; can this be ...
5 years, 4 months ago (2015-08-17 18:18:26 UTC) #4
wangyix
https://codereview.chromium.org/1287023009/diff/100001/src/effects/SkAlphaThresholdFilter.cpp File src/effects/SkAlphaThresholdFilter.cpp (right): https://codereview.chromium.org/1287023009/diff/100001/src/effects/SkAlphaThresholdFilter.cpp#newcode134 src/effects/SkAlphaThresholdFilter.cpp:134: void onSetData(const GrGLProgramDataManager&, const GrProcessor&) override; On 2015/08/17 18:18:26, ...
5 years, 4 months ago (2015-08-18 17:33:16 UTC) #5
bsalomon
lgtm
5 years, 4 months ago (2015-08-18 18:15:20 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1287023009/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1287023009/120001
5 years, 4 months ago (2015-08-18 18:17:14 UTC) #9
commit-bot: I haz the power
5 years, 4 months ago (2015-08-18 18:29:35 UTC) #10
Message was sent while issue was closed.
Committed patchset #6 (id:120001) as
https://skia.googlesource.com/skia/+/b1daa86732fe70aa4630c89d75ff0fd619d77c77

Powered by Google App Engine
This is Rietveld 408576698