Revision: 41825
http://brlcad.svn.sourceforge.net/brlcad/?rev=41825&view=rev
Author: brlcad
Date: 2010-12-29 01:54:10 +0000 (Wed, 29 Dec 2010)
Log Message:
-----------
automatic ws indent cleanup
Modified Paths:
--------------
brlcad/trunk/src/librt/primitives/brep/brep_debug.cpp
Modified: brlcad/trunk/src/librt/primitives/brep/brep_debug.cpp
===================================================================
--- brlcad/trunk/src/librt/primitives/brep/brep_debug.cpp 2010-12-29
01:52:48 UTC (rev 41824)
+++ brlcad/trunk/src/librt/primitives/brep/brep_debug.cpp 2010-12-29
01:54:10 UTC (rev 41825)
@@ -83,6 +83,7 @@
return plot;
}
+
#define ARB_FACE(valp, a, b, c, d) \
RT_ADD_VLIST(vhead, valp[a], BN_VLIST_LINE_MOVE); \
RT_ADD_VLIST(vhead, valp[b], BN_VLIST_LINE_DRAW); \
@@ -485,7 +486,6 @@
}
-
void
plottrimdirection(ON_BrepFace &face, struct bn_vlblock *vbp, int plotres)
{
@@ -611,20 +611,21 @@
return;
}
+
void
plotsurfaceknots(ON_Surface &surf, struct bn_vlblock *vbp)
{
register struct bu_list *vhead;
double pt1[3], pt2[3];
ON_2dPoint from, to;
- int spanu_cnt = surf.SpanCount(0);
- int spanv_cnt = surf.SpanCount(1);
- double *spanu = NULL;
- double *spanv = NULL;
- spanu = new double[spanu_cnt+1];
- spanv = new double[spanv_cnt+1];
- surf.GetSpanVector(0,spanu);
- surf.GetSpanVector(1,spanv);
+ int spanu_cnt = surf.SpanCount(0);
+ int spanv_cnt = surf.SpanCount(1);
+ double *spanu = NULL;
+ double *spanv = NULL;
+ spanu = new double[spanu_cnt+1];
+ spanv = new double[spanv_cnt+1];
+ surf.GetSpanVector(0, spanu);
+ surf.GetSpanVector(1, spanv);
vhead = rt_vlblock_find(vbp, YELLOW);
@@ -646,6 +647,7 @@
return;
}
+
void
plotcurve(ON_Curve &curve, struct bn_vlblock *vbp, int plotres)
{
@@ -916,7 +918,7 @@
int
brep_facetrim_plot(struct bu_vls *vls, struct brep_specific* bs, struct
rt_brep_internal*, struct bn_vlblock *vbp, int index, int plotres, bool dim3d)
{
- ON_wString wstr;
+ ON_wString wstr;
ON_TextLog tl(wstr);
ON_Brep* brep = bs->brep;
@@ -950,7 +952,7 @@
int
brep_trim_direction_plot(struct bu_vls *vls, struct brep_specific* bs, struct
rt_brep_internal*, struct bn_vlblock *vbp, int index, int plotres)
{
- ON_wString wstr;
+ ON_wString wstr;
ON_TextLog tl(wstr);
ON_Brep* brep = bs->brep;
@@ -980,7 +982,7 @@
int
brep_surface_plot(struct bu_vls *vls, struct brep_specific* bs, struct
rt_brep_internal*, struct bn_vlblock *vbp, int index, int plotres)
{
- ON_wString wstr;
+ ON_wString wstr;
ON_TextLog tl(wstr);
ON_Brep* brep = bs->brep;
@@ -1008,7 +1010,7 @@
int
brep_surface_normal_plot(struct bu_vls *vls, struct brep_specific* bs, struct
rt_brep_internal*, struct bn_vlblock *vbp, int index, int plotres)
{
- ON_wString wstr;
+ ON_wString wstr;
ON_TextLog tl(wstr);
ON_Brep* brep = bs->brep;
@@ -1025,7 +1027,7 @@
} else if (index < brep->m_S.Count()) {
ON_Surface *surf = brep->m_S[index];
surf->Dump(tl);
- plotsurfaceknots(*surf, vbp);
+ plotsurfaceknots(*surf, vbp);
plotsurfacenormals(*surf, vbp, plotres);
}
@@ -1033,10 +1035,11 @@
return 0;
}
+
int
brep_surface_knot_plot(struct bu_vls *vls, struct brep_specific* bs, struct
rt_brep_internal*, struct bn_vlblock *vbp, int index)
{
- ON_wString wstr;
+ ON_wString wstr;
ON_TextLog tl(wstr);
ON_Brep* brep = bs->brep;
@@ -1052,7 +1055,7 @@
} else if (index < brep->m_S.Count()) {
ON_Surface *surf = brep->m_S[index];
surf->Dump(tl);
- plotsurfaceknots(*surf, vbp);
+ plotsurfaceknots(*surf, vbp);
}
bu_vls_printf(vls, ON_String(wstr).Array());
@@ -1063,7 +1066,7 @@
int
brep_edge3d_plot(struct bu_vls *vls, struct brep_specific* bs, struct
rt_brep_internal*, struct bn_vlblock *vbp, int index, int plotres)
{
- ON_wString wstr;
+ ON_wString wstr;
ON_TextLog tl(wstr);
ON_Brep* brep = bs->brep;
@@ -1091,7 +1094,7 @@
int
brep_trim_plot(struct bu_vls *vls, struct brep_specific* bs, struct
rt_brep_internal*, struct bn_vlblock *vbp, int index, int plotres, bool dim3d)
{
- ON_wString wstr;
+ ON_wString wstr;
ON_TextLog tl(wstr);
ON_Brep* brep = bs->brep;
@@ -1114,545 +1117,553 @@
return 0;
}
+
/* a binary predicate for std:list implemented as a function */
extern bool near_equal (double first, double second);
void
-plotFace(SurfaceTree* st, struct bn_vlblock *vbp, int isocurveres, int gridres)
+plotFace(SurfaceTree* st, struct bn_vlblock *vbp, int UNUSED(isocurveres), int
gridres)
{
register struct bu_list *vhead;
- double pt1[3], pt2[3];
- ON_2dPoint from, to;
- std::list<BRNode*> m_trims_above_or_right;
- std::list<double> trim_hits;
+ double pt1[3], pt2[3];
+ ON_2dPoint from, to;
+ std::list<BRNode*> m_trims_above_or_right;
+ std::list<double> trim_hits;
- vhead = rt_vlblock_find(vbp, PEACH);
+ vhead = rt_vlblock_find(vbp, PEACH);
- const ON_Surface *surf = st->getSurface();
- CurveTree *ctree = st->ctree;
- ON_Interval udom = surf->Domain(0);
- ON_Interval vdom = surf->Domain(1);
- //bu_log("udom %f,%f vdom
%f,%f\n",udom.m_t[0],udom.m_t[1],vdom.m_t[0],vdom.m_t[1]);
+ const ON_Surface *surf = st->getSurface();
+ CurveTree *ctree = st->ctree;
+ ON_Interval udom = surf->Domain(0);
+ ON_Interval vdom = surf->Domain(1);
+ //bu_log("udom %f, %f vdom %f, %f\n", udom.m_t[0], udom.m_t[1],
vdom.m_t[0], vdom.m_t[1]);
- m_trims_above_or_right.clear();
+ m_trims_above_or_right.clear();
ON_2dPoint pt;
- for (int gd = 1; gd < gridres; gd++) {
+ for (int gd = 1; gd < gridres; gd++) {
- pt.x = udom.ParameterAt((double)gd /(double)gridres);
- pt.y = vdom.ParameterAt(0.0);
+ pt.x = udom.ParameterAt((double)gd /(double)gridres);
+ pt.y = vdom.ParameterAt(0.0);
- if (ctree != NULL) {
- m_trims_above_or_right.clear();
- ctree->getLeavesAbove(m_trims_above_or_right, pt,
0.0000001);
- }
- int cnt=1;
- //bu_log("U - %f\n",pt.x);
- trim_hits.clear();
- for (std::list<BRNode*>::iterator i =
m_trims_above_or_right.begin(); i != m_trims_above_or_right.end(); i++,cnt++) {
- BRNode* br = dynamic_cast<BRNode*>(*i);
+ if (ctree != NULL) {
+ m_trims_above_or_right.clear();
+ ctree->getLeavesAbove(m_trims_above_or_right, pt, 0.0000001);
+ }
+ int cnt=1;
+ //bu_log("U - %f\n", pt.x);
+ trim_hits.clear();
+ for (std::list<BRNode*>::iterator i = m_trims_above_or_right.begin(); i
!= m_trims_above_or_right.end(); i++, cnt++) {
+ BRNode* br = dynamic_cast<BRNode*>(*i);
- point_t bmin, bmax;
- br->GetBBox(bmin, bmax);
- if ((bmin[X] <= pt[X]) && (pt[X] <= bmax[X])) { //if check
trim and in BBox
- fastf_t v = br->getCurveEstimateOfV(pt[X],
0.0000001);
- trim_hits.push_back(v);
- //bu_log("%d V %d - %f pt %f,%f bmin %f,%f
bmax
%f,%f\n",br->m_face->m_face_index,cnt,v,pt.x,pt.y,bmin[X],bmin[Y],bmax[X],bmax[Y]);
+ point_t bmin, bmax;
+ br->GetBBox(bmin, bmax);
+ if ((bmin[X] <= pt[X]) && (pt[X] <= bmax[X])) { //if check trim and
in BBox
+ fastf_t v = br->getCurveEstimateOfV(pt[X], 0.0000001);
+ trim_hits.push_back(v);
+ //bu_log("%d V %d - %f pt %f, %f bmin %f, %f bmax %f, %f\n",
br->m_face->m_face_index, cnt, v, pt.x, pt.y, bmin[X], bmin[Y], bmax[X],
bmax[Y]);
+ }
+ }
+ trim_hits.sort();
+ trim_hits.unique(near_equal);
+
+ size_t hit_cnt = trim_hits.size();
+
+ if ((hit_cnt > 1) && ((hit_cnt % 2) == 0)) {
+ //bu_log("U - %f\n", pt.x);
+ while (!trim_hits.empty()) {
+ double tfrom = trim_hits.front();
+ trim_hits.pop_front();
+ double tto = trim_hits.front();
+ trim_hits.pop_front();
+ //bu_log("\tfrom - %f, to - %f\n", tfrom, tto);
+ fastf_t deltay = (tto-tfrom)/50.0;
+ for (fastf_t y = tfrom; y < tto - deltay; y = y + deltay) {
+ ON_3dPoint p = surf->PointAt(pt.x, y);
+ //bu_log("p1 2d - %f, %f 3d - %f, %f, %f\n", pt.x, y, p.x,
p.y, p.z);
+ VMOVE(pt1, p);
+ p = surf->PointAt(pt.x, y+deltay);
+ if (y+deltay > tto) {
+ p = surf->PointAt(pt.x, tto);
+ } else {
+ p = surf->PointAt(pt.x, y+deltay);
}
+ //bu_log("p1 2d - %f, %f 3d - %f, %f, %f\n", pt.x,
y+deltay, p.x, p.y, p.z);
+ VMOVE(pt2, p);
+ RT_ADD_VLIST(vhead, pt1, BN_VLIST_LINE_MOVE);
+ RT_ADD_VLIST(vhead, pt2, BN_VLIST_LINE_DRAW);
}
- trim_hits.sort();
- trim_hits.unique(near_equal);
- size_t hit_cnt = trim_hits.size();
+ }
+ }
+ // v direction
+ pt.x = udom.ParameterAt(0.0);
+ pt.y = vdom.ParameterAt((double)gd /(double)gridres);
- if ((hit_cnt > 1) && ((hit_cnt % 2) == 0)) {
- //bu_log("U - %f\n",pt.x);
- while (!trim_hits.empty())
- {
- double from = trim_hits.front();
- trim_hits.pop_front();
- double to = trim_hits.front();
- trim_hits.pop_front();
- //bu_log("\tfrom - %f, to - %f\n",from,to);
- fastf_t deltay = (to-from)/50.0;
- for (fastf_t y = from; y < to - deltay;
y = y + deltay) {
- ON_3dPoint p =
surf->PointAt(pt.x, y);
- //bu_log("p1 2d - %f,%f 3d -
%f,%f,%f\n",pt.x, y,p.x,p.y,p.z);
- VMOVE(pt1, p);
- p =
surf->PointAt(pt.x,y+deltay);
- if (y+deltay > to ) {
- p =
surf->PointAt(pt.x,to);
- } else {
- p =
surf->PointAt(pt.x,y+deltay);
- }
- //bu_log("p1 2d - %f,%f 3d -
%f,%f,%f\n",pt.x,y+deltay,p.x,p.y,p.z);
- VMOVE(pt2, p);
- RT_ADD_VLIST(vhead, pt1,
BN_VLIST_LINE_MOVE);
- RT_ADD_VLIST(vhead, pt2,
BN_VLIST_LINE_DRAW);
- }
+ if (ctree != NULL) {
+ m_trims_above_or_right.clear();
+ ctree->getLeavesRight(m_trims_above_or_right, pt, 0.0000001);
+ }
- }
- }
- // v direction
- pt.x = udom.ParameterAt(0.0);
- pt.y = vdom.ParameterAt((double)gd /(double)gridres);
+ cnt=1;
+ //bu_log("V - %f\n", pt.x);
+ trim_hits.clear();
+ for (std::list<BRNode*>::iterator i = m_trims_above_or_right.begin(); i
!= m_trims_above_or_right.end(); i++, cnt++) {
+ BRNode* br = dynamic_cast<BRNode*>(*i);
- if (ctree != NULL) {
- m_trims_above_or_right.clear();
- ctree->getLeavesRight(m_trims_above_or_right, pt,
0.0000001);
- }
+ point_t bmin, bmax;
+ br->GetBBox(bmin, bmax);
+ if ((bmin[Y] <= pt[Y]) && (pt[Y] <= bmax[Y])) { //if check trim and
in BBox
+ fastf_t u = br->getCurveEstimateOfU(pt[Y], 0.0000001);
+ trim_hits.push_back(u);
+ //bu_log("%d U %d - %f pt %f, %f bmin %f, %f bmax %f, %f\n",
br->m_face->m_face_index, cnt, u, pt.x, pt.y, bmin[X], bmin[Y], bmax[X],
bmax[Y]);
+ }
+ }
+ trim_hits.sort();
+ trim_hits.unique(near_equal);
- cnt=1;
- //bu_log("V - %f\n",pt.x);
- trim_hits.clear();
- for (std::list<BRNode*>::iterator i =
m_trims_above_or_right.begin(); i != m_trims_above_or_right.end(); i++,cnt++) {
- BRNode* br = dynamic_cast<BRNode*>(*i);
+ hit_cnt = trim_hits.size();
- point_t bmin, bmax;
- br->GetBBox(bmin, bmax);
- if ((bmin[Y] <= pt[Y]) && (pt[Y] <= bmax[Y])) { //if check
trim and in BBox
- fastf_t u = br->getCurveEstimateOfU(pt[Y],
0.0000001);
- trim_hits.push_back(u);
- //bu_log("%d U %d - %f pt %f,%f bmin %f,%f
bmax
%f,%f\n",br->m_face->m_face_index,cnt,u,pt.x,pt.y,bmin[X],bmin[Y],bmax[X],bmax[Y]);
+ if ((hit_cnt > 1) && ((hit_cnt % 2) == 0)) {
+ //bu_log("V - %f\n", pt.y);
+ while (!trim_hits.empty())
+ {
+ double tfrom = trim_hits.front();
+ trim_hits.pop_front();
+ double tto = trim_hits.front();
+ trim_hits.pop_front();
+ //bu_log("\tfrom - %f, to - %f\n", tfrom, tto);
+ fastf_t deltax = (tto-tfrom)/50.0;
+ for (fastf_t x = tfrom; x < tto; x = x + deltax) {
+ ON_3dPoint p = surf->PointAt(x, pt.y);
+ VMOVE(pt1, p);
+ if (x+deltax > tto) {
+ p = surf->PointAt(tto, pt.y);
+ } else {
+ p = surf->PointAt(x+deltax, pt.y);
}
+ VMOVE(pt2, p);
+ RT_ADD_VLIST(vhead, pt1, BN_VLIST_LINE_MOVE);
+ RT_ADD_VLIST(vhead, pt2, BN_VLIST_LINE_DRAW);
}
- trim_hits.sort();
- trim_hits.unique(near_equal);
- hit_cnt = trim_hits.size();
+ }
+ }
- if ((hit_cnt > 1) && ((hit_cnt % 2) == 0)) {
- //bu_log("V - %f\n",pt.y);
- while (!trim_hits.empty())
- {
- double from = trim_hits.front();
- trim_hits.pop_front();
- double to = trim_hits.front();
- trim_hits.pop_front();
- //bu_log("\tfrom - %f, to - %f\n",from,to);
- fastf_t deltax = (to-from)/50.0;
- for (fastf_t x = from; x < to; x = x +
deltax) {
- ON_3dPoint p = surf->PointAt(x,
pt.y);
- VMOVE(pt1, p);
- if (x+deltax > to ) {
- p =
surf->PointAt(to,pt.y);
- } else {
- p =
surf->PointAt(x+deltax,pt.y);
- }
- VMOVE(pt2, p);
- RT_ADD_VLIST(vhead, pt1,
BN_VLIST_LINE_MOVE);
- RT_ADD_VLIST(vhead, pt2,
BN_VLIST_LINE_DRAW);
- }
+ }
- }
- }
+ return;
+}
- }
- return;
-}
-
void
-drawisoUCheckForTrim(SurfaceTree* st, struct bn_vlblock *vbp,fastf_t from,
fastf_t to, fastf_t v, int curveres)
+drawisoUCheckForTrim(SurfaceTree* st, struct bn_vlblock *vbp, fastf_t from,
fastf_t to, fastf_t v, int UNUSED(curveres))
{
register struct bu_list *vhead;
- double pt1[3], pt2[3];
- std::list<BRNode*> m_trims_right;
- std::list<double> trim_hits;
+ double pt1[3], pt2[3];
+ std::list<BRNode*> m_trims_right;
+ std::list<double> trim_hits;
- vhead = rt_vlblock_find(vbp, YELLOW);
+ vhead = rt_vlblock_find(vbp, YELLOW);
- const ON_Surface *surf = st->getSurface();
- CurveTree *ctree = st->ctree;
+ const ON_Surface *surf = st->getSurface();
+ CurveTree *ctree = st->ctree;
double umin, umax;
surf->GetDomain(0, &umin, &umax);
- m_trims_right.clear();
+ m_trims_right.clear();
fastf_t tol = 0.001;
ON_2dPoint pt;
pt.x = umin;
- pt.y = v;
+ pt.y = v;
if (ctree != NULL) {
m_trims_right.clear();
- ctree->getLeavesRight(m_trims_right, pt, tol);
- }
+ ctree->getLeavesRight(m_trims_right, pt, tol);
+ }
- int cnt = 1;
- //bu_log("V - %f\n",pt.x);
- trim_hits.clear();
- for (std::list<BRNode*>::iterator i = m_trims_right.begin(); i !=
m_trims_right.end(); i++, cnt++) {
- BRNode* br = dynamic_cast<BRNode*> (*i);
+ int cnt = 1;
+ //bu_log("V - %f\n", pt.x);
+ trim_hits.clear();
+ for (std::list<BRNode*>::iterator i = m_trims_right.begin(); i !=
m_trims_right.end(); i++, cnt++) {
+ BRNode* br = dynamic_cast<BRNode*> (*i);
- point_t bmin, bmax;
- if (!br->m_Horizontal) {
- br->GetBBox(bmin, bmax);
- if (((bmin[Y] - tol) <= pt[Y]) && (pt[Y] <=
(bmax[Y]+tol))) { //if check trim and in BBox
- fastf_t u = br->getCurveEstimateOfU(pt[Y], tol);
- trim_hits.push_back(u);
- //bu_log("%d U %d - %f pt %f,%f bmin %f,%f
bmax
%f,%f\n",br->m_face->m_face_index,cnt,u,pt.x,pt.y,bmin[X],bmin[Y],bmax[X],bmax[Y]);
- }
- }
+ point_t bmin, bmax;
+ if (!br->m_Horizontal) {
+ br->GetBBox(bmin, bmax);
+ if (((bmin[Y] - tol) <= pt[Y]) && (pt[Y] <= (bmax[Y]+tol))) { //if
check trim and in BBox
+ fastf_t u = br->getCurveEstimateOfU(pt[Y], tol);
+ trim_hits.push_back(u);
+ //bu_log("%d U %d - %f pt %f, %f bmin %f, %f bmax %f, %f\n",
br->m_face->m_face_index, cnt, u, pt.x, pt.y, bmin[X], bmin[Y], bmax[X],
bmax[Y]);
+ }
}
- trim_hits.sort();
- trim_hits.unique(near_equal);
+ }
+ trim_hits.sort();
+ trim_hits.unique(near_equal);
- int hit_cnt = trim_hits.size();
- cnt = 1;
- //bu_log("\tdrawisoUCheckForTrim: hit_cnt %d from center %f %f 0.0 to
center %f %f 0.0\n",hit_cnt,from,v ,to,v);
+ int hit_cnt = trim_hits.size();
+ cnt = 1;
+ //bu_log("\tdrawisoUCheckForTrim: hit_cnt %d from center %f %f 0.0 to
center %f %f 0.0\n", hit_cnt, from, v , to, v);
- if ((hit_cnt > 0) && ((hit_cnt % 2) == 0)){
+ if ((hit_cnt > 0) && ((hit_cnt % 2) == 0)) {
/*
- if ((hit_cnt % 2) != 0) {
- //bu_log("V - %f\n",pt.y);
- if (!trim_hits.empty()) {
- double end = trim_hits.front();
- trim_hits.pop_front();
- //bu_log("\tfrom - %f, to - %f\n",from,to);
- fastf_t deltax = (end - from) / 50.0;
- if (deltax > 0.001) {
- for (fastf_t x = from; x < end && x <
to; x = x + deltax) {
- ON_3dPoint p = surf->PointAt(x,
pt.y);
- VMOVE(pt1, p);
- if (x + deltax > end) {
- if (x + deltax > to) {
- p =
surf->PointAt(to, pt.y);
- } else {
- p =
surf->PointAt(end, pt.y);
- }
- } else {
- if (x + deltax > to) {
- p =
surf->PointAt(to, pt.y);
- } else {
- p =
surf->PointAt(x + deltax, pt.y);
- }
- }
- VMOVE(pt2, p);
+ if ((hit_cnt % 2) != 0) {
+ //bu_log("V - %f\n", pt.y);
+ if (!trim_hits.empty()) {
+ double end = trim_hits.front();
+ trim_hits.pop_front();
+ //bu_log("\tfrom - %f, to - %f\n", from, to);
+ fastf_t deltax = (end - from) / 50.0;
+ if (deltax > 0.001) {
+ for (fastf_t x = from; x < end && x < to; x = x + deltax) {
+ ON_3dPoint p = surf->PointAt(x, pt.y);
+ VMOVE(pt1, p);
+ if (x + deltax > end) {
+ if (x + deltax > to) {
+ p = surf->PointAt(to, pt.y);
+ } else {
+ p = surf->PointAt(end, pt.y);
+ }
+ } else {
+ if (x + deltax > to) {
+ p = surf->PointAt(to, pt.y);
+ } else {
+ p = surf->PointAt(x + deltax, pt.y);
+ }
+ }
+ VMOVE(pt2, p);
- //bu_log(
- // "\t\t%d from
center %f %f 0.0 to center %f %f 0.0\n",
- // cnt++, x, v, x
+ deltax, v);
+ //bu_log(
+ // "\t\t%d from center %f %f 0.0 to center %f %f 0.0\n",
+ // cnt++, x, v, x + deltax, v);
- RT_ADD_VLIST(vhead, pt1,
BN_VLIST_LINE_MOVE);
- RT_ADD_VLIST(vhead, pt2,
BN_VLIST_LINE_DRAW);
- }
- }
- }
- }
+ RT_ADD_VLIST(vhead, pt1, BN_VLIST_LINE_MOVE);
+ RT_ADD_VLIST(vhead, pt2, BN_VLIST_LINE_DRAW);
+ }
+ }
+ }
+ }
*/
- while (!trim_hits.empty()) {
- double start = trim_hits.front();
- if (start < from) {
- start = from;
- }
- trim_hits.pop_front();
- double end = trim_hits.front();
- if (end > to) {
- end = to;
- }
- trim_hits.pop_front();
- //bu_log("\tfrom - %f, to - %f\n",from,to);
- fastf_t deltax = (end - start) / 50.0;
- if (deltax > 0.001) {
- for (fastf_t x = start; x < end; x = x +
deltax) {
- ON_3dPoint p = surf->PointAt(x, pt.y);
- VMOVE(pt1, p);
- if (x + deltax > end) {
- p = surf->PointAt(end, pt.y);
- } else {
- p = surf->PointAt(x + deltax,
pt.y);
- }
- VMOVE(pt2, p);
+ while (!trim_hits.empty()) {
+ double start = trim_hits.front();
+ if (start < from) {
+ start = from;
+ }
+ trim_hits.pop_front();
+ double end = trim_hits.front();
+ if (end > to) {
+ end = to;
+ }
+ trim_hits.pop_front();
+ //bu_log("\tfrom - %f, to - %f\n", from, to);
+ fastf_t deltax = (end - start) / 50.0;
+ if (deltax > 0.001) {
+ for (fastf_t x = start; x < end; x = x + deltax) {
+ ON_3dPoint p = surf->PointAt(x, pt.y);
+ VMOVE(pt1, p);
+ if (x + deltax > end) {
+ p = surf->PointAt(end, pt.y);
+ } else {
+ p = surf->PointAt(x + deltax, pt.y);
+ }
+ VMOVE(pt2, p);
- // bu_log(
- // "\t\t%d from center %f
%f 0.0 to center %f %f 0.0\n",
- // cnt++, x, v, x +
deltax, v);
+ // bu_log(
+ // "\t\t%d from
center %f %f 0.0 to center %f %f 0.0\n",
+ // cnt++, x, v, x
+ deltax, v);
- RT_ADD_VLIST(vhead, pt1,
BN_VLIST_LINE_MOVE);
- RT_ADD_VLIST(vhead, pt2,
BN_VLIST_LINE_DRAW);
- }
- }
+ RT_ADD_VLIST(vhead, pt1, BN_VLIST_LINE_MOVE);
+ RT_ADD_VLIST(vhead, pt2, BN_VLIST_LINE_DRAW);
}
+ }
}
+ }
- return;
+ return;
}
+
void
-drawisoVCheckForTrim(SurfaceTree* st, struct bn_vlblock *vbp,fastf_t from,
fastf_t to, fastf_t u, int curveres)
+drawisoVCheckForTrim(SurfaceTree* st, struct bn_vlblock *vbp, fastf_t from,
fastf_t to, fastf_t u, int UNUSED(curveres))
{
register struct bu_list *vhead;
- double pt1[3], pt2[3];
- std::list<BRNode*> m_trims_above;
- std::list<double> trim_hits;
+ double pt1[3], pt2[3];
+ std::list<BRNode*> m_trims_above;
+ std::list<double> trim_hits;
- vhead = rt_vlblock_find(vbp, YELLOW);
+ vhead = rt_vlblock_find(vbp, YELLOW);
- const ON_Surface *surf = st->getSurface();
- CurveTree *ctree = st->ctree;
+ const ON_Surface *surf = st->getSurface();
+ CurveTree *ctree = st->ctree;
double vmin, vmax;
surf->GetDomain(1, &vmin, &vmax);
- m_trims_above.clear();
+ m_trims_above.clear();
fastf_t tol = 0.001;
ON_2dPoint pt;
pt.x = u;
- pt.y = vmin;
+ pt.y = vmin;
if (ctree != NULL) {
m_trims_above.clear();
- ctree->getLeavesAbove(m_trims_above, pt, tol);
- }
+ ctree->getLeavesAbove(m_trims_above, pt, tol);
+ }
- int cnt = 1;
- trim_hits.clear();
- for (std::list<BRNode*>::iterator i = m_trims_above.begin(); i !=
m_trims_above.end(); i++,cnt++) {
- BRNode* br = dynamic_cast<BRNode*>(*i);
+ int cnt = 1;
+ trim_hits.clear();
+ for (std::list<BRNode*>::iterator i = m_trims_above.begin(); i !=
m_trims_above.end(); i++, cnt++) {
+ BRNode* br = dynamic_cast<BRNode*>(*i);
- point_t bmin, bmax;
- if (!br->m_Vertical) {
- br->GetBBox(bmin, bmax);
+ point_t bmin, bmax;
+ if (!br->m_Vertical) {
+ br->GetBBox(bmin, bmax);
- if (((bmin[X] - tol) <= pt[X]) && (pt[X] <=
(bmax[X]+tol))) { //if check trim and in BBox
- fastf_t v = br->getCurveEstimateOfV(pt[X], tol);
- trim_hits.push_back(v);
- //bu_log("%d V %d - %f pt %f,%f bmin %f,%f
bmax
%f,%f\n",br->m_face->m_face_index,cnt,v,pt.x,pt.y,bmin[X],bmin[Y],bmax[X],bmax[Y]);
- }
+ if (((bmin[X] - tol) <= pt[X]) && (pt[X] <= (bmax[X]+tol))) { //if
check trim and in BBox
+ fastf_t v = br->getCurveEstimateOfV(pt[X], tol);
+ trim_hits.push_back(v);
+ //bu_log("%d V %d - %f pt %f, %f bmin %f, %f bmax %f, %f\n",
br->m_face->m_face_index, cnt, v, pt.x, pt.y, bmin[X], bmin[Y], bmax[X],
bmax[Y]);
}
}
- trim_hits.sort();
- trim_hits.unique(near_equal);
+ }
+ trim_hits.sort();
+ trim_hits.unique(near_equal);
- size_t hit_cnt = trim_hits.size();
- cnt = 1;
+ size_t hit_cnt = trim_hits.size();
+ cnt = 1;
- //bu_log("\tdrawisoVCheckForTrim: hit_cnt %d from center %f %f 0.0 to
center %f %f 0.0\n",hit_cnt,u,from,u,to);
+ //bu_log("\tdrawisoVCheckForTrim: hit_cnt %d from center %f %f 0.0 to
center %f %f 0.0\n", hit_cnt, u, from, u, to);
- if ((hit_cnt > 0) && ((hit_cnt % 2) == 0)){
+ if ((hit_cnt > 0) && ((hit_cnt % 2) == 0)) {
/*
- if ((hit_cnt % 2) != 0) { //odd starting inside
- //bu_log("V - %f\n",pt.y);
- if (!trim_hits.empty()) {
- double end = trim_hits.front();
- trim_hits.pop_front();
- //bu_log("\tfrom - %f, to - %f\n",from,to);
- fastf_t deltay = (end - from) / 50.0;
- if (deltay > 0.001) {
- for (fastf_t y = from; y < end && y <
to; y = y + deltay) {
- ON_3dPoint p =
surf->PointAt(pt.x, y);
- VMOVE(pt1, p);
- if (y + deltay > end) {
- if (y + deltay > to) {
- p =
surf->PointAt(pt.x, to);
- } else {
- p =
surf->PointAt(pt.x, end);
- }
- } else {
- if (y + deltay > to) {
- p =
surf->PointAt(pt.x, to);
- } else {
- p =
surf->PointAt(pt.x, y + deltay);
- }
- }
- VMOVE(pt2, p);
+ if ((hit_cnt % 2) != 0) { //odd starting inside
+ //bu_log("V - %f\n", pt.y);
+ if (!trim_hits.empty()) {
+ double end = trim_hits.front();
+ trim_hits.pop_front();
+ //bu_log("\tfrom - %f, to - %f\n", from, to);
+ fastf_t deltay = (end - from) / 50.0;
+ if (deltay > 0.001) {
+ for (fastf_t y = from; y < end && y < to; y = y + deltay) {
+ ON_3dPoint p = surf->PointAt(pt.x, y);
+ VMOVE(pt1, p);
+ if (y + deltay > end) {
+ if (y + deltay > to) {
+ p = surf->PointAt(pt.x, to);
+ } else {
+ p = surf->PointAt(pt.x, end);
+ }
+ } else {
+ if (y + deltay > to) {
+ p = surf->PointAt(pt.x, to);
+ } else {
+ p = surf->PointAt(pt.x, y + deltay);
+ }
+ }
+ VMOVE(pt2, p);
- //bu_log(
- // "\t\t%d from
center %f %f 0.0 to center %f %f 0.0\n",
- // cnt++, u, y, u,
y + deltay);
+ //bu_log(
+ // "\t\t%d from center %f %f 0.0 to center %f %f 0.0\n",
+ // cnt++, u, y, u, y + deltay);
- RT_ADD_VLIST(vhead, pt1,
BN_VLIST_LINE_MOVE);
- RT_ADD_VLIST(vhead, pt2,
BN_VLIST_LINE_DRAW);
- }
- }
+ RT_ADD_VLIST(vhead, pt1, BN_VLIST_LINE_MOVE);
+ RT_ADD_VLIST(vhead, pt2, BN_VLIST_LINE_DRAW);
+ }
+ }
- }
- }
+ }
+ }
*/
- while (!trim_hits.empty()) {
- double start = trim_hits.front();
- trim_hits.pop_front();
- if (start < from) {
- start = from;
- }
- double end = trim_hits.front();
- trim_hits.pop_front();
- if (end > to) {
- end = to;
- }
- //bu_log("\tfrom - %f, to - %f\n",from,to);
- fastf_t deltay = (end - start) / 50.0;
- if (deltay > 0.001) {
- for (fastf_t y = start; y < end; y = y +
deltay) {
- ON_3dPoint p = surf->PointAt(pt.x, y);
- VMOVE(pt1, p);
- if (y + deltay > end) {
- p = surf->PointAt(pt.x, end);
- } else {
- p = surf->PointAt(pt.x, y +
deltay);
- }
- VMOVE(pt2, p);
+ while (!trim_hits.empty()) {
+ double start = trim_hits.front();
+ trim_hits.pop_front();
+ if (start < from) {
+ start = from;
+ }
+ double end = trim_hits.front();
+ trim_hits.pop_front();
+ if (end > to) {
+ end = to;
+ }
+ //bu_log("\tfrom - %f, to - %f\n", from, to);
+ fastf_t deltay = (end - start) / 50.0;
+ if (deltay > 0.001) {
+ for (fastf_t y = start; y < end; y = y + deltay) {
+ ON_3dPoint p = surf->PointAt(pt.x, y);
+ VMOVE(pt1, p);
+ if (y + deltay > end) {
+ p = surf->PointAt(pt.x, end);
+ } else {
+ p = surf->PointAt(pt.x, y + deltay);
+ }
+ VMOVE(pt2, p);
- //bu_log("\t\t%d from center %f %f 0.0
to center %f %f 0.0\n",
- // cnt++, u, y, u, y +
deltay);
+ //bu_log("\t\t%d from center %f %f 0.0 to center %f %f
0.0\n",
+ // cnt++, u, y, u, y + deltay);
- RT_ADD_VLIST(vhead, pt1,
BN_VLIST_LINE_MOVE);
- RT_ADD_VLIST(vhead, pt2,
BN_VLIST_LINE_DRAW);
- }
- }
+ RT_ADD_VLIST(vhead, pt1, BN_VLIST_LINE_MOVE);
+ RT_ADD_VLIST(vhead, pt2, BN_VLIST_LINE_DRAW);
}
+ }
}
- return;
+ }
+ return;
}
+
void
-drawisoU(SurfaceTree* st, struct bn_vlblock *vbp,fastf_t from, fastf_t to,
fastf_t v, int curveres)
+drawisoU(SurfaceTree* st, struct bn_vlblock *vbp, fastf_t from, fastf_t to,
fastf_t v, int curveres)
{
- register struct bu_list *vhead;
- double pt1[3], pt2[3];
- fastf_t deltau = (to - from) / curveres;
- const ON_Surface *surf = st->getSurface();
+ register struct bu_list *vhead;
+ double pt1[3], pt2[3];
+ fastf_t deltau = (to - from) / curveres;
+ const ON_Surface *surf = st->getSurface();
- vhead = rt_vlblock_find(vbp, YELLOW);
- for (fastf_t u = from; u < to; u = u + deltau) {
- ON_3dPoint p = surf->PointAt(u, v);
- //bu_log("p1 2d - %f,%f 3d - %f,%f,%f\n",pt.x, y,p.x,p.y,p.z);
- VMOVE(pt1, p);
- if (u + deltau > to) {
- p = surf->PointAt(to, v);
- } else {
- p = surf->PointAt(u + deltau, v);
- }
- //bu_log("p1 2d - %f,%f 3d -
%f,%f,%f\n",pt.x,y+deltay,p.x,p.y,p.z);
- VMOVE(pt2, p);
- RT_ADD_VLIST(vhead, pt1, BN_VLIST_LINE_MOVE);
- RT_ADD_VLIST(vhead, pt2, BN_VLIST_LINE_DRAW);
+ vhead = rt_vlblock_find(vbp, YELLOW);
+ for (fastf_t u = from; u < to; u = u + deltau) {
+ ON_3dPoint p = surf->PointAt(u, v);
+ //bu_log("p1 2d - %f, %f 3d - %f, %f, %f\n", pt.x, y, p.x, p.y, p.z);
+ VMOVE(pt1, p);
+ if (u + deltau > to) {
+ p = surf->PointAt(to, v);
+ } else {
+ p = surf->PointAt(u + deltau, v);
}
+ //bu_log("p1 2d - %f, %f 3d - %f, %f, %f\n", pt.x, y+deltay, p.x, p.y,
p.z);
+ VMOVE(pt2, p);
+ RT_ADD_VLIST(vhead, pt1, BN_VLIST_LINE_MOVE);
+ RT_ADD_VLIST(vhead, pt2, BN_VLIST_LINE_DRAW);
+ }
}
+
void
-drawisoV(SurfaceTree* st, struct bn_vlblock *vbp,fastf_t from, fastf_t to,
fastf_t u, int curveres)
+drawisoV(SurfaceTree* st, struct bn_vlblock *vbp, fastf_t from, fastf_t to,
fastf_t u, int curveres)
{
- register struct bu_list *vhead;
- double pt1[3], pt2[3];
- fastf_t deltav = (to - from) / curveres;
- const ON_Surface *surf = st->getSurface();
+ register struct bu_list *vhead;
+ double pt1[3], pt2[3];
+ fastf_t deltav = (to - from) / curveres;
+ const ON_Surface *surf = st->getSurface();
- vhead = rt_vlblock_find(vbp, YELLOW);
- for (fastf_t v = from; v < to; v = v + deltav) {
- ON_3dPoint p = surf->PointAt(u, v);
- //bu_log("p1 2d - %f,%f 3d - %f,%f,%f\n",pt.x, y,p.x,p.y,p.z);
- VMOVE(pt1, p);
- if (v + deltav > to) {
- p = surf->PointAt(u, to);
- } else {
- p = surf->PointAt(u, v + deltav);
- }
- //bu_log("p1 2d - %f,%f 3d -
%f,%f,%f\n",pt.x,y+deltay,p.x,p.y,p.z);
- VMOVE(pt2, p);
- RT_ADD_VLIST(vhead, pt1, BN_VLIST_LINE_MOVE);
- RT_ADD_VLIST(vhead, pt2, BN_VLIST_LINE_DRAW);
+ vhead = rt_vlblock_find(vbp, YELLOW);
+ for (fastf_t v = from; v < to; v = v + deltav) {
+ ON_3dPoint p = surf->PointAt(u, v);
+ //bu_log("p1 2d - %f, %f 3d - %f, %f, %f\n", pt.x, y, p.x, p.y, p.z);
+ VMOVE(pt1, p);
+ if (v + deltav > to) {
+ p = surf->PointAt(u, to);
+ } else {
+ p = surf->PointAt(u, v + deltav);
}
+ //bu_log("p1 2d - %f, %f 3d - %f, %f, %f\n", pt.x, y+deltay, p.x, p.y,
p.z);
+ VMOVE(pt2, p);
+ RT_ADD_VLIST(vhead, pt1, BN_VLIST_LINE_MOVE);
+ RT_ADD_VLIST(vhead, pt2, BN_VLIST_LINE_DRAW);
+ }
}
+
void
drawBBNode(SurfaceTree* st, struct bn_vlblock *vbp, BBNode * node) {
- if (node->isLeaf()) {
- //draw leaf
- if (node->m_trimmed) {
- return; // nothing to do node is trimmed
- } else if (node->m_checkTrim) { // node may contain trim check
all corners
+ if (node->isLeaf()) {
+ //draw leaf
+ if (node->m_trimmed) {
+ return; // nothing to do node is trimmed
+ } else if (node->m_checkTrim) { // node may contain trim check all
corners
#if 1
- fastf_t u = node->m_u[0];
- fastf_t v = node->m_v[0];
- fastf_t from = u;
- fastf_t to = node->m_u[1];
- //bu_log("drawBBNode: node %x uvmin center %f %f 0.0,
uvmax center %f %f
0.0\n",node,node->m_u[0],node->m_v[0],node->m_u[1],node->m_v[1]);
+ fastf_t u = node->m_u[0];
+ fastf_t v = node->m_v[0];
+ fastf_t from = u;
+ fastf_t to = node->m_u[1];
+ //bu_log("drawBBNode: node %x uvmin center %f %f 0.0, uvmax center
%f %f 0.0\n", node, node->m_u[0], node->m_v[0], node->m_u[1], node->m_v[1]);
- drawisoUCheckForTrim(st,vbp,from,to,v,3); //bottom
- v = node->m_v[1];
- drawisoUCheckForTrim(st,vbp,from,to,v,3); //top
- from = node->m_v[0];
- to = node->m_v[1];
- drawisoVCheckForTrim(st,vbp,from,to,u,3); //left
- u = node->m_u[1];
- drawisoVCheckForTrim(st,vbp,from,to,u,3); //right
+ drawisoUCheckForTrim(st, vbp, from, to, v, 3); //bottom
+ v = node->m_v[1];
+ drawisoUCheckForTrim(st, vbp, from, to, v, 3); //top
+ from = node->m_v[0];
+ to = node->m_v[1];
+ drawisoVCheckForTrim(st, vbp, from, to, u, 3); //left
+ u = node->m_u[1];
+ drawisoVCheckForTrim(st, vbp, from, to, u, 3); //right
#endif
- return;
- } else { // fully untrimmed just draw bottom and right edges
- fastf_t u = node->m_u[0];
- fastf_t v = node->m_v[0];
- fastf_t from = u;
- fastf_t to = node->m_u[1];
- drawisoU(st,vbp,from, to, v, 10); //bottom
+ return;
+ } else { // fully untrimmed just draw bottom and right edges
+ fastf_t u = node->m_u[0];
+ fastf_t v = node->m_v[0];
+ fastf_t from = u;
+ fastf_t to = node->m_u[1];
+ drawisoU(st, vbp, from, to, v, 10); //bottom
- from = v;
- to = node->m_v[1];
- drawisoV(st,vbp,from, to, u, 10); //right
- return;
- }
- } else {
- if (node->m_children.size() > 0) {
- for (std::vector<BBNode*>::iterator childnode =
node->m_children.begin(); childnode
- != node->m_children.end(); childnode++)
{
- drawBBNode(st,vbp,*childnode);
- }
- }
+ from = v;
+ to = node->m_v[1];
+ drawisoV(st, vbp, from, to, u, 10); //right
+ return;
}
+ } else {
+ if (node->m_children.size() > 0) {
+ for (std::vector<BBNode*>::iterator childnode =
node->m_children.begin(); childnode
+ != node->m_children.end(); childnode++) {
+ drawBBNode(st, vbp, *childnode);
+ }
+ }
+ }
}
+
void
-plotFaceFromSurfaceTree(SurfaceTree* st, struct bn_vlblock *vbp, int
isocurveres, int gridres) {
- BBNode *root = st->getRootNode();
- drawBBNode(st,vbp,root);
+plotFaceFromSurfaceTree(SurfaceTree* st, struct bn_vlblock *vbp, int
UNUSED(isocurveres), int UNUSED(gridres)) {
+ BBNode *root = st->getRootNode();
+ drawBBNode(st, vbp, root);
}
+
int brep_isosurface_plot(struct bu_vls *vls, struct brep_specific* bs, struct
rt_brep_internal*, struct bn_vlblock *vbp, int index, int plotres)
{
- ON_wString wstr;
+ ON_wString wstr;
ON_TextLog tl(wstr);
- ON_Brep* brep = bs->brep;
- if (brep == NULL || !brep->IsValid(&tl)) {
- bu_log("brep is NOT valid");
- //return -1;
- }
- if (index == -1) {
- for (index = 0; index < brep->m_F.Count(); index++) {
- ON_BrepFace& face = brep->m_F[index];
- SurfaceTree* st = new SurfaceTree(&face, true, 0);
+ ON_Brep* brep = bs->brep;
+ if (brep == NULL || !brep->IsValid(&tl)) {
+ bu_log("brep is NOT valid");
+ //return -1;
+ }
+ if (index == -1) {
+ for (index = 0; index < brep->m_F.Count(); index++) {
+ ON_BrepFace& face = brep->m_F[index];
+ SurfaceTree* st = new SurfaceTree(&face, true, 0);
#if 0
- plotFace(st, vbp, plotres, plotres);
+ plotFace(st, vbp, plotres, plotres);
#else
- plottrim(face, vbp, plotres, true);
- plotFaceFromSurfaceTree(st,vbp,plotres,plotres);
+ plottrim(face, vbp, plotres, true);
+ plotFaceFromSurfaceTree(st, vbp, plotres, plotres);
#endif
- delete st;
- }
- } else if (index < brep->m_S.Count()) {
- ON_BrepFaceArray& faces = brep->m_F;
- if (index < faces.Count()) {
- ON_BrepFace& face = faces[index];
- SurfaceTree* st = new SurfaceTree(&face, true, 0);
+ delete st;
+ }
+ } else if (index < brep->m_S.Count()) {
+ ON_BrepFaceArray& faces = brep->m_F;
+ if (index < faces.Count()) {
+ ON_BrepFace& face = faces[index];
+ SurfaceTree* st = new SurfaceTree(&face, true, 0);
#if 0
- plotFace(st, vbp, plotres, plotres);
+ plotFace(st, vbp, plotres, plotres);
#else
- plottrim(face, vbp, plotres, true);
- plotFaceFromSurfaceTree(st,vbp,plotres,plotres);
+ plottrim(face, vbp, plotres, true);
+ plotFaceFromSurfaceTree(st, vbp, plotres, plotres);
#endif
- delete st;
- }
+ delete st;
}
+ }
bu_vls_printf(vls, ON_String(wstr).Array());
- return 0;
+ return 0;
}
+
int
brep_surfaceleafs_plot(struct bu_vls *vls, struct brep_specific* bs, struct
rt_brep_internal*, struct bn_vlblock *vbp, bool dim3d, int index, int)
{
- ON_wString wstr;
+ ON_wString wstr;
ON_TextLog tl(wstr);
ON_Brep* brep = bs->brep;
@@ -1683,7 +1694,7 @@
int
brep_trimleafs_plot(struct bu_vls *vls, struct brep_specific* bs, struct
rt_brep_internal*, struct bn_vlblock *vbp, bool dim3d, int index, int)
{
- ON_wString wstr;
+ ON_wString wstr;
ON_TextLog tl(wstr);
ON_Brep* brep = bs->brep;
@@ -1788,17 +1799,15 @@
snprintf(commtag, 64, "_BC_S_");
ret = brep_surface_plot(vls, bs, bi, vbp, index, plotres);
} else if (strcmp(part, "E") == 0) {
- snprintf(commtag, 64, "_BC_EE_");
- int index1 = index;
- int index2 = plotres;
- ret = brep_isosurface_plot(vls, bs, bi, vbp, index,
plotres);
+ snprintf(commtag, 64, "_BC_EE_");
+ ret = brep_isosurface_plot(vls, bs, bi, vbp, index, plotres);
} else if (strcmp(part, "EE") == 0) {
- snprintf(commtag, 64, "_BC_EE_");
- int index1 = index;
- int index2 = plotres;
- for (int i=index1; i <= index2; i++) {
- ret = brep_isosurface_plot(vls, bs, bi, vbp, i,
3);
- }
+ snprintf(commtag, 64, "_BC_EE_");
+ int index1 = index;
+ int index2 = plotres;
+ for (int i=index1; i <= index2; i++) {
+ ret = brep_isosurface_plot(vls, bs, bi, vbp, i, 3);
+ }
} else if (strcmp(part, "SN") == 0) {
snprintf(commtag, 64, "_BC_SN_");
ret = brep_surface_normal_plot(vls, bs, bi, vbp, index,
plotres);
@@ -1809,38 +1818,39 @@
snprintf(commtag, 64, "_BC_F_");
ret = brep_facetrim_plot(vls, bs, bi, vbp, index, plotres,
true);
} else if (strcmp(part, "F2d") == 0) {
- snprintf(commtag, 64, "_BC_F2d_");
- ret = brep_facetrim_plot(vls, bs, bi, vbp, index,
plotres, false);
+ snprintf(commtag, 64, "_BC_F2d_");
+ ret = brep_facetrim_plot(vls, bs, bi, vbp, index, plotres,
false);
} else if (strcmp(part, "SBB") == 0) {
- snprintf(commtag, 64, "_BC_SBB_");
- ret = brep_surfaceleafs_plot(vls, bs, bi, vbp, true,
index, plotres);
+ snprintf(commtag, 64, "_BC_SBB_");
+ ret = brep_surfaceleafs_plot(vls, bs, bi, vbp, true, index,
plotres);
} else if (strcmp(part, "SBB2d") == 0) {
- snprintf(commtag, 64, "_BC_SBB2d_");
- ret = brep_surfaceleafs_plot(vls, bs, bi, vbp, false,
index, plotres);
+ snprintf(commtag, 64, "_BC_SBB2d_");
+ ret = brep_surfaceleafs_plot(vls, bs, bi, vbp, false, index,
plotres);
} else if (strcmp(part, "TD") == 0) {
- snprintf(commtag, 64, "_BC_TD_");
- ret = brep_trim_direction_plot(vls, bs, bi, vbp, index,
plotres);
+ snprintf(commtag, 64, "_BC_TD_");
+ ret = brep_trim_direction_plot(vls, bs, bi, vbp, index,
plotres);
} else if (strcmp(part, "T") == 0) {
- snprintf(commtag, 64, "_BC_T_");
- ret = brep_trim_plot(vls, bs, bi, vbp, index, plotres,
true);
+ snprintf(commtag, 64, "_BC_T_");
+ ret = brep_trim_plot(vls, bs, bi, vbp, index, plotres, true);
} else if (strcmp(part, "T2d") == 0) {
- snprintf(commtag, 64, "_BC_T2d_");
- ret = brep_trim_plot(vls, bs, bi, vbp, index, plotres,
false);
+ snprintf(commtag, 64, "_BC_T2d_");
+ ret = brep_trim_plot(vls, bs, bi, vbp, index, plotres, false);
} else if (strcmp(part, "TBB") == 0) {
- snprintf(commtag, 64, "_BC_TBB_");
- ret = brep_trimleafs_plot(vls, bs, bi, vbp, true,
index, plotres);
+ snprintf(commtag, 64, "_BC_TBB_");
+ ret = brep_trimleafs_plot(vls, bs, bi, vbp, true, index,
plotres);
} else if (strcmp(part, "TBB2d") == 0) {
- snprintf(commtag, 64, "_BC_TBB2d_");
- ret = brep_trimleafs_plot(vls, bs, bi, vbp, false,
index, plotres);
+ snprintf(commtag, 64, "_BC_TBB2d_");
+ ret = brep_trimleafs_plot(vls, bs, bi, vbp, false, index,
plotres);
} else if (strcmp(part, "E") == 0) {
- snprintf(commtag, 64, "_BC_E_");
- ret = brep_edge3d_plot(vls, bs, bi, vbp, index,
plotres);
+ snprintf(commtag, 64, "_BC_E_");
+ ret = brep_edge3d_plot(vls, bs, bi, vbp, index, plotres);
}
}
}
return ret;
}
+
/** @} */
/*
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and,
should the need arise, upgrade to a full multi-node Oracle RAC database
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits