diff options
author | Colin Okay <colin@cicadas.surf> | 2022-06-22 07:31:58 -0500 |
---|---|---|
committer | Colin Okay <colin@cicadas.surf> | 2022-06-22 07:31:58 -0500 |
commit | 7a9f89e46e21f2c18d6e61eee16c6d37bdd27800 (patch) | |
tree | 667c42d4b82b24b4e860286a1b54975bc5a6669d /wheelwork.lisp | |
parent | a3d98d979bca7f55c3fdbeda62f482374f140c73 (diff) |
[fix] bitmap shader program to handle alpha channel appropriately
Diffstat (limited to 'wheelwork.lisp')
-rw-r--r-- | wheelwork.lisp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/wheelwork.lisp b/wheelwork.lisp index 42dd830..a66d6a6 100644 --- a/wheelwork.lisp +++ b/wheelwork.lisp @@ -301,7 +301,10 @@ order). Makes sure to remove the unit from its current container if necessary." '(:fragment ((tc :vec2)) ((tex :sampler-2d)) - ((vari:texture tex tc))))) + ((let ((frag (vari:texture tex tc))) + (if (< (aref frag 3) 0.01) + (vari:discard) + frag)))))) (gl:program-uniformi shader (gl:get-uniform-location shader "TEX") |