commonMain.phraseTbnMatrix_shader.kt Maven / Gradle / Ivy
The newest version!
package org.openrndr.extra.shaderphrases.phrases
const val phraseTbnMatrix = """#pragma package org.openrndr.extra.shaderphrases.phrases
mat3 tbnMatrix(vec4 tangent, vec3 normal) {
vec3 bitangent = cross(normal, tangent.xyz) * tangent.w;
return mat3(tangent.xyz, bitangent, normal);
}"""
© 2015 - 2025 Weber Informatics LLC | Privacy Policy