How to show given x,y position on image frame?
조회 수: 2 (최근 30일)
이전 댓글 표시
I am trying to show shape connecting 3 x,y points on image frame.
fileCount=length(Files);
middleImage=round((fileCount/2)-5);
startingImage=Files(5).name;
middleImagePOS=Files(middleImage).name;
imagename1 = fullfile(outputFolder, middleImagePOS);
originalImage = imread(imagename1);
out = insertShape(originalImage,'Line',[
ex_points{5}(1,1) ex_points{5}(1,2)
ex_points{5}(2,1) ex_points{5}(2,2)
ex_points{5}(2,1) ex_points{5}(2,2)
ex_points{5}(3,1) ex_points{5}(3,2)
ex_points{5}(3,1) ex_points{5}(3,2)
ex_points{5}(1,1) ex_points{5}(1,2)
] );
%grayImage = insertMarker(originalImage,pos,'+','Color',color,'size',20);
imshow(out);
% plot([shoulder_X elbow_x wrist_x], [shoulder_Y elbow_y wrist_y],'g');
F = getframe;
imshow(F.cdata);
ex_points{5} -> is array which include x,y value of point a,b and c.
How can i show this shape on the image which i take? if that insertShape() worked, it should show the image like below

댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Surfaces, Volumes, and Polygons에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!