home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
GameStar 2006 January
/
Gamestar_80_2006-01_dvd.iso
/
Dema
/
splatmagazinerenegadepaintball_demo.exe
/
VShader072-000201327955.vsh
< prev
next >
Wrap
Text File
|
2005-10-13
|
5KB
|
222 lines
; This source file can be requested from NVLink.
; It could be re-assembled as a shader, but note that
; NVLink has already assembled this file into D3D opcodes
; You can ask NVLink for the constant and vertex slots from the API.
; Total Instructions: 92
; Instructions removed by optimizer: 1
; Used Constants: 20
; Used Vertex Slots: 0
; Used Registers: 6
#define c_constants 68
#define c_decompress_object_scale 69
#define c_ambient_light 74
#define c_worldviewprojection_0 70
#define c_worldviewprojection_1 71
#define c_worldviewprojection_2 72
#define c_worldviewprojection_3 73
#define c_cubematrix_0 77
#define c_cubematrix_1 78
#define c_cubematrix_2 79
#define c_fogconst 76
#define c_pointlight_diffuse_0 85
#define c_pointlight_diffuse_1 87
#define c_dirlight_diffuse_0 81
#define c_dirlight_diffuse_1 83
#define c_objectspace_eyeposition 75
#define c_dirlight_direction_0 80
#define c_dirlight_direction_1 82
#define c_pointlight_position_0 84
#define c_pointlight_position_1 86
vs.1.1
; f_decompress_position
mad r1.xy, v0.ywww, c[c_constants].wwww, v0.xzzz
mad r1.zw, v1.yyyy, c[c_constants].wwww, v1.xxxx
mad r1.xyz, r1.xyzz, c[c_decompress_object_scale].xxxx, -c[c_decompress_object_scale].yyyy
mov r1.w, c[c_constants].yyyy
; f_decompress_normal
mad r2, v3, c[c_constants].zzzz, -c[c_constants].yyyy
; f_decompress_texture0
mad r3.xy, v2.ywww, c[c_constants].wwww, v2.xzzz
mad oT0.xy, r3.xyyy, c[c_decompress_object_scale].zzzz, -c[c_decompress_object_scale].wwww
; f_loadbone0_index
mul r0.x, v12.xxxx, c[c_constants].wwww
mov a0.x, r0.xxxx
; f_getbonepos
dp4 r4.x, r1, c[a0.x + 0]
dp4 r4.y, r1, c[a0.x + 1]
dp4 r4.z, r1, c[a0.x + 2]
; f_accumulatebone0_pos
mul r4, r4.xyzz, v11.xxxx
; f_getbonenormal
dp3 r5.x, r2, c[a0.x + 0]
dp3 r5.y, r2, c[a0.x + 1]
dp3 r5.z, r2, c[a0.x + 2]
; f_accumulatebone0_normal
mul r5, r5.xyzz, v11.xxxx
; f_loadbone1_index
mul r0.x, v12.yyyy, c[c_constants].wwww
mov a0.x, r0.xxxx
; f_getbonepos
dp4 r6.x, r1, c[a0.x + 0]
dp4 r6.y, r1, c[a0.x + 1]
dp4 r6.z, r1, c[a0.x + 2]
; f_accumulatebone1_pos
mad r6, r6.xyzz, v11.yyyy, r4
; f_getbonenormal
dp3 r4.x, r2, c[a0.x + 0]
dp3 r4.y, r2, c[a0.x + 1]
dp3 r4.z, r2, c[a0.x + 2]
; f_accumulatebone1_normal
mad r4, r4.xyzz, v11.yyyy, r5
; f_loadbone2_index
mul r0.x, v12.zzzz, c[c_constants].wwww
mov a0.x, r0.xxxx
; f_getbonepos
dp4 r5.x, r1, c[a0.x + 0]
dp4 r5.y, r1, c[a0.x + 1]
dp4 r5.z, r1, c[a0.x + 2]
; f_accumulatebone2_pos
mad r5, r5.xyzz, v11.zzzz, r6
; f_getbonenormal
dp3 r6.x, r2, c[a0.x + 0]
dp3 r6.y, r2, c[a0.x + 1]
dp3 r6.z, r2, c[a0.x + 2]
; f_accumulatebone2_normal
mad r6, r6.xyzz, v11.zzzz, r4
; f_loadbone3_index
mul r0.x, v12.wwww, c[c_constants].wwww
mov a0.x, r0.xxxx
; f_getbonepos
dp4 r4.x, r1, c[a0.x + 0]
dp4 r4.y, r1, c[a0.x + 1]
dp4 r4.z, r1, c[a0.x + 2]
; f_accumulatebone3_pos
mad r4, r4.xyzz, v11.wwww, r5
; f_getbonenormal
dp3 r5.x, r2, c[a0.x + 0]
dp3 r5.y, r2, c[a0.x + 1]
dp3 r5.z, r2, c[a0.x + 2]
; f_accumulatebone3_normal
mad r5, r5.xyzz, v11.wwww, r6
; f_normalizeobject_normal
dp3 r5.w, r5, r5
rsq r5.w, r5.wwww
mul r5, r5, r5.wwww
; f_outputobjectpos_clipspace
mov r4.w, c[c_constants].yyyy
dp4 oPos.x, r4, c[c_worldviewprojection_0]
dp4 oPos.y, r4, c[c_worldviewprojection_1]
dp4 oPos.z, r4, c[c_worldviewprojection_2]
dp4 oPos.w, r4, c[c_worldviewprojection_3]
; f_set_ambient
mov r6, c[c_ambient_light]
; f_create_objectspace_eyevector_local_viewer
add r2, r4, -c[c_objectspace_eyeposition]
dp3 r2.w, r2, r2
rsq r1.w, r2.wwww
mul r2, -r2, r1.wwww
; f_calculate_linear_range_fog
rcp r1.w, r1.wwww
add r1.x, c[c_fogconst].yyyy, -r1.wwww
mul r1.x, r1.xxxx, c[c_fogconst].zzzz
add oFog, r1.xxxx, -c[c_fogconst].xxxx
; f_calculate_objectspace_reflection
dp3 r1.xyz, r2.xyzz, r5.xyzz
add r1.xyz, -r1.xyzz, -r1.xyzz
mad r1.xyz, r5.xyzz, -r1.xyzz, -r2.xyzz
; f_calculate_cubereflection_vector_t1
dp3 oT1.x, r1, c[c_cubematrix_0]
dp3 oT1.y, r1, c[c_cubematrix_1]
dp3 oT1.z, r1, c[c_cubematrix_2]
; f_calculate_objectspace_directionallight_diffuse_intensity
dp3 r1, r5, c[c_dirlight_direction_0]
; f_clamp_diffuse_exponentiate_specular
lit r1, r1
; f_dirlight_accumulate_diffuse
mad r1, r1.yyyy, c[c_dirlight_diffuse_0], r6
; f_calculate_objectspace_directionallight_diffuse_intensity
dp3 r6, r5, c[c_dirlight_direction_1]
; f_clamp_diffuse_exponentiate_specular
lit r6, r6
; f_dirlight_accumulate_diffuse
mad r6, r6.yyyy, c[c_dirlight_diffuse_1], r1
; f_calculate_objectspace_pointlight_vector
add r1, c[c_pointlight_position_0], -r4
dp3 r1.w, r1, r1
rsq r1.w, r1.wwww
mul r1, r1, r1.wwww
; f_calculate_objectspace_pointlight_diffuse_intensity
dp3 r1, r5, r1
; f_clamp_diffuse_exponentiate_specular
lit r1, r1
; f_pointlight_accumulate_diffuse
mad r1, r1.yyyy, c[c_pointlight_diffuse_0], r6
; f_calculate_objectspace_pointlight_vector
add r4, c[c_pointlight_position_1], -r4
dp3 r4.w, r4, r4
rsq r4.w, r4.wwww
mul r4, r4, r4.wwww
; f_calculate_objectspace_pointlight_diffuse_intensity
dp3 r5, r5, r4
; f_clamp_diffuse_exponentiate_specular
lit r5, r5
; f_pointlight_accumulate_diffuse
mad r5, r5.yyyy, c[c_pointlight_diffuse_1], r1
; f_write_default_texture
; f_set_diffuse_alpha_ambient
mov oD0.w, c[c_ambient_light].wwww
; f_write_diffuse_result
mov oD0.xyz, r5
; end