Replace GrColor4h with SkPMColor4f
- Mechanical replacement of GrColor4h (used throughout Ops) with
SkPMColor4f.
- API adaptation (to/FromGrColor -> to/From_BytesRGBA).
- Complete removal of FromFloats (source was already SkPMColor4f),
and toFloats (setting uniforms can directly access .vec()).
Bug: skia:
Change-Id: I37eece1fa7ed2545dc6843e840d4cc3c60f19747
Reviewed-on: https://skia-review.googlesource.com/c/166620
Reviewed-by: Mike Klein <mtklein@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
diff --git a/src/gpu/GrPathProcessor.h b/src/gpu/GrPathProcessor.h
index fd396d6..9bcddc5 100644
--- a/src/gpu/GrPathProcessor.h
+++ b/src/gpu/GrPathProcessor.h
@@ -16,7 +16,7 @@
*/
class GrPathProcessor : public GrPrimitiveProcessor {
public:
- static GrPathProcessor* Create(const GrColor4h& color,
+ static GrPathProcessor* Create(const SkPMColor4f& color,
const SkMatrix& viewMatrix = SkMatrix::I(),
const SkMatrix& localMatrix = SkMatrix::I()) {
return new GrPathProcessor(color, viewMatrix, localMatrix);
@@ -24,7 +24,7 @@
const char* name() const override { return "PathProcessor"; }
- const GrColor4h& color() const { return fColor; }
+ const SkPMColor4f& color() const { return fColor; }
const SkMatrix& viewMatrix() const { return fViewMatrix; }
const SkMatrix& localMatrix() const { return fLocalMatrix; }
@@ -50,9 +50,9 @@
return kBogus;
}
- GrPathProcessor(const GrColor4h&, const SkMatrix& viewMatrix, const SkMatrix& localMatrix);
+ GrPathProcessor(const SkPMColor4f&, const SkMatrix& viewMatrix, const SkMatrix& localMatrix);
- GrColor4h fColor;
+ SkPMColor4f fColor;
const SkMatrix fViewMatrix;
const SkMatrix fLocalMatrix;