Hacker News new | ask | show | jobs
by kmeisthax 1065 days ago
Flash was software rendered almost exclusively. It also had quality options that let you scale the software renderer down a whole lot. But it still required a beefy CPU to push all those pixels. On mobile, you don't get a fast CPU - you get hardware accelerated EVERYTHING. Everything has to be done on GPU. Hell, iPhones still have dedicated JPEG decoders in them.

And vector rendering on GPUs is a pain to do, even more so with Flash Player's rendering quirks. Adobe's official solution to hardware rendering on Flash was Starling Framework, which rendered all your assets to bitmap textures and then gave you a DisplayObject-compatible API that triggered Stage3D renders under the hood.

In Ruffle we use a tesselation library to render on GPU. This preserves vector scalability but it has other issues. Most movies work fine with it, but we have to waste time tessellating[0] assets, and in certain contrived cases we tesselate things wrong and movies look polygonal.

[0] Which we hid behind existing Flash preloaders. We don't even support progressive download yet! But the alternative was Homestuck hanging your browser for minutes on end.

2 comments

I always remember Flash being really fast at the vector calculation but and absolute hog on output rendering. So higher screen resolution hammered the CPU even though everything was setup.
I want you to know that I laughed very hard at finding a comment complaining about Homestuck in Ruffle unexpectedly here, thank you.

To be fair, on the single 100 mbit link the site used to be on, for new things being posted, that would be historically accurate...

[S] Cascade and [S] ACT 4 were my test cases for the "large movies hang the browser" bug[0]. Homestuck loves stressing out Ruffle's tessellator.

Oh and yes, the opening bars of "Doctor" are permanently burned into my head now.

[0] https://github.com/ruffle-rs/ruffle/pull/7858

It's okay, Cascade was a great test case for Newgrounds, too. ;)