Files
cool-source-archive/materialsystem/stdshadersdx11/bik_vs40.fxc
Totterynine 2773eae4d7 shaderapidx11
use -dxlevel 110 to use it
2021-09-22 18:56:56 +05:00

42 lines
880 B
Plaintext

// DYNAMIC: "DOWATERFOG" "0..0"
#include "common_vs_fxc.h"
#include "common_cbuffers_fxc.h"
CBUFFER_PERFRAME(register(b1))
CBUFFER_PERSCENE(register(b2))
static const int g_FogType = DOWATERFOG;
struct VS_INPUT
{
float4 vPos : POSITION;
float4 vTexCoord0 : TEXCOORD0;
};
struct VS_OUTPUT
{
float4 projPos : SV_POSITION; // Projection-space position
//float fog : FOG;
HALF2 baseTexCoord : TEXCOORD0; // Base texture coordinate
//float4 worldPos_projPosZ : TEXCOORD1; // Necessary for water fog dest alpha
//float4 fogFactorW : COLOR1;
};
VS_OUTPUT main( const VS_INPUT v )
{
VS_OUTPUT o = ( VS_OUTPUT )0;
float4x4 viewProj = mul(cViewMatrix, cProjMatrix);
// Transform into projection space
float4 projPos = mul(float4(v.vPos.xyz, 1), viewProj);
o.projPos = projPos;
o.baseTexCoord.xy = v.vTexCoord0;
return o;
}