ShaderNodes: Add BufferField node

This commit is contained in:
Jérôme Leclercq
2020-07-19 21:08:21 +02:00
parent 086f76fb97
commit 5258f0b61a
6 changed files with 514 additions and 0 deletions

View File

@@ -0,0 +1 @@
#include <ShaderNode/DataTypes/BoolData.hpp>

View File

@@ -0,0 +1,28 @@
#pragma once
#ifndef NAZARA_SHADERNODES_BOOLDATA_HPP
#define NAZARA_SHADERNODES_BOOLDATA_HPP
#include <ShaderNode/Previews/PreviewValues.hpp>
#include <nodes/NodeData>
struct BoolData : public QtNodes::NodeData
{
inline BoolData();
QtNodes::NodeDataType type() const override
{
return Type();
}
static QtNodes::NodeDataType Type()
{
return { "bool", "Bool" };
}
PreviewValues preview;
};
#include <ShaderNode/DataTypes/BoolData.inl>
#endif

View File

@@ -0,0 +1,7 @@
#include <ShaderNode/DataTypes/BoolData.hpp>
inline BoolData::BoolData() :
preview(1, 1)
{
preview(0, 0) = Nz::Vector4f(1.f, 1.f, 1.f, 0.f);
}