1#ifndef CANRAWPLAYERMODEL_H
2#define CANRAWPLAYERMODEL_H
8#include <QtCore/QObject>
9#include <readerwriterqueue.h>
11using QtNodes::NodeData;
12using QtNodes::NodeDataType;
13using QtNodes::PortIndex;
14using QtNodes::PortType;
24 unsigned int nPorts(PortType portType)
const override;
25 NodeDataType
dataType(PortType portType, PortIndex portIndex)
const override;
26 std::shared_ptr<NodeData>
outData(PortIndex port)
override;
27 void setInData(std::shared_ptr<NodeData> nodeData, PortIndex port)
override;
41 void sendFrame(
const QCanBusFrame& frame);
47 std::unique_ptr<NodePainter> _painter;
48 moodycamel::ReaderWriterQueue<std::shared_ptr<NodeData>> _msgQueue{ 127 };
Definition canrawplayermodel.h:18
QtNodes::NodePainterDelegate * painterDelegate() const override
Definition canrawplayermodel.cpp:34
std::shared_ptr< NodeData > outData(PortIndex port) override
Definition canrawplayermodel.cpp:54
unsigned int nPorts(PortType portType) const override
Definition canrawplayermodel.cpp:39
void setInData(std::shared_ptr< NodeData > nodeData, PortIndex port) override
Definition canrawplayermodel.cpp:67
virtual bool hasSeparateThread() const override
Definition canrawplayermodel.h:30
NodeDataType dataType(PortType portType, PortIndex portIndex) const override
Definition canrawplayermodel.cpp:44
void sendFrame(const QCanBusFrame &frame)
Callback, called when CanRawSender emits signal sendFrame, sends frame.
Definition canrawplayermodel.cpp:72
CanRawPlayerModel()
Definition canrawplayermodel.cpp:23
Definition componentmodel.h:37
Direction
The enum class describing frame direction.
Definition datadirection.h:7