// Copyright (c) .NET Foundation and Contributors (https://dotnetfoundation.org/ & https://stride3d.net) and Silicon Studio Corp. (https://www.siliconstudio.co.jp)
// Distributed under the MIT license. See the LICENSE.md file in the project root for more information.
/// <summary>
/// Returns the color behind the key passed as generic.
/// </summary>
/// <remarks>
/// LinkName: generic LinkType - the name of the key used to set the color.
/// </remarks>
shader ComputeColorConstantColorLink<LinkType LinkName> : ComputeColor
{
    cbuffer PerMaterial
    {
        [Color]
        [Link("LinkName")]
        stage float4 constantColor;
    }
    
    override float4 Compute()
    {
        return constantColor;
    }
};
