near plane clipping partial
This commit is contained in:
@@ -36,11 +36,25 @@ class DeltaVector3 {
|
||||
};
|
||||
|
||||
float getDeterminant(const DeltaVector2 &pointA, const DeltaVector2 &pointB, const DeltaVector2 &candidate);
|
||||
DeltaVector2 barycentricToScreen(const DeltaVector3 &baryPoint, const DeltaVector2 &a, const DeltaVector2 &b, const DeltaVector2 &c);
|
||||
DeltaVector3 intersect(DeltaVector3 a, DeltaVector3 b, float nearZ);
|
||||
|
||||
struct DeltaTriangle {
|
||||
DeltaVector3 a, b, c;
|
||||
};
|
||||
|
||||
struct DeltaTriangle2D {
|
||||
DeltaVector2 a, b, c;
|
||||
};
|
||||
|
||||
|
||||
struct DeltaRenderTriangle {
|
||||
DeltaVector3 a, b, c;
|
||||
DeltaVector2 uva, uvb, uvc;
|
||||
};
|
||||
|
||||
int clipTriangleAgainstNearPlane(float nearY, const DeltaRenderTriangle &in, DeltaRenderTriangle &out1, DeltaRenderTriangle &out2);
|
||||
|
||||
uint32_t SDLColorToUint32(SDL_Color color);
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user