getSize.lua 552 B

1234567891011121314151617181920212223242526
  1. return {
  2. tag = 'buffer-metadata',
  3. summary = 'Get the size of the Buffer, in bytes.',
  4. description = [[
  5. Returns the size of the Buffer in VRAM, in bytes. This is the same as `length * stride`.
  6. The size of the Buffer can't change after it's created.
  7. ]],
  8. arguments = {},
  9. returns = {
  10. size = {
  11. type = 'number',
  12. description = 'The size of the Buffer, in bytes.'
  13. }
  14. },
  15. variants = {
  16. {
  17. arguments = {},
  18. returns = { 'size' }
  19. }
  20. },
  21. related = {
  22. 'Buffer:getLength',
  23. 'Buffer:getStride'
  24. }
  25. }