Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Converting VisionImage to System.Drawing.Bitmap/Image in .NET, and vice-versa: my solution!

Solved!
Go to solution

...Then you will have to explain to your boss why the test results for your very important vision processing test are all jacked up because you were messing around with the Print Screen button when you weren't supposed to be.Smiley Wink

0 Kudos
Message 11 of 13
(2,244 Views)

Interesting...well about this PrintScreen key you can easily find a workaround using the KeyPreview feature in Winforms or filter the Message Loop...

Another way is to secure the access of the clipboard, I did not think about that before, but seems a very nice trick to me!

 

I did not try the Clipboard solution (I mean, not yet) but it seems to be a nice and simple workaround, I'm curious about how performant and efficient is this solution (especially for the memory concerns over a long period of a frenzy use...).

0 Kudos
Message 12 of 13
(2,239 Views)

It is very fast.

As long as you call Clipboard.Clear(), and clean up any bitmaps, you will not have any issues with memory consumption doing many itterations.

 

I've tested Nelval's solution and it also works well.

Message 13 of 13
(2,234 Views)