增加扫描线光栅算法

This commit is contained in:
2025-06-29 09:38:39 +08:00
parent 8388f448f3
commit 2fe2ef5d74
3 changed files with 57 additions and 34 deletions
+1
View File
@@ -415,6 +415,7 @@ struct iFloat2
iFloat2() : x(0), y(0) {}
iFloat2(const iFloat2& other) : x(other.x), y(other.y) {}
iFloat2(float32_t _x, float32_t _y) : x(_x), y(_y) {}
iFloat2(iFloat _x, iFloat _y) : x(_x), y(_y) {}
};
struct iFloat3
+2 -2
View File
@@ -42,8 +42,8 @@ public:
//Scaleline algorithm
static void drawTriangleScanline(int32_t canvasWidth, int32_t canvasHeight,
const fVector3& v0, const fVector3& v1, const fVector3& v2,
DrawTriangleCallback callback);
const fVector2& v0, const fVector2& v1, const fVector2& v2,
DrawTriangleCallback callback, bool ccw = true);
};
DV_CORE_END_NAMESPACE