2014-07-25 10:22:49 +02:00
|
|
|
<?xml version="1.0"?>
|
|
|
|
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
|
|
|
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
|
|
|
]>
|
2014-07-26 12:19:46 +02:00
|
|
|
<refentry id="binding">
|
2014-07-25 10:22:49 +02:00
|
|
|
<refmeta>
|
2014-07-26 12:19:46 +02:00
|
|
|
<refentrytitle>Writing bindings for libvips</refentrytitle>
|
2014-07-25 10:22:49 +02:00
|
|
|
<manvolnum>3</manvolnum>
|
2014-07-26 12:19:46 +02:00
|
|
|
<refmiscinfo>VIPS Library</refmiscinfo>
|
2014-07-25 10:22:49 +02:00
|
|
|
</refmeta>
|
|
|
|
|
|
|
|
<refnamediv>
|
2014-07-26 12:19:46 +02:00
|
|
|
<refname>Binding</refname>
|
|
|
|
<refpurpose>How to write bindings for libvips</refpurpose>
|
2014-07-25 10:22:49 +02:00
|
|
|
</refnamediv>
|
|
|
|
|
2014-07-26 12:19:46 +02:00
|
|
|
<refsect1 id="binding-goi">
|
|
|
|
<title>Binding and gobject-introspection</title>
|
2014-07-25 10:22:49 +02:00
|
|
|
<para>
|
2014-08-08 18:34:30 +02:00
|
|
|
Write this section once the vips8 Python binding is done.
|
2014-07-25 10:22:49 +02:00
|
|
|
</para>
|
2014-08-12 14:37:16 +02:00
|
|
|
|
|
|
|
<para>
|
|
|
|
If you are writing a language binding, you won't need these. Instead, make
|
|
|
|
a new operation with vips_operation_new() (all it does is look up the
|
|
|
|
operation by name with vips_type_find(), then call g_object_new() for you),
|
|
|
|
then use vips_argument_map() and friends to loop over the operation's
|
|
|
|
arguments setting them. Once you have set all arguments, use
|
|
|
|
vips_cache_operation_build() to look up the operation in the cache and
|
|
|
|
either build or dup it. If something goes wrong, you'll need to use
|
|
|
|
vips_object_unref_outputs() and g_object_unref() to free the
|
|
|
|
partially-built object.
|
|
|
|
</para>
|
2014-07-25 10:22:49 +02:00
|
|
|
</refsect1>
|
|
|
|
|
|
|
|
</refentry>
|