LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Text in the graph in real time

Solved!
Go to solution

Hello experts,

does anyone know how to solve this issue?

I have a graph where I display values in real-time, but when this text moves on the graph, it often flickers, which is not very pleasant to the eyes.

Do you know why it does this?

Is there a way to resolve it so that this text doesn't flicker?

 

Thank you for your response; I'm attaching the source code here as well.

0 Kudos
Message 1 of 5
(1,485 Views)

I suppose the code you posted is an abstract from your actual application.

I made a simple test app to check graph behavior and i see no flickering regardless the options set in the graph and/or in the code, so the flickering is probably caused by some other call in your code.

BTW: it is not needed to recreate the metafont on every timer call: you can simply create the one you need at program start and use it in your subsequent calls to PlotText ().

 

I am attaching the code to this message: feel free to test, modify and comment.



Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 2 of 5
(1,462 Views)

Hi Roberto,

thank you for your reply and making the program, I found that it affects the timer and I need it set to 0.01 and your test program has it set to 0.05 If you set it to 0.01 you will see text flicker.

Thanks for the advice

0 Kudos
Message 3 of 5
(1,449 Views)
Solution
Accepted by MajklS

Rather than flickering I see a ghost text immediately next the actual text drawn, but it could very well be a defect in my vision!

 

I see no reasonable way of reducing side effects at so fast a rate, but I wonder if you really need such rate, considering that not all people can appreciate 100 Hz variations. Consider also that your 100 Hz phenomenon falls beyond the capacity of a great numbers of monitors which have a 60 Hz refresh ratio.

That being said, you could reduce the flickering if you plot a point every two, thus halving the update rate, with an effect that won't probably be appreciated by users.



Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 4 of 5
(1,440 Views)

Yes, you are right, it is true that somewhere the flickering is not so frequent, precisely because of the higher frequency of the monitor.

So thank you for the advice, this will be enough for me and I will adjust the timer to a different speed.
Have a nice day

0 Kudos
Message 5 of 5
(1,425 Views)