From 89ea37184b8617a927ab95f2bc0309e67af5650b Mon Sep 17 00:00:00 2001 From: Gregg Tavares Date: Thu, 9 Jan 2025 22:30:14 -0800 Subject: [PATCH] typo --- webgpu/lessons/webgpu-copying-data.md | 4 ++-- webgpu/webgpu-vertex-buffers-index-buffer.html | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/webgpu/lessons/webgpu-copying-data.md b/webgpu/lessons/webgpu-copying-data.md index 93bf7583..67803bc8 100644 --- a/webgpu/lessons/webgpu-copying-data.md +++ b/webgpu/lessons/webgpu-copying-data.md @@ -239,7 +239,7 @@ encoder.copyTextureToBuffer( This has similar parameters to `copyBufferToTexture` just the texture (now the source) and the buffer (now the destination) -are swapped. Like `copyTextureToBuffer`, `bytesPerRow` **must be +are swapped. Like `copyBufferToTexture`, `bytesPerRow` **must be a multiple of 256!!** * `texture` must have a usage of `GPUTextureUsage.COPY_SRC` @@ -255,7 +255,7 @@ must only differ by the suffix `'-srgb'`. signature: ```js -encoder.copyTextureToBuffer( +encoder.copyTextureToTexture( // details of the source texture src: { texture, mipLevel: 0, origin: [0, 0, 0], aspect: "all" }, diff --git a/webgpu/webgpu-vertex-buffers-index-buffer.html b/webgpu/webgpu-vertex-buffers-index-buffer.html index 6928cfdf..cba2be44 100644 --- a/webgpu/webgpu-vertex-buffers-index-buffer.html +++ b/webgpu/webgpu-vertex-buffers-index-buffer.html @@ -66,9 +66,9 @@ // 2 vertices per subdivision // - // 0 2 4 6 8 ... - // // 1 3 5 7 9 ... + // + // 0 2 4 6 8 ... for (let i = 0; i <= numSubdivisions; ++i) { const angle = startAngle + (i + 0) * (endAngle - startAngle) / numSubdivisions;