Provided by: libcoin80-doc_3.1.4~abc9f50-4ubuntu2_all

**NAME**

SbCylinder - TheSbCylinderclass is a representation of a cylinder. This class is used within other classes in Coin. It contains data to represent a cylinder by an axis and a radius. The cylinder has no length/height value, which means it is treated as of infinite length.

**SYNOPSIS**

PublicMemberFunctionsSbCylinder(void)SbCylinder(constSbLine&a, const float r) voidsetValue(constSbLine&a, const float r) voidsetAxis(constSbLine&a) voidsetRadius(const float r) constSbLine&getAxis(void) const floatgetRadius(void) const SbBoolintersect(constSbLine&l,SbVec3f&intersection) const SbBoolintersect(constSbLine&l,SbVec3f&enter,SbVec3f&exit) const void

**Detailed** **Description**

TheSbCylinderclass is a representation of a cylinder. This class is used within other classes in Coin. It contains data to represent a cylinder by an axis and a radius. The cylinder has no length/height value, which means it is treated as of infinite length.SeeAlso:SbLine,SbSphere

**Constructor** **&** **Destructor** **Documentation**

SbCylinder::SbCylinder(void)The default constructor will make a cylinder of radius 1, center axis going through origo in the parallel direction of the positive y-axis.SbCylinder::SbCylinder(constSbLine&a,constfloatr)Construct and initialize anSbCylinderinstance with the given axisaand radiusr.

**Member** **Function** **Documentation**

voidSbCylinder::setValue(constSbLine&a,constfloatr)Set the axis and radius of the cylinder.SeeAlso:getAxis(),getRadius().voidSbCylinder::setAxis(constSbLine&a)Set the center axis of the cylinder.SeeAlso:setRadius(),getAxis().voidSbCylinder::setRadius(constfloatr)Set the radius of the cylinder.SeeAlso:setAxis(),getRadius().constSbLine&SbCylinder::getAxis(void)constReturn the line which is the center axis of the cylinder.SeeAlso:setAxis(),getRadius().floatSbCylinder::getRadius(void)constReturn radius of cylinder.SeeAlso:setRadius(),getAxis().SbBoolSbCylinder::intersect(constSbLine&l,SbVec3f&intersection)constFinds the intersection point of the raylon the cylinder where the ray enters, and return this point inintersection. If the ray does not intersect the cylinder,FALSEis returned, otherwise we will returnTRUE.SbBoolSbCylinder::intersect(constSbLine&l,SbVec3f&enter,SbVec3f&exit)constFind the intersection points of the raylon the cylinder and return these inenterandexit. If the ray just 'grazes' the cylinder, theenterandexitpoints have equal values. If the ray does not intersect the cylinder,FALSEis returned, otherwise we will returnTRUE.voidSbCylinder::print(FILE*fp)constDump the state of this object to thefilestream. Only works in debug version of library, method does nothing in an optimized compile.

**Author**

Generated automatically by Doxygen for Coin from the source code.