Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
how to superimpose a rectangle in video file ?

Subject: how to superimpose a rectangle in video file ?

From: Toan Cao

Date: 7 Dec, 2011 03:50:09

Message: 1 of 3

Hi everyone,

I met a problem and can not solve it by myself. I hope that there are some people to help me overcome it. I appreciate all your help !

I load a video file to process frame by frame as images. For each frame, i would like to superimpose a rectangle on it at given coordinates (I mean :I would like to indicate the object that is recognized on each frame).
So, when i playback processed video file, i will see the rectangle for each frame of this processed video file. How can i do it ?

Thanks in advance.
Toan

Subject: how to superimpose a rectangle in video file ?

From: witek@mathworks.com

Date: 7 Dec, 2011 12:22:51

Message: 2 of 3

Hi Toan,

If you have a Computer Vision System Toolbox, you can draw shapes (including the rectangle) by using
the following object:

http://www.mathworks.com/help/toolbox/vision/ref/vision.shapeinserterclass.html

Witek



Toan Cao <toancv3010@gmail.com> wrote:
> Hi everyone,
>
> I met a problem and can not solve it by myself. I hope that there are some people to help me overcome it. I appreciate all your help !
>
> I load a video file to process frame by frame as images. For each frame, i would like to superimpose a rectangle on it at given coordinates (I mean :I would like to indicate the object that is recognized on each frame).
> So, when i playback processed video file, i will see the rectangle for each frame of this processed video file. How can i do it ?
>
> Thanks in advance.
> Toan

Subject: how to superimpose a rectangle in video file ?

From: Toan Cao

Date: 7 Dec, 2011 15:04:08

Message: 3 of 3

witek@mathworks.com wrote in message <jbnlqr$j85$1@newscl01ah.mathworks.com>...
> Hi Toan,
>
> If you have a Computer Vision System Toolbox, you can draw shapes (including the rectangle) by using
> the following object:
>
> http://www.mathworks.com/help/toolbox/vision/ref/vision.shapeinserterclass.html
>
> Witek

Hi Witek,

I am using the Matlab 2009 and it is not supported the computer vision system toolbox. Can you show me how i will make my rectangle on image at given pixel coordinates?
Looking forward to your reply!
Toan

Tags for this Thread

No tags are associated with this thread.

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us