Skip to content

Draft: Introduce rolling average stacker, sequence dark/stack nodes, rework UI and FITSData.

Eric Dejouhanet requested to merge edejouhanet/kstars:feature__live_stack into master

This MR implements a simple rolling average of incoming ISD::Camera frames as an introduction to EAA with Ekos.

StackedFrame[k+1] = \frac {LightFrame + (k-1)*StackedFrame[k]} k

Currently, no coordinate offset is computed between frames, therefore guiding is required for proper results.

The live stacker works like the dark correction: it applies to single and looping/framing previews, and replaces the data of the incoming frame.

Solutions are explored for further improvement using a single camera:

  • Computing offsets in the same way as the Guide module, and progressively reducing the ROI of the frame only.
  • Solving the star field, computing offsets and reducing the ROI, then using the coordinates to recenter the target.
  • Sharing camera frames with the Guide module, duplicating frames.

The MR implements the LiveStackProcessor stacker in the same architecture as the DarkProcessor. The intent is to use the same operation stack as the Guide module to build a generic Pipeline class, agglomerating Node instances with a common interface.

Class FITSData is also modified to include metadata on whether a dark frame was corrected and how many light frames were stacked in. This information serves as marker to avoid repeating the Processor modifications on the incoming frame.

The stacker currently uses an agglomerating buffer of type double, which may take a lot of memory space depending on the frame dimensions. It probably only supports greyscale frames for now.

The UI in Capture is altered to look like this:

image

This is not very nice yet, and is very specific to Capture. I'd like to reuse the led appearance instead, with the idea of a node pipeline, a bit like Blender or Unreal Editor. Comments welcome.

Edited by Eric Dejouhanet

Merge request reports