diff options
Diffstat (limited to 'src/mesa/shader/slang/library/slang_core.gc')
-rw-r--r-- | src/mesa/shader/slang/library/slang_core.gc | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/src/mesa/shader/slang/library/slang_core.gc b/src/mesa/shader/slang/library/slang_core.gc index 78b983ce9a..063de8428b 100644 --- a/src/mesa/shader/slang/library/slang_core.gc +++ b/src/mesa/shader/slang/library/slang_core.gc @@ -2274,8 +2274,11 @@ bool __operator ^^ (const bool a, const bool b) { // } // -bool __operator ! (const bool a) { - return a == false; +bool __logicalNot(const bool a) +{ + if (a) + return false; + return true; } bool __logicalAnd(const bool a, const bool b) @@ -2285,6 +2288,20 @@ bool __logicalAnd(const bool a, const bool b) return false; } +bool __logicalOr(const bool a, const bool b) +{ + if (a) + return true; + return b; +} + +bool __logicalXor(const bool a, const bool b) +{ + if (a) + return __logicalNot(b); + return b; +} + // |