Windows ANE tutorial: The native DLL project

At the end of this part you will have: A C/C++ project which you have set up to use the Adobe AIR C API. Note that, although the steps here are done with Microsoft Visual C++, you don’t necessarily need to stick with it. Any IDE or command-line compiler that builds C/C++ code will do, for example GCC. The most important steps in this part of the tutorial are making sure that your C/C++ code can see FlashRuntimeExtensions.h and link with FlashRuntimeExtensions.lib from the Adobe AIR SDK. Time 8-10 miutes Share on: WhatsApp Read More

Categories: AIR Native Extensions and Tutorials.

Windows ANE tutorial: introduction

We sometimes get asked for help with putting ANEs for Windows together, build automation and debugging. The inspiration for this tutorial came from Eric Zwar, who bought our eBook Easy Native Extensions, which has examples for iOS, and heroically applied its principles to making an AIR Native Extension for Windows. Thank you, Eric! I hope you like this one. Share on: WhatsApp Read More

Categories: AIR Native Extensions and Tutorials.

Keeping your C native code reusable and independent of AIR

When you make a native extension using the AIR C API, your native code tends to have two parts:

  • one that's concerned with exposing functionality in a way that AIR can call, in other words, dependent on the AIR C API;
  • functional part, which deals with the platform-specific stuff. This part of your code doesn't (and shouldn't) care about whether it's used in an AIR native extension, a purely native app or something else.

Ideally you want to keep the dependency between these two parts one-directional: the AIR-concerned part should depend on the functional part, but the functional part should not know about and depend on AIR. If you decide to reuse your, say camera or speech recognition functionality, in another project that's not AIR-related , you don't want to force that to include the AIR C API.

So, what happens if you need to dispatch an event from the functional part of your code? Say, the camera refused to start or the speech processor is ready with results and you want you alert AIR to this... Read More

Categories: AIR Native Extensions.

Extension Initializer and Finalizer in C

The Extension Initializer and Finalizer are the entry and exit points to your native extension. They are also two of the ingredients that make your extension known to the world and make it distinguishable from other extensions in an app. This is why they need to have unique names. Their signatures however need to be exactly as prescribed by AIR. Today we look at what these are in the AIR C API.

Read More

Categories: AIR Native Extensions.