michael@0: /* michael@0: * Copyright 2012 Google Inc. michael@0: * michael@0: * Use of this source code is governed by a BSD-style license that can be michael@0: * found in the LICENSE file. michael@0: */ michael@0: #ifndef SkDQuadImplicit_DEFINED michael@0: #define SkDQuadImplicit_DEFINED michael@0: michael@0: #include "SkPathOpsQuad.h" michael@0: michael@0: class SkDQuadImplicit { michael@0: public: michael@0: explicit SkDQuadImplicit(const SkDQuad& q); michael@0: michael@0: bool match(const SkDQuadImplicit& two) const; michael@0: static bool Match(const SkDQuad& quad1, const SkDQuad& quad2); michael@0: michael@0: double x2() const { return fP[kXx_Coeff]; } michael@0: double xy() const { return fP[kXy_Coeff]; } michael@0: double y2() const { return fP[kYy_Coeff]; } michael@0: double x() const { return fP[kX_Coeff]; } michael@0: double y() const { return fP[kY_Coeff]; } michael@0: double c() const { return fP[kC_Coeff]; } michael@0: michael@0: private: michael@0: enum Coeffs { michael@0: kXx_Coeff, michael@0: kXy_Coeff, michael@0: kYy_Coeff, michael@0: kX_Coeff, michael@0: kY_Coeff, michael@0: kC_Coeff, michael@0: }; michael@0: michael@0: double fP[kC_Coeff + 1]; michael@0: }; michael@0: michael@0: #endif