We have a C++/CLI class, let us call it class A, from which we would like to register a non-static callback ("MyNonStaticCallback") into an unmanaged C++ class (class B).
e.g.
void MyNonStaticCallback(void* ...)
{
// Raise a C# event from this code
}
// Register callback into class B
myClassBInstance->RegisterCallback(..., &MyNonStaticCallback, ...);
The reason why we want a non-static callback is because we want to raise a C# event from this callback function.
I understand it ain't possible to pass an instance's data member as a function pointer. What would be the best way to proceed here ?
Thanks and Best Regards,
Romain