Skip to content

Commit

Permalink
WebGPUAttributes: Improve comment of byte alignment computation.
Browse files Browse the repository at this point in the history
  • Loading branch information
Mugen87 committed Oct 1, 2020
1 parent 73c6685 commit 7bc80c5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/jsm/renderers/webgpu/WebGPUAttributes.js
Expand Up @@ -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,
Expand Down

0 comments on commit 7bc80c5

Please sign in to comment.