没有合适的资源?快使用搜索试试~ 我知道了~
四种灰度变换的matlab代码.doc
需积分: 5 0 下载量 22 浏览量
2022-10-19
23:28:51
上传
评论
收藏 13KB DOC 举报
温馨提示
![preview](https://dl-preview.csdnimg.cn/86786199/0001-836f55cade75055de99c5d26ce03811a_thumbnail-wide.jpeg)
![preview-icon](https://csdnimg.cn/release/downloadcmsfe/public/img/scale.ab9e0183.png)
试读
2页
四种灰度变换的matlab代码.doc
资源详情
资源评论
资源推荐
![](https://csdnimg.cn/release/download_crawler_static/86786199/bg1.jpg)
版权所有:caoleiscu
欢迎指正:caoleiemail@163.com
[filename,pathname]=uigetfile('*.bmp;*.tif;*.jpg;*.png','输入原图像');
file_name=[pathname filename];
I=imread(file_name);
disp('四种基本的灰度变换,请输入选择项');
disp('0--图像反转');
disp('1--对数变换');
disp('2--伽马变换');
disp('3--分段线性变换');
disp('4--直方图均衡');
d=input('please input you choice(请输入您的选择):');
switch d
case 0
J=double(I);
J=256-1-J;
H=uint8(J);
subplot(121),imshow(I);
subplot(122),imshow(H);
case 1
J=log(1+double(I));
subplot(121),imshow(I);
subplot(122),imshow(J,[]);
case 2
x=0:255;
a=80,b=1.8,c=0.009;
J=b.^(c.*(double(I)-a))-1;
y=b.^(c.*(x-a))-1;
subplot(2,2,1),imshow(I);
subplot(2,2,2),imhist(I);
subplot(2,2,3),imshow(J);
subplot(2,2,4),imhist(J);
figure,plot(x,y);
case 3
f0=0;g0=0;
![docx](https://img-home.csdnimg.cn/images/20210720083331.png)
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![rar](https://img-home.csdnimg.cn/images/20210720083606.png)
![gz](https://img-home.csdnimg.cn/images/20210720083447.png)
![xlsx](https://img-home.csdnimg.cn/images/20210720083732.png)
![pptx](https://img-home.csdnimg.cn/images/20210720083543.png)
![pptx](https://img-home.csdnimg.cn/images/20210720083543.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![docx](https://img-home.csdnimg.cn/images/20210720083331.png)
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![xsl](https://img-home.csdnimg.cn/images/20210720083646.png)
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![avatar](https://profile-avatar.csdnimg.cn/acfce43ffe2c41f996326bd927946824_yhsbzl.jpg!1)
智慧安全方案
- 粉丝: 3702
- 资源: 59万+
上传资源 快速赚钱
我的内容管理 展开
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助
![voice](https://csdnimg.cn/release/downloadcmsfe/public/img/voice.245cc511.png)
![center-task](https://csdnimg.cn/release/downloadcmsfe/public/img/center-task.c2eda91a.png)
安全验证
文档复制为VIP权益,开通VIP直接复制
![dialog-icon](https://csdnimg.cn/release/downloadcmsfe/public/img/green-success.6a4acb44.png)
评论0