当前位置: 首页>>代码示例>>C++>>正文


C++ ON_BoundingBox::Set方法代码示例

本文整理汇总了C++中ON_BoundingBox::Set方法的典型用法代码示例。如果您正苦于以下问题:C++ ON_BoundingBox::Set方法的具体用法?C++ ON_BoundingBox::Set怎么用?C++ ON_BoundingBox::Set使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ON_BoundingBox的用法示例。


在下文中一共展示了ON_BoundingBox::Set方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: BoundingBox

ON_BoundingBox ON_Box::BoundingBox() const
{
  ON_BoundingBox bbox;
  ON_3dPoint corners[8];
  if ( GetCorners(corners) )
    bbox.Set(3,0,8,3,&corners[0].x,false);
  return bbox;
}
开发者ID:Arecius,项目名称:opennurbs,代码行数:8,代码来源:opennurbs_box.cpp

示例2: GetBoundingBox

bool ON_Line::GetBoundingBox(
       ON_BoundingBox& bbox,
       int bGrowBox
       ) const
{
  bbox.Set( 3, false, 2, 3, &from.x, bGrowBox );
  return true;
}
开发者ID:ckvk,项目名称:opennurbs,代码行数:8,代码来源:opennurbs_line.cpp

示例3: BoundingBox

ON_BoundingBox ON_Circle::BoundingBox() const
{
  ON_BoundingBox bbox;
  ON_3dPoint corners[4]; // = corners of square that contains circle
  corners[0] = plane.PointAt( radius, radius );
  corners[1] = plane.PointAt( radius,-radius );
  corners[2] = plane.PointAt(-radius, radius );
  corners[3] = plane.PointAt(-radius,-radius );
  bbox.Set(3,0,4,3,&corners[0].x,false);   
  return bbox;
}
开发者ID:ckvk,项目名称:opennurbs,代码行数:11,代码来源:opennurbs_circle.cpp

示例4: ON_Brep_GetTightBoundingBox_Helper

static bool ON_Brep_GetTightBoundingBox_Helper( const ON_Brep& brep, ON_BoundingBox& bbox, ON_Xform* xform )
{
  ON_Xform xform_inverse;
  ON_Xform* inverse = NULL;
  if( xform )
  {
    xform_inverse = xform->Inverse();
    inverse = &xform_inverse;
  }
  // make sure we have an empty/invalid bbox
  bbox.Destroy();

  // Compute Vertex bounding box.
  int vertex_count = brep.m_V.Count();
  if( xform )
  {
    ON_3dPointArray vtx(vertex_count);
    for( int i=0; i<vertex_count; i++ )
      vtx.Append(brep.m_V[i].point);
    vtx.GetTightBoundingBox(bbox, false, xform);
  }
  else
  {
    for( int i=0; i<vertex_count; i++ )
      bbox.Set(brep.m_V[i].point,true);
  }

  // Grow partial result with Edge bounding boxes.
  int edge_count = brep.m_E.Count();
  for( int i=0; i<edge_count; i++)
    ON_Brep_GetTightCurveBoundingBox_Helper(brep.m_E[i], bbox, xform, inverse);

  // Grow partial result with Face bounding boxes.
  int face_count = brep.m_F.Count();
  for( int i=0; i<face_count; i++)
    ON_Brep_GetTightFaceBoundingBox_Helper(brep.m_F[i], bbox, xform, inverse);

  return bbox.IsValid();
}
开发者ID:JohannesKu,项目名称:rhinocommon,代码行数:39,代码来源:on_geometry.cpp

示例5: BoundingBox

ON_BoundingBox ON_Line::BoundingBox() const
{
  ON_BoundingBox bbox;
  bbox.Set( 3, false, 2, 3, &from.x, false );
  return bbox;
}
开发者ID:ckvk,项目名称:opennurbs,代码行数:6,代码来源:opennurbs_line.cpp


注:本文中的ON_BoundingBox::Set方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。