Hiya all,
I'm currently trying to implement paging with the Volume class using the required and overflow functions. I use a pointer to construct the Volume but whenever I try to point the constructor to the two functions it fails with the error message:
Quote:
Error 1 error C2064: term does not evaluate to a function taking 2 arguments c:\program files\microsoft visual studio 10.0\vc\include\xxcallobj 13
I'm referencing these functions via &Object::FunctionName and that's what causes this error. When the functions are outside a class it works perfectly fine, but this is, of course, very impractical.
Is there any way to allow use of the functions when they are in the same or a different class? I've tried pointers to classes, this methods, and various other things but it just doesn't seem to work.
The two functions are currently in LevelHandler and this is the constructor of the volume:
Quote:
volume_data_ = new PolyVox::Volume<PolyVox::MaterialDensityPair44>(&LevelHandler::DataRequiredHandler, &LevelHandler::DataOverflowHandler, 32);
Thanks