ANNOUNCE: binding generator cppgir

Mark Nauwelaerts mark.nauwelaerts at gmail.com
Sat Nov 10 13:25:10 UTC 2018


Hi All,

Just a few words about cppgir; https://gitlab.com/mnauw/cppgir ...

cppgir is a gobject-introspection C++ binding wrapper generator.  That is, it 
processes GIR files derived from gobject-introspection annotations into a set of 
C++ files defining suitable namespaces, classes and other types that together 
form a C++ binding. In this way, the plain C libraries and objects become 
available as native objects along with (RAII) managed resource handling. The 
generated code only requires a C++11 compiler and library (as well as obviously 
the underlying C headers and libraries that are being wrapped).

This is evidently not specific to GStreamer development (or Gtk or ...), but it 
is nevertheless hoped it may be of use in developing compiled applications using 
GStreamer libraries. Whether such development involves a GUI layer (e.g. 
natively C++ based Qt, wrapping Gtk, ...) or purely serves middleware (e.g. 
streaming) purposes. The generated bindings provide convenient development (due 
to automated resource management) while retaining compile-time safety.

Another feauture might be handy even if one is not interested in generated C++ 
code. As the GIR files as processed, a number of consistency checks are 
performed. In that way, the generator also acts somewhat as annotation 
validator, and can typically spot some missing (out) or (array) (and related) 
annotations.

Mark.



More information about the gstreamer-devel mailing list