getPass.lua 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. return {
  2. tag = 'headset-misc',
  3. summary = 'Get a Pass that renders to the headset.',
  4. description = 'Returns a `Pass` that renders to the headset display.',
  5. arguments = {},
  6. returns = {
  7. pass = {
  8. type = 'Pass',
  9. description = 'The pass.'
  10. }
  11. },
  12. variants = {
  13. {
  14. arguments = {},
  15. returns = { 'pass' }
  16. }
  17. },
  18. notes = [[
  19. The same Pass will be returned until `lovr.headset.submit` is called.
  20. The first time this function is called during a frame, the views of the Pass will be initialized
  21. with the headset view poses and view angles.
  22. The pass will be cleared to the background color, which can be changed using
  23. `lovr.graphics.setBackgroundColor`.
  24. The pass will have a depth buffer. If `t.headset.stencil` was set to a truthy value in
  25. `lovr.conf`, the depth buffer will use the `d32fs8` format, otherwise `d32f` will be used.
  26. If `t.headset.antialias` was set to a truthy value in `lovr.conf`, the pass will be
  27. multisampled.
  28. ]],
  29. related = {
  30. 'lovr.graphics.newPass',
  31. 'lovr.graphics.getWindowPass',
  32. 'lovr.conf'
  33. }
  34. }