problem on tick callbacks

Please don't post Bullet support questions here, use the above forums instead.
freikorps
Posts: 5
Joined: Sun Jul 11, 2010 2:29 am

problem on tick callbacks

Post by freikorps »

When trying to use the callback function, I followed the code in the tutorial like this:
my header file:
.........
void myTickCallback(btDynamicsWorld *world, btScalar timeStep);
.........
my cpp file:

FrokLiftDemo::myTickCallback(btDynamicsWorld *world, btScalar timeStep) {
printf(“The world just ticked by %f seconds\n”, (float)timeStep);
}
after creating world:
myWorld->setInternalTickCallback(myTickCallback);

but there is an error: 'ForkLiftDemo::myTickCallback': function call missing argument list; use '&ForkLiftDemo::myTickCallback' to create a pointer to member

To my understand, the function setInternalCallback() need a btInternalTickCallback data as a parameter, but when applying setInternalCallback(myTickCallback), how may I set myTickCallback as an btInternalTickCallback kind?

thanks!