IpatchDLSWriter

IpatchDLSWriter — DLS instrument file writer

Stability Level

Stable, unless otherwise indicated

Functions

Object Hierarchy

    GObject
    ╰── IpatchRiff
        ╰── IpatchDLSWriter

Description

Writes a DLS instrument object tree (IpatchDLS) to a DLS file.

Functions

ipatch_dls_writer_new ()

IpatchDLSWriter *
ipatch_dls_writer_new (IpatchFileHandle *handle,
                       IpatchDLS2 *dls);

Create a new DLS file writer.

Parameters

handle

DLS file handle to save to or NULL to set later, taken over by writer object and will be closed on finalize.

 

dls

DLS object to save or NULL to set later

 

Returns

The new DLS writer


ipatch_dls_writer_set_patch ()

void
ipatch_dls_writer_set_patch (IpatchDLSWriter *writer,
                             IpatchDLS2 *dls);

Set the DLS patch object to save with a DLS writer.

Parameters

writer

DLS writer object

 

dls

DLS patch to save

 

ipatch_dls_writer_set_file_handle ()

void
ipatch_dls_writer_set_file_handle (IpatchDLSWriter *writer,
                                   IpatchFileHandle *handle);

Set the DLS file handle of a DLS writer. A convenience function, since ipatch_riff_set_file_handle() could also be used.

Parameters

writer

DLS writer object

 

handle

DLS file handle

 

ipatch_dls_writer_save ()

gboolean
ipatch_dls_writer_save (IpatchDLSWriter *writer,
                        GError **err);

Write a DLS or GigaSampler object to a file.

Parameters

writer

DLS writer object

 

err

Location to store error info or NULL

 

Returns

TRUE on success, FALSE on error


ipatch_dls_writer_create_stores ()

IpatchList *
ipatch_dls_writer_create_stores (IpatchDLSWriter *writer);

Create sample stores and add them to applicable IpatchSampleData objects and return object list. This function can be called multiple times, additional calls will return the same list.

Parameters

writer

SoundFont writer object

 

Returns

List of sample stores which the caller owns a reference to or NULL.

[transfer full]

Since: 1.1.0

See Also

IpatchDLS