Skip to content

v8.8.0

Compare
Choose a tag to compare
@Zyie Zyie released this 11 Feb 15:43
· 8 commits to dev since this release

💾 Download

Development Build:

Production Build:

Documentation:

Changed

v8.7.3...v8.8.0

🚨 Behavior Change 🚨

Since 8.0.0 PixiJS has been incorrectly applying gradients and graphics fill textures. Instead of using normalized "local space" coordinates (0–1), gradients were using "global space" values in pixels. This was an unintended change that made working with gradients/texture fills much harder. In this release, we have changed the default behavior back to "local space" to match v7.

For anyone who needs the old behavior, you can change the default options globally or you can control it individually as all APIs now accept a textureSpace property that can be set to "global". For example:

FillGradient.defaultLinearOptions.textureSpace = 'global'
FillGradient.defaultRadialOptions.textureSpace = 'global'
// or individually
new FillGraident(0, 0, 100, 100, 'global')

GraphicsContext.defaultFillStyle.textureSpace = 'global'
GraphicsContext.defaultStrokeStyle.textureSpace = 'global'
// or individually
new Graphics().fill({ texture, textureSpace: 'global' })
new Graphics().stroke({ texture, textureSpace: 'global' })

🚨 Behavior Change 🚨

Since version 8.0.0, TilingSprite has returned negative values for tilingSprite.bounds.width and tilingSprite.bounds.height. This has been corrected in this release, and these properties now return positive values. If your code relies on bounds, you may need to adjust it accordingly.

🎁 Added

🐛 Fixed