Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
Index your code
hub
/
github.com/ChartGPU/ChartGPU
/ clamp01
Function
clamp01
src/renderers/createAnnotationMarkerRenderer.ts:77–77 ·
view source on GitHub ↗
(v: number)
Source
from the content-addressed store, hash-verified
75
const
INSTANCE_STRIDE_BYTES = INSTANCE_STRIDE_FLOATS * 4;
76
77
const
clamp01 = (v: number): number => Math.min(1, Math.max(0, v));
78
79
const
nextPow2 = (v: number): number => {
80
if
(!Number.isFinite(v) || v <= 0)
return
1;
Callers
1
prepare
Function · 0.70
Calls
no outgoing calls
Tested by
no test coverage detected