I get asked for this quite a lot these days and for a spell I thought I'd deleted it but I found it again so before I lose it again here it is:
A blog discussing my successes, failures and in-betweeners whilst working on computer vision related projects.
Showing posts with label successes. Show all posts
Showing posts with label successes. Show all posts
Monday, 26 November 2012
Tuesday, 2 October 2012
Game Player - Step 1 - Representing the Game Board
I'd say we are just about finished Step 1 now which looking back at the first post for this project I said should "Grab an image of the game board." Well we've definitely done that and we've also separated the game board out from the rest of the image to make the rest of the processing easier and faster but there is still a few things to take care of before I can officially declare us on Step 2.
Although we can see the game board the computer still can't really see it. It's kind of like in the last post when we had worked out the purple areas but still had to do a little processing for the computer to be able to make sense of it. What we need to do is represent the game board in a way the computer can understand it and that is what this post, and the end of Step 1, is going to be all about.
Although we can see the game board the computer still can't really see it. It's kind of like in the last post when we had worked out the purple areas but still had to do a little processing for the computer to be able to make sense of it. What we need to do is represent the game board in a way the computer can understand it and that is what this post, and the end of Step 1, is going to be all about.
Our captured game board |
Friday, 6 July 2012
Fixes in OpenCV and RTSP
We've finally got it going!
I'll get onto what was wrong in a second but first I want to share this line with you:
As you can see it is the same as my camera connection url in the previous post except I've added ?tcp to the end. I've found that this forces the rtsp connection to run using the tcp protocol instead of the udp protocol which is useful if you can't afford to have any packet loss. This gives us a decent picture but still performed very poorly, freezing often and dropping the frame rate down to something terrible.
I'll get onto what was wrong in a second but first I want to share this line with you:
CvCapture *camera = cvCreateFileCapture("rtsp://admin:admin@192.168.1.128/ch1-s1?tcp");
As you can see it is the same as my camera connection url in the previous post except I've added ?tcp to the end. I've found that this forces the rtsp connection to run using the tcp protocol instead of the udp protocol which is useful if you can't afford to have any packet loss. This gives us a decent picture but still performed very poorly, freezing often and dropping the frame rate down to something terrible.
Subscribe to:
Posts (Atom)