for(index = 0; index < edge_count; index++)
{
printf("\nInfo for edge number: %d\n", index);
UF_MODL_ask_list_item(edge_list, index, &edge_id);
UF_MODL_ask_edge_verts(edge_id, p1, p2, &vertex);
printf("The number of vertices is: %d\n", vertex);
switch(vertex)
{
case 0:
printf("There are no vertices on this edge.\n");
break;
case 1:
printf("The X value of P1 is: %f\n", p1[0]);
printf("The Y value of P1 is: %f\n", p1[1]);
printf("The Z value of P1 is: %f\n", p1[2]);
break;
case 2:
fprintf(outFile,"The X value of P1 is: %f\n", p1[0]);
fprintf(outFile,"The Y value of P1 is: %f\n", p1[1]);
fprintf(outFile,"The Z value of P1 is: %f\n", p1[2]);
fprintf(outFile,"The X value of P2 is: %f\n", p2[0]);
fprintf(outFile,"The Y value of P2 is: %f\n", p2[1]);
fprintf(outFile,"The Z value of P2 is: %f\n", p2[2]);
break;
default:
break;
}
}
printf("Total number of faces: %d\n", face_count);
fclose(outFile);
}
/*ARGSUSED*/
void ufusr(char *param, int *retcode, int param_len)
{
if (!UF_CALL(UF_initialize()))
{
do_ugopen_api();
UF_CALL(UF_terminate());
}
}