Gegl.Path
Description: Reference for Gegl.Path

### Class

# GeglPath

#### Description

    final class Gegl.Path : GObject.Object
    {
      /* No available fields */
    }

No description available.

#### Ancestors

- GObject

#### Constructors

###### gegl_path_new

Creates a new `GeglPath` with no nodes.

###### gegl_path_new_from_string

Creates a new `GeglPath` with the nodes described in the string `instructions`. See `gegl_path_parse_string()` for details of the format of the string.

#### Functions

###### gegl_path_add_flattener

Add a new flattener, the flattener should produce a type of path that GeglPath already understands, if the flattener is unable to flatten the incoming path (doesn’t understand the instructions), the original path should be returned.

###### gegl_path_add_type

Adds a new type to the path system, FIXME this should probably return something on registration conflicts, for now it expects all registered paths to be aware of each other.

#### Instance methods

###### gegl_path_append

Use as follows: gegl_path_append (path, ‘M’, 0.0, 0.0); and gegl_path_append (path, ‘C’, 10.0, 10.0, 50.0, 10.0, 60.0, 0.0) the number of arguments are determined from the instruction provided.

###### gegl_path_calc

Compute the coordinates of the path at the `position` (length measured from start of path, not including discontinuities).

###### gegl_path_calc_values

Compute `num_samples` for a path into the provided arrays `xs` and `ys` the returned values include the start and end positions of the path.

###### gegl_path_calc_y_for_x

Compute a corresponding y coordinate for a given x input coordinate, returns 0 if computed correctly and -1 if the path doesn’t exist for the specified x coordinate.

###### gegl_path_clear

Remove all nods from a `path`.

###### gegl_path_closest_point

Figure out what and where on a path is closest to arbitrary coordinates.

###### gegl_path_dirty

Marks the path as dirty and issues an invalidation for the path rendering, use this if modifying the values of a GeglPathPoint inline.

###### gegl_path_foreach

Execute a provided function for every node in the path (useful for drawing and otherwise traversing a path.).

###### gegl_path_foreach_flat

Execute a provided function for the segments of a poly line approximating the path.

###### gegl_path_freeze

Make the `GeglPath` stop firing signals as it changes must be paired with a `gegl_path_thaw()` for the signals to start again.

###### gegl_path_get_bounds

Compute the bounding box of a path.

###### gegl_path_get_flat_path

Return a polyline version of `path`.

###### gegl_path_get_length

Returns the total length of the path.

###### gegl_path_get_matrix

Get the transformation matrix of the path.

###### gegl_path_get_n_nodes

Retrieves the number of nodes in the path.

###### gegl_path_get_node

Retrieve the node of the path at position `pos`.

###### gegl_path_get_path

Return the internal untouched `GeglPathList`.

###### gegl_path_insert_node

Insert the new node `node` at position `pos` in `path`. if `pos` = -1, the node is added in the last position.

###### gegl_path_is_empty

Check if the path contains any nodes.

###### gegl_path_parse_string

Parses `instructions` and appends corresponding nodes to path (call `gegl_path_clean()` first if you want to replace the existing path.

###### gegl_path_remove_node

Removes the node number `pos` in `path`.

###### gegl_path_replace_node

Replaces the exiting node at position `pos` in `path`.

###### gegl_path_set_matrix

Set the transformation matrix of the path.

###### gegl_path_thaw

Restart firing signals (unless the path has been frozen multiple times).

###### gegl_path_to_string

Serialize the paths nodes to a string.

##### Methods inherited from GObject (43)

Please see GObject for a full list of methods.

#### Signals

###### Gegl.Path::changed

No description available.

##### Signals inherited from GObject (1)

###### GObject::notify

The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

#### Class structure

    struct GeglPathClass {
      /* no available fields */
    }

No description available.