Using imwrite after DWT and IDWT
古いコメントを表示
I am having a problem while using imwrite after performing DWT and IDWT operations on an gray image.
the problem is that after the imwrite operation when i click on the resulting image file all that i am able to view is a white background instead of an image.
Is there any method to overcome this problem.
for example: if x is an m*n gray scale image then what i have done is
[A,B,C,D]=dwt2(x,'haar');
.....
.....
.....
here i have done some manipulations on the sub-bands(B,C,D)
.....
.....
.....
y=idwt2(A,B,C,D,'haar');
imwrite(y,'C:\Users\HOME\Desktop\IMAGEPROCESS','jpg');
After all these operations when i use imshow(y,[]) the correct image is being displayed. But its not the same case when i try to open the JPG image file(named IMAGEPROCESS in the Eg) as a result of the imwrite operation.
KINDLY HELP
採用された回答
その他の回答 (1 件)
Wayne King
2012 年 3 月 21 日
0 投票
imwrite() converts images to RGB before writing a jpeg file.
Can you please try writing a .png file and see if you have the same problem?
4 件のコメント
vikas
2012 年 3 月 21 日
Wayne King
2012 年 3 月 21 日
Are you viewing the image written by imwrite in MATLAB, or using other software?
vikas
2012 年 3 月 22 日
Wayne King
2012 年 3 月 22 日
Hi Vikas, can you go over to CSSM and there you will see my email. Send me the original image along with the MATLAB code you use to manipulate the coefficients and I will have a look. It's hard to go further without more information.
カテゴリ
ヘルプ センター および File Exchange で Neighborhood and Block Processing についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!