官方说明文档
http://cn.mathworks.com/help/vision/ref/insertshape.html;jsessionid=cf20e78d9c69962c2a47d7672c89
用figure 和plot的方式无法直接在原图上做标记,且图像会根据窗口的大小做压缩。
insertShape就类似于opencv中的rectangle,circle 等函数的集成了~~~
I = imread('peppers.png'); % where???
RGB = insertShape(I, 'circle', [150 280 35], 'LineWidth',20);
pos_triangle = [183 297 302 250 316 297];
pos_hexagon = [340 163 305 186 303 257 334 294 362 255 361 191];
RGB = insertShape(RGB, 'FilledPolygon', {pos_triangle, pos_hexagon}, 'Color', {'white', 'green'}, 'Opacity', 0.7);
imshow(RGB);
%insert mark
I = imread('peppers.png');
%Draw a plu