Team Fortress 2 Source Code as on 22/4/2020
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
693 B

  1. ps.1.1
  2. def c0,0,0,0,.1
  3. def c1,0,0,0,.1
  4. ;------------------------------------------------------------------------------
  5. ; Draw a texture . . woo hoo!
  6. ; t0 - texture
  7. ;
  8. ; The texture coordinates need to be defined as follows:
  9. ; tc0 - texcoords
  10. ; tc3 - detail texcoords
  11. ;
  12. ; c3 = outline color
  13. ;------------------------------------------------------------------------------
  14. tex t0 ; base color
  15. tex t3 ; detail mask
  16. mul r1,t0,t3 ; multiply
  17. mov r0.rgb, c3 ; color = outline color
  18. ;add r0.a, r1.a, c0.a
  19. ;cnd r0.rgb, r0.a, r0, r1 ; if ( alpha+c0 > 0.5 ) color = outline, else color = base
  20. sub r0.a, r1.a, c1.a
  21. cnd r0.rgb, r0.a, r1, r0 ; if ( alpha -c1 > 0.5) color=base