LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to realise double buffering using draw flattened pixmap and normal picture box?

Hey,

 

I have following Problem:

I am using a the "draw flattened pixmap.vi" to visualize an image in real time which i get from a camera stream every ~200ms.

The problem is that my solution works fine at some pcs and at some others the image visualization is flickering.

 

Question:

How can i avoid flickering? Is there any possibility to realize double buffering combined with "draw flattened pixmap.vi" and the elementary picture box?

Or is there any other idea how to avoid flickering?

 

Thanks 

 

0 Kudos
Message 1 of 5
(3,225 Views)

I once coded a plasma effect (somthing like: sin(scalex*x)+sin(scaley*y)+sin(scalex*x+t)+sin(scaley*y+t), where t is time) into a 2d picture control

where i had the same problem.

Maybe it would be worth to try array of 2d picture control with 2 elements (the 2 buffers).

1.) clear both picture control buffers

2.) display array element 1

3.) calculate array element 2

4.) switch to array element 2

5.) calculate array element 1

6.) switch to array element 1

...

However sync to screen display was way easier on old homecomputer systems than it is today. ;-(

This would really be of interest how such low level functions could be implemented into LabView.

 

 

0 Kudos
Message 2 of 5
(3,204 Views)

Thank you for your answer. 

Well, my question more refered to if it is possible to set somewhere a checkbox in order to activate an already existing double buffering mode of the picture control or if i have to implement it myself concurrent with your listing.

Maybe there is another easier way to get rid of the flickering which i did not consider so far ?!?!

 

 

0 Kudos
Message 3 of 5
(3,114 Views)

I had a similar issue with flickering and resolved it by right clicking the picture control and unchecking the "Erase First" option.

0 Kudos
Message 4 of 5
(2,450 Views)

Have you tried the Advanced>Synchronous Display option? Or the Smooth Updates option? (Only visible in run mode (CTRL+M). Try all combinations.

 

Updating with a local or property node makes a difference. Value property will be synchronised with a screen update. Try if it makes a difference (in combination with synchronous display and Smooth updates).

 

You might try defer panel updates (true before you update, false when done). If the update takes longer then a refresh, this will block the update until it's done.

 

0 Kudos
Message 5 of 5
(2,437 Views)