View Single Post
  #9   Spotlight this post!  
Unread 13-02-2009, 02:35
RyanCahoon's Avatar
RyanCahoon RyanCahoon is offline
Disassembling my prior presumptions
FRC #0766 (M-A Bears)
Team Role: Engineer
 
Join Date: Dec 2007
Rookie Year: 2007
Location: Mountain View
Posts: 689
RyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond reputeRyanCahoon has a reputation beyond repute
Re: Second Color is not being processed!

Also make sure that if you're creating a new image and passing it in as Image DST to Color Threshold, etc. If you don't do this, it will do in-place thresholding, which means that it will replace the source image with the filtered red/black image, so when you go to do the filtering for the second color, it won't find it. To fix this, create a new image using IMAQ Create (make sure to give it a different name) and wire the new image into the Image DST input on the first Color Threshold (to be extra safe, create another one for the second Color Threshold as well).

I haven't actually looked at the inside of the demo vision code to see what it does, so you may have already done this when converting the code, but this is a problem I've had before when writing my own vision code. Seeing a glimpse every 30 frames also sounds similar to what I've seen before.

--Ryan
__________________
FRC 2046, 2007-2008, Student member
FRC 1708, 2009-2012, College mentor; 2013-2014, Mentor
FRC 766, 2015-, Mentor
Reply With Quote