Go to Post AndyMark has done something amazing. - Sam390250 [more]
Home
Go Back   Chief Delphi > Technical > Programming > C/C++
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #8   Spotlight this post!  
Unread 09-02-2014, 01:36
sailorjoe sailorjoe is offline
Mentor, RoboEagles, FWHS
AKA: Joe Hafner
FRC #4579 (RoboEagles)
Team Role: Mentor
 
Join Date: Jan 2014
Rookie Year: 2014
Location: Auburn, WA
Posts: 10
sailorjoe is an unknown quantity at this point
Re: Vision sample code

Hi, SparkyShires. Thresholding is a way to separate the bright areas from the not-so-bright areas of in image. Basically, any pixel value below the threshold is converted to completely dark, or black. For extra complexity, This happens in each of the three color planes, which is why the Thresholding method requires so many parameters. After thresholding, the image will have only a few areas of interest, which were the bright areas in the image before thresholding. These are called "particles". The vision code processes these particles to determine Hot or Not.

When I moved the sample code into my robot program, I had to change some things. I took a few statements used to initialize the camera out to a separate method. Then I changed the VisionAnalysis method from void to boolean, and had it return the HotOrNot decision with a return statement just above the catch statements. With the changes made, I copied the whole kit-and-kabootle into a Camera Subsystem, which I call from an Autonomous Command.
More work to do! Good luck.
Reply With Quote
 


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 14:34.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


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