isTimingEnabled.lua 665 B

1234567891011121314151617181920212223242526
  1. return {
  2. tag = 'graphics-global',
  3. summary = 'Check if timing stats are enabled.',
  4. description = [[
  5. Returns whether timing stats are enabled. When enabled, `Pass:getStats` will return
  6. `submitTime` and `gpuTime` durations. Timing is enabled by default when `t.graphics.debug` is
  7. set in `lovr.conf`. Timing has a small amount of overhead, so it should only be enabled when
  8. needed.
  9. ]],
  10. arguments = {},
  11. returns = {
  12. enabled = {
  13. type = 'boolean',
  14. description = 'Whether timing is enabled.'
  15. }
  16. },
  17. variants = {
  18. {
  19. arguments = {},
  20. returns = { 'enabled' }
  21. }
  22. },
  23. related = {
  24. 'Pass:getStats'
  25. }
  26. }