#ifndef PERSIST_H #define PERSIST_H #include #include #include "model/processor/IProcessStrategy.h" #include "utils/OpenCLHelper.h" #define PERSIST_MAX_SIZE 8 typedef struct Persist_t { cl_int persist; cl_int mode; }Persist_t; class Persist : public IProcessStrategy { Q_OBJECT public: Q_INVOKABLE Persist(const Context context, const QString kernelPath, const QObject *parent); virtual void cpuProcess(ScenGenOutput_t parameters) override; virtual void finalize() override; private: KernelFunctor _kernelFunctor; virtual Image* processKernel(Image *frames, Buffer* scratchPad) override; Persist_t _kernelParameters; QVector _queue; Image* _imageSum; bool _reCalc; quint64 _lastWidth; quint64 _lastHeight; }; #endif // PERSIST_H