Added convinience constructor.

This commit is contained in:
Robert Osfield 2003-04-01 18:42:38 +00:00
parent 060b9f7150
commit 5b36049f33
2 changed files with 10 additions and 3 deletions

View File

@ -25,6 +25,8 @@ class SG_EXPORT PolygonOffset : public StateAttribute
PolygonOffset();
PolygonOffset(float factor, float units);
/** Copy constructor using CopyOp to manage deep vs shallow copy.*/
PolygonOffset(const PolygonOffset& po,const CopyOp& copyop=CopyOp::SHALLOW_COPY):
StateAttribute(po,copyop),

View File

@ -15,12 +15,17 @@
using namespace osg;
PolygonOffset::PolygonOffset()
PolygonOffset::PolygonOffset():
_factor(0.0f),
_units(0.0f)
{
_factor = 0.0f; // are these sensible defaut values?
_units = 0.0f;
}
PolygonOffset::PolygonOffset(float factor, float units):
_factor(factor),
_units(units)
{
}
PolygonOffset::~PolygonOffset()
{