I want to perform the operation stated above.
void myFunc(void *parameters)
{
myObject myObj = // Here I would like to receive the object I passed from the main
... // several stuff
}
...
int main()
{
...
myObject myObj(...);
_beginthread(myFunc, // Here I would like to pass on the object I created above)
...
}
Thanks in advance for your time. Have a pleasent day !
Directly from Microsoft’s documentation of
_beginthreadex:UPDATE: How to use the argument without global variables.
HINT: replace the int with your object