@galacean/engine-math 1.4.15 → 1.5.0-alpha.0

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@galacean/engine-math",
3
- "version": "1.4.15",
3
+ "version": "1.5.0-alpha.0",
4
4
  "publishConfig": {
5
5
  "access": "public",
6
6
  "registry": "https://registry.npmjs.org"
package/types/Color.d.ts CHANGED
@@ -5,17 +5,17 @@ import { ICopy } from "./ICopy";
5
5
  */
6
6
  export declare class Color implements IClone<Color>, ICopy<ColorLike, Color> {
7
7
  /**
8
- * Modify a value from the gamma space to the linear space.
9
- * @param value - The value in gamma space
8
+ * Modify a value from the sRGB space to the linear space.
9
+ * @param value - The value in sRGB space
10
10
  * @returns The value in linear space
11
11
  */
12
- static gammaToLinearSpace(value: number): number;
12
+ static sRGBToLinearSpace(value: number): number;
13
13
  /**
14
- * Modify a value from the linear space to the gamma space.
14
+ * Modify a value from the linear space to the sRGB space.
15
15
  * @param value - The value in linear space
16
- * @returns The value in gamma space
16
+ * @returns The value in sRGB space
17
17
  */
18
- static linearToGammaSpace(value: number): number;
18
+ static linearToSRGBSpace(value: number): number;
19
19
  /**
20
20
  * Determines whether the specified colors are equals.
21
21
  * @param left - The first color to compare
@@ -140,11 +140,11 @@ export declare class Color implements IClone<Color>, ICopy<ColorLike, Color> {
140
140
  */
141
141
  toLinear(out: Color): Color;
142
142
  /**
143
- * Modify components (r, g, b) of this color from linear space to gamma space.
144
- * @param out - The color in gamma space
145
- * @returns The color in gamma space
143
+ * Modify components (r, g, b) of this color from linear space to sRGB space.
144
+ * @param out - The color in sRGB space
145
+ * @returns The color in sRGB space
146
146
  */
147
- toGamma(out: Color): Color;
147
+ toSRGB(out: Color): Color;
148
148
  /**
149
149
  * Gets the brightness.
150
150
  * @returns The Hue-Saturation-Brightness (HSB) saturation for this
@@ -155,6 +155,12 @@ export declare class Color implements IClone<Color>, ICopy<ColorLike, Color> {
155
155
  * @return A JSON representation of this color
156
156
  */
157
157
  toJSON(): ColorLike;
158
+ /** @deprecated Please use `sRGBToLinearSpace` instead. */
159
+ static gammaToLinearSpace(value: number): number;
160
+ /** @deprecated Please use `linearToSRGBSpace` instead. */
161
+ static linearToGammaSpace(value: number): number;
162
+ /** @deprecated Please use `toSRGB` instead. */
163
+ toGamma(out: Color): Color;
158
164
  }
159
165
  interface ColorLike {
160
166
  /** {@inheritDoc Color._r} */