[clang] [llvm] [HLSL][DXIL] Implement `refract` intrinsic (PR #136026)

Farzon Lotfi via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 29 12:13:10 PDT 2025


================
@@ -71,6 +71,27 @@ constexpr vector<T, L> reflect_vec_impl(vector<T, L> I, vector<T, L> N) {
 #endif
 }
 
+template <typename T> constexpr T refract_impl(T I, T N, T eta) {
+  T k = 1 - eta * eta * (1 - (N * I * N *I));
----------------
farzonl wrote:

Install clangd vscode extension it has a tool that will fix formatting issues like this.

https://github.com/llvm/llvm-project/pull/136026


More information about the llvm-commits mailing list