Socket
Book a DemoInstallSign in
Socket

glsl-determinant

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

glsl-determinant

Computes the determinant of a matrix in glsl

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

glsl-determinant

Computes the determinant of a matrix in glsl

Example

#pragma glslify: det = require(glsl-determinant)

void main() {
  mat3 m = mat3(1, 2, 3,
                4, 5, 6,
                7, 8, 9);

  float d = det(m);

  //d is the determinant of m (0 in this case)
}

Usage

Install with npm:

npm install glsl-determinant

Then use with glslify.

API

#pragma glslify: determinant = require(glsl-determinant)

float d = determinant(float|mat2|mat3|mat4 m)

Computes the determinant of a matrix

  • m is a matrix, either float, mat2, mat3 or mat4

Returns The determinant of m

License

(c) 2014 Mikola Lysenko. MIT License

Keywords

determinant

FAQs

Package last updated on 10 Oct 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts