add game&rawdata
This commit is contained in:
parent
0133cd976c
commit
49b34b5546
45731 changed files with 709831 additions and 0 deletions
34
gamedata/shaders/r1/model_def_lq.vs.hlsl
Normal file
34
gamedata/shaders/r1/model_def_lq.vs.hlsl
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
#include "common.hlsli"
|
||||
#include "skin.hlsli"
|
||||
|
||||
struct vf
|
||||
{
|
||||
float4 hpos : POSITION;
|
||||
float2 tc0 : TEXCOORD0; // base
|
||||
float3 c0 : COLOR0; // color
|
||||
float fog : FOG;
|
||||
};
|
||||
|
||||
vf _main(v_model v)
|
||||
{
|
||||
vf o;
|
||||
|
||||
float4 pos = v.pos;
|
||||
float3 pos_w = mul(m_W, pos);
|
||||
float3 norm_w = normalize(mul(m_W, v.norm));
|
||||
|
||||
o.hpos = mul(m_WVP, pos); // xform, input in world coords
|
||||
o.tc0 = v.tc.xy; // copy tc
|
||||
o.c0 = calc_model_lq_lighting(norm_w);
|
||||
o.fog = calc_fogging(float4(pos_w, 1)); // fog, input in world coords
|
||||
|
||||
#ifdef SKIN_COLOR
|
||||
o.c0.rgb *= v.rgb_tint;
|
||||
#endif
|
||||
|
||||
return o;
|
||||
}
|
||||
|
||||
#define SKIN_LQ
|
||||
#define SKIN_VF vf
|
||||
#include "skin_main.hlsli"
|
||||
Loading…
Add table
Add a link
Reference in a new issue