@pixi/sprite-tiling
Advanced tools
Comparing version 5.0.0-alpha.2 to 5.0.0-alpha.3
/*! | ||
* @pixi/sprite-tiling - v5.0.0-alpha.2 | ||
* Compiled Sat, 17 Mar 2018 17:48:48 UTC | ||
* @pixi/sprite-tiling - v5.0.0-alpha.3 | ||
* Compiled Tue, 03 Jul 2018 04:08:21 UTC | ||
* | ||
@@ -206,3 +206,3 @@ * @pixi/sprite-tiling is licensed under the MIT License. | ||
this._bounds.maxX = this._width * (1 - this._anchor._x); | ||
this._bounds.maxY = this._height * (1 - this._anchor._x); | ||
this._bounds.maxY = this._height * (1 - this._anchor._y); | ||
@@ -315,10 +315,19 @@ if (!rect) | ||
* @param {number} height - the height of the tiling sprite | ||
* @param {boolean} [crossorigin] - if you want to specify the cross-origin parameter | ||
* @param {number} [scaleMode=PIXI.settings.SCALE_MODE] - if you want to specify the scale mode, | ||
* see {@link PIXI.SCALE_MODES} for possible values | ||
* @param {Object} [options] - See {@link PIXI.BaseTexture}'s constructor for options. | ||
* @return {PIXI.TilingSprite} A new TilingSprite using a texture from the texture cache matching the image id | ||
*/ | ||
TilingSprite.fromImage = function fromImage (imageId, width, height, crossorigin, scaleMode) | ||
TilingSprite.fromImage = function fromImage (imageId, width, height, options) | ||
{ | ||
return new TilingSprite(Texture.fromImage(imageId, crossorigin, scaleMode), width, height); | ||
// Fallback support for crossorigin, scaleMode parameters | ||
if (options && typeof options !== 'object') | ||
{ | ||
options = { | ||
scaleMode: arguments[4], | ||
resourceOptions: { | ||
crossorigin: arguments[3], | ||
}, | ||
}; | ||
} | ||
return new TilingSprite(Texture.from(imageId, options), width, height); | ||
}; | ||
@@ -325,0 +334,0 @@ |
/*! | ||
* @pixi/sprite-tiling - v5.0.0-alpha.2 | ||
* Compiled Sat, 17 Mar 2018 17:48:48 UTC | ||
* @pixi/sprite-tiling - v5.0.0-alpha.3 | ||
* Compiled Tue, 03 Jul 2018 04:08:21 UTC | ||
* | ||
@@ -210,3 +210,3 @@ * @pixi/sprite-tiling is licensed under the MIT License. | ||
this._bounds.maxX = this._width * (1 - this._anchor._x); | ||
this._bounds.maxY = this._height * (1 - this._anchor._x); | ||
this._bounds.maxY = this._height * (1 - this._anchor._y); | ||
@@ -319,10 +319,19 @@ if (!rect) | ||
* @param {number} height - the height of the tiling sprite | ||
* @param {boolean} [crossorigin] - if you want to specify the cross-origin parameter | ||
* @param {number} [scaleMode=PIXI.settings.SCALE_MODE] - if you want to specify the scale mode, | ||
* see {@link PIXI.SCALE_MODES} for possible values | ||
* @param {Object} [options] - See {@link PIXI.BaseTexture}'s constructor for options. | ||
* @return {PIXI.TilingSprite} A new TilingSprite using a texture from the texture cache matching the image id | ||
*/ | ||
TilingSprite.fromImage = function fromImage (imageId, width, height, crossorigin, scaleMode) | ||
TilingSprite.fromImage = function fromImage (imageId, width, height, options) | ||
{ | ||
return new TilingSprite(core.Texture.fromImage(imageId, crossorigin, scaleMode), width, height); | ||
// Fallback support for crossorigin, scaleMode parameters | ||
if (options && typeof options !== 'object') | ||
{ | ||
options = { | ||
scaleMode: arguments[4], | ||
resourceOptions: { | ||
crossorigin: arguments[3], | ||
}, | ||
}; | ||
} | ||
return new TilingSprite(core.Texture.from(imageId, options), width, height); | ||
}; | ||
@@ -329,0 +338,0 @@ |
{ | ||
"name": "@pixi/sprite-tiling", | ||
"version": "5.0.0-alpha.2", | ||
"version": "5.0.0-alpha.3", | ||
"main": "lib/sprite-tiling.js", | ||
@@ -28,8 +28,8 @@ "module": "lib/sprite-tiling.es.js", | ||
"dependencies": { | ||
"@pixi/constants": "^5.0.0-alpha.2", | ||
"@pixi/core": "^5.0.0-alpha.2", | ||
"@pixi/display": "^5.0.0-alpha.2", | ||
"@pixi/math": "^5.0.0-alpha.2", | ||
"@pixi/sprite": "^5.0.0-alpha.2", | ||
"@pixi/utils": "^5.0.0-alpha.2" | ||
"@pixi/constants": "^5.0.0-alpha.3", | ||
"@pixi/core": "^5.0.0-alpha.3", | ||
"@pixi/display": "^5.0.0-alpha.3", | ||
"@pixi/math": "^5.0.0-alpha.3", | ||
"@pixi/sprite": "^5.0.0-alpha.3", | ||
"@pixi/utils": "^5.0.0-alpha.3" | ||
}, | ||
@@ -36,0 +36,0 @@ "devDependencies": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
81661
855
Updated@pixi/core@^5.0.0-alpha.3
Updated@pixi/display@^5.0.0-alpha.3
Updated@pixi/math@^5.0.0-alpha.3
Updated@pixi/sprite@^5.0.0-alpha.3
Updated@pixi/utils@^5.0.0-alpha.3