Index: cc/quads/draw_polygon.h |
diff --git a/cc/quads/draw_polygon.h b/cc/quads/draw_polygon.h |
index 2dc642cde3195cd8beb47c74b72476cfb9ba1a5f..b3bde398c5556533d80deba71f0c030f64e8be30 100644 |
--- a/cc/quads/draw_polygon.h |
+++ b/cc/quads/draw_polygon.h |
@@ -40,11 +40,14 @@ |
// Split will only return true if it determines that we got back 2 |
// intersection points. Only when it returns true will front and back both be |
// valid new polygons that are on opposite sides of the splitting plane. |
- void SplitPolygon(std::unique_ptr<DrawPolygon> polygon, |
- std::unique_ptr<DrawPolygon>* front, |
- std::unique_ptr<DrawPolygon>* back, |
- bool* is_coplanar) const; |
+ bool Split(const DrawPolygon& splitter, |
+ std::unique_ptr<DrawPolygon>* front, |
+ std::unique_ptr<DrawPolygon>* back); |
float SignedPointDistance(const gfx::Point3F& point) const; |
+ // Checks polygon a against polygon b and returns which side it lies on, or |
+ // whether it crosses (necessitating a split in the BSP tree). |
+ static BspCompareResult SideCompare(const DrawPolygon& a, |
+ const DrawPolygon& b); |
void ToQuads2D(std::vector<gfx::QuadF>* quads) const; |
void TransformToScreenSpace(const gfx::Transform& transform); |
void TransformToLayerSpace(const gfx::Transform& inverse_transform); |