How to Align Ha and OIII FITS Images in GIMP
This guide explains how to import and align separate Hydrogen-alpha (H-alpha) and Oxygen-III (OIII) narrowband astronomical FITS exposures using GIMP. You will learn how to open single-channel astronomical data, stack the exposures as separate layers, use layer blend modes to identify misalignments, and apply translation and rotation transforms to achieve pixel-level star alignment for a bi-color composite.
1. Preparing and Loading FITS Files into GIMP
GIMP includes native support for loading single-channel FITS (Flexible Image Transport System) files.
- Launch GIMP and go to File > Open.
- Select your calibrated and stretched H-alpha FITS file. GIMP will import the raw values and display the file as a grayscale image.
- Bring in the OIII exposure by navigating to File > Open as Layers... and selecting your OIII FITS file.
- Rename your layers in the Layers panel (
Ctrl + L) to "Ha" and "OIII" to avoid confusion. Place the "Ha" layer at the bottom and the "OIII" layer on top.
Note: If your FITS files are linear (unstretched), perform an initial histogram stretch on each file (via Colors > Curves or Colors > Levels) so that background stars are easily visible before attempting alignment.
2. Setting Up the Alignment Environment
Aligning two astronomical exposures requires visual feedback to detect sub-pixel and pixel-level offsets.
- Select the top OIII layer in the Layers panel.
- Change the Mode dropdown at the top of the Layers panel from Normal to Difference.
- When two identical, perfectly aligned images are set to Difference, the canvas turns solid black. Any misalignment will show up as bright, doubled star edges or white silhouettes against a dark background.
3. Performing Positional (Translational) Alignment
- Zoom into a prominent, non-saturated reference star near the center
of the frame using the Zoom Tool (
Z). - Select the Move Tool (
M). - Ensure Move the active layer is selected in the Tool Options dock.
- With the OIII layer active, use the Arrow Keys on
your keyboard to nudge the layer one pixel at a time until the central
reference star turns as close to pitch black as possible. Holding
Shiftwhile pressing the arrow keys moves the layer in larger increments if the offset is significant.
4. Correcting Field Rotation
Field rotation commonly occurs between filter changes due to tracking errors or camera orientation shifts.
- Zoom out and inspect the outer corners of the image. If the central star is dark but stars near the edges show bright fringes, the frames are rotated relative to each other.
- Select the Rotate Tool
(
Shift + R). - Set the rotation center (pivot point) directly over the central star you aligned in Step 3 by clicking and dragging the small center circle.
- Zoom in on a sharp star near the outer edge of the frame.
- In the Rotate dialog, use fractional degree adjustments (e.g.,
0.10or-0.05) to rotate the layer until the edge star cancels out into black. - Click Rotate to commit the transform.
5. Verifying Alignment
- Set the OIII layer's blend mode back to Normal.
- Rapidly toggle the visibility icon (the eye symbol) next to the OIII layer. This "blinking" technique reveals any remaining drift or misalignment between the two channels.
- If necessary, use the Unified Transform Tool
(
Shift + T) to adjust for slight focal length variations or optical distortion between filters.
6. Cropping Incomplete Edges
Shifting and rotating will cause the boundaries of the OIII layer to misalign with the Ha layer's boundary.
- Select the Crop Tool (
Shift + C). - Draw a rectangle that encompasses only the area where both the Ha and OIII layers fully overlap.
- Press Enter to crop the entire image to the overlapping area.
Both narrowband channels are now aligned and ready to be assigned to RGB channels (typically Ha to Red, and OIII to Green and Blue) for final bi-color processing.