#pragma once #include #include #include #include enum class ShaderParameterType { Float, Vec2, Color, Boolean, Enum }; struct ShaderParameterOption { std::string value; std::string label; }; struct ShaderParameterDefinition { std::string id; std::string label; ShaderParameterType type = ShaderParameterType::Float; std::vector defaultNumbers; std::vector minNumbers; std::vector maxNumbers; std::vector stepNumbers; bool defaultBoolean = false; std::string defaultEnumValue; std::vector enumOptions; }; struct ShaderParameterValue { std::vector numberValues; bool booleanValue = false; std::string enumValue; }; enum class TemporalHistorySource { None, Source, PreLayerInput }; struct TemporalSettings { bool enabled = false; TemporalHistorySource historySource = TemporalHistorySource::None; unsigned requestedHistoryLength = 0; unsigned effectiveHistoryLength = 0; }; struct ShaderTextureAsset { std::string id; std::filesystem::path path; std::filesystem::file_time_type writeTime; }; struct ShaderPackage { std::string id; std::string displayName; std::string description; std::string category; std::string entryPoint; std::filesystem::path directoryPath; std::filesystem::path shaderPath; std::filesystem::path manifestPath; std::vector parameters; std::vector textureAssets; TemporalSettings temporal; std::filesystem::file_time_type shaderWriteTime; std::filesystem::file_time_type manifestWriteTime; }; struct RuntimeRenderState { std::string layerId; std::string shaderId; std::vector parameterDefinitions; std::map parameterValues; std::vector textureAssets; double timeSeconds = 0.0; double frameCount = 0.0; double mixAmount = 1.0; double bypass = 0.0; unsigned inputWidth = 0; unsigned inputHeight = 0; unsigned outputWidth = 0; unsigned outputHeight = 0; bool isTemporal = false; TemporalHistorySource temporalHistorySource = TemporalHistorySource::None; unsigned requestedTemporalHistoryLength = 0; unsigned effectiveTemporalHistoryLength = 0; };