push the HalfEdge into the ordered linked list of vertices
| 563 | |
| 564 | //push the HalfEdge into the ordered linked list of vertices |
| 565 | void LNLib::VoronoiDiagramGenerator::PQinsert(struct Halfedge* he, struct Site* v, float offset) |
| 566 | { |
| 567 | struct Halfedge* last, * next; |
| 568 | |
| 569 | he->vertex = v; |
| 570 | ref(v); |
| 571 | he->ystar = (float)(v->coord.y + offset); |
| 572 | last = &PQhash[PQbucket(he)]; |
| 573 | while ((next = last->PQnext) != (struct Halfedge*)NULL && |
| 574 | (he->ystar > next->ystar || |
| 575 | (he->ystar == next->ystar && v->coord.x > next->vertex->coord.x))) |
| 576 | { |
| 577 | last = next; |
| 578 | }; |
| 579 | he->PQnext = last->PQnext; |
| 580 | last->PQnext = he; |
| 581 | PQcount += 1; |
| 582 | } |
| 583 | |
| 584 | //remove the HalfEdge from the list of vertices |
| 585 | void LNLib::VoronoiDiagramGenerator::PQdelete(struct Halfedge* he) |
nothing calls this directly
no outgoing calls
no test coverage detected