From ad6dae42eb1f83983bb4b7b61e54c5c423f2105b Mon Sep 17 00:00:00 2001 From: Patrick Chevalley Date: Sat, 30 Dec 2023 19:32:01 +0100 Subject: [PATCH] Better error message for RGB FITS file from INDI (#1159) --- cam_indi.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/cam_indi.cpp b/cam_indi.cpp index d326d513a..54a8b344e 100644 --- a/cam_indi.cpp +++ b/cam_indi.cpp @@ -864,9 +864,15 @@ bool CameraINDI::ReadFITS(CapturedFrame *frame, usImage& img, bool takeSubframe, int nhdus = 0; fits_get_num_hdus(fptr, &nhdus, &status); + if (naxis == 3) + { + pFrame->Alert(_("RGB images are not supported, please switch the INDI driver to Mono")); + PHD_fits_close_file(fptr); + return true; + } if (nhdus != 1 || naxis != 2) { - pFrame->Alert(_("Unsupported type or read error loading FITS file")); + pFrame->Alert(_("Unsupported FITS file")); PHD_fits_close_file(fptr); return true; }