Hi,
I’m working on a component to read data from a 3d camera and would like my component to output every available frame. I have a listener that gets called when a new frame is available and I have the data available in the SolveInstance method, but how do I trigger the reevaluation every time a new frame becomes available?
I tried to call ExpireSolution from the listener but that did not help.
Also, do not call that method from a thread other than the UI thread.
Ah, so I guess that is the problem. I’m tried calling ExpireSolution(true) from the listener and that’s a different thread. So I have to call ExpireSolution from the ‘Main Tread’. What would be the standard way to signal an event from some background worker thread to the main UI thread? I guess I have to do some reading on Grasshopper and multi threading…
Hi,
I tried to invoke ExpireSolution from the main tread, using InvokeOnUiThread but it’s not working. Well, InvokeOnUiThread works, the invoked method really gets called from the main UI thread, but ExpireSolution(true) does not seam to have any effect, the SolveInstance method of the assembly does not get called.