Fix for Tiling Sprites that use trimmed frames. Before they would use the trimmed frame size, rather than the actual frame size. This updates generateTilingTexture to resolve it.
This commit is contained in:
parent
49c2ce1ca0
commit
661c5bc137
1 changed files with 10 additions and 2 deletions
|
@ -371,8 +371,16 @@ PIXI.TilingSprite.prototype.generateTilingTexture = function(forcePowerOfTwo)
|
|||
{
|
||||
if(isFrame)
|
||||
{
|
||||
targetWidth = frame.width;
|
||||
targetHeight = frame.height;
|
||||
if (texture.trim)
|
||||
{
|
||||
targetWidth = texture.trim.width;
|
||||
targetHeight = texture.trim.height;
|
||||
}
|
||||
else
|
||||
{
|
||||
targetWidth = frame.width;
|
||||
targetHeight = frame.height;
|
||||
}
|
||||
|
||||
newTextureRequired = true;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue