I = raw2planar(cfa)
separates the channels of the Bayer pattern CFA image cfa into a
multidimensional image, I, with a channel for each individual sensor
element.
Read a Color Filter Array (CFA) image into the workspace. The rawread function returns cfa, a 4012-by-6034 image.
cfa = rawread("colorCheckerTestImage.NEF");
Split the returned CFA image into several individual images, each representing a CFA sensor component. The CFA image has a Bayer pattern of RGGB. The raw2planar function returns 2206-by-3017-by-4 array representing each component of the RGGB pattern.
Image with a channel for each sensor element, returned as an
(M/2)-by-(N/2)-by-4 numeric array of the same
data type as cfa.
The order of the channels in the output image depends on the Bayer pattern of the
CFA: the order of the red, green, and blue sensors. The 2-by-2 grid of pixels in the
upper-left corner of the CFA image describes the channel order, from left-to-right,
top-to-bottom. I(:,:,1) corresponds to the sensor at
cfa(1,1), I(:,:,2) to the sensor at
cfa(1,2), I(:,:,3) to the sensor at
cfa(2,1), and I(:,:,4) to the sensor at
cfa(2,2).
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window.
Web browsers do not support MATLAB commands.
Website auswählen
Wählen Sie eine Website aus, um übersetzte Inhalte (sofern verfügbar) sowie lokale Veranstaltungen und Angebote anzuzeigen. Auf der Grundlage Ihres Standorts empfehlen wir Ihnen die folgende Auswahl: .
Sie können auch eine Website aus der folgenden Liste auswählen:
So erhalten Sie die bestmögliche Leistung auf der Website
Wählen Sie für die bestmögliche Website-Leistung die Website für China (auf Chinesisch oder Englisch). Andere landesspezifische Websites von MathWorks sind für Besuche von Ihrem Standort aus nicht optimiert.