Re: Extracting green channel from FITS
Posted by
han.k on
Mar 02, 2022; 11:34pm
URL: http://astroimagej.170.s1.nabble.com/Extracting-green-channel-from-FITS-tp1750p1812.html
The link to the FITs file posted earlier has a RGGB debayer/demosaic pattern.
The RGGB pattern should be interpretated as follows (corrected 2022-03-03):

So pixel 1,1 is top left.
Attached in a ZIP file a FITs image for testing the four possible patterns. I created it because it made testing much more simple.
bayer_test_pattern.zipFor demosaic pattern RGGB it shows this:

So for RGGB=RG it shows (yellow marked) from left to right red, green, blue.
To complicate things they invented a new keyword ROWORDER (not used in the ZWO FITS), see:
https://free-astro.org/index.php?title=Siril:FITS_orientationI'm not so happy about keyword ROWORDER but that was created.
Other keywords to include in the final debayer pattern are:
XBAYROFF
YBAYROFF
See:
https://cdn.diffractionlimited.com/help/maximdl/FITS_File_Header_Definitions.htmIt would be much simpler if the processing software would update the value of keyword BAYERPAT after each manipulation but some preferred to maintain the orginal BAYERPAT value.
Han,
author of ASTAP