GimpLoadProcedure

GimpLoadProcedure

Functions

Object Hierarchy

    GObject
    ╰── GimpProcedure
        ╰── GimpFileProcedure
            ╰── GimpLoadProcedure

Description

Functions

GimpRunLoadFunc ()

GimpValueArray *
(*GimpRunLoadFunc) (GimpProcedure *procedure,
                    GimpRunMode run_mode,
                    GFile *file,
                    const GimpValueArray *args,
                    gpointer run_data);

The load function is run during the lifetime of the GIMP session, each time a plug-in load procedure is called.

Parameters

procedure

the GimpProcedure that runs.

 

run_mode

the GimpRunMode.

 

file

the GFile to load from.

 

args

the procedure 's remaining arguments.

 

run_data

the run_data given in gimp_load_procedure_new().

[closure]

Returns

the procedure 's return values.

[transfer full]

Since: 3.0


gimp_load_procedure_new ()

GimpProcedure *
gimp_load_procedure_new (GimpPlugIn *plug_in,
                         const gchar *name,
                         GimpPDBProcType proc_type,
                         GimpRunLoadFunc run_func,
                         gpointer run_data,
                         GDestroyNotify run_data_destroy);

Creates a new load procedure named name which will call run_func when invoked.

See gimp_procedure_new() for information about proc_type .

GimpLoadProcedure is a GimpProcedure subclass that makes it easier to write file load procedures.

It automatically adds the standard

(GimpRunMode, GFile)

arguments and the standard

(GimpImage)

return value of a load procedure. It is possible to add additional arguments.

When invoked via gimp_procedure_run(), it unpacks these standard arguments and calls run_func which is a GimpRunLoadFunc. The "args" GimpValueArray of GimpRunLoadFunc only contains additionally added arguments.

Parameters

plug_in

a GimpPlugIn.

 

name

the new procedure's name.

 

proc_type

the new procedure's GimpPDBProcType.

 

run_func

the run function for the new procedure.

 

run_data

user data passed to run_func .

 

run_data_destroy

free function for run_data , or NULL.

[nullable]

Returns

a new GimpProcedure.

Since: 3.0


gimp_load_procedure_set_handles_raw ()

void
gimp_load_procedure_set_handles_raw (GimpLoadProcedure *procedure,
                                     gboolean handles_raw);

Registers a load loader procedure as capable of handling raw digital camera loads.

Parameters

procedure

A GimpLoadProcedure.

 

handles_raw

The procedure's handles raw flag.

 

Since: 3.0


gimp_load_procedure_get_handles_raw ()

gboolean
gimp_load_procedure_get_handles_raw (GimpLoadProcedure *procedure);

Parameters

procedure

A GimpLoadProcedure.

 

Returns

The procedure's handles raw flag as set with gimp_load_procedure_set_handles_raw().

Since: 3.0


gimp_load_procedure_set_thumbnail_loader ()

void
gimp_load_procedure_set_thumbnail_loader
                               (GimpLoadProcedure *procedure,
                                const gchar *thumbnail_proc);

Associates a thumbnail loader with a file load procedure.

Some file formats allow for embedded thumbnails, other file formats contain a scalable image or provide the image data in different resolutions. A file plug-in for such a format may register a special procedure that allows GIMP to load a thumbnail preview of the image. This procedure is then associated with the standard load procedure using this function.

Parameters

procedure

A GimpLoadProcedure.

 

thumbnail_proc

The name of the thumbnail load procedure.

 

Since: 3.0


gimp_load_procedure_get_thumbnail_loader ()

const gchar *
gimp_load_procedure_get_thumbnail_loader
                               (GimpLoadProcedure *procedure);

Parameters

procedure

A GimpLoadProcedure.

 

Returns

The procedure's thumbnail loader procedure as set with gimp_load_procedure_set_thumbnail_loader().

Since: 3.0