aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/gpu/GrFragmentProcessor.h
diff options
context:
space:
mode:
authorGravatar mtklein <mtklein@google.com>2016-07-30 14:21:10 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2016-07-30 14:21:10 -0700
commit02aed95f9c7c6745c02e9aa8604d27d7a3ae93db (patch)
treebf573a00bea3456ce3fcc43c052aa9ae107b60fe /include/gpu/GrFragmentProcessor.h
parent7c0db75f40f588d91884dfbf3c207d040f3d802d (diff)
Revert of GrFP can express distance vector field req., program builder declares variable for it (patchset #20 id:370001 of https://codereview.chromium.org/2114993002/ )
Reason for revert: UBSAN says we're reading a bad bool here: bool usesDistanceVectorField() const { return fUsesDistanceVectorField; } ../../../include/gpu/GrPaint.h:83:51: runtime error: load of value 239, which is not a valid value for type 'bool' SUMMARY: AddressSanitizer: undefined-behavior ../../../include/gpu/GrPaint.h:83:51 in Seems likely also the root of Valgrind failure: https://luci-milo.appspot.com/swarming/task/30522e4f2241cb10 Original issue's description: > GrFP can express distance vector field req., program builder declares variable for it > > This update allows fragment processors to require a field of vectors to the nearest edge. This requirement propagates: > > - from child FPs to their parent > - from parent FPs to the GrPaint > - from GrPaint through the PipelineBuilder into GrPipeline > - acessed from GrPipeline by GrGLSLProgramBuilder > > GrGLSL generates a variable for the distance vector and passes it down to the GeometryProcessor->emitCode() method. > > This CL's base is the CL for adding the BevelNormalSource API: https://codereview.chromium.org/2080993002 > > BUG=skia: > GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2114993002 > > Committed: https://skia.googlesource.com/skia/+/4ef6dfa7089c092c67b0d5ec34e89c1e319af196 TBR=egdaniel@google.com,robertphillips@google.com,bsalomon@google.com,dvonbeck@google.com # Not skipping CQ checks because original CL landed more than 1 days ago. BUG=skia: Review-Url: https://codereview.chromium.org/2201613002
Diffstat (limited to 'include/gpu/GrFragmentProcessor.h')
-rw-r--r--include/gpu/GrFragmentProcessor.h9
1 files changed, 0 insertions, 9 deletions
diff --git a/include/gpu/GrFragmentProcessor.h b/include/gpu/GrFragmentProcessor.h
index ffbf576dbe..4b56fbf728 100644
--- a/include/gpu/GrFragmentProcessor.h
+++ b/include/gpu/GrFragmentProcessor.h
@@ -65,7 +65,6 @@ public:
GrFragmentProcessor()
: INHERITED()
- , fUsesDistanceVectorField(false)
, fUsesLocalCoords(false)
, fNumTexturesExclChildren(0)
, fNumBuffersExclChildren(0)
@@ -111,9 +110,6 @@ public:
/** Do any of the coordtransforms for this processor require local coords? */
bool usesLocalCoords() const { return fUsesLocalCoords; }
- /** Does this FP need a vector to the nearest edge? */
- bool usesDistanceVectorField() const { return fUsesDistanceVectorField; }
-
/** Returns true if this and other processor conservatively draw identically. It can only return
true when the two processor are of the same subclass (i.e. they return the same object from
from getFactory()).
@@ -177,11 +173,6 @@ protected:
*/
virtual void onComputeInvariantOutput(GrInvariantOutput* inout) const = 0;
- /* Sub-classes should set this to true in their constructors if they need access to a distance
- * vector field to the nearest edge
- */
- bool fUsesDistanceVectorField;
-
private:
void notifyRefCntIsZero() const final;