Screenshot of AstroGraph

Astrophotography App for iPad and Mac

AstroGraph is an application for iPadOS 15 and macOS 12 that allows you to control external cameras, primarily for the purpose of astrophotography. Beta available on TestFlight. Download macOS version.

Photography Features

AstroGraph allows you to connect and control your camera using your iPad or Mac. You can also edit photographs in-app, and export them to other apps and services. Additionally, AstroGraph allows you to create timelapse videos from sets of images (macOS-only for now).

Astrophotography-Specific Features

In addition to being a generic camera control application, AstroGraph has specific features to support Astrophotography.

Bahtinov Focus Analyzer

Screenshot of bahtinov analysis

AstroGraph can analyze images with bahtnov diffraction lines to determine how in-focus an image is, and help you adjust the focus of your imaging setup.

Automatic Alignment and Stacking

AstroGraph will automatically align and stack images whenever you select multiple images to edit.

Technical Details


AstroGraph uses the ImageCaptureCore api to directly control plugged-in cameras. Upon connection, the app will open a session and send PTP commands to the camera. The PTP code in AstroGraph is a fork of Indigo, with changes specific for iPadOS.

Bahtinov Focus Analyzer

Bahtinov diffraction lines are analyzed using OpenCV's Probabilistic hough line detector. These lines are examined to determine the center and side lines. Focus is then calculated based off the intersection of the side lines and how for that intersection is from the center line. Anything less than 1 pixel is considered "in focus" as far as the UI will tell you, though this was arbitrarily chosen.

Automatic Alignment

AstroGraph implements a parallelized version of FOCUS for automatically aligning images. Stars in each image are detected using OpenCV's SimpleBlobDetector class. Afterwards, stars are matched up to a target image. An affine transform for each image is calculated using the rigid algorithm. Finally, images are stacked together on the GPU using metal to average each image.