24小时热门版块排行榜    

查看: 1965  |  回复: 8
当前只显示满足指定条件的回帖,点击这里查看本话题的所有回帖

小鬼木木

新虫 (小有名气)

[求助] 如何在MATLAB读取的图片中添加坐标系 已有1人参与

如何在MATLAB读取的一副图片中,以图片中心为坐标原点画坐标系?求大神帮助,谢谢!
期望效果图如上传的图片所示

如何在MATLAB读取的图片中添加坐标系
示例.png
回复此楼
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

小鬼木木

新虫 (小有名气)

引用回帖:
8楼: Originally posted by FMStation at 2016-09-24 19:56:51
https://stackoverflow.com/questions/10738810/matlab-referencing-an-element-in-a-structure

谢谢你的耐心解答!
9楼2016-09-24 20:26:44
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖
查看全部 9 个回答

FMStation

至尊木虫 (知名作家)

【答案】应助回帖

★ ★ ★ ★ ★ ★ ★ ★ ★ ★
感谢参与,应助指数 +1
小鬼木木: 金币+10, ★★★很有帮助 2016-09-24 13:55:05
https://www.mathworks.com/matlabcentral/newsreader/view_thread/288905
CODE:
L = bwlabel(Iedge);
ZB1 = regionprops(L, 'Centroid'); %acquire the center of mass
center_x = ZB1.Centroid(1); %acquire X position of the center mass
center_y = ZB1.Centroid(2); %acquire Y position of the center mass

line(center_x, center_y, 'Marker', '*', 'MarkerEdgeColor', 'r')

» 本帖已获得的红花(最新10朵)

2楼2016-09-23 18:01:57
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

小鬼木木

新虫 (小有名气)

引用回帖:
2楼: Originally posted by FMStation at 2016-09-23 18:01:57
https://www.mathworks.com/matlabcentral/newsreader/view_thread/288905


L = bwlabel(Iedge);
ZB1 = regionprops(L, 'Centroid'); %acquire the center of mass
center_x = ZB1.Centroid(1); %acquire X  ...

非常感谢,但是,我算是一个MATLAB小白,根据这个代码,没做出来呀,总是提示各种错误,你能不能帮我测试下,看看到底怎么回事,谢谢。
3楼2016-09-24 13:54:19
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

小鬼木木

新虫 (小有名气)

送红花一朵
引用回帖:
2楼: Originally posted by FMStation at 2016-09-23 18:01:57
https://www.mathworks.com/matlabcentral/newsreader/view_thread/288905


L = bwlabel(Iedge);
ZB1 = regionprops(L, 'Centroid'); %acquire the center of mass
center_x = ZB1.Centroid(1); %acquire X  ...

常感谢,但是,我算是一个MATLAB小白,根据这个代码,没做出来呀,总是提示各种错误,你能不能帮我测试下,看看到底怎么回事,谢谢。
4楼2016-09-24 14:15:25
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖
信息提示
请填处理意见