Add shadernode (big WIP)

This commit is contained in:
Lynix
2020-05-18 19:55:12 +02:00
parent 8c0d34313e
commit c26f3b9b71
12 changed files with 410 additions and 1 deletions

View File

@@ -0,0 +1,31 @@
#pragma once
#ifndef NAZARA_SHADERNODES_FRAGMENTOUTPUT_HPP
#define NAZARA_SHADERNODES_FRAGMENTOUTPUT_HPP
#include <DataModels/ShaderNode.hpp>
#include <QtWidgets/QDoubleSpinBox>
#include <QtWidgets/QFormLayout>
class FragmentOutput : public ShaderNode
{
public:
Nz::ShaderAst::ExpressionPtr GetExpression(Nz::ShaderAst::ExpressionPtr* expressions, std::size_t count) const override;
QString caption() const override { return "Fragment shader output"; }
QString name() const override { return "FragmentShaderOutput"; }
QtNodes::NodeDataType dataType(QtNodes::PortType portType, QtNodes::PortIndex portIndex) const override;
QWidget* embeddedWidget() override;
unsigned int nPorts(QtNodes::PortType portType) const override;
std::shared_ptr<QtNodes::NodeData> outData(QtNodes::PortIndex port) override;
void setInData(std::shared_ptr<QtNodes::NodeData>, int) override {};
};
#include <DataModels/FragmentOutput.inl>
#endif