ruffle-rs / ruffle

A Flash Player emulator written in Rust
https://ruffle.rs
Other
15.43k stars 799 forks source link

aperturescience.com: DefineVideoStream, got Invalid data: Invalid video codec. #5704

Open FoxMcCloud45 opened 2 years ago

FoxMcCloud45 commented 2 years ago

Describe the bug

https://www.aperturescience.com uses an old SWF file made in 2010.

In Mozilla Firefox, the first frame of the video shows but nothing else happens. In Google Chrome, the Flash window shows a PLAY button, clicking it causes a black render.

The website's SWF file is hosted at https://www.aperturescience.com/aperturescience.swf

Also provided below. aperturescience.zip .

Expected behavior

The SWF's video should play normally.

Affected platform

Browser's extension

Operating system

Microsoft Windows 10 LTSC 2019 (1809)

Browser

Mozilla Firefox 91.3.0esr

Additional information

Firefox's JavaScript console log is attached below. console-export-2021-11-22_21-27-39.txt

n0samu commented 2 years ago

This SWF uses an external video file. Ruffle doesn't support loading external video/audio/image assets yet.

vladislavkoz commented 2 years ago

Hello guys. I have SWF which uses some FLV video files. As I understand support for FLV is not added yet. And as I understand, we can't use any video files. Is it correct? In my case, I have the following error: image

I'm using the following FLV files: image

Is there any scheduled work on adding video files support then? Could you propose any workaround for this before video support is added?

danielhjacobs commented 2 years ago

Embedded H.263 and VP6(A) videos work. FLVs/external videos do not work.

vladislavkoz commented 2 years ago

A)

So does it mean that we can't use external videos at all?

danielhjacobs commented 2 years ago

Correct. You need to embed an H.263 or VP6 video in the swf, like this: https://dnalc.cshl.edu/view/962-Causes-Smoking-Prevention.html

Lord-McSweeney commented 1 year ago

Video has been implemented- however, this seems to need something else to work, as it currently just shows a single frame. Stub warning: Stub: Stream data processing (name: onXMPData)

n0samu commented 9 months ago

As I mentioned in https://github.com/ruffle-rs/ruffle/pull/12091#issuecomment-1674177630:

The video shows only the first frame, and more strangely, the audio plays but periodically glitches out. Might there be some script data interleaved with the audio that Ruffle is erroneously trying to play back?

torokati44 commented 3 months ago

This SWF streams two FLV files: https://www.aperturescience.com/wcc_holiday10_v03.flv https://www.aperturescience.com/wcc_holiday10_v03_egg.flv

They each have a VP6 video in them, which is well supported.

And I can confirm that they are streamed and decoded correctly - they just aren't visible on the stage for some reason!

torokati44 commented 3 months ago

Ah, _level0.cam1._videoHolder has its visibility turned off (or rather, not turned on) for some reason. Flipping it on manually does show the video playing. Although, at a weird position/size/aspect ratio:

image

shaunroselt commented 1 month ago

+1