-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add PixiJS v8 support to spine (#2641)
* add v8 support to spine! * Renamed examples folder for consistency. * Gitignore dist. * Tsconfig. * Package json. * Modification due to strictNullChecks=true. * Run tsfmt. * Use clipper.clipTriangles not deprecated version. * Aligned example to spine-pixi (v7). * Fix clipping dark tint wrong param. * Removed useless clipper. * Push texture issue repro example * fix attachment.uvs by copying them * SlotObject alpha connected to skeleton and slot alpha. * add topology for future v8 release * Dark tint rendered is enabled if at least one slot has dark tint, or by configuration. Fixed clipping while using dark tint. * Optimized clipping by using clipTrianglesUnpacked. * Repro example for clipping issue. * Aligned constructor and from signature of spine-pixi(-v7) to v8. Deprecated old signatures. * Removed useless function. * Fixed clipping issue flagging attachment as dirty if indices change. * Clipping attachments clip slot object through Pixi Graphics masks. * Add autoUpdate in SpineFromOptions * Added javadoc to pixiv8 * Updated pixi7 examples to use SpineFromOptions interface * Aligned atlas loader to use texturePreference for bundles. * Add pool to manage slot objects masks * Fixed minor issues with SpineDebugRenderer * Aligned spine-pixi-v8 with latest spine-core * Updated build and publish script --------- Co-authored-by: Davide Tantillo <[email protected]>
- Loading branch information
1 parent
b610bd7
commit ecbe9b0
Showing
111 changed files
with
38,050 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,15 +10,16 @@ up into multiple modules: | |
1. `spine-threejs/`, a self-contained [THREE.JS](https://threejs.org/) backend, built on the core classes. | ||
1. `spine-player/`, a self-contained player to easily display Spine animations on your website, built on the core classes and WebGL backend. | ||
1. `spine-phaser/`, a [Phaser](https://phaser.io/) backend, built on the core classes. | ||
1. `spine-pixi/`, a [PixiJS](https://pixijs.com/) backend, built on the core classes. | ||
1. `spine-pixi/`, a [PixiJS v7](https://pixijs.com/) backend, built on the core classes. | ||
1. `spine-pixi-v8/`, a [PixiJS v8](https://pixijs.com/) backend, built on the core classes. | ||
|
||
In most cases, the `spine-player` module is best suited for your needs. Please refer to the [Spine Web Player documentation](https://esotericsoftware.com/spine-player) for more information. | ||
|
||
For documentation of the core API in `spine-core`, please refer to our [Spine Runtimes Guide](http://esotericsoftware.com/spine-runtimes-guide). | ||
|
||
For documentation of `spine-phaser`, please refer to our [spine-phaser Guide](https://esotericsoftware.com/spine-phaser). | ||
|
||
For documentation of `spine-pixi`, please refer to our [spine-pixi Guide](https://esotericsoftware.com/spine-pixi). | ||
For documentation of `spine-pixi` and `spine-pixi`, please refer to our [spine-pixi Guide](https://esotericsoftware.com/spine-pixi). | ||
|
||
For documentation of `spine-canvaskit`, please refer to our [spine-canvaskit Guide](https://esotericsoftware.com/spine-canvaskit). | ||
|
||
|
@@ -79,6 +80,9 @@ You can include a module in your project via a `<script>` tag from the [unpkg](h | |
// spine-pixi | ||
<script src="https://unpkg.com/@esotericsoftware/[email protected].*/dist/iife/spine-pixi.js"></script> | ||
// spine-pixi-v8 | ||
<script src="https://unpkg.com/@esotericsoftware/[email protected].*/dist/iife/spine-pixi-v8.js"></script> | ||
``` | ||
|
||
We also provide `js.map` source maps. They will be automatically fetched from unpkg when debugging code of a spine-module in Chrome, Firefox, or Safari, mapping the JavaScript code back to its original TypeScript sources. | ||
|
@@ -98,6 +102,7 @@ npm install @esotericsoftware/spine-player | |
npm install @esotericsoftware/spine-threejs | ||
npm install @esotericsoftware/spine-phaser | ||
npm install @esotericsoftware/spine-pixi | ||
npm install @esotericsoftware/spine-pixi-v8 | ||
``` | ||
|
||
spine-ts modules are provided in the [ECMAScript format](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Modules), which can be consumed natively by all modern browsers, or bundled by tools like [webpack](https://webpack.js.org/), [Babel](https://babeljs.io/), [Parcel](https://parceljs.org/), or [esbuild](https://esbuild.github.io/). You can import functions and classes from a spine-ts module in your JavaScript or TypeScript code using the `import` syntax to get access to all exported constants, functions, and classes of a module: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,6 +21,7 @@ then | |
spine-player/dist/iife/* \ | ||
spine-threejs/dist/iife/* \ | ||
spine-pixi/dist/iife/* \ | ||
spine-pixi-v8/dist/iife/* \ | ||
spine-phaser/dist/iife/* \ | ||
spine-player/css/spine-player.css | ||
curl -f -F "[email protected]" "$TS_UPDATE_URL$BRANCH" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# spine-ts Pixi.js v8 | ||
|
||
Please see the top-level [README.md](../README.md) for more information. |
Oops, something went wrong.