public static FLOAT4 QTConj( FLOAT4 A ) { FLOAT4 Result ; Result.w = A.w ; Result.x = -A.x ; Result.y = -A.y ; Result.z = -A.z ; return Result ; }
public static FLOAT4 F4Scale( FLOAT4 In, float Scale ) { FLOAT4 Result ; Result.x = In.x * Scale ; Result.y = In.y * Scale ; Result.z = In.z * Scale ; Result.w = In.w * Scale ; return Result ; }
public static FLOAT4 QTCross( FLOAT4 A, FLOAT4 B ) { FLOAT4 Result ; Result.w = A.w * B.w - ( A.x * B.x + A.y * B.y + A.z * B.z ) ; Result.x = B.x * A.w + A.x * B.w + ( A.y * B.z - A.z * B.y ) ; Result.y = B.y * A.w + A.y * B.w + ( A.z * B.x - A.x * B.z ) ; Result.z = B.z * A.w + A.z * B.w + ( A.x * B.y - A.y * B.x ) ; return Result ; }
public static FLOAT4 F4Add( FLOAT4 In1, FLOAT4 In2 ) { FLOAT4 Result ; Result.x = In1.x + In2.x ; Result.y = In1.y + In2.y ; Result.z = In1.z + In2.z ; Result.w = In1.w + In2.w ; return Result ; }
public static FLOAT4 F4Sub( FLOAT4 In1, FLOAT4 In2 ) { FLOAT4 Result ; Result.x = In1.x - In2.x ; Result.y = In1.y - In2.y ; Result.z = In1.z - In2.z ; Result.w = In1.w - In2.w ; return Result ; }
extern static int dx_SetPSConstFArray_x64( int ConstantIndex, out FLOAT4 ParamArray, int ParamNum);
public static int SetPSConstFArray( int ConstantIndex, out FLOAT4 ParamArray, int ParamNum) { if( System.IntPtr.Size == 4 ) { return dx_SetPSConstFArray_x86( ConstantIndex , out ParamArray , ParamNum ); } else { return dx_SetPSConstFArray_x64( ConstantIndex , out ParamArray , ParamNum ); } }
public static int SetPSConstF( int ConstantIndex, FLOAT4 Param) { if( System.IntPtr.Size == 4 ) { return dx_SetPSConstF_x86( ConstantIndex , Param ); } else { return dx_SetPSConstF_x64( ConstantIndex , Param ); } }
extern static int dx_SetPSConstF_x64( int ConstantIndex, FLOAT4 Param);
extern static int dx_SetVSConstF_x86( int ConstantIndex, FLOAT4 Param);
public static int SetPSConstFArray( int ConstantIndex, out FLOAT4 ParamArray, int ParamNum) { return dx_SetPSConstFArray( ConstantIndex , out ParamArray , ParamNum ); }
public static int SetPSConstF( int ConstantIndex, FLOAT4 Param) { return dx_SetPSConstF( ConstantIndex , Param ); }