<!--
Copyright 2013 Autodesk, Inc. All rights reserved. 

Use of this software is subject to the terms of the Autodesk 
license agreement provided at the time of installation or download, 
or which otherwise accompanies this software in either electronic 
or hard copy form.
-->
<fragment  uiName="xgenVSNw" name="xgenVSNw" type="interpolant" class="ShadeFragment" version="1.0" feature_level="0" >
    <description>
        <![CDATA[
Generate normals for xgen splines.]]>
    </description>
    <properties>
        <float3  name="widthVecFinal" flags="varyingInputParam" />
        <float3  name="curveVec" semantic="TEXCOORD1" flags="varyingInputParam" />
    </properties>
    <values>
    </values>
    <outputs>
        <float3  name="nw" semantic="TEXCOORD7" />
    </outputs>
    <implementation>
        <implementation  render="OGSRenderer" language="Cg" lang_version="2.100000" >
            <function_name val="xgenVSNw" />
            <vertex_source>
                <![CDATA[
float3 ixgenVSNw(float3 widthVecFinal, float3 curveVec)
{
    return normalize(cross(widthVecFinal, curveVec));
}
                ]]>
            </vertex_source>
            <source>
                <![CDATA[
float3 xgenVSNw(float3 iNw)
{
    return normalize( iNw );
}
               ]]>
             </source>
        </implementation>
        <implementation  render="OGSRenderer" language="HLSL" lang_version="11.000000" >
            <function_name val="xgenVSNw" />
            <vertex_source>
                <![CDATA[
float3 ixgenVSNw(float3 widthVecFinal, float3 curveVec)
{
    return normalize(cross(widthVecFinal, curveVec));
}
                ]]>
            </vertex_source>
            <source>
                <![CDATA[
float3 xgenVSNw(float3 iNw)
{
    return normalize( iNw );
}
               ]]>
            </source>
        </implementation>
        <implementation  render="OGSRenderer" language="HLSL" lang_version="10.000000" >
            <function_name val="xgenVSNw" />
            <vertex_source>
                <![CDATA[
float3 ixgenVSNw(float3 widthVecFinal, float3 curveVec)
{
    return normalize(cross(widthVecFinal, curveVec));
}
                ]]>
            </vertex_source>
            <source>
                <![CDATA[
float3 xgenVSNw(float3 iNw)
{
    return normalize( iNw );
}
               ]]>
            </source>
        </implementation>
    </implementation>
</fragment>