mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2025-03-01 10:33:28 +00:00
Merge pull request #946 from m-seker/refactor/python
Move Python related code to Python module
This commit is contained in:
@@ -68,7 +68,7 @@ signals:
|
||||
void setInputImage(int priority, const Image<ColorRgb> &image, int timeout_ms, bool clearEffect);
|
||||
|
||||
private:
|
||||
|
||||
void setModuleParameters();
|
||||
void addImage();
|
||||
|
||||
Hyperion *_hyperion;
|
||||
|
26
include/python/PythonProgram.h
Normal file
26
include/python/PythonProgram.h
Normal file
@@ -0,0 +1,26 @@
|
||||
#pragma once
|
||||
|
||||
#include <QByteArray>
|
||||
#include <QString>
|
||||
|
||||
// Python includes
|
||||
// collide of qt slots macro
|
||||
#undef slots
|
||||
#include "Python.h"
|
||||
#define slots
|
||||
|
||||
class Logger;
|
||||
|
||||
class PythonProgram
|
||||
{
|
||||
public:
|
||||
PythonProgram(const QString & name, Logger * log);
|
||||
~PythonProgram();
|
||||
|
||||
void execute(const QByteArray &python_code);
|
||||
|
||||
private:
|
||||
QString _name;
|
||||
Logger* _log;
|
||||
PyThreadState* _tstate;
|
||||
};
|
Reference in New Issue
Block a user