Ejemplo n.º 1
0
        public SpriteDebugPS()
        {
            Name             = "SpriteDebugPS";
            Type             = ShaderType.Pixel;
            KeyPart          = new TechniqueKey(ps: PixelShaderFlags.Diffuse);
            FeatureLevel     = FeatureLevel.PS_4_0_Level_9_1;
            EnableSeparators = true;
            var inputStruct = SpriteVS.VSOut;

            inputStruct.Name = "input";

            InputStruct  = inputStruct;
            OutputStruct = Struct.PixelShaderOutput;
            Struct cbMaterial = ConstantBuffer.CBMaterial;
            Struct material   = (Struct)cbMaterial[Param.Struct.Material];

            Add(cbMaterial);

            Result = new PSOutputNode()
            {
                FinalColor = new ReferenceNode {
                    Value = material["Diffuse"]
                },
                Output = OutputStruct
            };
        }
Ejemplo n.º 2
0
        public SpritePS()
        {
            Name             = "SpritePS";
            Type             = ShaderType.Pixel;
            KeyPart          = new TechniqueKey(ps: PixelShaderFlags.Diffuse | PixelShaderFlags.DiffuseMap);
            FeatureLevel     = FeatureLevel.PS_4_0_Level_9_1;
            EnableSeparators = true;
            var inputStruct = SpriteVS.VSOut;

            inputStruct.Name = "input";

            InputStruct  = inputStruct;
            OutputStruct = Struct.PixelShaderOutput;
            Struct   cbMaterial = ConstantBuffer.CBMaterial;
            Struct   material   = (Struct)cbMaterial[Param.Struct.Material];
            Variable tDiffuse   = Texture.Diffuse;
            Variable sDiffuse   = Sampler.MinMagMipLinearWrap;

            Add(cbMaterial);
            Add(sDiffuse);
            Add(tDiffuse);

            TextureSampleNode nTexSample = new TextureSampleNode
            {
                Coordinates = new ReferenceNode {
                    Value = InputStruct[Param.SemanticVariables.Texture]
                },
                Texture   = tDiffuse,
                Sampler   = sDiffuse,
                IsVerbose = true,
                Output    = new Vector()
                {
                    Name = "cDiffuse", Type = Shaders.Type.Float4
                }
            };

            MultiplyNode nMultiply = new MultiplyNode
            {
                Input1 = nTexSample,
                Input2 = new ReferenceNode {
                    Value = material[Param.Material.Diffuse]
                },
                Output = new Vector {
                    Name = "cFinal", Type = Shaders.Type.Float4
                }
            };

            Result = new PSOutputNode
            {
                FinalColor = nMultiply,
                Output     = OutputStruct
            };
        }
Ejemplo n.º 3
0
        public SkyboxPS()
        {
            Name             = "SkyboxPS";
            Type             = ShaderType.Pixel;
            KeyPart          = new TechniqueKey(ps: PixelShaderFlags.Diffuse);
            FeatureLevel     = FeatureLevel.PS_4_0_Level_9_1;
            EnableSeparators = true;
            var inputStruct = SkyboxVS.VSOutput;

            inputStruct.Name = "input";

            InputStruct  = inputStruct;
            OutputStruct = Struct.PixelShaderOutput;

            Struct cbMaterial = Structs.ConstantBuffer.CBMaterial;
            Struct material   = (Struct)cbMaterial[Param.Struct.Material];

            Add(cbMaterial);

            Texture tDiffuse        = Texture.CubeMap;
            Sampler sDiffuseSampler = Sampler.MinMagMipLinearWrap;

            Add(tDiffuse);
            Add(sDiffuseSampler);
            TextureSampleNode textureSample = new TextureSampleNode
            {
                Coordinates = new ReferenceNode {
                    Value = InputStruct[Param.SemanticVariables.Texture]
                },
                Texture = tDiffuse,
                Sampler = sDiffuseSampler
            };
            MultiplyNode multiply = new MultiplyNode
            {
                Input1 = textureSample,
                Input2 = new ReferenceNode {
                    Value = material[Param.Material.Diffuse]
                }
            };

            Result = new PSOutputNode
            {
                FinalColor = multiply,
                Output     = OutputStruct
            };
        }
Ejemplo n.º 4
0
        public ShapePS()
        {
            Name             = "ShapePS";
            Type             = ShaderType.Pixel;
            KeyPart          = new TechniqueKey(ps: PixelShaderFlags.Diffuse);
            FeatureLevel     = FeatureLevel.PS_4_0_Level_9_1;
            EnableSeparators = true;
            var inputStruct = ShapeVS.VSOut;

            inputStruct.Name = "input";
            InputStruct      = inputStruct;
            OutputStruct     = Struct.PixelShaderOutput;

            Result = new PSOutputNode
            {
                FinalColor = new ReferenceNode()
                {
                    Value = InputStruct[Param.SemanticVariables.Color]
                },
                Output = OutputStruct
            };
        }
Ejemplo n.º 5
0
        public FullScreenQuadPS()
        {
            Name             = "FullScreenQuadPS";
            Type             = ShaderType.Pixel;
            KeyPart          = new TechniqueKey(ps: PixelShaderFlags.DiffuseMap);
            FeatureLevel     = FeatureLevel.PS_4_0_Level_9_1;
            EnableSeparators = true;
            var inputStruct = SpriteVS.VSOut;

            inputStruct.Name = "input";

            InputStruct  = inputStruct;
            OutputStruct = Struct.PixelShaderOutput;
            Variable tDiffuse = Texture.Diffuse;
            Variable sDiffuse = Sampler.MinMagMipLinearWrap;

            Add(sDiffuse);
            Add(tDiffuse);

            TextureSampleNode nTexSample = new TextureSampleNode
            {
                Coordinates = new ReferenceNode {
                    Value = InputStruct[Param.SemanticVariables.Texture]
                },
                Texture   = tDiffuse,
                Sampler   = sDiffuse,
                IsVerbose = true,
                Output    = new Vector()
                {
                    Name = "cDiffuse", Type = Shaders.Type.Float4
                }
            };

            Result = new PSOutputNode
            {
                FinalColor = nTexSample,
                Output     = OutputStruct
            };
        }
Ejemplo n.º 6
0
        public GlowPS()
        {
            Name             = "GlowPS";
            Type             = ShaderType.Pixel;
            KeyPart          = new TechniqueKey(ps: PixelShaderFlags.Diffuse | PixelShaderFlags.DiffuseMap);
            FeatureLevel     = FeatureLevel.PS_4_0_Level_9_1;
            EnableSeparators = true;
            var inputStruct = SpriteVS.VSOut;

            inputStruct.Name = "input";

            InputStruct  = inputStruct;
            OutputStruct = Struct.PixelShaderOutput;
            Texture tDiffuse = Texture.Diffuse;
            Texture tGlow    = new Texture {
                Name = "tGlow", Type = Shaders.Type.Texture2D
            };
            Variable sLinearWrap = Sampler.MinMagMipLinearWrap;
            var      cbFrame     = CBFrame;

            Add(sLinearWrap);
            Add(tDiffuse);
            Add(tGlow);
            Add(cbFrame);

            TextureSampleNode nTexSample = new TextureSampleNode
            {
                Coordinates = new ReferenceNode {
                    Value = InputStruct[Param.SemanticVariables.Texture]
                },
                Texture   = tDiffuse,
                Sampler   = sLinearWrap,
                IsVerbose = true,
                Output    = new Vector {
                    Name = "cDiffuse", Type = Shaders.Type.Float4
                }
            };

            TextureSampleNode nGlowSample = new TextureSampleNode
            {
                Coordinates = new ReferenceNode {
                    Value = InputStruct[Param.SemanticVariables.Texture]
                },
                Texture   = tGlow,
                Sampler   = sLinearWrap,
                IsVerbose = true,
                Output    = new Vector {
                    Name = "cGlow", Type = Shaders.Type.Float4
                }
            };

            UnaryFunctionNode nSaturate = new UnaryFunctionNode
            {
                Input1 = new AdditionNode
                {
                    Input1 = nTexSample,
                    Input2 = new MultiplyNode
                    {
                        Input1 = nGlowSample,
                        Input2 = new ReferenceNode {
                            Value = cbFrame[Param.Floats.GlowStrength]
                        },
                        Parenthesize = true
                    }
                },
                Function = HlslIntrinsics.Saturate
            };

            Result = new PSOutputNode
            {
                FinalColor = nSaturate,
                Output     = OutputStruct
            };
        }
Ejemplo n.º 7
0
        public BloomExtractPS()
        {
            Name             = "BloomExtractPS";
            Type             = ShaderType.Pixel;
            KeyPart          = new TechniqueKey(ps: PixelShaderFlags.Diffuse | PixelShaderFlags.DiffuseMap);
            FeatureLevel     = FeatureLevel.PS_4_0_Level_9_1;
            EnableSeparators = true;
            var inputStruct = SpriteVS.VSOut;

            inputStruct.Name = "input";

            InputStruct  = inputStruct;
            OutputStruct = Struct.PixelShaderOutput;
            Texture tDiffuse    = Texture.Diffuse;
            Sampler sLinearWrap = Sampler.MinMagMipLinearWrap;
            var     cbFrame     = CBFrame;

            Add(sLinearWrap);
            Add(tDiffuse);
            Add(cbFrame);

            TextureSampleNode nTexSample = new TextureSampleNode
            {
                Coordinates = new ReferenceNode {
                    Value = InputStruct[Param.SemanticVariables.Texture]
                },
                Texture   = tDiffuse,
                Sampler   = sLinearWrap,
                IsVerbose = true,
                Output    = new Vector {
                    Name = "cDiffuse", Type = Shaders.Type.Float4
                }
            };

            UnaryFunctionNode nSaturate = new UnaryFunctionNode
            {
                Input1 = new DivisionNode()
                {
                    Input1 = new SubtractionNode()
                    {
                        Input1 = nTexSample,
                        Input2 = new ReferenceNode()
                        {
                            Value = cbFrame[Param.Floats.BloomThreshold]
                        },
                        Parenthesize = true
                    },
                    Input2 = new SubtractionNode()
                    {
                        Input1 = new ScalarNode()
                        {
                            Value = 1.0f
                        },
                        Input2 = new ReferenceNode()
                        {
                            Value = cbFrame[Param.Floats.BloomThreshold]
                        },
                        Parenthesize = true
                    }
                },
                Function = HlslIntrinsics.Saturate
            };

            Result = new PSOutputNode
            {
                FinalColor = nSaturate,
                Output     = OutputStruct
            };
        }
Ejemplo n.º 8
0
        public BloomCombinePS()
        {
            Name             = "BloomCombinePS";
            Type             = ShaderType.Pixel;
            KeyPart          = new TechniqueKey(ps: PixelShaderFlags.Diffuse | PixelShaderFlags.DiffuseMap);
            FeatureLevel     = FeatureLevel.PS_4_0_Level_9_1;
            EnableSeparators = true;
            var inputStruct = SpriteVS.VSOut;

            inputStruct.Name = "input";

            InputStruct  = inputStruct;
            OutputStruct = Struct.PixelShaderOutput;
            Texture tDiffuse = Texture.Diffuse;
            Texture tBloom   = new Texture()
            {
                Name = "tBloom", Type = Shaders.Type.Texture2D
            };
            Sampler sLinearWrap = Sampler.MinMagMipLinearWrap;
            var     cbFrame     = CBFrame;

            var blurParams = (Struct)cbFrame[0];

            Add(sLinearWrap);
            Add(tDiffuse);
            Add(tBloom);
            Add(cbFrame);

            TextureSampleNode nTexSample = new TextureSampleNode
            {
                Coordinates = new ReferenceNode {
                    Value = InputStruct[Param.SemanticVariables.Texture]
                },
                Texture   = tDiffuse,
                Sampler   = sLinearWrap,
                IsVerbose = true,
                Output    = new Vector {
                    Name = "cDiffuse", Type = Shaders.Type.Float4
                },
            };

            TextureSampleNode nBloomSample = new TextureSampleNode
            {
                Coordinates = new ReferenceNode {
                    Value = InputStruct[Param.SemanticVariables.Texture]
                },
                Texture   = tBloom,
                Sampler   = sLinearWrap,
                IsVerbose = true,
                Output    = new Vector {
                    Name = "cBloom", Type = Shaders.Type.Float4
                }
            };

            var mAdjustSaturation = new AdjustSaturation();

            FunctionNode nAdjustBloomSaturation = new FunctionNode()
            {
                Inputs = new List <INode>()
                {
                    nBloomSample,
                    new ReferenceNode()
                    {
                        Value = blurParams[Param.Floats.BloomSaturation]
                    }
                },
                Method     = mAdjustSaturation,
                ReturnType = Shaders.Type.Float4
            };

            FunctionNode nAdjustBaseSaturation = new FunctionNode()
            {
                Inputs = new List <INode>()
                {
                    nTexSample,
                    new ReferenceNode()
                    {
                        Value = blurParams[Param.Floats.BloomBaseSaturation]
                    }
                },
                Method     = mAdjustSaturation,
                ReturnType = Shaders.Type.Float4
            };

            MultiplyNode nMulBloom = new MultiplyNode()
            {
                Input1 = nAdjustBloomSaturation,
                Input2 = new ReferenceNode()
                {
                    Value = blurParams[Param.Floats.BloomIntensity]
                },
                Output    = nBloomSample.Output,
                IsVerbose = true,
                Declare   = false
            };
            MultiplyNode nMulBase = new MultiplyNode()
            {
                Input1 = nAdjustBaseSaturation,
                Input2 = new ReferenceNode()
                {
                    Value = blurParams[Param.Floats.BloomBaseIntensity]
                },
                Output    = nTexSample.Output,
                IsVerbose = true,
                Declare   = false
            };

            MultiplyNode nDarken = new MultiplyNode()
            {
                Input1 = nMulBase,
                Input2 = new SubtractionNode()
                {
                    Input1 = new ScalarNode()
                    {
                        Value = 1
                    },
                    Input2 = new UnaryFunctionNode()
                    {
                        Input1 = nMulBloom, Function = HlslIntrinsics.Saturate
                    },
                    Parenthesize = true
                },
                Output         = nTexSample.Output,
                IsVerbose      = true,
                Declare        = false,
                AssignToInput1 = true
            };

            Result = new PSOutputNode
            {
                FinalColor = new AdditionNode()
                {
                    Input1 = nDarken, Input2 = nMulBloom
                },
                Output = OutputStruct
            };
        }
Ejemplo n.º 9
0
        public WireframePS()
        {
            Name             = "WireframePS";
            Type             = ShaderType.Pixel;
            KeyPart          = new TechniqueKey(ps: PixelShaderFlags.Diffuse, sm: ShaderModel.SM_4_0_Level_9_3);
            FeatureLevel     = FeatureLevel.PS_4_0_Level_9_3;
            EnableSeparators = true;
            var inputStruct = WireframeVS.VertexPositionTextureIntensityBarycentricOut;

            inputStruct.Name = "input";
            InputStruct      = inputStruct;
            OutputStruct     = Struct.PixelShaderOutput;
            Structs.ConstantBuffer cbInstance = ConstantBuffer.CBMaterial;

            Struct material = (Struct)cbInstance[Param.Struct.Material];

            Add(cbInstance);

            IVariable position    = InputStruct[Param.SemanticVariables.ObjectPosition];
            IVariable diffuse     = material[Param.Material.Diffuse];
            IVariable specular    = material[Param.Material.Specular];
            IVariable intensity   = InputStruct[Param.SemanticVariables.Intensity];
            IVariable texture     = InputStruct[Param.SemanticVariables.Texture];
            IVariable barycentric = InputStruct[Param.SemanticVariables.Barycentric];

            //2
            UnaryFunctionNode fWidth = new UnaryFunctionNode
            {
                Input1 = new ReferenceNode()
                {
                    Value = barycentric
                },
                Function = HlslIntrinsics.Fwidth,
                Output   = new Vector()
                {
                    Type = Shaders.Type.Float3, Name = "d"
                },
                IsVerbose = true
            };

            //TrinaryFunctionNode smoothstep = new TrinaryFunctionNode()
            //{
            //    Input1 = new ConstantNode() {Value = new[] {0f, 0f, 0f}},
            //    Input2 = new MultiplyNode() {Input1 = new ScalarNode() {Value = 1.5f}, Input2 = fWidth},
            //    Input3 = new ReferenceNode() {Value = barycentric},
            //    Function = HLSLIntrinsics.Smoothstep,
            //    IsVerbose = true,
            //    Output = new Vector() {  Type = Shaders.Type.Float3, Name = "a3"}
            //};

            TrinaryFunctionNode smoothstep = new TrinaryFunctionNode()
            {
                Input1 = fWidth,
                Input2 = new MultiplyNode()
                {
                    Input1 = new ScalarNode()
                    {
                        Value = 3f
                    }, Input2 = fWidth
                },
                Input3 = new ReferenceNode()
                {
                    Value = barycentric
                },
                Function  = HlslIntrinsics.Smoothstep,
                IsVerbose = true,
                Output    = new Vector()
                {
                    Type = Shaders.Type.Float3, Name = "a3"
                }
            };

            BinaryFunctionNode minDistanceXY = new BinaryFunctionNode()
            {
                Input1 = new SwizzleNode
                {
                    Input   = smoothstep,
                    Swizzle = new[] { Swizzle.X }
                },
                Input2 = new SwizzleNode
                {
                    Input   = smoothstep,
                    Swizzle = new[] { Swizzle.Y }
                },
                Function = HlslIntrinsics.Min,
            };
            BinaryFunctionNode edgeIntensity = new BinaryFunctionNode()
            {
                Input1 = minDistanceXY,
                Input2 = new SwizzleNode
                {
                    Input   = smoothstep,
                    Swizzle = new[] { Swizzle.Z }
                },
                Function = HlslIntrinsics.Min,
                Output   = new Vector()
                {
                    Type = Shaders.Type.Float, Name = "minDistance"
                },
                IsVerbose = true
            };

            MultiplyNode objectDiffuse = new MultiplyNode()
            {
                Input1 = new ReferenceNode()
                {
                    Value = diffuse
                },
                Input2 = new CastNode
                {
                    Input = new SwizzleNode
                    {
                        Input = new ReferenceNode {
                            Value = intensity
                        },
                        Swizzle = new[] { Swizzle.X, Swizzle.Y, Swizzle.Z, Swizzle.Null }
                    },
                    Mask   = new[] { "0", "0", "0", "1" },
                    Output = new Vector()
                    {
                        Type = Shaders.Type.Float4, Name = "intensity4"
                    }
                },
                Output = new Vector()
                {
                    Type = Shaders.Type.Float4, Name = "diffuse"
                },
                IsVerbose = true
            };

            TrinaryFunctionNode finalColor = new TrinaryFunctionNode()
            {
                Input1 = new ReferenceNode()
                {
                    Value = specular
                },
                Input2   = objectDiffuse,
                Input3   = edgeIntensity,
                Function = HlslIntrinsics.Lerp
            };

            Result = new PSOutputNode
            {
                FinalColor = finalColor,
                Output     = OutputStruct
            };
        }
Ejemplo n.º 10
0
        public GaussianBlurPS()
        {
            Name             = "GaussianBlurPS";
            Type             = ShaderType.Pixel;
            FeatureLevel     = FeatureLevel.PS_4_0_Level_9_1;
            KeyPart          = new TechniqueKey(ps: PixelShaderFlags.DiffuseMap);
            EnableSeparators = true;
            Struct inputStruct = SpriteVS.VSOut;

            inputStruct.Name = "input";
            InputStruct      = inputStruct;
            var cbStatic           = CBFrame;
            var fOffsetsAndWeights = CBFrame[Param.Floats.BlurOffsetsAndWeights];

            Texture tDiffuse = Texture.Diffuse;
            Sampler sLinear  = Sampler.MinMagMipLinearWrap;

            Add(tDiffuse);
            Add(sLinear);
            Add(cbStatic);

            DeclarationNode nColor        = DeclarationNode.InitNode("color", Shaders.Type.Float4, 0, 0, 0, 0);
            ArrayNode       fOffsetWeight = new ArrayNode {
                Input = fOffsetsAndWeights, Index = "i"
            };

            AdditionNode nBlur = new AdditionNode
            {
                PreCondition = new ForBlock
                {
                    PreCondition   = nColor,
                    StartCondition = new ScalarNode {
                        Value = 0
                    },
                    EndCondition = new ScalarNode {
                        Value = 15
                    }
                },
                OpensBlock = true,
                Input1     = nColor,
                Input2     = new MultiplyNode
                {
                    Input1 = new TextureSampleNode
                    {
                        Texture     = tDiffuse,
                        Sampler     = sLinear,
                        Coordinates = new AdditionNode
                        {
                            Input1 = new ReferenceNode {
                                Value = InputStruct[Param.SemanticVariables.Texture]
                            },
                            Input2 = new SwizzleNode {
                                Input = fOffsetWeight, Swizzle = new [] { Swizzle.X, Swizzle.Y }
                            },
                        }
                    },
                    Input2 = new SwizzleNode {
                        Input = fOffsetWeight, Swizzle = new[] { Swizzle.Z }
                    },
                },
                ClosesBlock    = true,
                IsVerbose      = true,
                Declare        = false,
                AssignToInput1 = true,
                Output         = nColor.Output
            };

            OutputStruct = Struct.PixelShaderOutput;
            Result       = new PSOutputNode
            {
                FinalColor = nBlur,
                Output     = OutputStruct
            };
        }
Ejemplo n.º 11
0
        public PhongPS()
        {
            Name             = "PhongPS";
            Type             = ShaderType.Pixel;
            KeyPart          = new TechniqueKey(ps: PixelShaderFlags.Diffuse | PixelShaderFlags.Specular);
            FeatureLevel     = FeatureLevel.PS_4_0_Level_9_1;
            EnableSeparators = true;
            var input = Struct.VertexPositionNormalTextureOut;

            input.Name   = "input";
            InputStruct  = input;
            OutputStruct = Struct.PixelShaderOutput;

            Structs.ConstantBuffer cbStatic   = CBLight;
            Structs.ConstantBuffer cbFrame    = CBFrame;
            Structs.ConstantBuffer cbInstance = ConstantBuffer.CBMaterial;

            Struct pointLight = (Struct)cbStatic[Param.Struct.PointLight];
            Struct material   = (Struct)cbInstance[Param.Struct.Material];

            Add(cbStatic);
            Add(cbFrame);
            Add(cbInstance);

            CastNode vWorldPos = new CastNode
            {
                Input = new SwizzleNode {
                    Input = new ReferenceNode {
                        Value = InputStruct[Param.SemanticVariables.WorldPosition]
                    }
                    , Swizzle = new[] { Swizzle.X, Swizzle.Y, Swizzle.Z }
                },
                Output = new Vector {
                    Type = Shaders.Type.Float3, Name = "vWorldPos",
                },
                IsVerbose = true
            };

            SubtractionNode vLightDirection = new SubtractionNode
            {
                Input1 = new ReferenceNode {
                    Value = pointLight[Param.Light.Position]
                },
                Input2 = vWorldPos,
            };

            SubtractionNode vViewDirection = new SubtractionNode
            {
                Input1 = new ReferenceNode {
                    Value = cbFrame[Param.Vectors.CameraPosition]
                },
                Input2 = vWorldPos,
            };

            ReferenceNode nNormal = new ReferenceNode {
                Value = InputStruct[Param.SemanticVariables.Normal]
            };

            UnaryFunctionNode normalizeNormal = new UnaryFunctionNode
            {
                Input1   = nNormal,
                Function = HlslIntrinsics.Normalize,
                Output   = new Vector {
                    Type = nNormal.Output.Type, Name = "vNormal"
                },
                IsVerbose = true,
            };

            UnaryFunctionNode normalizeViewDirection = new UnaryFunctionNode
            {
                Input1   = vViewDirection,
                Function = HlslIntrinsics.Normalize,
                Output   = new Vector {
                    Type = vViewDirection.Output.Type, Name = "vViewDirection"
                },
                IsVerbose = true,
            };

            UnaryFunctionNode normalizeLightDirection = new UnaryFunctionNode
            {
                Input1   = vLightDirection,
                Function = HlslIntrinsics.Normalize,
                Output   = new Vector {
                    Type = vLightDirection.Output.Type, Name = "vLightDirection"
                },
                IsVerbose = true,
            };

            InvertNode vLightDirectionInv = new InvertNode
            {
                Input = normalizeLightDirection,
                //Output = new Vector { Type = Shaders.Type.Float3, Name = "vLightDirection" },
            };

            PhongLightingNode nPhongLighting = new PhongLightingNode
            {
                Light = new ReferenceNode {
                    Value = pointLight
                },
                Material = new ReferenceNode {
                    Value = material
                },
                ViewDirection  = normalizeViewDirection,
                Normal         = normalizeNormal,
                LightDirection = vLightDirectionInv,
                Specular       = true,
            };

            Result = new PSOutputNode
            {
                FinalColor = nPhongLighting,
                Output     = OutputStruct
            };
        }