필터 지우기
필터 지우기

How to read and view the .tif file in MATLAB?

조회 수: 23 (최근 30일)
SUSHMA MB
SUSHMA MB 2017년 7월 29일
댓글: Akira Agata 2017년 7월 31일
How can i view the .tiff file. I am able to read the .tif file but i am not able to view it. I used the following code to view, but its not working.
% DICOM Example Script
clear all; close all; clc
% Read all Tiff images
obj = Tiff('clipped_row2.tif','r');
i = 1;
while 1
subimage = obj.read();
subimages(:,:,:,i) = subimage(:,:,1:3);
if (obj.lastDirectory())
break;
end
obj.nextDirectory()
i = i+1;
end
dicomwrite( subimages, 'output_image.dcm');
dicomanon('output_image.dcm', 'output_anon.dcm');
X = dicomread('output_image.dcm');
  댓글 수: 4
SUSHMA MB
SUSHMA MB 2017년 7월 31일
Its a geo tiff file
Akira Agata
Akira Agata 2017년 7월 31일
I'm not familiar with geoTIFF file, but MATLAB Mapping Toolbox has geotiffread and mapshow functions to read and view geoTIFF file, respectively. Please take a look at help page of these functions.

댓글을 달려면 로그인하십시오.

답변 (1개)

Walter Roberson
Walter Roberson 2017년 7월 31일
You will need to
permute(x, [1 2 4 3])
to get the RGB into the place that vol3d expects.

카테고리

Help CenterFile Exchange에서 Image Data에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by