Browse Source

Update compute_shaders.rst (#6762)

* Update compute_shaders.rst

32 bit = to 4 bytes not 8 bytes.

---------

Co-authored-by: Clay John <[email protected]>
Kwu564 2 years ago
parent
commit
79da2289cf
1 changed files with 2 additions and 2 deletions
  1. 2 2
      tutorials/shaders/compute_shaders.rst

+ 2 - 2
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