The Wayback Machine - https://webcf.waybackmachine.org/web/20220402134739/https://github.com/mrdoob/three.js/commit/7bc80c5a84e277cef288fe2a5d35b1d1347fc10b
Skip to content
Permalink
Browse files
WebGPUAttributes: Improve comment of byte alignment computation.
  • Loading branch information
Mugen87 committed on Oct 1, 2020
1 parent 73c6685 commit 7bc80c5a84e277cef288fe2a5d35b1d1347fc10b
Showing with 1 addition and 1 deletion.
  1. +1 −1 examples/jsm/renderers/webgpu/WebGPUAttributes.js
@@ -64,7 +64,7 @@ class WebGPUAttributes {
_createBuffer( attribute, usage ) {

const array = attribute.array;
const size = array.byteLength + ( ( 4 - ( array.byteLength % 4 ) ) % 4 ); // ensure 4 byte alignment
const size = array.byteLength + ( ( 4 - ( array.byteLength % 4 ) ) % 4 ); // ensure 4 byte alignment, see #20441

const buffer = this.device.createBuffer( {
size: size,

0 comments on commit 7bc80c5

Please sign in to comment.