Labfans是一个针对大学生、工程师和科研工作者的技术社区。 论坛首页 | 联系我们(Contact Us)
MATLAB爱好者论坛-LabFans.com
返回   MATLAB爱好者论坛-LabFans.com > 工程数学软件 > MATLAB论坛
MATLAB论坛 一切MATLAB相关问题在此讨论。
 
 
主题工具 显示模式
旧 2009-05-14, 13:36   #4
silas_xue
高级会员
 
注册日期: 2008-11-01
年龄: 39
帖子: 406
声望力: 26
silas_xue 是一个将要出名的人
默认 回复: 求助——如何改变程序中中值滤波的窗口大小

lz 圆形窗口 即以你的所在像像素点为圆心 寻找indice在某一半径内的值
由于是数字图像 不可能做到完全的圆处理 近似搜索
希望可以对你有些帮助

pseudo:
... % initial process, imread,
for i,j %denote p(i,j) as the current
for beta %beta as the index searching angle
loc = find(p(i+floor[k*cos(beta)+0.5],i+floor[k*sin(beta)+0.5]))
mean(loc) % fitering: two ways available: p(i,j) anticipation or p(i,j) un-anticipation
p(i,j) = mean (loc) % current pixel updated
end for
end for
...

PS: No cosideration of boundary and probable value overflowing.

Thx for reading.
PS:若还算满意,直接点击“Thanks”,再次登陆时亦便于查看回答是否真的帮到你了。
个人观点 仅供参考 多多交流 相互学习
silas_xue 当前离线   回复时引用此帖
 


发帖规则
不可以发表新主题
不可以发表回复
不可以上传附件
不可以编辑自己的帖子

启用 BB 代码
论坛启用 表情符号
论坛启用 [IMG] 代码
论坛禁用 HTML 代码



所有时间均为北京时间。现在的时间是 16:14


Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.