Skip to content

Instantly share code, notes, and snippets.

View greggman's full-sized avatar
😁

Greggman greggman

😁
View GitHub Profile
@greggman
greggman / README.md
Created May 2, 2024 16:14
WebGPU: Small Code Textured Quad
@greggman
greggman / code snippets.md
Last active April 29, 2024 21:02
code snippets

WebGPU request limits

  const adapter = await navigator?.gpu.requestAdapter();
  const device = await adapter?.requestDevice({
    requiredLimits: {
      maxBufferSize: adapter.limits.maxBufferSize,
    },
  });
@greggman
greggman / README.md
Created April 27, 2024 21:14
WebGL: Multiple Canvases <details>
@greggman
greggman / bytebeats.md
Last active April 27, 2024 20:31
bytebeats
@greggman
greggman / README.md
Last active April 27, 2024 09:56
ByteBeatNode (visualizer via AnalyserNode)
@greggman
greggman / README.md
Last active April 27, 2024 09:56
ByteBeatNode (visualizer)
@greggman
greggman / README.md
Last active April 27, 2024 09:52
ByteBeatNode (umd)
@greggman
greggman / README.md
Last active April 27, 2024 09:51
ByteBeatNode (esm)
@greggman
greggman / threejs-fragment-shader-r122.glsl
Last active April 26, 2024 15:31
three.js standard shaders r122
#version 300 es
#define varying in
out highp vec4 pc_fragColor;
#define gl_FragColor pc_fragColor
#define gl_FragDepthEXT gl_FragDepth
#define texture2D texture
#define textureCube texture
#define texture2DProj textureProj
#define texture2DLodEXT textureLod
#define texture2DProjLodEXT textureProjLod
@greggman
greggman / index.css
Created October 17, 2020 16:56
Load Obj - Stack Overflow
body { margin: 0; }
canvas { width: 100vw; height: 100vh; display block; }