Commit Graph

1217 Commits

Author SHA1 Message Date
renovate[bot] 8b8d028816 chore: Bump wgpu to 0.19.3, naga to 0.19.2 2024-03-01 23:58:50 +01:00
renovate[bot] 6e84b05b66 fix(deps): update rust dependencies 2024-03-01 22:46:32 +01:00
TÖRÖK Attila 10fa4175c4 chore: Bump jpegxr and nellymoser-rs git references 2024-03-01 21:54:18 +01:00
Kamil Jarosz a0f2941a2e desktop: Update winit to 0.29.12
This fixes critical crashes on X11
2024-03-01 12:10:37 +01:00
Tom Schuster a03355458f desktop: Add gamepad support using gilrs 2024-02-28 21:21:09 +01:00
Kamil Jarosz f6907a5c73 desktop: Add tests for connect_socket
Add tests for ExternalNavigatorBackend::connect_socket.
2024-02-28 19:42:54 +01:00
Aaron Hill 3e99dd3999 core: Use latest fluent-templates `master` for reproducible builds 2024-02-27 21:36:28 -05:00
TÖRÖK Attila e56a4597cc desktop: chore: Update winit to 0.29.11 2024-02-27 22:43:59 +01:00
renovate[bot] 9cdb2f31cc fix(deps): update rust dependencies 2024-02-26 08:14:26 +01:00
TÖRÖK Attila 2ffebcfc8a chore: Run `cargo update` 2024-02-21 00:18:38 +01:00
renovate[bot] 6b89737093 fix(deps): update rust dependencies 2024-02-19 11:32:22 +01:00
Tom Schuster ba7c9a4e31 avm2: Always serialize as ECMAArray, which produces an AMF0 MixedArray 2024-02-19 10:13:18 +01:00
renovate[bot] 637b277481 web: chore: Bump wasm-bindgen to 0.2.91 2024-02-16 09:48:30 +01:00
renovate[bot] 1651b7a5b0 desktop: chore: Update `egui` to 0.26.2 2024-02-16 01:52:41 +01:00
TÖRÖK Attila 28c380cfac desktop: Update egui to 0.26.0 2024-02-05 19:05:10 +01:00
renovate[bot] 477440d387 fix(deps): update rust dependencies 2024-02-05 07:56:07 +01:00
renovate[bot] c044f57bc1 chore(deps): update rust crate naga_oil to 0.13.0 2024-02-04 20:50:19 -05:00
Kamil Jarosz 4154a0945d text: Implement advanced horizontal text controls for EditText 2024-02-01 20:18:29 +01:00
Aaron Hill 78873e3670 avm2: Add new 'stub-report' binary crate
This writes the AVM2 stub report to the specified path.
2024-01-31 20:22:06 -05:00
renovate[bot] 3737725a21 fix(deps): update rust dependencies 2024-01-30 09:23:15 +01:00
Nathan Adams fcb74d8fbc wgpu: Deduplicate common gradients from a single Mesh 2024-01-27 21:37:22 +01:00
Nathan Adams ab404bae2a wgpu: Remove ouroboros and typed-arena, no longer needed 2024-01-27 21:37:22 +01:00
David Wendt 91dd9563bb core: Add method to read downloads in chunks instead of all-at-once. 2024-01-25 23:24:09 -07:00
sleepycatcoding 88f8020e54 chore: Run `cargo update` to bump patch versions in `Cargo.lock`
Should fix https://github.com/ruffle-rs/ruffle/actions/runs/7611140142/job/20725992433

Changes:
```
Updating git repository `https://github.com/emilk/egui`
Updating crates.io index
Updating git repository `https://github.com/ruffle-rs/rust-flash-lso`
Updating git repository `https://github.com/ruffle-rs/jpegxr`
Updating git repository `https://github.com/ruffle-rs/nellymoser`
Updating git repository `https://github.com/ruffle-rs/h263-rs`
Updating git repository `https://github.com/ruffle-rs/nihav-vp6`
Updating openssl-sys v0.9.98 -> v0.9.99
Updating rustfft v6.1.0 -> v6.2.0
Updating shlex v1.2.0 -> v1.3.0
Updating weezl v0.1.7 -> v0.1.8
Updating wide v0.7.13 -> v0.7.14
```
2024-01-22 14:25:14 +01:00
renovate[bot] 262dff83a4 fix(deps): update rust dependencies 2024-01-22 03:09:33 +01:00
TÖRÖK Attila 733459a296 chore: Switch to wgpu 0.19.1 from git 2024-01-22 01:51:07 +01:00
Nathan Adams 8c6f8231d6 deps: Use wgpu by commit, for DX12 fix 2024-01-21 19:36:08 +01:00
Nathan Adams 4d16e24889 wgpu: Update wgpu and naga to 0.19 2024-01-21 19:36:08 +01:00
Nathan Adams d717f92403 tests: Don't set logger in test framework, it's the responsibility of the caller 2024-01-18 16:07:24 +01:00
Nathan Adams f65060e8c9 desktop: Update winit to 0.29.10 and egui to 0.25.0 2024-01-16 21:10:36 +01:00
zhenghaoz 5169d9db3d avm2: Fix multiply with overflow in `string_to_f64` 2024-01-15 23:44:14 -05:00
renovate[bot] 3c115238fd fix(deps): update rust dependencies 2024-01-16 01:13:38 +01:00
renovate[bot] e0a22b56ce fix(deps): update wasm-bindgen 2024-01-15 17:24:02 -05:00
Aaron Hill 2557d14678 Bump jpegxr dependency for wasm ABI bugfix
This fixes a crash when loading an ATF 'compressed alpha'
texture under wasm. The rust-side jpegxr wrapper was calling
C functions that trigger a WASM ABI bug.

See d49988f40f
for more details
2024-01-14 00:59:19 +01:00
Nathan Adams 7e4ac986f2 core: Add FontFace struct, for loading a Font from a file binary 2024-01-08 23:00:18 +01:00
renovate[bot] a328deab11 fix(deps): update rust dependencies 2024-01-08 02:59:04 +01:00
TÖRÖK Attila f0ed5c7211 chore: Upgrade gc-arena to 0.5.0 2024-01-06 09:45:35 +01:00
renovate[bot] c47962fc71 fix(deps): update rust crate syn to 2.0.44 2024-01-01 04:29:05 +01:00
renovate[bot] 6a0a35c370 fix(deps): update rust dependencies 2024-01-01 02:44:40 +01:00
renovate[bot] 91d0520a43 fix(deps): update rust dependencies 2024-01-01 02:03:54 +01:00
TÖRÖK Attila 061b7f9904 chore: Run `cargo update` to bump patch versions in `Cargo.lock`
Changes:

    Updating git repository `https://github.com/gfx-rs/wgpu`
    Updating crates.io index
    Updating git repository `https://github.com/ruffle-rs/rust-flash-lso`
    Updating git repository `https://github.com/ruffle-rs/jpegxr`
    Updating git repository `https://github.com/ruffle-rs/nellymoser`
    Updating git repository `https://github.com/kyren/gc-arena`
    Updating git repository `https://github.com/ruffle-rs/h263-rs`
    Updating git repository `https://github.com/ruffle-rs/nihav-vp6`
    Updating crossbeam-channel v0.5.9 -> v0.5.10
    Updating crossbeam-epoch v0.9.16 -> v0.9.17
    Updating crossbeam-utils v0.8.17 -> v0.8.18
    Updating event-listener v4.0.0 -> v4.0.1
    Updating fdeflate v0.3.1 -> v0.3.2
    Updating linkme v0.3.19 -> v0.3.20
    Updating linkme-impl v0.3.19 -> v0.3.20
    Updating mach2 v0.4.1 -> v0.4.2
    Updating memmap2 v0.9.2 -> v0.9.3
    Removing memoffset v0.9.0
    Updating object v0.32.1 -> v0.32.2
    Updating openssl-sys v0.9.97 -> v0.9.98
    Updating pkg-config v0.3.27 -> v0.3.28
    Updating profiling v1.0.12 -> v1.0.13
    Updating profiling-procmacros v1.0.12 -> v1.0.13
    Updating self_cell v1.0.2 -> v1.0.3
    Updating serde_spanned v0.6.4 -> v0.6.5
    Updating thiserror v1.0.51 -> v1.0.52
    Updating thiserror-impl v1.0.51 -> v1.0.52
    Updating time v0.3.30 -> v0.3.31
    Updating time-macros v0.2.15 -> v0.2.16
    Updating winnow v0.5.28 -> v0.5.30
    Updating zerocopy v0.7.31 -> v0.7.32
    Updating zerocopy-derive v0.7.31 -> v0.7.32
2023-12-26 17:47:12 +01:00
renovate[bot] 216a8f3b14 fix(deps): update rust dependencies 2023-12-25 10:09:07 +01:00
TÖRÖK Attila f5f8962ce1 chore: Update naga to 0.14.2, run `cargo update` 2023-12-18 17:07:16 -05:00
renovate[bot] 0e5ef32654 fix(deps): update rust dependencies 2023-12-18 08:16:28 +01:00
Aaron Hill 287ca8801a avm2: Implement AIR playerglobal versioning
This builds on our existing playerglobal versioning support
to add in AIR versioning. We closely follow the avmplus implementation:

* When an SWF is loaded, we chose either a FlashPlayer or AIR
APIVersion for its SWF version, based on our configured player runtime.
* When loading playerglobals, we look at the player runtime. In AIR
  mode, we map FlashPlayer-versioned definitions to the closest AIR
  version. This ensures that all runtime APIVersions are in the
  same series (either AIR or FlashPlayer). In FlashPlayer mode,
  all AIR-versioned definitions get mapped to VM_INTERNAL, hiding
  them from user code.

Part of our existing api versioning code was implemented incorrectly.
Within playerglobals, we need to treat all unmarked namespaces as
VM_INTERNAL - this allows things like playerglobal script
initializer "initproperty" opcodes to see any VM_INTERNAL AIR
definitions (when we run under FlashPlayer mode). Previously, we
were using AllVersions, which would result in those VM_INTERNAL
definitions being hidden from other playerglobal code, which is
not correct.

Using this support, I've added a stub for the AIR-only
'flash.net.DatagramSocket'. I've also extended the test framework
with a new 'player_options.runtime' config option, which can be
set to "AIR" or "FlashPlayer" to configure the test runtime mode.

I've also added two new tests:
* 'air_hidden_lookup' runs under the FlashPlayer runtime, and verifies
  that a list of classes (currently just "DatagramSocket" are
  inacessible).
* 'air_datagram_socket', which uses `player_options.runtime = "AIR"`
  to construct an instance of `flash.net.DatagramSocket`. We can
  extend this test once we implement more of `DatagramSocket`

With this commit, we have all of the needed infrastructure to start
implementing and testing AIR-only classes and methods.
2023-12-16 19:11:50 -05:00
dependabot[bot] e39fc86ee5 build(deps): bump zerocopy from 0.7.30 to 0.7.31
Bumps [zerocopy](https://github.com/google/zerocopy) from 0.7.30 to 0.7.31.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google/zerocopy/compare/v0.7.30...v0.7.31)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-12-15 07:20:50 +01:00
TÖRÖK Attila bf9cf92af8 render/wgpu: Update wgpu to 0.18.0, naga to 0.14.1, naga_oil to 0.11.0, egui to 0.24.1 2023-12-14 01:36:42 +01:00
TÖRÖK Attila 430f69de7b chore: Run `cargo update` 2023-12-13 22:01:02 +01:00
renovate[bot] 3a033f0f28 fix(deps): update rust dependencies 2023-12-11 15:51:12 +01:00
renovate[bot] e196a544dd fix(deps): update rust crate bitstream-io to v2 2023-12-11 11:25:12 +01:00
bi4k8 4d07e43bc4
desktop: Add "wayland-data-control" feature for arboard
This fixes a crash on start when running under Wayland.
2023-12-11 10:08:15 +00:00
renovate[bot] 40b92e69f7 fix(deps): update rust dependencies 2023-12-05 21:08:16 +01:00
renovate[bot] a0c33382bf fix(deps): update wasm-bindgen 2023-12-04 12:08:22 +01:00
TÖRÖK Attila 4c8a5714b8 chore: Bump `tracing-tracy` to 0.10.4 to match `profiling`
And avoid "span! without a running Client" errors due to
duplicate `tracy-client` dependency.
2023-11-29 13:11:07 +01:00
TÖRÖK Attila ca25f82900 chore: Bump wasm-bindgen to 0.2.89 (0.2.88 got yanked) 2023-11-28 21:43:41 -05:00
renovate[bot] 6da223a875 fix(deps): update rust dependencies 2023-11-27 09:44:47 +01:00
renovate[bot] 7757d060ff fix(deps): update rust dependencies to v2 2023-11-20 09:03:08 +01:00
renovate[bot] 2a83274c7f fix(deps): update rust dependencies 2023-11-19 21:09:42 -05:00
Nathan Adams d6f16b0be5 tests: Make tests use a virtual filesystem, which currently maps to the regular physical FS rooted in a test directory 2023-11-13 22:28:10 +01:00
renovate[bot] 32c65e6460 fix(deps): update rust dependencies 2023-11-13 09:10:26 +01:00
Nathan Adams 424821724f desktop: Show ruffle logo in about dialog 2023-11-12 21:42:02 +01:00
Aaron Hill f04496d1f3 chore: Update ahash and self_cell
Both of these had yanked versions, and self_cell had a security advisory
2023-11-12 00:15:51 +01:00
Aaron Hill b056e12f4b avm2: Re-use same AMFValue for the same Object ptr
This preserves object identity across a serialization
round-trip. Unfortunately, we don't currently implement this
correctly in flash_lso, so I've added a stub message.

Once flash_lso is fixed, this code will start working. For now,
it just allows us to detect (via the stub) if this is actually
used by an SWF.
2023-11-10 17:52:47 -05:00
Nathan Adams eb72cfb498 tests: Removed the need for test framework to depend on libtest_mimic 2023-11-10 22:02:18 +01:00
Nathan Adams 2b450af8d5 tests: Test framework doesn't need walkdir 2023-11-10 22:02:18 +01:00
Nathan Adams bce0608e1f tests: Move all wgpu code out of test framework, make it abstract over any/no renderer, and make wgpu option if imgtests isn't enabled 2023-11-10 22:02:18 +01:00
Nathan Adams 673d52f013 tests: Move test framework into its own crate 2023-11-10 22:02:18 +01:00
Lord-McSweeney 2f5166790c chore: Update flash-lso 2023-11-10 18:26:02 +01:00
Nathan Adams fe2ff4f242 chore: Update flash-lso 2023-11-09 20:01:52 +01:00
Nathan Adams e6c46d22f2 avm2: Implement NetConnection.send and NetConnection.addHeader 2023-11-09 12:39:22 +01:00
renovate[bot] acadb2b2d3 fix(deps): update wasm-bindgen 2023-11-07 12:18:50 +01:00
CUB3D b0d88645bc avm1: Implement FileReference 2023-11-03 19:32:24 +01:00
renovate[bot] 1377a5b07b fix(deps): update rust dependencies 2023-11-01 00:45:43 +01:00
Aaron Hill 84f788c2d2
avm2: Use RawTable to implement 'public index' iteration (#12470)
* avm2: Use RawTable to implement 'public index' iteration

This makes our implementation more closely aligned with avmplus.
In particular, it's now possible to delete keys from an object
while iterating without disturbing the iteration order (as long
as those keys were already produced by the iterator).

This is based on @Bale001's work on RawTable-based iteration

A few tests had their output changed (they depend on the exact
object iteration order, and don't neccessarily match Flash Player
exactly).

* Use Cell to store index fields

* Remove outdated comment
2023-10-28 20:44:01 +00:00
TÖRÖK Attila 0c0b86c008 core,web: Replace `instant` with `web-time` 2023-10-28 03:01:45 +02:00
renovate[bot] 7b3ae30fbf fix(deps): update rust crate async-io to v2 2023-10-23 13:05:02 +02:00
renovate[bot] cd01bfe7d6 fix(deps): update rust dependencies 2023-10-23 02:55:11 +02:00
TÖRÖK Attila 627e8c8063 core: Switch dasp from a git revision to v0.11.0 2023-10-17 21:31:18 +02:00
renovate[bot] b427940431 fix(deps): update rust dependencies 2023-10-16 09:51:22 +02:00
TÖRÖK Attila 0a9be1592c chore: Run `cargo update` 2023-10-16 00:03:37 +02:00
TÖRÖK Attila 6c5187621d build: Switch back to the v0.17 branch in the main wgpu repo 2023-10-16 00:03:37 +02:00
sleepycatcoding d3765027f0 web: Use gloo_net instead of manually using web_sys
This relieves some headaches with on connect callback and spawning of the
sending async task, since some SWFs like to send data before the connect event
is called.
2023-10-15 12:00:41 +02:00
renovate[bot] 18796a67fe fix(deps): update rust dependencies 2023-10-10 02:15:59 +02:00
TÖRÖK Attila 602154b1b7 core,desktop: Switch to egui v0.23.0
Since it's compatible with wgpu 0.17.x.
2023-10-09 18:51:01 -04:00
TÖRÖK Attila 214c5d3bf7 chore: Run `cargo update` 2023-10-04 19:19:51 -04:00
renovate[bot] 428e89af73 fix(deps): update rust dependencies 2023-10-04 19:19:51 -04:00
Aaron Hill 25cf77c4a2 desktop: Handle cookies and Content-Type for HTTP requests
Both of these are handled automatically by the browser in the
web backend. This makes the desktop client store cookies between
requests (though they are discarded when the desktop player is closed),
and set the "Content-Type" header based on the mime-type supplied
in the URLRequest.
2023-10-02 19:41:39 -04:00
Aaron Hill 2dcd783261 render: Disable wgpu unused shader output check when possible
Since wgpu hasn't yet released a version with this feature, I manually
backported it to the 0.17 branch.
This doesn't work on Windows (HLSL), but works on all other platforms.
2023-09-30 17:59:36 -04:00
Aaron Hill ec7a8ac645
avm2: Add support for Stage3D bytearray/compressed textures (#13180) 2023-09-28 03:03:30 +00:00
renovate[bot] 7e4e4d4c5b fix(deps): update rust dependencies 2023-09-25 11:14:39 +02:00
renovate[bot] 37e2c06034 fix(deps): update rust dependencies 2023-09-18 00:00:45 +02:00
Aaron Hill 1c0ae0b6d8 render: Bump wgpu to 0.17 and naga to 0.13 2023-09-07 18:49:59 -04:00
renovate[bot] dabc2d56b9 fix(deps): update rust dependencies 2023-09-04 10:25:24 +02:00
Aaron Hill ccf42c3614 naga-pixelbender: Stub out Opcode::Loop
Some experimentation with Pixel Bender Studio shows
that Opcode::Loop has a 23-byte payload. I haven't tried to
figure out how to interpet the payload yet, but we can now
skip over the opcode instead of bailing out entirely.
2023-08-30 17:36:31 -04:00
renovate[bot] 4e75c3890a fix(deps): update rust dependencies 2023-08-28 07:39:35 +02:00
Nathan Adams eb2afb19c4 render: Add DrawCommand::CubicCurveTo 2023-08-27 20:17:43 +02:00
TÖRÖK Attila 96505a7bde video,chore: Bump h263-rs git refs (and update Cargo.lock fully while there) 2023-08-26 22:18:14 +02:00
Moulins 87437c1d6b avm2: use `RefLock` instead of `GcCell` in avm2's scope chain
Also bumps gc-arena to be able to use `Write<Option<_>>::as_write`
2023-08-26 11:00:40 +02:00
TÖRÖK Attila b69bd09546 video/vp6: Bump nihav-vp6 crate git refs 2023-08-26 11:35:38 +03:00
renovate[bot] 2f4c7d2fe3 fix(deps): update rust dependencies 2023-08-21 08:59:07 +02:00
renovate[bot] 1f4bfcf10d fix(deps): update rust dependencies 2023-08-18 23:32:15 +02:00
renovate[bot] 93f08d7738 chore(deps): lock file maintenance rust dependencies 2023-08-14 23:58:45 +02:00
renovate[bot] a4b179e1e0 chore(deps): lock file maintenance rust dependencies 2023-08-08 23:19:16 +02:00
renovate[bot] 477ff400a7 chore(deps): lock file maintenance rust dependencies 2023-08-02 13:36:13 +02:00
sleepycatcoding a31a9668bc chore: update Cargo.lock 2023-07-31 22:32:03 +02:00
sleepycatcoding 9604b07518 tests: Allow passing path to mocket utility
Also use anyhow to remove some unwraps.
2023-07-26 14:01:03 +02:00
sleepycatcoding a0e40287c9 tests: Rename socket-mock utility to mocket 2023-07-26 14:01:03 +02:00
sleepycatcoding d5da477df8 tests: Improve socket testing backend 2023-07-26 14:01:03 +02:00
sleepycatcoding 5d29c909c6 tests: Use socket.json when running tests 2023-07-26 14:01:03 +02:00
sleepycatcoding 3e8ee00a67 tests: Move SocketEvent into ruffle_socket_format crate 2023-07-26 14:01:03 +02:00
sleepycatcoding 88626b7212 tests: Add experimental socket_mock tool
This is used to help to create/test socket.json files against real Flash Player to verify behavior.
2023-07-26 14:01:03 +02:00
Nathan Adams a7c6a8bb77 chore: Update libz-sys to 1.1.12 2023-07-26 13:19:14 +02:00
renovate[bot] 3e63a88c34 chore(deps): lock file maintenance rust dependencies 2023-07-25 08:23:28 +03:00
sleepycatcoding 41a63e3bef desktop: make socket connections async
This also fixes an unrelated bug where null bytes were added to data, this
broke data parsing.
2023-07-23 09:13:01 +02:00
relrelb 151ad97686 avm1: Migrate `SharedObject` to `NativeObject` 2023-07-17 11:34:06 +03:00
renovate[bot] 268403faad chore(deps): lock file maintenance rust dependencies 2023-07-17 09:55:56 +03:00
CUB3D 27bc6e9609 avm1: Fix panic on writing self-referential SharedObjects 2023-07-15 11:45:02 +02:00
Moulins 3ea67668c0 render: make Context3D renderers fully GC-agnostic
The 'gc_arena' dependency was only used to manipulate the `GcCell`s
containing the vertex and fragment shaders; replacing these by a
reference to a plain old `Cell` means tha  the Context3D traits and
types do not need to interact with GC'd object anymore.

As a knock-on effect, we can also remove the `Activation` parameter
from most of the `Context3DObject` methods.
2023-07-14 16:06:36 -06:00
TÖRÖK Attila 39e51a7dcf video/h263: Add a deblocking filter as a postprocessing step 2023-07-14 14:44:23 +02:00
TÖRÖK Attila 765ceb70a0 chore: Bump h263-rs git ref to latest master 2023-07-14 14:44:23 +02:00
renovate[bot] f0607d6a1f chore(deps): lock file maintenance rust dependencies 2023-07-11 22:42:51 +02:00
renovate[bot] 664227dcdf fix(deps): update rust crate libflate to v2 2023-07-10 08:20:45 +02:00
moulins f5b4fbce77
Upgrade to new `gc-arena` API (#11182)
* core: add temporary, ruffle-internal copy of `gc-arena` crate

This will allow bumping the upstream `gc-arena` version while
reexporting our own version of the old `GcCell` API, so that
Ruffle's code can be gradually migrated.

Once the migration is done, this crate should be removed.

* core: bump `gc-arena` to kyren/gc-arena#56

Add back the removed `GcCell` to our internal facade crate

* core: bump `gc-arena` to current master

This bump renames `Gc::allocate` to `Gc::new`

* core: rename `GcCell::allocate` to `GcCell::new`, to match `Gc`

* core: bump gc-arena to (slighly after) v0.3.1

Add typedefs for old `*Context` names in the gc-arena facade crate

* core: replace uses of `CollectionContext<'_>` by `&Collection`

* core: Add `gc()` convenience method for `*Context` and `Activation` types

This allows shortening most instances of `[activation.]context.gc_context`
to `activation.gc()` or `context.gc()` (but not all instances, because of
borrowck) Note that this doesn't actually do these shortenings to avoid
major code churn.
2023-07-09 17:04:25 -04:00
nosamu c60742428c desktop: Use suitable CJK fonts for each language on Windows 2023-07-06 21:42:02 +02:00
renovate[bot] 13b1078142 chore(deps): lock file maintenance rust dependencies 2023-07-03 08:28:13 +03:00
Aaron Hill 26101ae979 render: Add 'renderdoc' feature/module for manual frame capture
This feature is disabled by default. When enabled, you can use
`ruffle_render::renderdoc::begin_frame_capture` and
`ruffle_render::renderdoc::end_frame_capture` to manually trigger
a RenderDoc frame capture (if Ruffle wasn't launched by RenderDoc,
this logs an error).

This is very useful when debugging Stage3D/PixelBender bugs, as you
can produce a capture containing only the relevant graphics calls.
2023-07-02 13:59:19 -04:00
Aaron Hill 6e1f00edf2
render: Implement more PixelBender features (#11800) 2023-07-01 13:50:43 -04:00
David Wendt bc9fd3613e core: Add stub FLV processing 2023-06-30 16:14:28 -06:00
David Wendt 0f176484ea flv: Refactor tag parsing to use error codes instead of `None`. 2023-06-30 16:14:28 -06:00
David Wendt 5b93a9e316 flv: Add new crate for FLV (de)muxing 2023-06-30 16:14:28 -06:00
renovate[bot] 3057aa59dd chore(deps): lock file maintenance rust dependencies 2023-06-25 21:53:00 -04:00
renovate[bot] f62dd17284 fix(deps): update rust crate indexmap to v2 2023-06-25 20:27:33 -04:00
Nathan Adams 647006b8d0 core: Add more avm2 debug info 2023-06-21 18:27:12 +02:00
Nathan Adams 5b429e3bf5 core: Add filtering to avm2 debug window 2023-06-21 18:27:12 +02:00
TÖRÖK Attila 7bbaeb2a61 chore: Bump ouroboros to 0.17.0. 2023-06-17 18:49:05 -05:00
renovate[bot] 7a21756ddb chore(deps): lock file maintenance rust dependencies 2023-06-17 11:00:52 -05:00
TÖRÖK Attila 12a28b0c5b chore: Bump `tracing-tracy` to version-match `profiling`
This fixes `thread 'main' panicked at 'span! without a running Client'`
when enabling the `tracy` feature.
2023-06-17 12:12:46 +02:00
Aaron Hill 69fce3f7f8
wpgu: Initial implementation of PixelBender shader execution (#11441)
* wpgu: Initial implementation of PixelBender shader execution

The implementation is split across four crates:
* `ruffle_render` now holds the main PixelBender bytecode parsing
   implementation (previously, this was in `ruffle_core`).
* `ruffle_core` holds some helper functions for converting between
   AVM2 `Value`s and the PixelBender vector types.
* `naga-pixelbender` (newly created) constructs a Naga `Module`
  from parsed PixelBender bytecode
* `ruffle_render_wgpu` sets up the render pipeline for the shader
  constructed by `naga-pixelbender`, and actually executes the shader.

The Actionscript-side shader parameters are passed in through uniforms.
This allows us to cache the compiled `naga::Module` and associated
wgpu types inside `ShaderData`, when it's first created. Each invocation
of a `ShaderJob` only needs to create a bind group and render pass.

Limitations:

* Only a few of the PixelBender opcodes are implemented - however, this is
enough to get Stemlands cannon rotation working, as well as a cool
"donut" shader that I found and included as a test.
* PixelBender matrix types are not supported.
* Only BitmapData is supported as an input/output type - Flash Player
  also supports using Vector and ByteArray
* ShaderJob execution is always synchronous.

* Adjust comments

* Address review comments
2023-06-15 22:50:24 +00:00
renovate[bot] fc933f485f fix(deps): update wasm-bindgen 2023-06-15 20:50:04 +02:00
Aaron Hill cd2c7f6f2f tests: Enable tracing_subscriber in tests
Previously, we weren't displaying any Ruffle logs when running tests.
2023-06-14 17:15:31 -05:00
renovate[bot] 438e6f36ff chore(deps): lock file maintenance rust dependencies 2023-06-12 08:50:07 +03:00
renovate[bot] a621472336 chore(deps): lock file maintenance rust dependencies 2023-06-09 20:17:25 +03:00
Aaron Hill d44c9cceb1 wgpu: Cache compiled naga-agal shader module
We use an `lru::LruCache` inside `ShaderModuleAgal`. This automatically
gives us the proper garbage-collection behavior (when the Flash
Program3D instance is garbage collected, we'll drop the
`ShaderModuleAgal` and the cache).

The cache is keyed on the data needed to compile the shader (vertex
attributes and sampler overrides). This lets us avoid shader
recompilations when a Stage3D program repeatedly uses the same
Program3D with different sampler overrides / vertex attribute formats.
2023-06-08 02:57:47 -05:00
renovate[bot] f1fe998869 chore(deps): lock file maintenance rust dependencies 2023-06-04 22:53:18 -05:00
Nathan Adams e12e2a2e54 core: Initial Debug UI 2023-06-03 09:11:06 +02:00
Nathan Adams eb70a4f361 core: Update gc_arena to 63dab12871321e0e5ada10ff1f1de8f4cf1764f9 2023-06-03 09:11:06 +02:00
relrelb abb0e33431 chore: Use Rust's `OnceCell`/`OnceLock`
They were stabilized in Rust 1.70.0, which was released yesterday.
This removes the `once_cell` dependency.
2023-06-02 22:21:38 +03:00
renovate[bot] 847dece735 chore(deps): lock file maintenance rust dependencies 2023-05-28 23:54:33 -05:00
Nathan Adams d8bfb003c5 desktop: Switch to egui 0.22.0 2023-05-24 23:50:48 +02:00
Nathan Adams 12e2758464 desktop: Localise texts 2023-05-24 23:50:48 +02:00