How can read PNG image in actual size?

조회 수: 7 (최근 30일)
Noor Abbas
Noor Abbas 2019년 5월 30일
댓글: Noor Abbas 2019년 6월 6일
I have tried to read image using imread but It read image with small size!
  댓글 수: 5
Noor Abbas
Noor Abbas 2019년 6월 2일
I have tried to attached a copy of image but Matlab offer 2MB to attached not 68 MB.
Do you have another way to attached this image?
Thanks in advance
Walter Roberson
Walter Roberson 2019년 6월 2일
You can possibly zip it and attach that.
Or you can put it up on google drive or dropbox.

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

답변 (2개)

Image Analyst
Image Analyst 2019년 6월 2일
Obviously your screen is not 68 MB in size so you're either going to have to demagnify the image to see all of it, or you're going to have to just look at a small part of it, in its pixel-for-pixel true size, though a small window.
See my attached zoom demo, and also look into the function truesize().
  댓글 수: 4
Image Analyst
Image Analyst 2019년 6월 2일
He can drop it in his MATLAB online drive (preferably) and give us the link.
Alternatively use Google drive or dropbox or similar.
Noor Abbas
Noor Abbas 2019년 6월 3일
Dear Walter Roberson and Image Analyst,
Could you please find link of image , the attached image is 46MB on mylaptop, but when read it in Matlab is 120*160 .
the link is
Thanks in advance

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


Walter Roberson
Walter Roberson 2019년 6월 3일
That is not a PNG file, it is a DNG file, which is a TIFF variation used to store raw image data.
T = Tiff('L1.DNG');
offset = getTag(T, 'SubIFD');
setSubDirectory(T,offset)
imCFA = read(T);
This will give you Color Filter Array (CFA) data as uint16 -- sort of like Bayer Mosaicing
The imCFA array is 4000 x 5984 . Apple's Preview says the image is 5976 × 3992 after demosaicing.
Unfortunately Tiff class does not know about the tags needed to read the CFAPattern. Apple Preview says it is 2, 1, 1, 0, which would correspond to Blue, Green, Green, Red. Unfortunately I have not yet figured out how to decode the information.
The file includes a 599040 byte "MakerNotes" TIFF tag. https://owl.phy.queensu.ca/~phil/exiftool/idiosyncracies.html says that your particular model of Leica, Leica M (Type 240) has the most idiotic MakerNotes format out of all of the Leica models out of all camera manufacturers. Somewhere in there is a preview image.
  댓글 수: 6
Walter Roberson
Walter Roberson 2019년 6월 4일
I am not at all confident as to interpretation, but parts of the file hint that there might be a 1920 x 1280 preview inside the file.
Noor Abbas
Noor Abbas 2019년 6월 6일
Thanks Walter Roberson for everything.

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

카테고리

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

제품

Community Treasure Hunt

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

Start Hunting!

Translated by