Code Monkey home page Code Monkey logo

multiobjecttrackingbasedoncolor's Introduction

MultiObjectTrackingBasedOnColor

ghit.me

Track multiple objects based on their color using OpenCV


In order to run the application, you need to do the follwing steps:

1 - Proper installation of OpenCV V2.4.9

2- Make a new project in Visual Sudio including OpenCV path in your solution.

3- Add the attached files and build the project.

Note: make sure you have a web cam in your PC or Laptop.

On Linux you will need to have opencv-devel installed and then run make.

Thank You,

Ahmad Kaifi,
Hassan Althobaiti,
Zubir Rentiya

Throughput Graph

multiobjecttrackingbasedoncolor's People

Contributors

akaifi avatar bmwiedemann avatar bryant1410 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

multiobjecttrackingbasedoncolor's Issues

Error when make in the directory! PLEASE HELP

sky@Sky:~/OpenCV/src/Multi_color$ make
g++ pkg-config --cflags opencv -c -o multipleObjectTracking.o multipleObjectTracking.cpp
multipleObjectTracking.cpp: In function ‘void createTrackbars()’:
multipleObjectTracking.cpp:70:34: error: ‘namedWindow’ was not declared in this scope
namedWindow(trackbarWindowName,0);
^
multipleObjectTracking.cpp:73:39: warning: too many arguments for format [-Wformat-extra-args]
sprintf( TrackbarName, "H_MIN", H_MIN);
^
multipleObjectTracking.cpp:74:39: warning: too many arguments for format [-Wformat-extra-args]
sprintf( TrackbarName, "H_MAX", H_MAX);
^
multipleObjectTracking.cpp:75:39: warning: too many arguments for format [-Wformat-extra-args]
sprintf( TrackbarName, "S_MIN", S_MIN);
^
multipleObjectTracking.cpp:76:39: warning: too many arguments for format [-Wformat-extra-args]
sprintf( TrackbarName, "S_MAX", S_MAX);
^
multipleObjectTracking.cpp:77:39: warning: too many arguments for format [-Wformat-extra-args]
sprintf( TrackbarName, "V_MIN", V_MIN);
^
multipleObjectTracking.cpp:78:39: warning: too many arguments for format [-Wformat-extra-args]
sprintf( TrackbarName, "V_MAX", V_MAX);
^
multipleObjectTracking.cpp:84:74: error: ‘createTrackbar’ was not declared in this scope
createTrackbar( "H_MIN", trackbarWindowName, &H_MIN, H_MAX, on_trackbar );
^
multipleObjectTracking.cpp: In function ‘void drawObject(std::vector, cv::Mat&, cv::Mat&, std::vector<std::vector<cv::Point_ > >, std::vector<cv::Vec<int, 4> >)’:
multipleObjectTracking.cpp:95:2: error: ‘drawContours’ is not a member of ‘cv’
cv::drawContours(frame,contours,i,theObjects.at(i).getColor(),3,8,hierarchy);
^
multipleObjectTracking.cpp:96:2: error: ‘circle’ is not a member of ‘cv’
cv::circle(frame,cv::Point(theObjects.at(i).getXPos(),theObjects.at(i).getYPos
^
multipleObjectTracking.cpp:97:2: error: ‘putText’ is not a member of ‘cv’
cv::putText(frame,intToString(theObjects.at(i).getXPos())+ " , " + intToString
^
multipleObjectTracking.cpp:98:2: error: ‘putText’ is not a member of ‘cv’
cv::putText(frame,theObjects.at(i).getType(),cv::Point(theObjects.at(i).getXPo
^
multipleObjectTracking.cpp: In function ‘void drawObject(std::vector, cv::Mat&)’:
multipleObjectTracking.cpp:106:2: error: ‘circle’ is not a member of ‘cv’
cv::circle(frame,cv::Point(theObjects.at(i).getXPos(),theObjects.at(i).getYPos
^
multipleObjectTracking.cpp:107:2: error: ‘putText’ is not a member of ‘cv’
cv::putText(frame,intToString(theObjects.at(i).getXPos())+ " , " + intToString
^
multipleObjectTracking.cpp:108:2: error: ‘putText’ is not a member of ‘cv’
cv::putText(frame,theObjects.at(i).getType(),cv::Point(theObjects.at(i).getXPo
^
multipleObjectTracking.cpp: In function ‘void morphOps(cv::Mat&)’:
multipleObjectTracking.cpp:116:44: error: ‘MORPH_RECT’ was not declared in this scope
Mat erodeElement = getStructuringElement( MORPH_RECT,Size(3,3));
^
multipleObjectTracking.cpp:116:64: error: ‘getStructuringElement’ was not declared in this scope
Mat erodeElement = getStructuringElement( MORPH_RECT,Size(3,3));
^
multipleObjectTracking.cpp:120:34: error: ‘erode’ was not declared in this scope
erode(thresh,thresh,erodeElement);
^
multipleObjectTracking.cpp:123:36: error: ‘dilate’ was not declared in this scope
dilate(thresh,thresh,dilateElement);
^
multipleObjectTracking.cpp: In function ‘void trackFilteredObject(cv::Mat, cv::Mat, cv::Mat&)’:
multipleObjectTracking.cpp:135:76: error: ‘findContours’ was not declared in this scope
findContours(temp,contours,hierarchy,CV_RETR_CCOMP,CV_CHAIN_APPROX_SIMPLE );
^
multipleObjectTracking.cpp:146:54: error: ‘moments’ was not declared in this scope
Moments moment = moments((cv::Mat)contours[index]);
^
multipleObjectTracking.cpp:173:92: error: ‘putText’ was not declared in this scope
cameraFeed,"TOO MUCH NOISE! ADJUST FILTER",Point(0,50),1,2,Scalar(0,0,255),2);
^
multipleObjectTracking.cpp: In function ‘void trackFilteredObject(Object, cv::Mat, cv::Mat, cv::Mat&)’:
multipleObjectTracking.cpp:186:76: error: ‘findContours’ was not declared in this scope
findContours(temp,contours,hierarchy,CV_RETR_CCOMP,CV_CHAIN_APPROX_SIMPLE );
^
multipleObjectTracking.cpp:196:54: error: ‘moments’ was not declared in this scope
Moments moment = moments((cv::Mat)contours[index]);
^
multipleObjectTracking.cpp:223:93: error: ‘putText’ was not declared in this scope
cameraFeed,"TOO MUCH NOISE! ADJUST FILTER",Point(0,50),1,2,Scalar(0,0,255),2);
^
multipleObjectTracking.cpp: In function ‘int main(int, char**)’:
multipleObjectTracking.cpp:242:2: error: ‘VideoCapture’ was not declared in this scope
VideoCapture capture;
^
multipleObjectTracking.cpp:244:2: error: ‘capture’ was not declared in this scope
capture.open(0);
^
multipleObjectTracking.cpp:250:14: error: ‘waitKey’ was not declared in this scope
waitKey(1000);
^
multipleObjectTracking.cpp:261:27: error: ‘COLOR_BGR2HSV’ was not declared in this scope
cvtColor(cameraFeed,HSV,COLOR_BGR2HSV);
^
multipleObjectTracking.cpp:261:40: error: ‘cvtColor’ was not declared in this scope
cvtColor(cameraFeed,HSV,COLOR_BGR2HSV);
^
multipleObjectTracking.cpp:272:32: error: ‘imshow’ was not declared in this scope
imshow(windowName2,threshold);
^
multipleObjectTracking.cpp:280:51: error: ‘namedWindow’ was not declared in this scope
namedWindow( window_name, CV_WINDOW_AUTOSIZE );
^
multipleObjectTracking.cpp:282:84: error: ‘createTrackbar’ was not declared in this scope
eateTrackbar( "Min Threshold:", window_name, &lowThreshold, max_lowThreshold);
^
multipleObjectTracking.cpp:316:31: error: ‘imshow’ was not declared in this scope
imshow(windowName,cameraFeed);
^
: recipe for target 'multipleObjectTracking.o' failed
make: *** [multipleObjectTracking.o] Error 1

Erros in CannyThreshold and trackFiltredObject

Hi , i'm using opencv 3.0.0 and visual studio 2013 pro
when i build my project i get the following errors

CannyThreshold : undefined identifier
trackFiltredObject : function does not take 3 arguments

Getting more done in GitHub with ZenHub

Hola! @akaifi has created a ZenHub account for the akaifi organization. ZenHub is the leading team collaboration and project management solution built for GitHub.


How do I use ZenHub?

To get set up with ZenHub, all you have to do is download the browser extension and log in with your GitHub account. Once you do, you’ll get access to ZenHub’s complete feature-set immediately.

What can ZenHub do?

ZenHub adds a series of enhancements directly inside the GitHub UI:

  • Real-time, customizable task boards for GitHub issues;
  • Burndown charts, estimates, and velocity tracking based on GitHub Milestones;
  • Personal to-do lists and task prioritization;
  • “+1” button for GitHub issues and comments;
  • Drag-and-drop file sharing;
  • Time-saving shortcuts like a quick repo switcher.

Add ZenHub to GitHub

Still curious? See more ZenHub features or read user reviews. This issue was written by your friendly ZenHub bot, posted by request from @akaifi.

ZenHub Board

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.