Ask Your Question
1

discretization

asked 2013-01-31 21:52:12 -0500

meenagkm gravatar image

updated 2013-01-31 23:35:21 -0500

Haris gravatar image

I want to discretize a contour which was drawn manually in an image. could anyone help me to code this.

edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted
1

answered 2013-02-01 01:29:40 -0500

In the first, preprocessing your image & extract contour then discretize the contour by approxPolyDP() function.

edit flag offensive delete link more
1

answered 2013-02-01 01:20:25 -0500

Michael Burdinov gravatar image

There nothing continuous in image so anything drawn in it is already discrete.

If you need to find polygon for this drawn contour you can use findContours function. Note that last parameter is method that may be used for simplification of extracted contour, so you can control discretization level.

Or if you already has the polygon and only want to simplify it you can use approxPolyDP function.

edit flag offensive delete link more
Login/Signup to Answer

Question Tools

Stats

Asked: 2013-01-31 21:52:12 -0500

Seen: 220 times

Last updated: Feb 01 '13