sdfsdfs
This commit is contained in:
59
node_modules/pixi.js/lib/utils/data/ViewableBuffer.d.ts
generated
vendored
Normal file
59
node_modules/pixi.js/lib/utils/data/ViewableBuffer.d.ts
generated
vendored
Normal file
@@ -0,0 +1,59 @@
|
||||
type TypedArray = Float32Array | Uint32Array | Int32Array | Uint8Array;
|
||||
/**
|
||||
* Flexible wrapper around `ArrayBuffer` that also provides typed array views on demand.
|
||||
* @memberof utils
|
||||
*/
|
||||
export declare class ViewableBuffer {
|
||||
/** The size of the buffer in bytes. */
|
||||
size: number;
|
||||
/** Underlying `ArrayBuffer` that holds all the data and is of capacity `this.size`. */
|
||||
rawBinaryData: ArrayBuffer;
|
||||
/** View on the raw binary data as a `Uint32Array`. */
|
||||
uint32View: Uint32Array;
|
||||
/** View on the raw binary data as a `Float32Array`. */
|
||||
float32View: Float32Array;
|
||||
uint16View: Uint16Array;
|
||||
private _int8View;
|
||||
private _uint8View;
|
||||
private _int16View;
|
||||
private _int32View;
|
||||
private _float64Array;
|
||||
private _bigUint64Array;
|
||||
/**
|
||||
* @param length - The size of the buffer in bytes.
|
||||
*/
|
||||
constructor(length: number);
|
||||
/**
|
||||
* @param arrayBuffer - The source array buffer.
|
||||
*/
|
||||
constructor(arrayBuffer: ArrayBuffer);
|
||||
/** View on the raw binary data as a `Int8Array`. */
|
||||
get int8View(): Int8Array;
|
||||
/** View on the raw binary data as a `Uint8Array`. */
|
||||
get uint8View(): Uint8Array;
|
||||
/** View on the raw binary data as a `Int16Array`. */
|
||||
get int16View(): Int16Array;
|
||||
/** View on the raw binary data as a `Int32Array`. */
|
||||
get int32View(): Int32Array;
|
||||
/** View on the raw binary data as a `Float64Array`. */
|
||||
get float64View(): Float64Array;
|
||||
/** View on the raw binary data as a `BigUint64Array`. */
|
||||
get bigUint64View(): BigUint64Array;
|
||||
/**
|
||||
* Returns the view of the given type.
|
||||
* @param type - One of `int8`, `uint8`, `int16`,
|
||||
* `uint16`, `int32`, `uint32`, and `float32`.
|
||||
* @returns - typed array of given type
|
||||
*/
|
||||
view(type: string): TypedArray;
|
||||
/** Destroys all buffer references. Do not use after calling this. */
|
||||
destroy(): void;
|
||||
/**
|
||||
* Returns the size of the given type in bytes.
|
||||
* @param type - One of `int8`, `uint8`, `int16`,
|
||||
* `uint16`, `int32`, `uint32`, and `float32`.
|
||||
* @returns - size of the type in bytes
|
||||
*/
|
||||
static sizeOf(type: string): number;
|
||||
}
|
||||
export {};
|
104
node_modules/pixi.js/lib/utils/data/ViewableBuffer.js
generated
vendored
Normal file
104
node_modules/pixi.js/lib/utils/data/ViewableBuffer.js
generated
vendored
Normal file
@@ -0,0 +1,104 @@
|
||||
'use strict';
|
||||
|
||||
"use strict";
|
||||
class ViewableBuffer {
|
||||
constructor(sizeOrBuffer) {
|
||||
if (typeof sizeOrBuffer === "number") {
|
||||
this.rawBinaryData = new ArrayBuffer(sizeOrBuffer);
|
||||
} else if (sizeOrBuffer instanceof Uint8Array) {
|
||||
this.rawBinaryData = sizeOrBuffer.buffer;
|
||||
} else {
|
||||
this.rawBinaryData = sizeOrBuffer;
|
||||
}
|
||||
this.uint32View = new Uint32Array(this.rawBinaryData);
|
||||
this.float32View = new Float32Array(this.rawBinaryData);
|
||||
this.size = this.rawBinaryData.byteLength;
|
||||
}
|
||||
/** View on the raw binary data as a `Int8Array`. */
|
||||
get int8View() {
|
||||
if (!this._int8View) {
|
||||
this._int8View = new Int8Array(this.rawBinaryData);
|
||||
}
|
||||
return this._int8View;
|
||||
}
|
||||
/** View on the raw binary data as a `Uint8Array`. */
|
||||
get uint8View() {
|
||||
if (!this._uint8View) {
|
||||
this._uint8View = new Uint8Array(this.rawBinaryData);
|
||||
}
|
||||
return this._uint8View;
|
||||
}
|
||||
/** View on the raw binary data as a `Int16Array`. */
|
||||
get int16View() {
|
||||
if (!this._int16View) {
|
||||
this._int16View = new Int16Array(this.rawBinaryData);
|
||||
}
|
||||
return this._int16View;
|
||||
}
|
||||
/** View on the raw binary data as a `Int32Array`. */
|
||||
get int32View() {
|
||||
if (!this._int32View) {
|
||||
this._int32View = new Int32Array(this.rawBinaryData);
|
||||
}
|
||||
return this._int32View;
|
||||
}
|
||||
/** View on the raw binary data as a `Float64Array`. */
|
||||
get float64View() {
|
||||
if (!this._float64Array) {
|
||||
this._float64Array = new Float64Array(this.rawBinaryData);
|
||||
}
|
||||
return this._float64Array;
|
||||
}
|
||||
/** View on the raw binary data as a `BigUint64Array`. */
|
||||
get bigUint64View() {
|
||||
if (!this._bigUint64Array) {
|
||||
this._bigUint64Array = new BigUint64Array(this.rawBinaryData);
|
||||
}
|
||||
return this._bigUint64Array;
|
||||
}
|
||||
/**
|
||||
* Returns the view of the given type.
|
||||
* @param type - One of `int8`, `uint8`, `int16`,
|
||||
* `uint16`, `int32`, `uint32`, and `float32`.
|
||||
* @returns - typed array of given type
|
||||
*/
|
||||
view(type) {
|
||||
return this[`${type}View`];
|
||||
}
|
||||
/** Destroys all buffer references. Do not use after calling this. */
|
||||
destroy() {
|
||||
this.rawBinaryData = null;
|
||||
this._int8View = null;
|
||||
this._uint8View = null;
|
||||
this._int16View = null;
|
||||
this.uint16View = null;
|
||||
this._int32View = null;
|
||||
this.uint32View = null;
|
||||
this.float32View = null;
|
||||
}
|
||||
/**
|
||||
* Returns the size of the given type in bytes.
|
||||
* @param type - One of `int8`, `uint8`, `int16`,
|
||||
* `uint16`, `int32`, `uint32`, and `float32`.
|
||||
* @returns - size of the type in bytes
|
||||
*/
|
||||
static sizeOf(type) {
|
||||
switch (type) {
|
||||
case "int8":
|
||||
case "uint8":
|
||||
return 1;
|
||||
case "int16":
|
||||
case "uint16":
|
||||
return 2;
|
||||
case "int32":
|
||||
case "uint32":
|
||||
case "float32":
|
||||
return 4;
|
||||
default:
|
||||
throw new Error(`${type} isn't a valid view type`);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
exports.ViewableBuffer = ViewableBuffer;
|
||||
//# sourceMappingURL=ViewableBuffer.js.map
|
1
node_modules/pixi.js/lib/utils/data/ViewableBuffer.js.map
generated
vendored
Normal file
1
node_modules/pixi.js/lib/utils/data/ViewableBuffer.js.map
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
102
node_modules/pixi.js/lib/utils/data/ViewableBuffer.mjs
generated
vendored
Normal file
102
node_modules/pixi.js/lib/utils/data/ViewableBuffer.mjs
generated
vendored
Normal file
@@ -0,0 +1,102 @@
|
||||
"use strict";
|
||||
class ViewableBuffer {
|
||||
constructor(sizeOrBuffer) {
|
||||
if (typeof sizeOrBuffer === "number") {
|
||||
this.rawBinaryData = new ArrayBuffer(sizeOrBuffer);
|
||||
} else if (sizeOrBuffer instanceof Uint8Array) {
|
||||
this.rawBinaryData = sizeOrBuffer.buffer;
|
||||
} else {
|
||||
this.rawBinaryData = sizeOrBuffer;
|
||||
}
|
||||
this.uint32View = new Uint32Array(this.rawBinaryData);
|
||||
this.float32View = new Float32Array(this.rawBinaryData);
|
||||
this.size = this.rawBinaryData.byteLength;
|
||||
}
|
||||
/** View on the raw binary data as a `Int8Array`. */
|
||||
get int8View() {
|
||||
if (!this._int8View) {
|
||||
this._int8View = new Int8Array(this.rawBinaryData);
|
||||
}
|
||||
return this._int8View;
|
||||
}
|
||||
/** View on the raw binary data as a `Uint8Array`. */
|
||||
get uint8View() {
|
||||
if (!this._uint8View) {
|
||||
this._uint8View = new Uint8Array(this.rawBinaryData);
|
||||
}
|
||||
return this._uint8View;
|
||||
}
|
||||
/** View on the raw binary data as a `Int16Array`. */
|
||||
get int16View() {
|
||||
if (!this._int16View) {
|
||||
this._int16View = new Int16Array(this.rawBinaryData);
|
||||
}
|
||||
return this._int16View;
|
||||
}
|
||||
/** View on the raw binary data as a `Int32Array`. */
|
||||
get int32View() {
|
||||
if (!this._int32View) {
|
||||
this._int32View = new Int32Array(this.rawBinaryData);
|
||||
}
|
||||
return this._int32View;
|
||||
}
|
||||
/** View on the raw binary data as a `Float64Array`. */
|
||||
get float64View() {
|
||||
if (!this._float64Array) {
|
||||
this._float64Array = new Float64Array(this.rawBinaryData);
|
||||
}
|
||||
return this._float64Array;
|
||||
}
|
||||
/** View on the raw binary data as a `BigUint64Array`. */
|
||||
get bigUint64View() {
|
||||
if (!this._bigUint64Array) {
|
||||
this._bigUint64Array = new BigUint64Array(this.rawBinaryData);
|
||||
}
|
||||
return this._bigUint64Array;
|
||||
}
|
||||
/**
|
||||
* Returns the view of the given type.
|
||||
* @param type - One of `int8`, `uint8`, `int16`,
|
||||
* `uint16`, `int32`, `uint32`, and `float32`.
|
||||
* @returns - typed array of given type
|
||||
*/
|
||||
view(type) {
|
||||
return this[`${type}View`];
|
||||
}
|
||||
/** Destroys all buffer references. Do not use after calling this. */
|
||||
destroy() {
|
||||
this.rawBinaryData = null;
|
||||
this._int8View = null;
|
||||
this._uint8View = null;
|
||||
this._int16View = null;
|
||||
this.uint16View = null;
|
||||
this._int32View = null;
|
||||
this.uint32View = null;
|
||||
this.float32View = null;
|
||||
}
|
||||
/**
|
||||
* Returns the size of the given type in bytes.
|
||||
* @param type - One of `int8`, `uint8`, `int16`,
|
||||
* `uint16`, `int32`, `uint32`, and `float32`.
|
||||
* @returns - size of the type in bytes
|
||||
*/
|
||||
static sizeOf(type) {
|
||||
switch (type) {
|
||||
case "int8":
|
||||
case "uint8":
|
||||
return 1;
|
||||
case "int16":
|
||||
case "uint16":
|
||||
return 2;
|
||||
case "int32":
|
||||
case "uint32":
|
||||
case "float32":
|
||||
return 4;
|
||||
default:
|
||||
throw new Error(`${type} isn't a valid view type`);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
export { ViewableBuffer };
|
||||
//# sourceMappingURL=ViewableBuffer.mjs.map
|
1
node_modules/pixi.js/lib/utils/data/ViewableBuffer.mjs.map
generated
vendored
Normal file
1
node_modules/pixi.js/lib/utils/data/ViewableBuffer.mjs.map
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
9
node_modules/pixi.js/lib/utils/data/removeItems.d.ts
generated
vendored
Normal file
9
node_modules/pixi.js/lib/utils/data/removeItems.d.ts
generated
vendored
Normal file
@@ -0,0 +1,9 @@
|
||||
/**
|
||||
* Remove items from a javascript array without generating garbage
|
||||
* @function removeItems
|
||||
* @memberof utils
|
||||
* @param {Array<any>} arr - Array to remove elements from
|
||||
* @param {number} startIdx - starting index
|
||||
* @param {number} removeCount - how many to remove
|
||||
*/
|
||||
export declare function removeItems(arr: any[], startIdx: number, removeCount: number): void;
|
19
node_modules/pixi.js/lib/utils/data/removeItems.js
generated
vendored
Normal file
19
node_modules/pixi.js/lib/utils/data/removeItems.js
generated
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
'use strict';
|
||||
|
||||
"use strict";
|
||||
function removeItems(arr, startIdx, removeCount) {
|
||||
const length = arr.length;
|
||||
let i;
|
||||
if (startIdx >= length || removeCount === 0) {
|
||||
return;
|
||||
}
|
||||
removeCount = startIdx + removeCount > length ? length - startIdx : removeCount;
|
||||
const len = length - removeCount;
|
||||
for (i = startIdx; i < len; ++i) {
|
||||
arr[i] = arr[i + removeCount];
|
||||
}
|
||||
arr.length = len;
|
||||
}
|
||||
|
||||
exports.removeItems = removeItems;
|
||||
//# sourceMappingURL=removeItems.js.map
|
1
node_modules/pixi.js/lib/utils/data/removeItems.js.map
generated
vendored
Normal file
1
node_modules/pixi.js/lib/utils/data/removeItems.js.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"removeItems.js","sources":["../../../src/utils/data/removeItems.ts"],"sourcesContent":["/**\n * Remove items from a javascript array without generating garbage\n * @function removeItems\n * @memberof utils\n * @param {Array<any>} arr - Array to remove elements from\n * @param {number} startIdx - starting index\n * @param {number} removeCount - how many to remove\n */\nexport function removeItems(arr: any[], startIdx: number, removeCount: number): void\n{\n const length = arr.length;\n let i;\n\n if (startIdx >= length || removeCount === 0)\n {\n return;\n }\n\n removeCount = (startIdx + removeCount > length ? length - startIdx : removeCount);\n\n const len = length - removeCount;\n\n for (i = startIdx; i < len; ++i)\n {\n arr[i] = arr[i + removeCount];\n }\n\n arr.length = len;\n}\n"],"names":[],"mappings":";;;AAQgB,SAAA,WAAA,CAAY,GAAY,EAAA,QAAA,EAAkB,WAC1D,EAAA;AACI,EAAA,MAAM,SAAS,GAAI,CAAA,MAAA,CAAA;AACnB,EAAI,IAAA,CAAA,CAAA;AAEJ,EAAI,IAAA,QAAA,IAAY,MAAU,IAAA,WAAA,KAAgB,CAC1C,EAAA;AACI,IAAA,OAAA;AAAA,GACJ;AAEA,EAAA,WAAA,GAAe,QAAW,GAAA,WAAA,GAAc,MAAS,GAAA,MAAA,GAAS,QAAW,GAAA,WAAA,CAAA;AAErE,EAAA,MAAM,MAAM,MAAS,GAAA,WAAA,CAAA;AAErB,EAAA,KAAK,CAAI,GAAA,QAAA,EAAU,CAAI,GAAA,GAAA,EAAK,EAAE,CAC9B,EAAA;AACI,IAAA,GAAA,CAAI,CAAC,CAAA,GAAI,GAAI,CAAA,CAAA,GAAI,WAAW,CAAA,CAAA;AAAA,GAChC;AAEA,EAAA,GAAA,CAAI,MAAS,GAAA,GAAA,CAAA;AACjB;;;;"}
|
17
node_modules/pixi.js/lib/utils/data/removeItems.mjs
generated
vendored
Normal file
17
node_modules/pixi.js/lib/utils/data/removeItems.mjs
generated
vendored
Normal file
@@ -0,0 +1,17 @@
|
||||
"use strict";
|
||||
function removeItems(arr, startIdx, removeCount) {
|
||||
const length = arr.length;
|
||||
let i;
|
||||
if (startIdx >= length || removeCount === 0) {
|
||||
return;
|
||||
}
|
||||
removeCount = startIdx + removeCount > length ? length - startIdx : removeCount;
|
||||
const len = length - removeCount;
|
||||
for (i = startIdx; i < len; ++i) {
|
||||
arr[i] = arr[i + removeCount];
|
||||
}
|
||||
arr.length = len;
|
||||
}
|
||||
|
||||
export { removeItems };
|
||||
//# sourceMappingURL=removeItems.mjs.map
|
1
node_modules/pixi.js/lib/utils/data/removeItems.mjs.map
generated
vendored
Normal file
1
node_modules/pixi.js/lib/utils/data/removeItems.mjs.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"removeItems.mjs","sources":["../../../src/utils/data/removeItems.ts"],"sourcesContent":["/**\n * Remove items from a javascript array without generating garbage\n * @function removeItems\n * @memberof utils\n * @param {Array<any>} arr - Array to remove elements from\n * @param {number} startIdx - starting index\n * @param {number} removeCount - how many to remove\n */\nexport function removeItems(arr: any[], startIdx: number, removeCount: number): void\n{\n const length = arr.length;\n let i;\n\n if (startIdx >= length || removeCount === 0)\n {\n return;\n }\n\n removeCount = (startIdx + removeCount > length ? length - startIdx : removeCount);\n\n const len = length - removeCount;\n\n for (i = startIdx; i < len; ++i)\n {\n arr[i] = arr[i + removeCount];\n }\n\n arr.length = len;\n}\n"],"names":[],"mappings":";AAQgB,SAAA,WAAA,CAAY,GAAY,EAAA,QAAA,EAAkB,WAC1D,EAAA;AACI,EAAA,MAAM,SAAS,GAAI,CAAA,MAAA,CAAA;AACnB,EAAI,IAAA,CAAA,CAAA;AAEJ,EAAI,IAAA,QAAA,IAAY,MAAU,IAAA,WAAA,KAAgB,CAC1C,EAAA;AACI,IAAA,OAAA;AAAA,GACJ;AAEA,EAAA,WAAA,GAAe,QAAW,GAAA,WAAA,GAAc,MAAS,GAAA,MAAA,GAAS,QAAW,GAAA,WAAA,CAAA;AAErE,EAAA,MAAM,MAAM,MAAS,GAAA,WAAA,CAAA;AAErB,EAAA,KAAK,CAAI,GAAA,QAAA,EAAU,CAAI,GAAA,GAAA,EAAK,EAAE,CAC9B,EAAA;AACI,IAAA,GAAA,CAAI,CAAC,CAAA,GAAI,GAAI,CAAA,CAAA,GAAI,WAAW,CAAA,CAAA;AAAA,GAChC;AAEA,EAAA,GAAA,CAAI,MAAS,GAAA,GAAA,CAAA;AACjB;;;;"}
|
12
node_modules/pixi.js/lib/utils/data/uid.d.ts
generated
vendored
Normal file
12
node_modules/pixi.js/lib/utils/data/uid.d.ts
generated
vendored
Normal file
@@ -0,0 +1,12 @@
|
||||
type UIDNames = 'default' | 'resource' | 'texture' | 'textureSource' | 'textureResource' | 'batcher' | 'graphicsContext' | 'graphicsView' | 'graphicsPath' | 'fillGradient' | 'fillPattern' | 'meshView' | 'renderable' | 'buffer' | 'bufferResource' | 'geometry' | 'instructionSet' | 'renderTarget' | 'uniform' | 'spriteView' | 'textView' | 'tilingSpriteView';
|
||||
/**
|
||||
* Gets the next unique identifier
|
||||
* @param name - The name of the identifier.
|
||||
* @function uid
|
||||
* @returns {number} The next unique identifier to use.
|
||||
* @memberof utils
|
||||
*/
|
||||
export declare function uid(name?: UIDNames): number;
|
||||
/** Resets the next unique identifier to 0. This is used for some tests, dont touch or things WILL explode :) */
|
||||
export declare function resetUids(): void;
|
||||
export {};
|
21
node_modules/pixi.js/lib/utils/data/uid.js
generated
vendored
Normal file
21
node_modules/pixi.js/lib/utils/data/uid.js
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
'use strict';
|
||||
|
||||
"use strict";
|
||||
const uidCache = {
|
||||
default: -1
|
||||
};
|
||||
function uid(name = "default") {
|
||||
if (uidCache[name] === void 0) {
|
||||
uidCache[name] = -1;
|
||||
}
|
||||
return ++uidCache[name];
|
||||
}
|
||||
function resetUids() {
|
||||
for (const key in uidCache) {
|
||||
delete uidCache[key];
|
||||
}
|
||||
}
|
||||
|
||||
exports.resetUids = resetUids;
|
||||
exports.uid = uid;
|
||||
//# sourceMappingURL=uid.js.map
|
1
node_modules/pixi.js/lib/utils/data/uid.js.map
generated
vendored
Normal file
1
node_modules/pixi.js/lib/utils/data/uid.js.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"uid.js","sources":["../../../src/utils/data/uid.ts"],"sourcesContent":["const uidCache: Record<string, number> = {\n default: -1,\n};\n\ntype UIDNames =\n | 'default'\n | 'resource'\n | 'texture'\n | 'textureSource'\n | 'textureResource'\n | 'batcher' //\n | 'graphicsContext' //\n | 'graphicsView' //\n | 'graphicsPath' //\n | 'fillGradient' //\n | 'fillPattern' //\n | 'meshView' //\n | 'renderable' //\n | 'buffer' //\n | 'bufferResource' //\n | 'geometry'\n | 'instructionSet' //\n | 'renderTarget' //\n | 'uniform' //\n | 'spriteView' //\n | 'textView' //\n | 'tilingSpriteView'; // ;\n\n/**\n * Gets the next unique identifier\n * @param name - The name of the identifier.\n * @function uid\n * @returns {number} The next unique identifier to use.\n * @memberof utils\n */\nexport function uid(name: UIDNames = 'default'): number\n{\n if (uidCache[name] === undefined)\n {\n uidCache[name] = -1;\n }\n\n return ++uidCache[name];\n}\n\n/** Resets the next unique identifier to 0. This is used for some tests, dont touch or things WILL explode :) */\nexport function resetUids(): void\n{\n for (const key in uidCache)\n {\n delete uidCache[key];\n }\n}\n"],"names":[],"mappings":";;;AAAA,MAAM,QAAmC,GAAA;AAAA,EACrC,OAAS,EAAA,CAAA,CAAA;AACb,CAAA,CAAA;AAiCgB,SAAA,GAAA,CAAI,OAAiB,SACrC,EAAA;AACI,EAAI,IAAA,QAAA,CAAS,IAAI,CAAA,KAAM,KACvB,CAAA,EAAA;AACI,IAAA,QAAA,CAAS,IAAI,CAAI,GAAA,CAAA,CAAA,CAAA;AAAA,GACrB;AAEA,EAAO,OAAA,EAAE,SAAS,IAAI,CAAA,CAAA;AAC1B,CAAA;AAGO,SAAS,SAChB,GAAA;AACI,EAAA,KAAA,MAAW,OAAO,QAClB,EAAA;AACI,IAAA,OAAO,SAAS,GAAG,CAAA,CAAA;AAAA,GACvB;AACJ;;;;;"}
|
18
node_modules/pixi.js/lib/utils/data/uid.mjs
generated
vendored
Normal file
18
node_modules/pixi.js/lib/utils/data/uid.mjs
generated
vendored
Normal file
@@ -0,0 +1,18 @@
|
||||
"use strict";
|
||||
const uidCache = {
|
||||
default: -1
|
||||
};
|
||||
function uid(name = "default") {
|
||||
if (uidCache[name] === void 0) {
|
||||
uidCache[name] = -1;
|
||||
}
|
||||
return ++uidCache[name];
|
||||
}
|
||||
function resetUids() {
|
||||
for (const key in uidCache) {
|
||||
delete uidCache[key];
|
||||
}
|
||||
}
|
||||
|
||||
export { resetUids, uid };
|
||||
//# sourceMappingURL=uid.mjs.map
|
1
node_modules/pixi.js/lib/utils/data/uid.mjs.map
generated
vendored
Normal file
1
node_modules/pixi.js/lib/utils/data/uid.mjs.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"uid.mjs","sources":["../../../src/utils/data/uid.ts"],"sourcesContent":["const uidCache: Record<string, number> = {\n default: -1,\n};\n\ntype UIDNames =\n | 'default'\n | 'resource'\n | 'texture'\n | 'textureSource'\n | 'textureResource'\n | 'batcher' //\n | 'graphicsContext' //\n | 'graphicsView' //\n | 'graphicsPath' //\n | 'fillGradient' //\n | 'fillPattern' //\n | 'meshView' //\n | 'renderable' //\n | 'buffer' //\n | 'bufferResource' //\n | 'geometry'\n | 'instructionSet' //\n | 'renderTarget' //\n | 'uniform' //\n | 'spriteView' //\n | 'textView' //\n | 'tilingSpriteView'; // ;\n\n/**\n * Gets the next unique identifier\n * @param name - The name of the identifier.\n * @function uid\n * @returns {number} The next unique identifier to use.\n * @memberof utils\n */\nexport function uid(name: UIDNames = 'default'): number\n{\n if (uidCache[name] === undefined)\n {\n uidCache[name] = -1;\n }\n\n return ++uidCache[name];\n}\n\n/** Resets the next unique identifier to 0. This is used for some tests, dont touch or things WILL explode :) */\nexport function resetUids(): void\n{\n for (const key in uidCache)\n {\n delete uidCache[key];\n }\n}\n"],"names":[],"mappings":";AAAA,MAAM,QAAmC,GAAA;AAAA,EACrC,OAAS,EAAA,CAAA,CAAA;AACb,CAAA,CAAA;AAiCgB,SAAA,GAAA,CAAI,OAAiB,SACrC,EAAA;AACI,EAAI,IAAA,QAAA,CAAS,IAAI,CAAA,KAAM,KACvB,CAAA,EAAA;AACI,IAAA,QAAA,CAAS,IAAI,CAAI,GAAA,CAAA,CAAA,CAAA;AAAA,GACrB;AAEA,EAAO,OAAA,EAAE,SAAS,IAAI,CAAA,CAAA;AAC1B,CAAA;AAGO,SAAS,SAChB,GAAA;AACI,EAAA,KAAA,MAAW,OAAO,QAClB,EAAA;AACI,IAAA,OAAO,SAAS,GAAG,CAAA,CAAA;AAAA,GACvB;AACJ;;;;"}
|
4
node_modules/pixi.js/lib/utils/data/updateQuadBounds.d.ts
generated
vendored
Normal file
4
node_modules/pixi.js/lib/utils/data/updateQuadBounds.d.ts
generated
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
import type { ObservablePoint } from '../../maths/point/ObservablePoint';
|
||||
import type { Texture } from '../../rendering/renderers/shared/texture/Texture';
|
||||
import type { BoundsData } from '../../scene/container/bounds/Bounds';
|
||||
export declare function updateQuadBounds(bounds: BoundsData, anchor: ObservablePoint, texture: Texture, padding: number): void;
|
24
node_modules/pixi.js/lib/utils/data/updateQuadBounds.js
generated
vendored
Normal file
24
node_modules/pixi.js/lib/utils/data/updateQuadBounds.js
generated
vendored
Normal file
@@ -0,0 +1,24 @@
|
||||
'use strict';
|
||||
|
||||
"use strict";
|
||||
function updateQuadBounds(bounds, anchor, texture, padding) {
|
||||
const { width, height } = texture.orig;
|
||||
const trim = texture.trim;
|
||||
if (trim) {
|
||||
const sourceWidth = trim.width;
|
||||
const sourceHeight = trim.height;
|
||||
bounds.minX = trim.x - anchor._x * width - padding;
|
||||
bounds.maxX = bounds.minX + sourceWidth;
|
||||
bounds.minY = trim.y - anchor._y * height - padding;
|
||||
bounds.maxY = bounds.minY + sourceHeight;
|
||||
} else {
|
||||
bounds.minX = -anchor._x * width - padding;
|
||||
bounds.maxX = bounds.minX + width;
|
||||
bounds.minY = -anchor._y * height - padding;
|
||||
bounds.maxY = bounds.minY + height;
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
exports.updateQuadBounds = updateQuadBounds;
|
||||
//# sourceMappingURL=updateQuadBounds.js.map
|
1
node_modules/pixi.js/lib/utils/data/updateQuadBounds.js.map
generated
vendored
Normal file
1
node_modules/pixi.js/lib/utils/data/updateQuadBounds.js.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"updateQuadBounds.js","sources":["../../../src/utils/data/updateQuadBounds.ts"],"sourcesContent":["import type { ObservablePoint } from '../../maths/point/ObservablePoint';\nimport type { Texture } from '../../rendering/renderers/shared/texture/Texture';\nimport type { BoundsData } from '../../scene/container/bounds/Bounds';\n\nexport function updateQuadBounds(\n bounds: BoundsData,\n anchor: ObservablePoint,\n texture: Texture,\n padding: number\n)\n{\n const { width, height } = texture.orig;\n const trim = texture.trim;\n\n if (trim)\n {\n const sourceWidth = trim.width;\n const sourceHeight = trim.height;\n\n bounds.minX = (trim.x) - (anchor._x * width) - padding;\n bounds.maxX = bounds.minX + sourceWidth;\n\n bounds.minY = (trim.y) - (anchor._y * height) - padding;\n bounds.maxY = bounds.minY + sourceHeight;\n }\n\n else\n {\n bounds.minX = (-anchor._x * width) - padding;\n bounds.maxX = bounds.minX + width;\n\n bounds.minY = (-anchor._y * height) - padding;\n bounds.maxY = bounds.minY + height;\n }\n\n return;\n}\n"],"names":[],"mappings":";;;AAIO,SAAS,gBACZ,CAAA,MAAA,EACA,MACA,EAAA,OAAA,EACA,OAEJ,EAAA;AACI,EAAA,MAAM,EAAE,KAAA,EAAO,MAAO,EAAA,GAAI,OAAQ,CAAA,IAAA,CAAA;AAClC,EAAA,MAAM,OAAO,OAAQ,CAAA,IAAA,CAAA;AAErB,EAAA,IAAI,IACJ,EAAA;AACI,IAAA,MAAM,cAAc,IAAK,CAAA,KAAA,CAAA;AACzB,IAAA,MAAM,eAAe,IAAK,CAAA,MAAA,CAAA;AAE1B,IAAA,MAAA,CAAO,IAAQ,GAAA,IAAA,CAAK,CAAM,GAAA,MAAA,CAAO,KAAK,KAAS,GAAA,OAAA,CAAA;AAC/C,IAAO,MAAA,CAAA,IAAA,GAAO,OAAO,IAAO,GAAA,WAAA,CAAA;AAE5B,IAAA,MAAA,CAAO,IAAQ,GAAA,IAAA,CAAK,CAAM,GAAA,MAAA,CAAO,KAAK,MAAU,GAAA,OAAA,CAAA;AAChD,IAAO,MAAA,CAAA,IAAA,GAAO,OAAO,IAAO,GAAA,YAAA,CAAA;AAAA,GAIhC,MAAA;AACI,IAAA,MAAA,CAAO,IAAQ,GAAA,CAAC,MAAO,CAAA,EAAA,GAAK,KAAS,GAAA,OAAA,CAAA;AACrC,IAAO,MAAA,CAAA,IAAA,GAAO,OAAO,IAAO,GAAA,KAAA,CAAA;AAE5B,IAAA,MAAA,CAAO,IAAQ,GAAA,CAAC,MAAO,CAAA,EAAA,GAAK,MAAU,GAAA,OAAA,CAAA;AACtC,IAAO,MAAA,CAAA,IAAA,GAAO,OAAO,IAAO,GAAA,MAAA,CAAA;AAAA,GAChC;AAEA,EAAA,OAAA;AACJ;;;;"}
|
22
node_modules/pixi.js/lib/utils/data/updateQuadBounds.mjs
generated
vendored
Normal file
22
node_modules/pixi.js/lib/utils/data/updateQuadBounds.mjs
generated
vendored
Normal file
@@ -0,0 +1,22 @@
|
||||
"use strict";
|
||||
function updateQuadBounds(bounds, anchor, texture, padding) {
|
||||
const { width, height } = texture.orig;
|
||||
const trim = texture.trim;
|
||||
if (trim) {
|
||||
const sourceWidth = trim.width;
|
||||
const sourceHeight = trim.height;
|
||||
bounds.minX = trim.x - anchor._x * width - padding;
|
||||
bounds.maxX = bounds.minX + sourceWidth;
|
||||
bounds.minY = trim.y - anchor._y * height - padding;
|
||||
bounds.maxY = bounds.minY + sourceHeight;
|
||||
} else {
|
||||
bounds.minX = -anchor._x * width - padding;
|
||||
bounds.maxX = bounds.minX + width;
|
||||
bounds.minY = -anchor._y * height - padding;
|
||||
bounds.maxY = bounds.minY + height;
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
export { updateQuadBounds };
|
||||
//# sourceMappingURL=updateQuadBounds.mjs.map
|
1
node_modules/pixi.js/lib/utils/data/updateQuadBounds.mjs.map
generated
vendored
Normal file
1
node_modules/pixi.js/lib/utils/data/updateQuadBounds.mjs.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"updateQuadBounds.mjs","sources":["../../../src/utils/data/updateQuadBounds.ts"],"sourcesContent":["import type { ObservablePoint } from '../../maths/point/ObservablePoint';\nimport type { Texture } from '../../rendering/renderers/shared/texture/Texture';\nimport type { BoundsData } from '../../scene/container/bounds/Bounds';\n\nexport function updateQuadBounds(\n bounds: BoundsData,\n anchor: ObservablePoint,\n texture: Texture,\n padding: number\n)\n{\n const { width, height } = texture.orig;\n const trim = texture.trim;\n\n if (trim)\n {\n const sourceWidth = trim.width;\n const sourceHeight = trim.height;\n\n bounds.minX = (trim.x) - (anchor._x * width) - padding;\n bounds.maxX = bounds.minX + sourceWidth;\n\n bounds.minY = (trim.y) - (anchor._y * height) - padding;\n bounds.maxY = bounds.minY + sourceHeight;\n }\n\n else\n {\n bounds.minX = (-anchor._x * width) - padding;\n bounds.maxX = bounds.minX + width;\n\n bounds.minY = (-anchor._y * height) - padding;\n bounds.maxY = bounds.minY + height;\n }\n\n return;\n}\n"],"names":[],"mappings":";AAIO,SAAS,gBACZ,CAAA,MAAA,EACA,MACA,EAAA,OAAA,EACA,OAEJ,EAAA;AACI,EAAA,MAAM,EAAE,KAAA,EAAO,MAAO,EAAA,GAAI,OAAQ,CAAA,IAAA,CAAA;AAClC,EAAA,MAAM,OAAO,OAAQ,CAAA,IAAA,CAAA;AAErB,EAAA,IAAI,IACJ,EAAA;AACI,IAAA,MAAM,cAAc,IAAK,CAAA,KAAA,CAAA;AACzB,IAAA,MAAM,eAAe,IAAK,CAAA,MAAA,CAAA;AAE1B,IAAA,MAAA,CAAO,IAAQ,GAAA,IAAA,CAAK,CAAM,GAAA,MAAA,CAAO,KAAK,KAAS,GAAA,OAAA,CAAA;AAC/C,IAAO,MAAA,CAAA,IAAA,GAAO,OAAO,IAAO,GAAA,WAAA,CAAA;AAE5B,IAAA,MAAA,CAAO,IAAQ,GAAA,IAAA,CAAK,CAAM,GAAA,MAAA,CAAO,KAAK,MAAU,GAAA,OAAA,CAAA;AAChD,IAAO,MAAA,CAAA,IAAA,GAAO,OAAO,IAAO,GAAA,YAAA,CAAA;AAAA,GAIhC,MAAA;AACI,IAAA,MAAA,CAAO,IAAQ,GAAA,CAAC,MAAO,CAAA,EAAA,GAAK,KAAS,GAAA,OAAA,CAAA;AACrC,IAAO,MAAA,CAAA,IAAA,GAAO,OAAO,IAAO,GAAA,KAAA,CAAA;AAE5B,IAAA,MAAA,CAAO,IAAQ,GAAA,CAAC,MAAO,CAAA,EAAA,GAAK,MAAU,GAAA,OAAA,CAAA;AACtC,IAAO,MAAA,CAAA,IAAA,GAAO,OAAO,IAAO,GAAA,MAAA,CAAA;AAAA,GAChC;AAEA,EAAA,OAAA;AACJ;;;;"}
|
Reference in New Issue
Block a user