@woosh/meep-engine 2.98.0 → 2.98.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/build/meep.cjs +33 -10
  2. package/build/meep.min.js +1 -1
  3. package/build/meep.module.js +33 -10
  4. package/package.json +1 -1
  5. package/src/core/collection/set/compute_set_difference.d.ts.map +1 -1
  6. package/src/core/collection/set/compute_set_difference.js +8 -0
  7. package/src/core/collection/set/compute_set_difference.spec.d.ts +2 -0
  8. package/src/core/collection/set/compute_set_difference.spec.d.ts.map +1 -0
  9. package/src/core/collection/set/compute_set_difference.spec.js +45 -0
  10. package/src/core/collection/set/compute_set_intersection.d.ts +1 -0
  11. package/src/core/collection/set/compute_set_intersection.d.ts.map +1 -1
  12. package/src/core/collection/set/compute_set_intersection.js +9 -0
  13. package/src/core/collection/set/compute_set_intersection.spec.d.ts +2 -0
  14. package/src/core/collection/set/compute_set_intersection.spec.d.ts.map +1 -0
  15. package/src/core/collection/set/compute_set_intersection.spec.js +45 -0
  16. package/src/core/collection/set/set_remove.d.ts +2 -0
  17. package/src/core/collection/set/set_remove.d.ts.map +1 -1
  18. package/src/core/collection/set/set_remove.js +2 -0
  19. package/src/core/color/oklab/XYZ.spec.d.ts +2 -0
  20. package/src/core/color/oklab/XYZ.spec.d.ts.map +1 -0
  21. package/src/core/color/oklab/XYZ.spec.js +17 -0
  22. package/src/core/color/oklab/oklab_to_xyz.d.ts +9 -0
  23. package/src/core/color/oklab/oklab_to_xyz.d.ts.map +1 -0
  24. package/src/core/color/oklab/oklab_to_xyz.js +32 -0
  25. package/src/core/color/oklab/oklab_to_xyz.spec.d.ts +2 -0
  26. package/src/core/color/oklab/oklab_to_xyz.spec.d.ts.map +1 -0
  27. package/src/core/color/oklab/oklab_to_xyz.spec.js +31 -0
  28. package/src/core/color/oklab/xyz_to_oklab.d.ts +8 -0
  29. package/src/core/color/oklab/xyz_to_oklab.d.ts.map +1 -0
  30. package/src/core/color/oklab/xyz_to_oklab.js +29 -0
  31. package/src/core/color/oklab/xyz_to_oklab.spec.d.ts +2 -0
  32. package/src/core/color/oklab/xyz_to_oklab.spec.d.ts.map +1 -0
  33. package/src/core/color/oklab/xyz_to_oklab.spec.js +31 -0
  34. package/src/core/color/sRGB/linear_to_sRGB.d.ts.map +1 -1
  35. package/src/core/color/sRGB/linear_to_sRGB.js +16 -5
  36. package/src/core/color/sRGB/sRGB_to_linear.d.ts.map +1 -1
  37. package/src/core/color/sRGB/sRGB_to_linear.js +17 -5
  38. package/src/core/color/xyz/rgb_to_xyz.d.ts +1 -0
  39. package/src/core/color/xyz/rgb_to_xyz.d.ts.map +1 -1
  40. package/src/core/color/xyz/rgb_to_xyz.js +4 -3
  41. package/src/core/color/xyz/xyz_to_rgb.d.ts +1 -1
  42. package/src/core/color/xyz/xyz_to_rgb.js +4 -4
  43. package/src/core/color/hsluv/HSLuv.d.ts +0 -13
  44. package/src/core/color/hsluv/HSLuv.d.ts.map +0 -1
  45. package/src/core/color/hsluv/HSLuv.js +0 -187
package/build/meep.cjs CHANGED
@@ -53633,7 +53633,11 @@ function rgb2uint24(r, g, b) {
53633
53633
  }
53634
53634
 
53635
53635
  function convert(c) {
53636
- return (c < 0.0031308) ? c * 12.92 : 1.055 * (Math.pow(c, 0.41666)) - 0.055;
53636
+ if (c < 0.0031308) {
53637
+ return c * 12.92;
53638
+ } else {
53639
+ return 1.055 * (Math.pow(c, 0.4166666666666667)) - 0.055;
53640
+ }
53637
53641
  }
53638
53642
 
53639
53643
  /**
@@ -53643,10 +53647,17 @@ function convert(c) {
53643
53647
  * @param {number[]|ArrayLike<number>} input
53644
53648
  * @param {number} input_offset
53645
53649
  */
53646
- function linear_to_sRGB(output, output_offset, input, input_offset) {
53647
- output[output_offset] = convert(input[input_offset]);
53648
- output[output_offset + 1] = convert(input[input_offset + 1]);
53649
- output[output_offset + 2] = convert(input[input_offset + 2]);
53650
+ function linear_to_sRGB(
53651
+ output, output_offset,
53652
+ input, input_offset
53653
+ ) {
53654
+ const r = input[input_offset];
53655
+ const g = input[input_offset + 1];
53656
+ const b = input[input_offset + 2];
53657
+
53658
+ output[output_offset] = convert(r);
53659
+ output[output_offset + 1] = convert(g);
53660
+ output[output_offset + 2] = convert(b);
53650
53661
  }
53651
53662
 
53652
53663
  /**
@@ -53655,7 +53666,11 @@ function linear_to_sRGB(output, output_offset, input, input_offset) {
53655
53666
  * @return {number|number}
53656
53667
  */
53657
53668
  function convert_channel_sRGB_to_linear(c) {
53658
- return (c < 0.04045) ? c * 0.0773993808 : Math.pow(c * 0.9478672986 + 0.0521327014, 2.4);
53669
+ if (c < 0.04045) {
53670
+ return c * 0.0773993808;
53671
+ } else {
53672
+ return Math.pow(c * 0.9478672986 + 0.0521327014, 2.4);
53673
+ }
53659
53674
  }
53660
53675
 
53661
53676
  /**
@@ -53665,10 +53680,18 @@ function convert_channel_sRGB_to_linear(c) {
53665
53680
  * @param {number[]} input
53666
53681
  * @param {number} input_offset
53667
53682
  */
53668
- function sRGB_to_linear(output, output_offset, input, input_offset) {
53669
- output[output_offset] = convert_channel_sRGB_to_linear(input[input_offset]);
53670
- output[output_offset + 1] = convert_channel_sRGB_to_linear(input[input_offset + 1]);
53671
- output[output_offset + 2] = convert_channel_sRGB_to_linear(input[input_offset + 2]);
53683
+ function sRGB_to_linear(
53684
+ output, output_offset,
53685
+ input, input_offset
53686
+ ) {
53687
+
53688
+ const sR = input[input_offset];
53689
+ const sG = input[input_offset + 1];
53690
+ const sB = input[input_offset + 2];
53691
+
53692
+ output[output_offset] = convert_channel_sRGB_to_linear(sR);
53693
+ output[output_offset + 1] = convert_channel_sRGB_to_linear(sG);
53694
+ output[output_offset + 2] = convert_channel_sRGB_to_linear(sB);
53672
53695
  }
53673
53696
 
53674
53697
  /**