I need some conceptual help for my Qt application.
I have a program that receives image data from 12 Analog Digital Converters (ADCs - they digitize the signal of 12 detectors in an electron microscope). I display these images live in my app. Now I want to give the user the opportunity to apply mathematical operations on the signals in a very flexible manner, while maintaining the live display.
Therefore, I consider to implement the shunting yard algorithm. My idea is that the user enters/mixes the signals in a textBox as he/she likes. For example, if a sum of four ADC signals is needed, the user just enters
"ADC01 + ADC02 + ADC03 + ADC04"
I understand how to apply the algorithm to get the Polish Postfix Notation and also how to evaluate such an expression. However, this approach seems to be too slow to be applied on currently 8x256x256 values (eight square images, all values need to be refreshed at the same time unfortunately). Surely, the Postfix conversion only needs to be done once, but the insert of my variables and the evaluation seems to me much more costly than just writing
uint valToDisp = ADC[1]+ADC[2]+ADC[3]+ADC[4];
in code.
Can you think of any way to do such a thing with good performance? What I thought of is to create some kind of dynamic function out of the postfix, but I am not sure how to realize something like this in C++.