图像处理(空间变换)
2010-12-12 17:40
260 查看
空间变换是将输入图像的像素位置映射到输出图像的新位置。
常用的图像几何操作:缩放、旋转、透视变换
示例一:剪变换
I=imread('cameraman.tif');
tform=maketform('affine',[1 0 0;.5 1 0;0 0 1]);
J=imtransform(I,tform);
subplot(1,2,1);imshow(I);
subplot(1,2,2);imshow(J);
示例二:透视变换
I=imread('cameraman.tif');
udata=[0 1];vdata=[0 1];
tform=maketform('projective',[0 0; 1 0; 1 1;0 1],[-4 2;-8 -3;-3 -5;6 3]);
[B,xdata,ydata]=imtransform(I,tform,'bicubic','udata',udata,'vdata',vdata,'size',size(I),'fill',128);
subplot(1,2,1);imshow(udata,vdata,I);
subplot(1,2,2);imshow(xdata,ydata,B);
常用的图像几何操作:缩放、旋转、透视变换
示例一:剪变换
I=imread('cameraman.tif');
tform=maketform('affine',[1 0 0;.5 1 0;0 0 1]);
J=imtransform(I,tform);
subplot(1,2,1);imshow(I);
subplot(1,2,2);imshow(J);
示例二:透视变换
I=imread('cameraman.tif');
udata=[0 1];vdata=[0 1];
tform=maketform('projective',[0 0; 1 0; 1 1;0 1],[-4 2;-8 -3;-3 -5;6 3]);
[B,xdata,ydata]=imtransform(I,tform,'bicubic','udata',udata,'vdata',vdata,'size',size(I),'fill',128);
subplot(1,2,1);imshow(udata,vdata,I);
subplot(1,2,2);imshow(xdata,ydata,B);
相关文章推荐
- OpenCV图像处理(2)-空间变换,几何变换,阈值处理
- 【数字图像处理】六.MFC空间几何变换之图像平移、镜像、旋转、缩放具体解释
- 【数字图像处理】六.MFC空间几何变换之图像平移、镜像、旋转、缩放详解
- 数字图像处理-空间域图像增强(一)(图像反转,对数变换,幂次变换、分段线性变换)
- 数字图像处理——灰度变换与空间滤波(使用MFC)
- 图像处理之空间变换
- 数字图像处理--空间变换
- 数字图像处理--空间变换
- 基础图像处理之混合空间增强——(Java:拉普拉斯锐化、Sobel边缘检测、均值滤波、伽马变换)
- 数字图像处理-空间域处理-灰度变换-基本灰度变换函数(反转变换、对数变换、伽马变换和分段线性变换)
- 数字图像处理--空间变换
- 数字图像处理--空间变换
- 图像处理 灰度变换与空间滤波
- 数字图像处理--空间变换
- 数字图像处理-空间域处理-直方图均衡化
- 傅里叶变换在图像处理中的作用
- 图像处理 C语言 hough变换 检测直线
- 图像处理中的颜色空间
- QT实现图像处理-傅立叶变换、傅立叶反变换、平滑、锐化与模板匹配
- 【计算机视觉】【图像处理】对比度增强方法:伽马变换、全局直方图均衡化、限制对比度的自适应直方图均衡化