Using Scaleform for Game Asset Rendering, not just UI

387 Views Asked by At

Has anyone tried using Scaleform for actual game asset rendering in an iOS game, not just UI. The goal is to utilize vector swf's that will be converted to polygons via Scaleform but have C++ code driving the game (no AS3). If you have tried it how did you feel about the results? Could it render fast enough?

2

There are 2 best solutions below

0
On

Scaleform has been used in several iOS games as the entire engine (including AS3). Here are some examples:

TinyThief: http://inthefold.autodesk.com/in_the_fold/2013/07/5-ants-brings-tiny-thief-to-ios-and-android-with-autodesk-scaleform-mobile-sdk.html

You Don't Know Jack: http://inthefold.autodesk.com/in_the_fold/2013/01/you-dont-know-jack-qa.html

0
On

You can certainly use Scaleform for this purpose. Scaleform includes the Direct Access API (DAPI) which allows C++ to manage Flash resources (this includes creating symbol instances at runtime and managing their states + lifetime).

The GFx::Value class is the basis of DAPI and should provide most, if not all, of the functionality you would need. You may still need some AS3 code to glue some things together, but that should be negligible.

Performance of static vector content is dependent on the complexity of the shape (more paths, more styles => more triangles + batches). I'd try to limit the number of vector (shape) timeline animations because shape morphing will cause re-tessellation. Scaling vector content will also cause re-tessellation, so keep that in mind.