Adds a new vertex to all instances of a given edge
| 884 | |
| 885 | // Adds a new vertex to all instances of a given edge |
| 886 | void AddVertToAllEdges(room *rp, int v0, int v1, int new_v) { |
| 887 | face *fp; |
| 888 | int f, v; |
| 889 | |
| 890 | for (f = 0, fp = rp->faces; f < rp->num_faces; f++, fp++) { |
| 891 | for (v = 0; v < fp->num_verts; v++) { |
| 892 | if (((fp->face_verts[v] == v0) && (fp->face_verts[(v + 1) % fp->num_verts] == v1)) || |
| 893 | ((fp->face_verts[v] == v1) && (fp->face_verts[(v + 1) % fp->num_verts] == v0))) |
| 894 | AddVertToFace(rp, f, new_v, v); |
| 895 | } |
| 896 | } |
| 897 | } |
| 898 | |
| 899 | // Adds a new point to all instances of a given edge |
| 900 | // First adds the point to the room (or finds it there), then calls AddVertToAllEdges() |
no test coverage detected