h0=figure('toolbar','none',...
'position',[198 56 350 468],...
'name','函数变换');
h1=axes('parent',h0,...
'position',[0.25 0.45 0.5 0.5],...
'visible','off');
I=imread('cameraman.tif');
imshow(I)
b1=uicontrol('parent',h0,...
'units','points',...
'tag','b1',...
'backgroundcolor',[0.75 0.75 0.75],...
'style','pushbutton',...
'string','图像压缩',...
'position',[30 100 50 20],...
'callback',[...
'cla,',...
'I=imread(''cameraman.tif'');,',...
'I2=im2double(I);,',...
'imshow(I2)']);
b2=uicontrol('parent',h0,...
'units','points',...
'tag','b2',...
'backgroundcolor',[0.75 0.75 0.75],...
'style','pushbutton',...
'string','图像解压',...
'position',[100 100 50 20],...
'callback',[...
'cla,',...
'I=imread(''cameraman.tif'');,',...
'I=im2double(I);,',...
'T=dctmtx(8);,',...
'B=blkproc(I,[8 8],''P1*x*P2'',T,T'');,',...
'mask=[1 1 1 1 0 0 0 0;,',...
'1 1 1 0 0 0 0 0;,',...
'1 1 0 0 0 0 0 0;,',...
'1 0 0 0 0 0 0 0;,',...
'0 0 0 0 0 0 0 0;,',...
'0 0 0 0 0 0 0 0;,',...
'0 0 0 0 0 0 0 0;,',...
'0 0 0 0 0 0 0 0];,',...
'B2=blkproc(B,[8 8],''P1.*x'',mask);,',...
'I2=blkproc(B2,[8 8],''P1*x*P2'',T'',T);,',...
'imshow(I2)']);
b3=uicontrol('parent',h0,...
'units','points',...
'tag','b3',...
'backgroundcolor',[0.75 0.75 0.75],...
'style','pushbutton',...
'string','线条解析',...
'position',[170 100 50 20],...
'callback',[...
'cla,',...
'I=imread(''cameraman.tif'');,',...
'BW=edge(I);,',...
'imshow(BW)']);
b4=uicontrol('parent',h0,...
'units','points',...
'tag','b4',...
'backgroundcolor',[0.75 0.75 0.75],...
'style','pushbutton',...
'string','关闭',...
'fontsize',15,...
'position',[80 50 80 30],...
'callback','close');
txysjys.rar_matlab 图像压缩_图像压缩与解压_图像压缩解压
版权申诉
147 浏览量
2022-07-14
20:54:29
上传
评论
收藏 51KB RAR 举报
小贝德罗
- 粉丝: 69
- 资源: 1万+
最新资源
- #P0015. 全排列 超级简单
- pta题库答案c语言之排序4统计工龄.zip
- pta题库答案c语言之树结构7堆中的路径.zip
- pta题库答案c语言之树结构3TreeTraversalsAgain.zip
- pta题库答案c语言之树结构2ListLeaves.zip
- pta题库答案c语言之树结构1树的同构.zip
- 基于C++实现民航飞行与地图简易管理系统可执行程序+说明+详细注释.zip
- pta题库答案c语言之复杂度1最大子列和问题.zip
- 三维装箱问题(Three-Dimensional Bin Packing Problem,3D-BPP)是一个经典的组合优化问题
- 以下是一些关于Linux线程同步的基本概念和方法.txt
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈