| 1169 | } |
| 1170 | |
| 1171 | void LNLib::VoronoiDiagramGenerator::insertVertexAddress(long vertexNum, struct Site* address) |
| 1172 | { |
| 1173 | if (vertices == 0) |
| 1174 | { |
| 1175 | vertices = (struct Site**)myalloc(4000 * sizeof(*vertices)); |
| 1176 | sizeOfVertices = 4000; |
| 1177 | for (int i = sizeOfVertices - 4000; i < sizeOfVertices; i++) |
| 1178 | { |
| 1179 | vertices[i] = 0; |
| 1180 | } |
| 1181 | } |
| 1182 | //if the site address being entered is past the end of the array, then grow the array |
| 1183 | while (vertexNum > sizeOfVertices - 1) |
| 1184 | { |
| 1185 | vertices = (Site**)realloc(vertices, (sizeOfVertices + 4000) * sizeof(Site*)); |
| 1186 | sizeOfVertices += 4000; |
| 1187 | |
| 1188 | for (int i = sizeOfVertices - 4000; i < sizeOfVertices; i++) |
| 1189 | { |
| 1190 | vertices[i] = 0; |
| 1191 | } |
| 1192 | } |
| 1193 | vertices[vertexNum] = address; |
| 1194 | } |
| 1195 | |
| 1196 | void LNLib::VoronoiDiagramGenerator::insertVertexLink(long vertexNum, long vertexLinkedTo) |
| 1197 | { |
nothing calls this directly
no outgoing calls
no test coverage detected