Skip to main content

Function: computeTiledPositionalEncodingTSL()

computeTiledPositionalEncodingTSL(tx, ty): any[]

Builds the 12 positional-encoding scalars for one sub-texel offset (tx, ty) (each typically in [0, 1), the fractional position within a grid cell - see the 4-tap loops in NTCDecoderTSL.js/NTCGPUComputeTSL.js that already compute this for bilinear/learned interpolation). Ordered [tx octave0 sin, tx octave0 cos, tx octave1 sin, tx octave1 cos, tx octave2 sin, tx octave2 cos, ty ...(same 6)].

Parameters​

tx​

any

ty​

any

Returns​

any[]