Using imsharpen with imagesc

조회 수: 3 (최근 30일)
Articat 2019년 9월 25일
답변: Subhadeep Koley 2019년 10월 29일
Can you use imsharpen with imagesc?
Trying to use imshapren with the following code:
PLIFData_rot = (flipud(PLIFdata(:,:,imFrame)));
FiltImPLIF = imguidedfilter(imgaussfilt((PLIFData_rot)));
caxis([0 .1]);
pbaspect([50 50 1]);
  댓글 수: 2
Adam 2019년 9월 25일
imsharpen acts on the raw data so it is independent of how you visualise the data afterwards. So yes, no reason why you can't use it with imagesc. Just apply it first to the raw data, them pass the result to imagesc instead of the original.
Articat 2019년 9월 25일
I tried setting I equal to the imagesc() argument and then later sharpening the image but I get the error: "image cannot be a child of image". Any ideas?

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

채택된 답변

Subhadeep Koley
Subhadeep Koley 2019년 10월 29일
Hi, from your previous comment it seems that you are trying to pass the image object returned by imagesc() into the input of imsharpen(). Something like below,
I = imagesc(xVecPLIF,yVecPLIF,double(FiltImPLIF)/double(max(max(FiltImPLIF))));
sharpenImage = imsharpen(I);
In the code above I is an object whereas, input of imsharpen() is designed to be a grayscale or truecolor (RGB) image one of these types: uint8, int8, uint16, int16, uint32, int32, single, double.
Instead, try this
FiltImPLIF_Sharpen = imsharpen(double(FiltImPLIF)/double(max(max(FiltImPLIF))));

추가 답변 (0개)


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

Community Treasure Hunt

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

Start Hunting!

Translated by