!!ARBfp1.0 # OPTION ARB_precision_hint_fastest; #/*ŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻ*\ # File: Program for XREngine final framebuffer paste # # Author: Magnus Högdahl # # Copyright: Starbreeze AB 2004 # # History: # # Cycles/64 pixel vector: ALU 16, vertex 0, texture 16, sequencer 12, interpolator 8 # 3 GPRs, 63 threads, Performance (if enough threads): ~16 cycles per vector # 577400 ns @ 1280x720 #\*____________________________________________________________________________________________*/ #----------------------------------- OUTPUT oCol = result.color; ATTRIB tc0 = fragment.texcoord[0]; ATTRIB tc1 = fragment.texcoord[1]; TEMP t0; TEMP t1; TEMP r0; TEMP r1; TEMP r2; #----------------------------------- TEX t0, tc0, texture[0], 2D; TEX t1, tc1, texture[1], 2D; MUL t1,t1,t1; MUL t0,t0,t0; ADD r0, t0, t1; MUL_SAT r1.rgb, t0, t1; SUB r0.rgb, r0, r1; MAX r0, r0, 0.00000001; RSQ r1.x, r0.x; RSQ r1.y, r0.y; RSQ r1.z, r0.z; MUL r0.rgb, r0, r1; MOV oCol, r0; END