View Single Post
  #1   Spotlight this post!  
Unread 28-01-2017, 11:02
wwalcher wwalcher is offline
Registered User
FRC #4511
 
Join Date: Jan 2017
Location: Minnesota
Posts: 5
wwalcher is an unknown quantity at this point
How do you draw a bounding box using GRIP?

Hey there!

I've managed get my GRIP pipeline working, and have successfully manipulated the data from NetworkTables in our Java program to detect the distance from the targets on the sides of the gear hook.
However, I now want to actually use the vision data to determine how the robot drives. Since there are two targets being detected, I felt it would make sense to draw a bounding box around the two and use the center of the bounding box as my target for the hook (as it should be approximately in the middle of the bounding rectangle). I figured that GRIP would have the ability to draw a bounding box, but lo and behold, it does not. So, I figure I can use OpenCV to do this using the boundingRect() method, but my question is: How do I do this? Is there a way for me to access the actual OpenCV code being generated by GRIP and add in the boundingRect() method?
Any help would be greatly appreciated!

Thanks!
Reply With Quote