智慧水务管理系统 - 精河县供水工程综合管理平台

StencilOperation.js 1.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. // @ts-check
  2. import WebGLConstants from "../Core/WebGLConstants.js";
  3. /**
  4. * Determines the action taken based on the result of the stencil test.
  5. *
  6. * @enum {number}
  7. */
  8. const StencilOperation = {
  9. /**
  10. * Sets the stencil buffer value to zero.
  11. *
  12. * @type {number}
  13. * @constant
  14. */
  15. ZERO: WebGLConstants.ZERO,
  16. /**
  17. * Does not change the stencil buffer.
  18. *
  19. * @type {number}
  20. * @constant
  21. */
  22. KEEP: WebGLConstants.KEEP,
  23. /**
  24. * Replaces the stencil buffer value with the reference value.
  25. *
  26. * @type {number}
  27. * @constant
  28. */
  29. REPLACE: WebGLConstants.REPLACE,
  30. /**
  31. * Increments the stencil buffer value, clamping to unsigned byte.
  32. *
  33. * @type {number}
  34. * @constant
  35. */
  36. INCREMENT: WebGLConstants.INCR,
  37. /**
  38. * Decrements the stencil buffer value, clamping to zero.
  39. *
  40. * @type {number}
  41. * @constant
  42. */
  43. DECREMENT: WebGLConstants.DECR,
  44. /**
  45. * Bitwise inverts the existing stencil buffer value.
  46. *
  47. * @type {number}
  48. * @constant
  49. */
  50. INVERT: WebGLConstants.INVERT,
  51. /**
  52. * Increments the stencil buffer value, wrapping to zero when exceeding the unsigned byte range.
  53. *
  54. * @type {number}
  55. * @constant
  56. */
  57. INCREMENT_WRAP: WebGLConstants.INCR_WRAP,
  58. /**
  59. * Decrements the stencil buffer value, wrapping to the maximum unsigned byte instead of going below zero.
  60. *
  61. * @type {number}
  62. * @constant
  63. */
  64. DECREMENT_WRAP: WebGLConstants.DECR_WRAP,
  65. };
  66. Object.freeze(StencilOperation);
  67. export default StencilOperation;