Axoverlay 2 API
Migration from Axoverlay v1

The quickest way to start migrating is to read the provided 'axoverlay2.c' example program.

This document highlights some important differences between Axoverlay v1 and v2.

Bring-your-own event loop

Axoverlay v1 requires use of the Glib event loop. Axoverlay v2 can work with any standard event library, including Glib.

Imperative design

In Axoverlay v1 the library drives the logic by issuing callbacks to the application code. In Axoverlay v2 the application drives everything by issuing imperative commands such as 'create overlay', 'get a new frame buffer for overlay 7', 'move overlay 4' and so on.

Use of Vdo APIs

Axoverlay v1 has a built-in stream monitor which provides a limited set of stream information to the application. In Axoverlay v2 the application is expected to directly use the standard Vdo API to monitor video streams and their settings.

Meaning of the word 'overlay'

Axoverlay's v1 built-in stream monitor automatically creates overlays based on feedback from application-provided callbacks. The application never directly creates an overlay on a specific stream. Because of this, the terminology can be a bit confusing. What is called an 'overlay' in Axoverlay v1 should rather be understood as a kind of template from which multiple concrete overlays can be created on different streams.

In Axoverlay v2 'overlay' always refers to a concrete overlay applied to a specific stream, with a certain pixel size, a set of frame buffers.

No backends

Axoverlay v1 provides a set of wrappers ('backends') for common graphics toolkits, along with a raw memory backend ('open backend'). In Axoverlay v2 there are no backends, just a raw memory/dma_buf option that can be integrated into any available graphics toolkit.