Why does imread read the alpha channel, but not the image itself?
이전 댓글 표시
Hi all,
I would like to read a png with transparent background in MATLAB (2014b, Windows 7) using imread:
[icon, map, alpha] = imread('icon.png');
However, icon is now only zeros, but the alpha channel is read correctly (the map is empty as well). I made the png with Photoshop and I tried several options, such as making the image indexed, RGB, grayscale, 8 bits, 32 bits, et cetera.
Does anyone have an idea about why my alpha channel is read correctly, but the image data is black? How should I save the image from Photoshop such that it is read in MATLAB? Thanks in advance!
Kind regards, Mark
채택된 답변
추가 답변 (1개)
Raphael
2018년 4월 6일
편집: Walter Roberson
2018년 4월 7일
1 개 추천
댓글 수: 1
Walter Roberson
2018년 4월 7일
Notice, though, that "icon is now only zeros", so something else was going wrong for the user.
카테고리
도움말 센터 및 File Exchange에서 Image Processing Toolbox에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
