Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   C/C++ (http://www.chiefdelphi.com/forums/forumdisplay.php?f=183)
-   -   How to display image (RGB, Binary, HSV, etc.) on driver station screen (http://www.chiefdelphi.com/forums/showthread.php?t=111772)

13liud 01-21-2013 09:24 PM

How to display image (RGB, Binary, HSV, etc.) on driver station screen
 
We are trying to implement vision, but we can't move forward until we can actually see the images we're working with. Is there some way to, once we have an image (RGB, Binary, HSV, etc.) stored as a C++ variable, to display it or see it, preferably as a live feed? How exactly could I do this?

If that's not possible, I need any means of viewing an image file created on the cRIO for testing purposes.

rbmj 01-23-2013 08:42 AM

Re: How to display image (RGB, Binary, HSV, etc.) on driver station screen
 
You can write the image to a file and then look at it on your computer by FTP-ing to the cRIO.

mikets 01-23-2013 01:10 PM

Re: How to display image (RGB, Binary, HSV, etc.) on driver station screen
 
Quote:

Originally Posted by 13liud (Post 1219774)
We are trying to implement vision, but we can't move forward until we can actually see the images we're working with. Is there some way to, once we have an image (RGB, Binary, HSV, etc.) stored as a C++ variable, to display it or see it, preferably as a live feed? How exactly could I do this?

If that's not possible, I need any means of viewing an image file created on the cRIO for testing purposes.

As long as your camera is on the standard IP address, you should be able to see the live feed of the camera on your dashboard.

Toa Circuit 01-26-2013 08:09 PM

Re: How to display image (RGB, Binary, HSV, etc.) on driver station screen
 
If you look at the image processing example... there is the following lines:
Code:

BinaryImage *thresholdImage=image->ThresholdHSV(threshold); // get just the green target pixels
//thresholdImage->Write("/threshold.png");
BinaryImage *convexHullImage=thresholdImage->ConvexHull(false); // fill in partial and full rectangles
//convexHullImage->Write("/ConvexHull.png");
BinaryImage *filteredImage=convexHullImage->ParticleFilter(criteria, 1); //Remove small particles
//filteredImage->Write("Filtered.png");

Uncomment the commented out lines and the files will be saved to the cRIO. Just then get them off with FTPing to the cRIO (At 10.xx.yy.2) with a program like FileZilla.
The documentation reccommends you comment out the loop before writing to the cRIO flash though to keep it from deteriorating. How important this is, Im not sure of. I did it though, and it worked just fine for our purposes, if not better (Cause we could just enable and grab processed pictures, then reenable again and such.)

Greg McKaskle 01-27-2013 08:52 AM

Re: How to display image (RGB, Binary, HSV, etc.) on driver station screen
 
The cRIO is sold industrially for machine monitoring. The filesystem does wear-leveling and the flash is capable of many many rewrites. It is fine to use the flash for debugging, that is one of the reasons it is there.

Greg McKaskle


All times are GMT -5. The time now is 10:27 AM.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi