Prev: Thresholding Video Frames
Next: video Help
From: Don Orofino on 1 May 2010 09:49 Since you indicate that you know the Car Tracking demo in VIP Blockset (viptrafficof.mdl), you already have a good head start. I presume you're in Simulink and continuing your work there... One step in tracking is blob analysis - each "region of interest" (here, a car) is tracked as a blob of pixels. Each blob can compute various attributes about itself, including its centroid, bounding box, etc. That's how we generate the box around each tracked car in the demo -- the green outline is simply connecting the corners of these bounding box coordinates visually. You might be after the centroid of the region, not the bounding box. So dig in to that model. Look under the "Thresholding and Region Filtering" subsystem, find the Blob Analysis block, open its dialog and turn on some other attributes. You can record these centroids to the workspace using the To Workspace or Signal To Workspace blocks. You can also superimpose markers using those centroids with the "Draw Shapes" or "Draw Markers" blocks in VIP Blockset, to confirm you're extracting the right values visually. --Don "Mohammad AlHourani" <comp.soft-sys.matlab(a)mathworks.com> wrote in message <hrfru1$7td$1(a)fred.mathworks.com>... > hello every one,,i'm doin my grad project,,and i want to track in real-time a swarm of mobile robots using a webcam and know their locations,,i've used Optical Flow,,Horn Schunck to track the objects,,,,it works well and track moving objects only in the environment,,now i want to know their coordinates on the simulink output video,,,i tried this: > on the model -> right click -> signal & scope manager -> viewers -> XY graph and attach to model,,,i don't know what to specify as inputs in the XY graph,,i tried the BBox that shown didn't work,,,i think its a matrix input,,but i don't know,,,, > > i really need help in this,,,i just want (X,Y) for a moving object from the simulink output,,,,,btw i used almost the same algorithm in the Matlab -> start -> demos -> blocksets -> video and image processing -> tracking -> tracking cars using optical flow > but i edited and use it in a real-time and it works... > > so,,how i can retrieve the coordinates of the moving object in the video????????? > > thx for help in advance
|
Pages: 1 Prev: Thresholding Video Frames Next: video Help |