Look at roipoly
using r
and c
inputs in addition to input image I
.
segment image using pixel coordinates matlab
-
30-07-2022 - |
문제
This question maybe pretty basic, so please bear with me. I have 4 pixel coordinats and an image. I want to segment the image part within this 4 points alone and make a new image. Can you please tell me the easiest way to do this?
해결책
다른 팁
Assuming you have a coordinate list xcoord
matching with ycoord
and want to have the smallest square that contains your pixels:
myImage = rand(100)
xcoord = [12 16 22 82];
ycoord = [24 70 12 34];
mySegment = myImage(xcoord(min):xcoord(max),ycoord(min):ycoord(max))
제휴하지 않습니다 StackOverflow