From David Fries, add init() call to SphereSegment constructor, and

new get methods for draw mask and color.
This commit is contained in:
Robert Osfield
2004-03-31 08:52:47 +00:00
parent d73824f0a1
commit 316c646a8f
2 changed files with 56 additions and 1 deletions

View File

@@ -82,7 +82,9 @@ public:
_elevMin(0.0f), _elevMax(osg::PI/2.0f),
_density(10),
_drawMask(DrawMask(ALL))
{}
{
init();
}
/**
Construct by angle ranges. Note that the azimuth 'zero' is the Y axis; specifying
@@ -164,6 +166,22 @@ public:
*/
void getArea(osg::Vec3& v, float& azRange, float& elevRange) const;
/** Set the area of the sphere segment
@param azMin azimuth minimum
@param azMin azimuth maximum
@param elevMin elevation minimum
@param elevMax elevation maximum
*/
void setArea(float azMin, float azMax, float elevMin, float elevMax);
/** Get the area of the sphere segment
@param azMin azimuth minimum
@param azMin azimuth maximum
@param elevMin elevation minimum
@param elevMax elevation maximum
*/
void getArea(float &azMin, float &azMax, float &elevMin, float &elevMax) const;
/** Set the density of the sphere segment */
void setDensity(int d);
@@ -177,18 +195,33 @@ public:
*/
void setDrawMask(DrawMask dm);
/** Get the DrawMask */
DrawMask getDrawMask() const { return _drawMask; }
/** Set the color of the surface. */
void setSurfaceColor(const osg::Vec4& c);
/** Get the color of the surface. */
osg::Vec4 getSurfaceColor() const { return _surfaceColor; }
/** Set the color of the spokes. */
void setSpokeColor(const osg::Vec4& c);
/** Get the color of the spokes. */
osg::Vec4 getSpokeColor() const { return _spokeColor; }
/** Set the color of the edge line. */
void setEdgeLineColor(const osg::Vec4& c);
/** Get the color of the edge line. */
osg::Vec4 getEdgeLineColor() const { return _edgeLineColor; }
/** Set the color of the planes. */
void setSideColor(const osg::Vec4& c);
/** Get the color of the planes. */
osg::Vec4 getSideColor() const { return _planeColor; }
/** Set color of all components. */
void setAllColors(const osg::Vec4& c);