MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / CodeRadPoint

Function CodeRadPoint

editor/editor_lighting.cpp:1504–1517  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1502}
1503
1504uint8_t CodeRadPoint(rad_point *rp) {
1505 uint8_t code = 0;
1506 if (rp->pos.x < rad_ClipLeft->x)
1507 code |= CC_OFF_LEFT;
1508 if (rp->pos.x > rad_ClipRight->x)
1509 code |= CC_OFF_RIGHT;
1510 if (rp->pos.y < rad_ClipBottom->y)
1511 code |= CC_OFF_BOT;
1512 if (rp->pos.y > rad_ClipTop->y)
1513 code |= CC_OFF_TOP;
1514 rp->code = code;
1515
1516 return code;
1517}
1518
1519void ClipSurfaceElement(vector *surf_verts, rad_element *ep, vector *clip_verts, int nv) {
1520 rad_point src_verts[50];

Callers 2

ClipSurfaceElementFunction · 0.85
ClipRadEdgeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected