void FrontBackSplitTest() { struct node* empty_list = BuildEmpty(); struct node* list1 = BuildOne(); struct node* list2 = BuildOneTwo(); struct node* list3 = BuildOneThree(); struct node* list4 = BuildOneThreeFour(); struct node* front = NULL; struct node* back = NULL; printf("** test case 1 **\n"); printf("origin list:\n"); Print(empty_list); FrontBackSplit(empty_list, front, back); printf("After split:\n"); Print(front); Print(back); printf("** test case 2 **\n"); printf("origin list:\n"); Print(list1); FrontBackSplit(list1, front, back); printf("After split:\n"); Print(front); Print(back); printf("** test case 3 **\n"); printf("origin list:\n"); Print(list2); FrontBackSplit(list2, front, back); printf("After split:\n"); Print(front); Print(back); printf("** test case 4 **\n"); printf("origin list:\n"); Print(list3); FrontBackSplit(list3, front, back); printf("After split:\n"); Print(front); Print(back); printf("** test case 5 **\n"); printf("origin list:\n"); Print(list4); FrontBackSplit(list4, front, back); printf("After split:\n"); Print(front); Print(back); }
void bhkProxyObject::BuildMesh(TimeValue t) { ivalid = FOREVER; int bvType = 0; pblock2->GetValue(PB_BOUND_TYPE, 0, bvType, FOREVER, 0); BuildEmpty(); switch (bvType) { default: case bv_type_none: // Delete mesh. break; case bv_type_box: // box BuildColBox(); break; case bv_type_shapes: // Shapes BuildColStrips(); //BuildBox(mesh,,,) break; case bv_type_packed: // Packed BuildColPackedStrips(); //BuildSphere(); break; case bv_type_convex: BuildColConvex(); //BuildScubaMesh(); break; case bv_type_capsule: BuildColCapsule(); break; case bv_type_obb: BuildColOBB(); break; case bv_type_cmsd: BuildColCMSD(); break; } }