Post

Replies

Boosts

Views

Activity

Reply to Question about multithreading
Well I'm using XCode and C++ so I figured this forum would be appropriate. This is exactly what I want to do:I have a MessageManager that loops in a thread.I have an InputClass that loops in a thread too.I want to do something simple. I want to input a keypress to the InputClass thread. Then I want the InputClasss to send a message to the MessageManager alerting it that the key was pressed. Then the MessageManager does some processes....
Dec ’19
Reply to Deleted Function
Ok. Is there anyway to pass messages from one thread to another. For example,if I create a thread like this: std::thread manual_thread(&ManualSampler::loop, &ms); manual_thread.detach();where ms is static ManualSampler ms;can I later on call a function on that thread. LIke ms.print();?Would that execute on the thread?
Dec ’19