Utilities

These are JavaScript functions that can be added to your Babylon.js project if they are useful. Each is given a brief explanation and a Playground example of its use.

In This Category

Mesh Surface Area
Helpful code snippet for finding the surface area of a mesh in Babylon.js.
Mesh Surface Area
Deconstruct A Mesh
Helpful code snippet for deconstructing a mesh in Babylon.js.
Deconstruct A Mesh
Making A Frame
Helpful code snippet for a frame in Babylon.js.
Making A Frame
Increasing Facets
Helpful code snippet for increasing facets of a mesh in Babylon.js.
Increasing Facets
Create Points Inside A Mesh
Helpful code snippet for creating points inside of a mesh in Babylon.js.
Create Points Inside A Mesh
Check When a Point is Inside a Mesh
Helpful code snippet for checking when a point is inside of a mesh in Babylon.js.
Check When a Point is Inside a Mesh
Draw a Line With a Set Width
Helpful code snippet for drawing a line of a set width in Babylon.js.
Draw a Line With a Set Width
Forcing Shared Vertices
Helpful code snippet for forcing mesh to share vertices in Babylon.js.
Forcing Shared Vertices
Extrusion With Sharp Corners
Helpful code snippet for extruding with sharp corners in Babylon.js.
Extrusion With Sharp Corners
Display Vertex Normals
Helpful code snippet for displaying vertex normals in Babylon.js.
Display Vertex Normals
Open A URL On An Event
Helpful code snippet for opening a url on an event in Babylon.js.
Open A URL On An Event
Display Tangent, Normal, and Binormal of a Path3D
Helpful code snippet for displaying helpful information about a Path3D object in Babylon.js.
Display Tangent, Normal, and Binormal of a Path3D
Rotate and Scale About a Point
Helpful code snippet for rotating and scaling about a point in Babylon.js.
Rotate and Scale About a Point
Draw a Sector of a Circle
Helpful code snippet for drawing a sector of a circle in Babylon.js.
Draw a Sector of a Circle
Spherical Panning Camera
Helpful code snippet for creating a spherical panning camera in Babylon.js.
Spherical Panning Camera
Draw Points on a Mesh Surface
Helpful code snippet for drawing points on a mesh surface in Babylon.js.
Draw Points on a Mesh Surface
Display Axes
Helpful feature for displaying world axes in Babylon.js.
Display Axes