CompareMode.lua 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. return {
  2. summary = 'Different depth test modes.',
  3. description = [[
  4. The method used to compare z values when deciding how to overlap rendered objects. This is
  5. called the "depth test", and it happens on a pixel-by-pixel basis every time new objects are
  6. drawn. If the depth test "passes" for a pixel, then the pixel color will be replaced by the
  7. new color and the depth value in the depth buffer will be updated. Otherwise, the pixel will
  8. not be changed and the depth value will not be updated.
  9. ]],
  10. values = {
  11. {
  12. name = 'equal',
  13. description = 'The depth test passes when the depth values are equal.',
  14. },
  15. {
  16. name = 'notequal',
  17. description = 'The depth test passes when the depth values are not equal.',
  18. },
  19. {
  20. name = 'less',
  21. description = 'The depth test passes when the new depth value is less than the existing one.',
  22. },
  23. {
  24. name = 'lequal',
  25. description = [[
  26. The depth test passes when the new depth value is less than or equal to the existing one.
  27. ]],
  28. },
  29. {
  30. name = 'gequal',
  31. description = [[
  32. The depth test passes when the new depth value is greater than or equal to the existing one.
  33. ]],
  34. },
  35. {
  36. name = 'greater',
  37. description = [[
  38. The depth test passes when the new depth value is greater than the existing one.
  39. ]]
  40. }
  41. },
  42. related = {
  43. 'lovr.graphics.getDepthTest',
  44. 'lovr.graphics.setDepthTest',
  45. 'lovr.graphics.getStencilTest',
  46. 'lovr.graphics.setStencilTest'
  47. }
  48. }