
Company News
Socket Named Top Sales Organization by RepVue
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.
Part of a fork of @toji's
gl-matrix split into smaller pieces: this
package contains glMatrix.vec4.
vec4 = require('gl-vec4')Will load all of the module's functionality and expose it on a single object. Note that any of the methods may also be required directly from their files.
For example, the following are equivalent:
var scale = require('gl-vec4').scale
var scale = require('gl-vec4/scale')
Adds two vec4's
Creates a new vec4 initialized with values from an existing vector
Copy the values from one vec4 to another
Creates a new, empty vec4
Calculates the euclidian distance between two vec4's
Divides two vec4's
Calculates the dot product of two vec4's
Creates a new vec4 initialized with the given values
Returns the inverse of the components of a vec4
Calculates the length of a vec4
Performs a linear interpolation between two vec4's
Returns the maximum of two vec4's
Returns the minimum of two vec4's
Multiplies two vec4's
Negates the components of a vec4
Normalize a vec4
Generates a random vector with the given scale
Scales a vec4 by a scalar number
Adds two vec4's after scaling the second operand by a scalar value
Set the components of a vec4 to the given values
Calculates the squared euclidian distance between two vec4's
Calculates the squared length of a vec4
Subtracts vector b from vector a
Transforms the vec4 with a mat4.
Transforms the vec4 with a quat
MIT. See LICENSE.md for details.
FAQs
gl-matrix's vec4, split into smaller pieces
The npm package gl-vec4 receives a total of 23,105 weekly downloads. As such, gl-vec4 popularity was classified as popular.
We found that gl-vec4 demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?

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.

Company News
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.

Security News
NIST will stop enriching most CVEs under a new risk-based model, narrowing the NVD's scope as vulnerability submissions continue to surge.

Company News
/Security News
Socket is an initial recipient of OpenAI's Cybersecurity Grant Program, which commits $10M in API credits to defenders securing open source software.