Skip to content

docs: Add an SDF version of the OS Awards Statuette#2607

Open
reczkok wants to merge 1 commit into
releasefrom
feat/os-sdf
Open

docs: Add an SDF version of the OS Awards Statuette#2607
reczkok wants to merge 1 commit into
releasefrom
feat/os-sdf

Conversation

@reczkok

@reczkok reczkok commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

No description provided.

@github-actions

github-actions Bot commented Jun 12, 2026

Copy link
Copy Markdown

pkg.pr.new

packages
Ready to be installed by your favorite package manager ⬇️

https://pkg.pr.new/software-mansion/TypeGPU/typegpu@28d213cf5fa072a21ee109a2b164a686f2a02ad1
https://pkg.pr.new/software-mansion/TypeGPU/@typegpu/cli@28d213cf5fa072a21ee109a2b164a686f2a02ad1
https://pkg.pr.new/software-mansion/TypeGPU/@typegpu/noise@28d213cf5fa072a21ee109a2b164a686f2a02ad1
https://pkg.pr.new/software-mansion/TypeGPU/@typegpu/react@28d213cf5fa072a21ee109a2b164a686f2a02ad1
https://pkg.pr.new/software-mansion/TypeGPU/unplugin-typegpu@28d213cf5fa072a21ee109a2b164a686f2a02ad1

benchmark
view benchmark

commit
view commit

@github-actions

github-actions Bot commented Jun 12, 2026

Copy link
Copy Markdown

📊 Bundle Size Comparison

🟢 Decreased ➖ Unchanged 🔴 Increased ❔ Unknown
0 356 0 0

👀 Notable results

Static test results:

No major changes.

Dynamic test results:

No major changes.

📋 All results

Click to reveal the results table (355 entries).
Test tsdown
dataImportEverything.ts 88.14 kB (➖)
dataImportOneDirect.ts 23.28 kB (➖)
dataImportOneStar.ts 23.28 kB (➖)
functionWithUseGpu.ts 282 B (➖)
functionWithoutUseGpu.ts 24 B (➖)
importEntireLibrary.ts 287.23 kB (➖)
stdImportEverything.ts 104.29 kB (➖)
stdImportOneDirect.ts 46.93 kB (➖)
stdImportOneStar.ts 46.93 kB (➖)
tgpuImportEverything.ts 259.37 kB (➖)
tgpuImportOne.ts 259.38 kB (➖)
MissingBindGroupsError from typegpu.ts 1.35 kB (➖)
MissingSlotValueError from typegpu.ts 151 B (➖)
MissingVertexBuffersError from typegpu.ts 1.36 kB (➖)
NotUniformError from typegpu.ts 1.31 kB (➖)
ResolutionError from typegpu.ts 2.33 kB (➖)
ShaderGenerator from typegpu.ts 1.66 kB (➖)
Void from typegpudata.ts 734 B (➖)
WgslGenerator from typegpu.ts 112.92 kB (➖)
abs from typegpustd.ts 64.37 kB (➖)
acos from typegpustd.ts 64.37 kB (➖)
acosh from typegpustd.ts 64.37 kB (➖)
add from typegpustd.ts 46.92 kB (➖)
align from typegpudata.ts 24.97 kB (➖)
alignmentOf from typegpudata.ts 20.51 kB (➖)
allEq from typegpustd.ts 50.30 kB (➖)
all from typegpustd.ts 50.30 kB (➖)
and from typegpustd.ts 50.29 kB (➖)
any from typegpustd.ts 50.30 kB (➖)
arrayLength from typegpustd.ts 13.00 kB (➖)
arrayOf from typegpudata.ts 24.83 kB (➖)
asin from typegpustd.ts 64.37 kB (➖)
asinh from typegpustd.ts 64.37 kB (➖)
atan2 from typegpustd.ts 64.37 kB (➖)
atan from typegpustd.ts 64.37 kB (➖)
atanh from typegpustd.ts 64.37 kB (➖)
atomicAdd from typegpustd.ts 14.37 kB (➖)
atomicAnd from typegpustd.ts 14.37 kB (➖)
atomicLoad from typegpustd.ts 14.36 kB (➖)
atomicMax from typegpustd.ts 14.37 kB (➖)
atomicMin from typegpustd.ts 14.37 kB (➖)
atomicOr from typegpustd.ts 14.37 kB (➖)
atomicStore from typegpustd.ts 14.36 kB (➖)
atomicSub from typegpustd.ts 14.37 kB (➖)
atomicXor from typegpustd.ts 14.37 kB (➖)
atomic from typegpudata.ts 779 B (➖)
bitShiftLeft from typegpustd.ts 46.92 kB (➖)
bitShiftRight from typegpustd.ts 46.92 kB (➖)
bitcastU32toF32 from typegpustd.ts 42.75 kB (➖)
bitcastU32toI32 from typegpustd.ts 42.75 kB (➖)
bool from typegpudata.ts 11.54 kB (➖)
builtin from typegpudata.ts 27.29 kB (➖)
ceil from typegpustd.ts 64.37 kB (➖)
clamp from typegpustd.ts 64.37 kB (➖)
common from typegpu.ts 57.09 kB (➖)
comparisonSampler from typegpudata.ts 753 B (➖)
copy from typegpustd.ts 13 kB (➖)
cos from typegpustd.ts 64.37 kB (➖)
cosh from typegpustd.ts 64.37 kB (➖)
countLeadingZeros from typegpustd.ts 64.37 kB (➖)
countOneBits from typegpustd.ts 64.37 kB (➖)
countTrailingZeros from typegpustd.ts 64.37 kB (➖)
cross from typegpustd.ts 64.37 kB (➖)
d from typegpu.ts 85.82 kB (➖)
deepEqual from typegpudata.ts 2.19 kB (➖)
degrees from typegpustd.ts 64.37 kB (➖)
determinant from typegpustd.ts 64.37 kB (➖)
disarrayOf from typegpudata.ts 13.59 kB (➖)
discard from typegpustd.ts 12.76 kB (➖)
distance from typegpustd.ts 64.37 kB (➖)
div from typegpustd.ts 46.92 kB (➖)
dot4I8Packed from typegpustd.ts 64.37 kB (➖)
dot4U8Packed from typegpustd.ts 64.37 kB (➖)
dot from typegpustd.ts 64.37 kB (➖)
dpdxCoarse from typegpustd.ts 13.61 kB (➖)
dpdxFine from typegpustd.ts 13.61 kB (➖)
dpdx from typegpustd.ts 13.60 kB (➖)
dpdyCoarse from typegpustd.ts 13.61 kB (➖)
dpdyFine from typegpustd.ts 13.61 kB (➖)
dpdy from typegpustd.ts 13.61 kB (➖)
eq from typegpustd.ts 50.30 kB (➖)
exp2 from typegpustd.ts 64.37 kB (➖)
exp from typegpustd.ts 64.37 kB (➖)
extensionEnabled from typegpustd.ts 13.15 kB (➖)
extractBits from typegpustd.ts 64.37 kB (➖)
f16 from typegpudata.ts 11.54 kB (➖)
f32 from typegpudata.ts 11.54 kB (➖)
faceForward from typegpustd.ts 64.37 kB (➖)
firstLeadingBit from typegpustd.ts 64.37 kB (➖)
firstTrailingBit from typegpustd.ts 64.37 kB (➖)
float16 from typegpudata.ts 19.47 kB (➖)
float16x2 from typegpudata.ts 19.47 kB (➖)
float16x4 from typegpudata.ts 19.47 kB (➖)
float32 from typegpudata.ts 19.47 kB (➖)
float32x2 from typegpudata.ts 19.47 kB (➖)
float32x3 from typegpudata.ts 19.47 kB (➖)
float32x4 from typegpudata.ts 19.47 kB (➖)
floor from typegpustd.ts 64.37 kB (➖)
fma from typegpustd.ts 64.37 kB (➖)
formatToWGSLType from typegpudata.ts 19.46 kB (➖)
fract from typegpustd.ts 64.37 kB (➖)
frexp from typegpustd.ts 64.37 kB (➖)
fwidthCoarse from typegpustd.ts 13.61 kB (➖)
fwidthFine from typegpustd.ts 13.61 kB (➖)
fwidth from typegpustd.ts 13.61 kB (➖)
ge from typegpustd.ts 50.30 kB (➖)
getLongestContiguousPrefix from typegpudata.ts 23.30 kB (➖)
getTargetShaderLanguage from typegpustd.ts 13.10 kB (➖)
gt from typegpustd.ts 50.30 kB (➖)
i32 from typegpudata.ts 11.54 kB (➖)
identity2 from typegpustd.ts 25.55 kB (➖)
identity3 from typegpustd.ts 25.55 kB (➖)
identity4 from typegpustd.ts 25.55 kB (➖)
insertBits from typegpustd.ts 64.37 kB (➖)
interpolate from typegpudata.ts 24.98 kB (➖)
invariant from typegpudata.ts 25.35 kB (➖)
inverseSqrt from typegpustd.ts 64.37 kB (➖)
isAccessor from typegpu.ts 65 B (➖)
isAlignAttrib from typegpudata.ts 755 B (➖)
isAtomic from typegpudata.ts 755 B (➖)
isBeingTranspiled from typegpustd.ts 13.04 kB (➖)
isBufferShorthand from typegpu.ts 1.71 kB (➖)
isBuffer from typegpu.ts 87.25 kB (➖)
isBuiltinAttrib from typegpudata.ts 757 B (➖)
isBuiltin from typegpudata.ts 23.23 kB (➖)
isCloseTo from typegpustd.ts 50.30 kB (➖)
isComparisonSampler from typegpu.ts 61.70 kB (➖)
isContiguous from typegpudata.ts 23.29 kB (➖)
isData from typegpudata.ts 1.81 kB (➖)
isDecorated from typegpudata.ts 758 B (➖)
isDisarray from typegpudata.ts 1.11 kB (➖)
isInterpolateAttrib from typegpudata.ts 761 B (➖)
isLazy from typegpu.ts 61 B (➖)
isLocationAttrib from typegpudata.ts 758 B (➖)
isLooseData from typegpudata.ts 1.16 kB (➖)
isLooseDecorated from typegpudata.ts 1.12 kB (➖)
isMutableAccessor from typegpu.ts 73 B (➖)
isPackedData from typegpudata.ts 19.53 kB (➖)
isPtr from typegpudata.ts 752 B (➖)
isSampler from typegpu.ts 61.68 kB (➖)
isSizeAttrib from typegpudata.ts 754 B (➖)
isSlot from typegpu.ts 61 B (➖)
isTexture from typegpu.ts 61.68 kB (➖)
isTgpuComputeFn from typegpu.ts 69 B (➖)
isTgpuFn from typegpu.ts 765 B (➖)
isTgpuFragmentFn from typegpu.ts 70 B (➖)
isTgpuVertexFn from typegpu.ts 68 B (➖)
isUnstruct from typegpudata.ts 1.11 kB (➖)
isUsableAsRender from typegpu.ts 55 B (➖)
isUsableAsSampled from typegpu.ts 56 B (➖)
isUsableAsStorage from typegpu.ts 56 B (➖)
isUsableAsUniform from typegpu.ts 61.67 kB (➖)
isUsableAsVertex from typegpu.ts 87.24 kB (➖)
isVariable from typegpu.ts 63.39 kB (➖)
isWgslArray from typegpudata.ts 754 B (➖)
isWgslData from typegpudata.ts 1.31 kB (➖)
isWgslStruct from typegpudata.ts 755 B (➖)
ldexp from typegpustd.ts 64.37 kB (➖)
le from typegpustd.ts 50.30 kB (➖)
length from typegpustd.ts 64.37 kB (➖)
location from typegpudata.ts 24.97 kB (➖)
log2 from typegpustd.ts 64.37 kB (➖)
log from typegpustd.ts 64.37 kB (➖)
lt from typegpustd.ts 50.30 kB (➖)
mat2x2f from typegpudata.ts 25.55 kB (➖)
mat3x3f from typegpudata.ts 25.55 kB (➖)
mat4x4f from typegpudata.ts 25.55 kB (➖)
matToArray from typegpudata.ts 25.68 kB (➖)
max from typegpustd.ts 64.37 kB (➖)
memoryLayoutOf from typegpudata.ts 40.60 kB (➖)
min from typegpustd.ts 64.37 kB (➖)
mix from typegpustd.ts 64.37 kB (➖)
mod from typegpustd.ts 46.92 kB (➖)
modf from typegpustd.ts 64.37 kB (➖)
mul from typegpustd.ts 46.92 kB (➖)
ne from typegpustd.ts 50.30 kB (➖)
neg from typegpustd.ts 46.92 kB (➖)
normalize from typegpustd.ts 64.37 kB (➖)
not from typegpustd.ts 50.30 kB (➖)
or from typegpustd.ts 50.29 kB (➖)
pack2x16float from typegpustd.ts 34.51 kB (➖)
pack4x8unorm from typegpustd.ts 34.51 kB (➖)
packedFormats from typegpudata.ts 19.49 kB (➖)
patchArrayBuffer from typegpu.ts 49.75 kB (➖)
pow from typegpustd.ts 64.37 kB (➖)
ptrFn from typegpudata.ts 859 B (➖)
ptrHandle from typegpudata.ts 851 B (➖)
ptrPrivate from typegpudata.ts 858 B (➖)
ptrStorage from typegpudata.ts 856 B (➖)
ptrUniform from typegpudata.ts 852 B (➖)
ptrWorkgroup from typegpudata.ts 860 B (➖)
quantizeToF16 from typegpustd.ts 64.37 kB (➖)
radians from typegpustd.ts 64.37 kB (➖)
range from typegpustd.ts 13.42 kB (➖)
readFromArrayBuffer from typegpu.ts 50.34 kB (➖)
ref from typegpudata.ts 4.79 kB (➖)
reflect from typegpustd.ts 64.37 kB (➖)
refract from typegpustd.ts 64.37 kB (➖)
reverseBits from typegpustd.ts 64.37 kB (➖)
rotateX4 from typegpustd.ts 47.68 kB (➖)
rotateY4 from typegpustd.ts 47.69 kB (➖)
rotateZ4 from typegpustd.ts 47.69 kB (➖)
rotationX4 from typegpustd.ts 25.55 kB (➖)
rotationY4 from typegpustd.ts 25.55 kB (➖)
rotationZ4 from typegpustd.ts 25.55 kB (➖)
round from typegpustd.ts 64.37 kB (➖)
sampler from typegpudata.ts 742 B (➖)
saturate from typegpustd.ts 64.37 kB (➖)
scale4 from typegpustd.ts 47.68 kB (➖)
scaling4 from typegpustd.ts 25.55 kB (➖)
select from typegpustd.ts 50.30 kB (➖)
sign from typegpustd.ts 64.37 kB (➖)
sin from typegpustd.ts 64.37 kB (➖)
sinh from typegpustd.ts 64.37 kB (➖)
sint16 from typegpudata.ts 19.47 kB (➖)
sint16x2 from typegpudata.ts 19.47 kB (➖)
sint16x4 from typegpudata.ts 19.47 kB (➖)
sint32 from typegpudata.ts 19.47 kB (➖)
sint32x2 from typegpudata.ts 19.47 kB (➖)
sint32x3 from typegpudata.ts 19.47 kB (➖)
sint32x4 from typegpudata.ts 19.47 kB (➖)
sint8 from typegpudata.ts 19.47 kB (➖)
sint8x2 from typegpudata.ts 19.47 kB (➖)
sint8x4 from typegpudata.ts 19.47 kB (➖)
sizeOf from typegpudata.ts 23.28 kB (➖)
size from typegpudata.ts 24.97 kB (➖)
smoothstep from typegpustd.ts 64.37 kB (➖)
snorm16 from typegpudata.ts 19.47 kB (➖)
snorm16x2 from typegpudata.ts 19.47 kB (➖)
snorm16x4 from typegpudata.ts 19.47 kB (➖)
snorm8 from typegpudata.ts 19.47 kB (➖)
snorm8x2 from typegpudata.ts 19.47 kB (➖)
snorm8x4 from typegpudata.ts 19.47 kB (➖)
sqrt from typegpustd.ts 64.37 kB (➖)
std from typegpu.ts 101.45 kB (➖)
step from typegpustd.ts 64.37 kB (➖)
storageBarrier from typegpustd.ts 14.37 kB (➖)
struct from typegpudata.ts 3.42 kB (➖)
sub from typegpustd.ts 46.92 kB (➖)
subgroupAdd from typegpustd.ts 22.54 kB (➖)
subgroupAll from typegpustd.ts 22.55 kB (➖)
subgroupAnd from typegpustd.ts 22.55 kB (➖)
subgroupAny from typegpustd.ts 22.55 kB (➖)
subgroupBallot from typegpustd.ts 22.55 kB (➖)
subgroupBroadcastFirst from typegpustd.ts 22.55 kB (➖)
subgroupBroadcast from typegpustd.ts 22.55 kB (➖)
subgroupElect from typegpustd.ts 22.55 kB (➖)
subgroupExclusiveAdd from typegpustd.ts 22.55 kB (➖)
subgroupExclusiveMul from typegpustd.ts 22.55 kB (➖)
subgroupInclusiveAdd from typegpustd.ts 22.55 kB (➖)
subgroupInclusiveMul from typegpustd.ts 22.55 kB (➖)
subgroupMax from typegpustd.ts 22.55 kB (➖)
subgroupMin from typegpustd.ts 22.55 kB (➖)
subgroupMul from typegpustd.ts 22.55 kB (➖)
subgroupOr from typegpustd.ts 22.55 kB (➖)
subgroupShuffleDown from typegpustd.ts 22.55 kB (➖)
subgroupShuffleUp from typegpustd.ts 22.55 kB (➖)
subgroupShuffleXor from typegpustd.ts 22.55 kB (➖)
subgroupShuffle from typegpustd.ts 22.55 kB (➖)
subgroupXor from typegpustd.ts 22.55 kB (➖)
tan from typegpustd.ts 64.37 kB (➖)
tanh from typegpustd.ts 64.37 kB (➖)
texture1d from typegpudata.ts 12.00 kB (➖)
texture2dArray from typegpudata.ts 12.02 kB (➖)
texture2d from typegpudata.ts 12.00 kB (➖)
texture3d from typegpudata.ts 12.00 kB (➖)
textureBarrier from typegpustd.ts 14.36 kB (➖)
textureCubeArray from typegpudata.ts 12.02 kB (➖)
textureCube from typegpudata.ts 12.00 kB (➖)
textureDepth2dArray from typegpudata.ts 12.01 kB (➖)
textureDepth2d from typegpudata.ts 11.99 kB (➖)
textureDepthCubeArray from typegpudata.ts 12.01 kB (➖)
textureDepthCube from typegpudata.ts 11.99 kB (➖)
textureDepthMultisampled2d from typegpudata.ts 12.01 kB (➖)
textureDimensions from typegpustd.ts 24.30 kB (➖)
textureExternal from typegpudata.ts 873 B (➖)
textureGather from typegpustd.ts 24.30 kB (➖)
textureLoad from typegpustd.ts 24.31 kB (➖)
textureMultisampled2d from typegpudata.ts 12.02 kB (➖)
textureSampleBaseClampToEdge from typegpustd.ts 24.31 kB (➖)
textureSampleBias from typegpustd.ts 24.31 kB (➖)
textureSampleCompareLevel from typegpustd.ts 24.31 kB (➖)
textureSampleCompare from typegpustd.ts 24.31 kB (➖)
textureSampleGrad from typegpustd.ts 24.31 kB (➖)
textureSampleLevel from typegpustd.ts 24.31 kB (➖)
textureSample from typegpustd.ts 24.31 kB (➖)
textureStorage1d from typegpudata.ts 1.01 kB (➖)
textureStorage2dArray from typegpudata.ts 1.03 kB (➖)
textureStorage2d from typegpudata.ts 1.01 kB (➖)
textureStorage3d from typegpudata.ts 1.01 kB (➖)
textureStore from typegpustd.ts 24.31 kB (➖)
tgpu.accessor from typegpu.ts 259.37 kB (➖)
tgpu.bindGroupLayout from typegpu.ts 259.38 kB (➖)
tgpu.comptime from typegpu.ts 259.37 kB (➖)
tgpu.computeFn from typegpu.ts 259.38 kB (➖)
tgpu.const from typegpu.ts 259.37 kB (➖)
tgpu.fn from typegpu.ts 259.37 kB (➖)
tgpu.fragmentFn from typegpu.ts 259.38 kB (➖)
tgpu.initFromDevice from typegpu.ts 259.38 kB (➖)
tgpu.init from typegpu.ts 259.37 kB (➖)
tgpu.lazy from typegpu.ts 259.37 kB (➖)
tgpu.mutableAccessor from typegpu.ts 259.38 kB (➖)
tgpu.privateVar from typegpu.ts 259.38 kB (➖)
tgpu.resolveWithContext from typegpu.ts 259.38 kB (➖)
tgpu.resolve from typegpu.ts 259.37 kB (➖)
tgpu.slot from typegpu.ts 259.37 kB (➖)
tgpu.unroll from typegpu.ts 259.37 kB (➖)
tgpu.vertexFn from typegpu.ts 259.37 kB (➖)
tgpu.vertexLayout from typegpu.ts 259.38 kB (➖)
tgpu.workgroupVar from typegpu.ts 259.38 kB (➖)
tgpu from typegpu.ts 259.37 kB (➖)
translate4 from typegpustd.ts 47.68 kB (➖)
translation4 from typegpustd.ts 25.55 kB (➖)
transpose from typegpustd.ts 64.37 kB (➖)
trunc from typegpustd.ts 64.37 kB (➖)
u16 from typegpudata.ts 11.57 kB (➖)
u32 from typegpudata.ts 11.54 kB (➖)
uint16 from typegpudata.ts 19.47 kB (➖)
uint16x2 from typegpudata.ts 19.47 kB (➖)
uint16x4 from typegpudata.ts 19.47 kB (➖)
uint32 from typegpudata.ts 19.47 kB (➖)
uint32x2 from typegpudata.ts 19.47 kB (➖)
uint32x3 from typegpudata.ts 19.47 kB (➖)
uint32x4 from typegpudata.ts 19.47 kB (➖)
uint8 from typegpudata.ts 19.46 kB (➖)
uint8x2 from typegpudata.ts 19.47 kB (➖)
uint8x4 from typegpudata.ts 19.47 kB (➖)
unorm10 10 10 2 from typegpudata.ts 19.47 kB (➖)
unorm16 from typegpudata.ts 19.47 kB (➖)
unorm16x2 from typegpudata.ts 19.47 kB (➖)
unorm16x4 from typegpudata.ts 19.47 kB (➖)
unorm8 from typegpudata.ts 19.47 kB (➖)
unorm8x2 from typegpudata.ts 19.47 kB (➖)
unorm8x4 bgra from typegpudata.ts 19.47 kB (➖)
unorm8x4 from typegpudata.ts 19.47 kB (➖)
unpack2x16float from typegpustd.ts 34.51 kB (➖)
unpack4x8unorm from typegpustd.ts 34.51 kB (➖)
unstruct from typegpudata.ts 1.55 kB (➖)
vec2b from typegpudata.ts 17.97 kB (➖)
vec2f from typegpudata.ts 17.97 kB (➖)
vec2h from typegpudata.ts 17.97 kB (➖)
vec2i from typegpudata.ts 17.97 kB (➖)
vec2u from typegpudata.ts 17.97 kB (➖)
vec3b from typegpudata.ts 17.97 kB (➖)
vec3f from typegpudata.ts 17.97 kB (➖)
vec3h from typegpudata.ts 17.97 kB (➖)
vec3i from typegpudata.ts 17.97 kB (➖)
vec3u from typegpudata.ts 17.97 kB (➖)
vec4b from typegpudata.ts 17.97 kB (➖)
vec4f from typegpudata.ts 17.97 kB (➖)
vec4h from typegpudata.ts 17.97 kB (➖)
vec4i from typegpudata.ts 17.97 kB (➖)
vec4u from typegpudata.ts 17.97 kB (➖)
workgroupBarrier from typegpustd.ts 14.37 kB (➖)
writeToArrayBuffer from typegpu.ts 49.55 kB (➖)

If you wish to run a comparison for other, slower bundlers, run the 'Tree-shake test' from the GitHub Actions menu.

@github-actions

github-actions Bot commented Jun 12, 2026

Copy link
Copy Markdown

Resolution Time Benchmark

---
config:
  themeVariables:
    xyChart:
      plotColorPalette: "#E63946, #3B82F6, #059669"
---
xychart
  title "Random Branching (🔴 PR | 🔵 main | 🟢 release)"
  x-axis "max depth" [1, 2, 3, 4, 5, 6, 7, 8]
  y-axis "time (ms)"
  line [0.79, 1.57, 3.31, 5.15, 6.04, 8.17, 17.25, 19.50]
  line [0.80, 1.64, 3.52, 4.70, 5.77, 9.31, 18.18, 20.29]
  line [0.83, 1.65, 3.45, 5.06, 5.92, 9.54, 17.23, 20.35]
Loading
---
config:
  themeVariables:
    xyChart:
      plotColorPalette: "#E63946, #3B82F6, #059669"
---
xychart
  title "Linear Recursion (🔴 PR | 🔵 main | 🟢 release)"
  x-axis "max depth" [1, 2, 3, 4, 5, 6, 7, 8]
  y-axis "time (ms)"
  line [0.26, 0.47, 0.64, 0.69, 0.97, 1.05, 1.19, 1.30]
  line [0.33, 0.48, 0.62, 0.68, 0.98, 1.01, 1.23, 1.36]
  line [0.23, 0.46, 0.56, 0.69, 0.97, 0.99, 1.19, 1.34]
Loading
---
config:
  themeVariables:
    xyChart:
      plotColorPalette: "#E63946, #3B82F6, #059669"
---
xychart
  title "Full Tree (🔴 PR | 🔵 main | 🟢 release)"
  x-axis "max depth" [1, 2, 3, 4, 5, 6, 7, 8]
  y-axis "time (ms)"
  line [0.79, 1.77, 3.32, 5.18, 10.20, 21.56, 45.54, 91.90]
  line [0.79, 1.79, 3.03, 6.23, 10.66, 21.56, 45.57, 93.56]
  line [0.74, 1.84, 3.29, 5.15, 10.13, 21.22, 46.03, 92.31]
Loading

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a ray-marched SDF-based renderer for the OS Awards statuette example and refactors the existing mesh-based renderer into shared “common” modules so the demo can switch between SDF and mesh rendering modes.

Changes:

  • Added an SDF shape definition, UV atlas mapping, and an SDF renderer with epoxy interior tracing.
  • Refactored environment sampling, PBR helpers, and material sampling into common/ and updated the main example to use a shared bind group.
  • Added a mesh-renderer module and a UI control to toggle between sdf and mesh renderers.

Reviewed changes

Copilot reviewed 8 out of 11 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
apps/typegpu-docs/src/examples/rendering/os-awards/sdf/uv.ts Adds UV region selection/atlas coefficients for the SDF award.
apps/typegpu-docs/src/examples/rendering/os-awards/sdf/shape.ts Defines SDF primitives/ops composing the award + epoxy wood block and bounds.
apps/typegpu-docs/src/examples/rendering/os-awards/sdf/renderer.ts Implements SDF ray marching + epoxy shading/path tracing logic.
apps/typegpu-docs/src/examples/rendering/os-awards/scene.ts Tweaks camera zoom range and adds scene.sdfEpoxy parameters used by the SDF renderer.
apps/typegpu-docs/src/examples/rendering/os-awards/mesh/renderer.ts Extracts the mesh pipeline into a dedicated renderer module.
apps/typegpu-docs/src/examples/rendering/os-awards/index.ts Refactors the example entrypoint to shared bind group + renderer toggle + inverse transform uniform.
apps/typegpu-docs/src/examples/rendering/os-awards/common/shading.ts Centralizes bind group layout, tonemapping, env/material sampling, and shared shading helpers.
apps/typegpu-docs/src/examples/rendering/os-awards/common/pbr.ts Extracts PBR utility functions used by shading.
apps/typegpu-docs/src/examples/rendering/os-awards/common/model.ts Simplifies texture creation options (conditional viewFormats).
apps/typegpu-docs/src/examples/rendering/os-awards/common/cubemap.ts Adds shared equirect->cubemap conversion and direction/UV helpers.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +1 to +3
import tgpu, { d, std, type TgpuRoot } from 'typegpu';
import { type loadModel, ModelVertex } from '../common/model.ts';
import {
Comment on lines +179 to +181
destroy() {
resizeObserver.unobserve(canvas);
},
Comment on lines +91 to +95
const shadeEpoxyWood = (hit: d.v3f, normal: d.v3f): d.v3f => {
'use gpu';
const worldWoodNormal = modelDirToWorld(normal);
const uv = awardUv(hit, d.vec3f(1, 0, 0));
const woodAlbedo =
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants