How can I import .dng files using compression scheme 52546?
5 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
I am using this code to import .DNG raw images. However MATLAB doesn't seem to support 52546 compression. Any suggestion on how I can use these images in matlab without using external softwear?
clear; clc; close all;
%Example of reading and processing a Milky Way image I took with Matlab TIFF%
%By Fernando Zigunov 2020
f='20240213_191745.dng';
[RGB, I]=ReadDNG(f,'rggb');
RGB=RGB/(2^8); %Correct levels for 12-bit camera
imshow(RGB); %Shows image (only shiny stars appear)
%%
%=====Very simple image postprocessing, just to show what can be done======
%Image stretching (parameters manually selected)
RGBadjusted=imadjust(RGB,[0 0 0;0.02 0.04 0.016],[0 0 0;1 1 1],1.5);
%Denoising
W=5;
RGBadjusted(:,:,1)=wiener2(RGBadjusted(:,:,1),[W W]);
RGBadjusted(:,:,2)=wiener2(RGBadjusted(:,:,2),[W W]);
RGBadjusted(:,:,3)=wiener2(RGBadjusted(:,:,3),[W W]);
imshow(RGBadjusted)
0 comentarios
Respuestas (1)
Austin M. Weber
el 16 de Feb. de 2024
I haven't worked with .dng images before, but I found a function called DNG2JPG on the MATLAB File Exchange that might be useful (see the link and/or the attached function file). As the name implies, it converts .dng files into the .jpg format, which is a much more accessible file type.
Hopefully this helps.
0 comentarios
Ver también
Categorías
Más información sobre Image Data en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!