My code looks something like this:
Originally Posted by Shakti
- Take Data
- Convert through LUT
- Display data
Taking data is by far the most time-consuming, as the PCI card I take the data from needs to sync to an external camera with some given framerate. If I tell it to get a frame, it first waits for the sync signal and then takes the data. If I fire at 7.5fps, it will have to wait for the next pulse. That would be best suited for a different thread I believe.
The weird thing though is if I tell it to do something like this:
It will only display the OpenGL frame once the loop is finished. This has to be some issue with Qt, because running this code:
for (int i = 0; i < max_frames; i++)
//take data function
//convert through LUT function
//display through OpenGL function
It will hang until the loop is done, and then display whatever my string was 10 times all at once. So this is going to be way more complicated than I originally thought.
for (int i = 0; i < 10; i++)