Kstars

fitshistogramcommand.h
1/*
2 SPDX-FileCopyrightText: 2021 Jasem Mutlaq <mutlaqja@ikarustech.com>
3
4 SPDX-License-Identifier: GPL-2.0-or-later
5*/
6
7#pragma once
8
9#include <QUndoCommand>
10#include "fitsdata.h"
11
12class FITSData;
13class FITSHistogramEditor;
14
15class FITSHistogramCommand : public QUndoCommand
16{
17 public:
18 FITSHistogramCommand(const QSharedPointer<FITSData> &data, FITSHistogramEditor * inHisto, FITSScale newType,
19 const QVector<double> &lmin,
20 const QVector<double> &lmax);
21 virtual ~FITSHistogramCommand();
22
23 virtual void redo() override;
24 virtual void undo() override;
25 virtual QString text() const;
26
27 private:
28 bool calculateDelta(const uint8_t * buffer);
29 bool reverseDelta();
30
31 FITSImage::Statistic stats;
32
33 QSharedPointer<FITSData> m_ImageData;
34 FITSHistogramEditor * histogram { nullptr };
35 FITSScale type;
36 QVector<double> min, max;
37
38 unsigned char * delta { nullptr };
39 unsigned long compressedBytes { 0 };
40
41};
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri May 17 2024 11:48:26 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.