Changed instances of new across to use osgNew to help debugging, and fixed

an unitialized variable in Sequence.
This commit is contained in:
Robert Osfield
2002-08-28 21:40:38 +00:00
parent 3065f35ae2
commit b546c63139
5 changed files with 35 additions and 26 deletions

View File

@@ -34,7 +34,8 @@ public :
const float getTime(int frame) const;
/** Interval modes */
enum LoopMode {
enum LoopMode
{
LOOP,
SWING
};
@@ -43,7 +44,8 @@ public :
void setInterval(LoopMode mode, int begin, int end);
/** Get sequence mode & interval. */
inline void getInterval(LoopMode& mode, int& begin, int& end) const {
inline void getInterval(LoopMode& mode, int& begin, int& end) const
{
mode = _loopMode;
begin = _begin;
end = _end;
@@ -53,13 +55,15 @@ public :
void setDuration(float speed, int nreps = -1);
/** Get duration */
inline void getDuration(float& speed, int& nreps) const {
inline void getDuration(float& speed, int& nreps) const
{
speed = _speed;
nreps = _nreps;
}
/** Sequence modes */
enum SequenceMode {
enum SequenceMode
{
START,
STOP,
PAUSE,

View File

@@ -459,7 +459,7 @@ Starts a TestSuite singleton function
{ \
static osg::ref_ptr<osgUtx::TestSuite> s_suite = 0; \
if ( s_suite == 0 ) { \
s_suite = new osgUtx::TestSuite( #tsuite );
s_suite = osgNew osgUtx::TestSuite( #tsuite );
@@ -468,7 +468,7 @@ Adds a test case to a suite object being created in a TestSuite singleton functi
@see OSGUTX_BEGIN_TESTSUITE, OSGUTX_END_TESTSUITE
*/
#define OSGUTX_ADD_TESTCASE( tfixture, tmethod ) \
s_suite->add( new osgUtx::TestCase_<tfixture>( \
s_suite->add( osgNew osgUtx::TestCase_<tfixture>( \
#tmethod, &tfixture::tmethod ) );
/**