From 79da2289cfdaf2b687628424e4c7ca6914c4c2ef Mon Sep 17 00:00:00 2001 From: Kwu564 Date: Tue, 14 Feb 2023 02:32:10 -0800 Subject: [PATCH] Update compute_shaders.rst (#6762) * Update compute_shaders.rst 32 bit = to 4 bytes not 8 bytes. --------- Co-authored-by: Clay John --- tutorials/shaders/compute_shaders.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tutorials/shaders/compute_shaders.rst b/tutorials/shaders/compute_shaders.rst index 7f162bfa7..d85803429 100644 --- a/tutorials/shaders/compute_shaders.rst +++ b/tutorials/shaders/compute_shaders.rst @@ -206,7 +206,7 @@ So let's initialize an array of floats and create a storage buffer: var input_bytes := input.to_byte_array() # Create a storage buffer that can hold our float values. - # Each float has 8 byte (32 bit) so 10 x 8 = 80 bytes + # Each float has 4 bytes (32 bit) so 10 x 4 = 40 bytes var buffer := rd.storage_buffer_create(input_bytes.size(), input_bytes) .. code-tab:: csharp @@ -217,7 +217,7 @@ So let's initialize an array of floats and create a storage buffer: Buffer.BlockCopy(input, 0, inputBytes, 0, inputBytes.Length); // Create a storage buffer that can hold our float values. - // Each float has 8 byte (32 bit) so 10 x 8 = 80 bytes + // Each float has 4 bytes (32 bit) so 10 x 4 = 40 bytes var buffer = rd.StorageBufferCreate((uint)inputBytes.Length, inputBytes); With the buffer in place we need to tell the rendering device to use this