Doxygen Source Code Documentation
user.c File Reference
#include "qhull_a.h"Go to the source code of this file.
Functions | |
| int | qh_new_qhull (int dim, int numpoints, coordT *points, boolT ismalloc, char *qhull_cmd, FILE *outfile, FILE *errfile) |
| void | qh_errexit (int exitcode, facetT *facet, ridgeT *ridge) |
| void | qh_errprint (char *string, facetT *atfacet, facetT *otherfacet, ridgeT *atridge, vertexT *atvertex) |
| void | qh_printfacetlist (facetT *facetlist, setT *facets, boolT printall) |
| void | qh_user_memsizes (void) |
Function Documentation
|
||||||||||||||||
|
||||||||||||||||||||||||
|
Definition at line 254 of file user.c. References ridgeT::bottom, fout, i, otherfacet_, qh, qh_ALL, qh_PRINTEND, qh_printfacet(), qh_printneighborhood(), qh_printridge(), qh_printvertex(), and ridgeT::top. Referenced by qh_buildhull(), qh_checkfacet(), qh_checkflipped_all(), qh_checkvertex(), qh_errexit(), qh_errexit2(), qh_findhorizon(), qh_matchduplicates(), qh_mergecycle(), qh_mergefacet(), qh_mergevertex_neighbors(), qh_partitioncoplanar(), qh_rename_sharedvertex(), qh_setfacetplane(), and qh_tracemerge().
00254 {
00255 int i;
00256
00257 if (atfacet) {
00258 fprintf(qh ferr, "%s FACET:\n", string);
00259 qh_printfacet(qh ferr, atfacet);
00260 }
00261 if (otherfacet) {
00262 fprintf(qh ferr, "%s OTHER FACET:\n", string);
00263 qh_printfacet(qh ferr, otherfacet);
00264 }
00265 if (atridge) {
00266 fprintf(qh ferr, "%s RIDGE:\n", string);
00267 qh_printridge(qh ferr, atridge);
00268 if (atridge->top && atridge->top != atfacet && atridge->top != otherfacet)
00269 qh_printfacet(qh ferr, atridge->top);
00270 if (atridge->bottom
00271 && atridge->bottom != atfacet && atridge->bottom != otherfacet)
00272 qh_printfacet(qh ferr, atridge->bottom);
00273 if (!atfacet)
00274 atfacet= atridge->top;
00275 if (!otherfacet)
00276 otherfacet= otherfacet_(atridge, atfacet);
00277 }
00278 if (atvertex) {
00279 fprintf(qh ferr, "%s VERTEX:\n", string);
00280 qh_printvertex (qh ferr, atvertex);
00281 }
00282 if (qh fout && qh FORCEoutput && atfacet && !qh QHULLfinished && !qh IStracing) {
00283 fprintf(qh ferr, "ERRONEOUS and NEIGHBORING FACETS to output\n");
00284 for (i= 0; i < qh_PRINTEND; i++) /* use fout for geomview output */
00285 qh_printneighborhood (qh fout, qh PRINTout[i], atfacet, otherfacet,
00286 !qh_ALL);
00287 }
00288 } /* errprint */
|
|
||||||||||||||||||||||||||||||||
|
Definition at line 120 of file user.c. References boolT, coordT, free, qh, qh_check_output(), qh_check_points(), qh_init_B(), qh_initflags(), qh_initqhull_start(), qh_meminit(), qh_produce_output(), qh_qhull(), qh_setfeasible(), qh_sethalfspace_all(), and trace1.
00121 {
00122 int exitcode, hulldim;
00123 boolT new_ismalloc;
00124 static boolT firstcall = True;
00125 coordT *new_points;
00126
00127 if (firstcall) {
00128 qh_meminit (errfile);
00129 firstcall= False;
00130 }
00131 if (strncmp (qhull_cmd,"qhull ", 6)) {
00132 fprintf (errfile, "qh_new_qhull: start qhull_cmd argument with \"qhull \"\n");
00133 exit(1);
00134 }
00135 qh_initqhull_start (NULL, outfile, errfile);
00136 trace1(( qh ferr, "qh_new_qhull: build new Qhull for %d %d-d points with %s\n", numpoints, dim, qhull_cmd));
00137 exitcode = setjmp (qh errexit);
00138 if (!exitcode)
00139 {
00140 qh NOerrexit = False;
00141 qh_initflags (qhull_cmd);
00142 if (qh DELAUNAY)
00143 qh PROJECTdelaunay= True;
00144 if (qh HALFspace) {
00145 /* points is an array of halfspaces,
00146 the last coordinate of each halfspace is its offset */
00147 hulldim= dim-1;
00148 qh_setfeasible (hulldim);
00149 new_points= qh_sethalfspace_all (dim, numpoints, points, qh feasible_point);
00150 new_ismalloc= True;
00151 if (ismalloc)
00152 free (points);
00153 }else {
00154 hulldim= dim;
00155 new_points= points;
00156 new_ismalloc= ismalloc;
00157 }
00158 qh_init_B (new_points, numpoints, hulldim, new_ismalloc);
00159 qh_qhull();
00160 qh_check_output();
00161 if (outfile)
00162 qh_produce_output();
00163 if (qh VERIFYoutput && !qh STOPpoint && !qh STOPcone)
00164 qh_check_points();
00165 }
00166 qh NOerrexit = True;
00167 return exitcode;
00168 } /* new_qhull */
|
|
||||||||||||||||
|
Definition at line 302 of file user.c. References boolT, FORALLfacet_, FOREACHfacet_, qh, qh_printafacet(), qh_printbegin(), qh_printend(), and qh_PRINTfacets. Referenced by qh_addpoint(), qh_findhorizon(), qh_makenewfacets(), qh_matchnewfacets(), and qh_partitionall().
00302 {
00303 facetT *facet, **facetp;
00304
00305 qh_printbegin (qh ferr, qh_PRINTfacets, facetlist, facets, printall);
00306 FORALLfacet_(facetlist)
00307 qh_printafacet(qh ferr, qh_PRINTfacets, facet, printall);
00308 FOREACHfacet_(facets)
00309 qh_printafacet(qh ferr, qh_PRINTfacets, facet, printall);
00310 qh_printend (qh ferr, qh_PRINTfacets, facetlist, facets, printall);
00311 } /* printfacetlist */
|
|
|
Definition at line 323 of file user.c. Referenced by qh_initqhull_mem().
00323 {
00324
00325 /* qh_memsize (size); */
00326 } /* user_memsizes */
|