Gimp.Resource.get_by_id
Description: Reference for Gimp.Resource.get_by_id

### Function

# Gimp Resourceget_by_id

since: 3.0

#### Declaration [src]

    GimpResource*
    gimp_resource_get_by_id (
      gint32 resource_id
    )

#### Description [src]

Returns a `GimpResource` representing `resource_id`. Since `GimpResource` is an abstract class, the real object type will actually be the proper subclass.

Note: in most use cases, you should not need to retrieve a `GimpResource` by its ID, which is mostly internal data and not reusable across sessions. Use the appropriate functions for your use case instead.

Available since: 3.0

#### Parameters

`resource_id`

  Type: `gint32`

  The resource id.

#### Return value

Type: `GimpResource`

A `GimpResource` for `resource_id` or `NULL` if `resource_id` does not represent a valid resource. The object belongs to libgimp and you must not modify or unref it.

The data is owned by the called function.
The return value can be `NULL`.