// 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>
/// Performs skinning on the normals.
/// </summary>
shader NormalMeshSkinning : TransformationSkinning, NormalStream
{
    override stage void PreTransformPosition()
    {
        base.PreTransformPosition();
        streams.meshNormal = normalize(mul(streams.meshNormal, (float3x3)streams.skinningBlendMatrix)); // TODO: Does this result in an object or world space normal? If world space, write to meshNormalWS instead!
    }
};
