Commit Graph

10715 Commits

Author SHA1 Message Date
David Wendt 81740d09f7 tests: Change seek test output to match test harness timing.
We are not interested in testing the timing of buffer loads (since that will vary based on hardware), we just need to know that we got a buffer load event.

Furthermore all our seeks are in-buffer so multiple buffer full events shouldn't happen in Ruffle.
2023-10-10 18:49:09 -06:00
David Wendt 759aa1e469 core: Allow seeks to process on paused streams.
Our list of 'playing' streams is now a list of 'active' streams. This nomenclature change also indicates a rule change: streams are activated whenever there is work for them to do, and they are only ever deactivated by themselves when they're out of work to do. We no longer deactivate streams when they are paused as they may still have a queued seek to process.
2023-10-10 18:49:09 -06:00
David Wendt e5b59438f7 core: Swap order of parameters on `NetStream.Seek.Notify` event 2023-10-10 18:49:09 -06:00
David Wendt 87b9cf2fa0 tests: Remove all time assertions from the seek test as our test harness and loader impl screws up timing 2023-10-10 18:49:09 -06:00
David Wendt 525165caf6 tests: Change AVM2 version of the `netstream_seek_flv` test to wait for video to play before tracking time and seeking. 2023-10-10 18:49:09 -06:00
David Wendt 4420dc8d23 core: Let each VM flag if it wants to send seek events or not 2023-10-10 18:49:09 -06:00
David Wendt c086a6da11 chore: Fix let statements holding unnecessary borrows, *grumble grumble* 2023-10-10 18:49:09 -06:00
David Wendt 78e41b5be5 avm1: Implement `NetStream.time` 2023-10-10 18:49:09 -06:00
David Wendt c23f346665 chore: Ensure all `NetStream` code is working in milliseconds.
AVM `NetStream` reports and accepts values in seconds, so all the unit conversions went there now.
2023-10-10 18:49:09 -06:00
David Wendt a0a762ccfc core: `NetStream` seeks are queued.
They do not execute until the next stream tick.

We also implement a few new status events, including some AVM2 exclusive ones.
2023-10-10 18:49:09 -06:00
David Wendt d3335f4dc4 tests: Add AVM1 version of `netstream_seek_flv` 2023-10-10 18:49:09 -06:00
David Wendt 3f13087d39 chore: Use `get_f64` for `NetStream.seek` 2023-10-10 18:49:09 -06:00
David Wendt 99de1ae154 avm2: Implement `NetStream.time` 2023-10-10 18:49:09 -06:00
David Wendt 008427e490 tests: Work around our test harness not loading videos syncronously 2023-10-10 18:49:09 -06:00
David Wendt 5cf005e69e tests: Add test for seeking NetStream on AVM2 2023-10-10 18:49:09 -06:00
David Wendt 0d886dd860 core: Add `NetStream.Pause.Notify` event 2023-10-10 18:49:09 -06:00
David Wendt 3566d7f43a core: Fire `NetStream.SeekStart.Notify` events 2023-10-10 18:49:09 -06:00
David Wendt 1f5947912d core: Defensively program against `flv` being broken 2023-10-10 18:49:09 -06:00
David Wendt 9754d925a5 flv: `skip_back` needs to consider the offset of the back pointers and not just tags 2023-10-10 18:49:09 -06:00
David Wendt 3be9ce4ac0 avm2: Implement `NetStream.seek` 2023-10-10 18:49:09 -06:00
David Wendt e440e175d9 avm1: Implement `seek` method 2023-10-10 18:49:09 -06:00
David Wendt bc6291898c core: Add a `seek` method 2023-10-10 18:49:09 -06:00
David Wendt 4867ff1210 core: Break type sniffing out into a separate fn. 2023-10-10 18:49:09 -06:00
TÖRÖK Attila 0ef28604b1 renovate: Include winit, egui-winit, and raw-window-handle in the wgpu dep group 2023-10-10 03:05:54 +02:00
renovate[bot] 18796a67fe fix(deps): update rust dependencies 2023-10-10 02:15:59 +02:00
Lord-McSweeney 7254cdeef9 avm2: Throw ArgumentError when trying to construct `new Worker()` 2023-10-10 01:20:06 +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
sleepycatcoding 21a1e1f670 avm2: Small set_property_local fixup
Fixes a borrow panic and logic error.
2023-10-10 00:24:39 +02:00
sleepycatcoding 0b2771c23d avm2: Implement other XMLList set_property_local path 2023-10-10 00:24:39 +02:00
sleepycatcoding 917e70086b avm2: Throw Error 1089, if base list length bigger than 1
This is not mentioned in the E4X specification, but this is what avmplus
seems to be doing.
2023-10-10 00:24:39 +02:00
sleepycatcoding ca5ba4877c avm2: Implement one XMLList set_property path 2023-10-10 00:24:39 +02:00
sleepycatcoding 709306be81 avm2: Implement resolveValue 2023-10-10 00:24:39 +02:00
sleepycatcoding 4285d998dc avm2: Add target property to XMLListObject 2023-10-10 00:24:39 +02:00
Nathan Adams a3b95d9534 avm2: Fix missing stub imports in TextRenderer.as 2023-10-09 23:54:58 +02:00
Crowdin Bot 13b50fecb5 chore: Update translations from Crowdin 2023-10-09 23:10:41 +02:00
Adrian Wielgosik cea0f1b1f1 swf: Add test for DefineFont2/3 roundtrips 2023-10-08 12:13:16 +02:00
Adrian Wielgosik 3e5482a761 swf: Better adjust offsets for has_wide_offsets in writer 2023-10-08 12:13:16 +02:00
Adrian Wielgosik 9ab50bcd74 swf: Fix writing an all-zeros straight ShapeRecord 2023-10-08 12:13:16 +02:00
Adrian Wielgosik f08ee6de58 swf: Add a missing offset to DefineFont2/3 offset table 2023-10-08 12:13:16 +02:00
Adrian Wielgosik cc5c46dda2 swf: Fix writing of an all-zeros curve ShapeRecord 2023-10-08 12:13:16 +02:00
Lord-McSweeney b877a39c47 avm2: Implement SharedObject.setProperty 2023-10-07 23:49:36 +02:00
Tom Schuster c6804be307 avm2: Add smoke test for namespace issue in monopoly 2023-10-07 23:46:40 +02:00
Tom Schuster ed1a2ee27c avm2: Add failing namespace test for flash.xml 2023-10-07 23:46:40 +02:00
Tom Schuster 278a6ddf53 avm2: Use the localName in XMLDocument::_convertXmlNode 2023-10-07 23:46:40 +02:00
Crowdin Bot 3dc75f7ab8 chore: Update translations from Crowdin 2023-10-07 23:37:34 +02:00
sleepycatcoding ce2862dd45 avm2: Fix KeyboardEvent clone
also adds missing commandKey property.
2023-10-07 08:57:34 +02:00
Aaron Hill 3a658f5dec avm2: Implement BitmapData.copyPixelsToByteArray
This basically just re-uses the implementation of getPixels
2023-10-05 17:35:54 -04:00
Crowdin Bot 53babdd675 chore: Update translations from Crowdin 2023-10-05 23:09:23 +02:00
sleepycatcoding 5992f6b3c7 avm2: Fix handling of XMLList when set as attribute value
Fixes test `e11_6_1` when combined #13255.
2023-10-05 21:26:41 +02:00
sleepycatcoding 80ccc1d8a3 avm2: Implement some obscure SWFv9 XML behavior
This affects appendChild, prependChild, insertChildBefore, insertChildAfter.
2023-10-05 16:12:43 +02:00