I\'m trying to call a function that takes an argument, void(*)(void*, int, const char*), but I cannot figure out how to pass those arguments to the function.
Unless I totally misinterpret your code, you are trying to pass a function pointer with an argument by doing
function(20, 20, ptr(20));
That is incorrect and illegal. In order to pass a function as a parameter into another function you have to follow the following syntax
function(20, 20, &ptr);
or
function(20, 20, ptr);
Even though I would recomment leaving the '&' for readability