30 lines
742 B
C++
30 lines
742 B
C++
#pragma once
|
|
|
|
#include "Plot.h"
|
|
#include <QApplication>
|
|
#include <QThread>
|
|
|
|
|
|
namespace YSG {
|
|
struct PlotPrivate {
|
|
explicit PlotPrivate(Plot* plot) : q(plot) {};
|
|
Plot *q{};
|
|
int mRefreshTimesPreSecond = 30;
|
|
TimerThread* mTimerThread{};
|
|
QTimer *mTimer{};
|
|
enum PlotState { NeedToRender, NeedToPaint};
|
|
QAtomicInteger<int> mPlotState = NeedToRender;
|
|
SpinLock mBufferLock, mRenderLock, mPrepareDataLock, mMustPrepareDataLock;
|
|
//QPixmap *mRenderBuffer{}, mPaintBuffer;
|
|
//QImage *mRenderBuffer{}, mPaintBuffer;
|
|
QImage *mRenderBuffer{};
|
|
QPixmap mPaintBuffer{};
|
|
QColor mBackground = Qt::black;
|
|
PerformanceShower *mShower{};
|
|
};
|
|
|
|
|
|
}
|
|
|
|
|