API Reference > OdDb Classes > OdDb3dSolid Class > OdDb3dSolid Methods > OdDb3dSolid::createFrustum Method
OdDb3dSolid::createFrustum Method
Syntax
C++
virtual void createFrustum(double height, double xRadius, double yRadius, double topXRadius);
Parameters 
Description 
double height 
[in] Dimension along the WCS Z-axis.  
double xRadius 
[in] Base radius along the WCS X-axis.  
double yRadius 
[in] Base radius along the WCS Y-axis.  
double topXRadius 
[in] Top radius along the WCS X-axis. 

Creates a WCS aligned frustum centered about the world origin. 

 

The function can generate a frustum that is any one of the following: 

 

  • A circular cylinder (when xRadius is equal to topXRadius and xRadius and yRadius are the same)
  • An elliptical cylinder (when xRadius is equal to topXRadius and xRadius and yRadius are not the same)
  • A circular cone (when topXRadius is zero and xRadius and yRadius are the same)
  • An elliptical cone (when topXRadius is zero and xRadius and yRadius are not the same)
  • A truncated circular cone (when topXRadius is not zero but not equal to xRadius and xRadius and yRadius are the same)
  • A truncated elliptical cone (when topXRadius is not zero but not equal to xRadius and xRadius and yRadius are not the same)

 

The following constraints are applied: 

 

  • height >= 1e-6.
  • xRadius >= 1e-6.
  • yRadius >= 1e-6.
  • topXRadius >= 1e-6.
Copyright © 2002–2020. Open Design Alliance. All rights reserved.