1SoCylinder(3IV)()                                            SoCylinder(3IV)()
2
3
4

NAME

6       SoCylinder — cylinder shape node
7

INHERITS FROM

9       SoBase > SoFieldContainer > SoNode > SoShape > SoCylinder
10

SYNOPSIS

12       #include <Inventor/nodes/SoCylinder.h>
13
14     enum Part {
15          SoCylinder::SIDES   The cylindrical part
16          SoCylinder::TOP     The top circular face
17          SoCylinder::BOTTOM  The bottom circular face
18          SoCylinder::ALL     All parts
19     }
20
21          Fields from class SoCylinder:
22
23     SoSFBitMask         parts
24     SoSFFloat           radius
25     SoSFFloat           height
26
27          Methods from class SoCylinder:
28
29                         SoCylinder()
30     void                addPart(SoCylinder::Part part)
31     void                removePart(SoCylinder::Part part)
32     SbBool              hasPart(SoCylinder::Part part) const
33     static SoType       getClassTypeId()
34
35          Methods from class SoNode:
36
37     void                setOverride(SbBool state)
38     SbBool              isOverride() const
39     SoNode *            copy(SbBool copyConnections = FALSE) const
40     virtual SbBool      affectsState() const
41     static SoNode *     getByName(const SbName &name)
42     static int          getByName(const SbName &name, SoNodeList &list)
43
44          Methods from class SoFieldContainer:
45
46     void                setToDefaults()
47     SbBool              hasDefaultValues() const
48     SbBool              fieldsAreEqual(const SoFieldContainer *fc) const
49     void                copyFieldValues(const  SoFieldContainer  *fc,  SbBool
50                              copyConnections = FALSE)
51     SbBool              set(const char *fieldDataString)
52     void                get(SbString &fieldDataString)
53     virtual int         getFields(SoFieldList &resultList) const
54     virtual SoField *   getField(const SbName &fieldName) const
55     SbBool              getFieldName(const SoField *field, SbName &fieldName)
56                              const
57     SbBool              isNotifyEnabled() const
58     SbBool              enableNotify(SbBool flag)
59
60          Methods from class SoBase:
61
62     void                ref()
63     void                unref() const
64     void                unrefNoDelete() const
65     void                touch()
66     virtual SoType      getTypeId() const
67     SbBool              isOfType(SoType type) const
68     virtual void        setName(const SbName &name)
69     virtual SbName      getName() const
70
71

DESCRIPTION

73       This  node  represents  a simple capped cylinder centered around the y-
74       axis. By default, the cylinder is centered at (0,0,0) and has a default
75       size  of  -1  to +1 in all three dimensions. You can use the radius and
76       height fields to create a cylinder with a different size.
77
78       The cylinder is transformed by the  current  cumulative  transformation
79       and  is drawn with the current lighting model, drawing style, material,
80       and geometric complexity.
81
82       If the current material binding is PER_PART  or  PER_PART_INDEXED,  the
83       first  current material is used for the sides of the cylinder, the sec‐
84       ond is used for the top, and the third is used for the  bottom.  Other‐
85       wise, the first material is used for the entire cylinder.
86
87       When  a  texture is applied to a cylinder, it is applied differently to
88       the sides, top, and bottom. On the sides, the  texture  wraps  counter‐
89       clockwise  (from  above) starting at the back of the cylinder. The tex‐
90       ture has a vertical seam at the back, intersecting  the  yz-plane.  For
91       the  top  and  bottom,  a  circle  is cut out of the texture square and
92       applied to the top or bottom circle. The top texture appears right side
93       up  when  the  top of the cylinder is tilted toward the camera, and the
94       bottom texture appears right side up when the top of  the  cylinder  is
95       tilted away from the camera.
96

FIELDS

98     SoSFBitMask         parts
99          Visible parts of cylinder.
100
101     SoSFFloat           radius
102     SoSFFloat           height
103          Define the cylinder's height and radius; values must be greater than
104          0.0.
105
106

METHODS

108                         SoCylinder()
109          Creates a cylinder node with default settings.
110
111     void                addPart(SoCylinder::Part part)
112     void                removePart(SoCylinder::Part part)
113          These are convenience functions that make it easy to turn on or  off
114          a part of the cylinder.
115
116     SbBool              hasPart(SoCylinder::Part part) const
117          This convenience function returns whether a given part is on or off.
118
119     static SoType       getClassTypeId()
120          Returns type identifier for this class.
121
122

ACTION BEHAVIOR

124       SoGLRenderAction
125          Draws  cylinder based on the current coordinates, materials, drawing
126          style, and so on.
127
128     SoRayPickAction
129          Intersects the ray with the cylinder. The part of the cylinder  that
130          was picked is available from the SoCylinderDetail.
131
132     SoGetBoundingBoxAction
133          Computes the bounding box that encloses the cylinder.
134
135     SoCallbackAction
136          If  any triangle callbacks are registered with the action, they will
137          be invoked for each successive triangle that approximates the cylin‐
138          der.
139
140

FILE FORMAT/DEFAULTS

142       Cylinder {
143          parts   ALL
144          radius  1
145          height  2
146     }
147

SEE ALSO

149       SoCone, SoCube, SoCylinderDetail, SoSphere
150
151
152
153
154                                                             SoCylinder(3IV)()
Impressum