## EntangleCameraList

EntangleCameraList — a list of camera devices on the system

## Functions

EntangleCameraList * | entangle_camera_list_new_active ()
EntangleCameraList * | entangle_camera_list_new_supported ()
gboolean | entangle_camera_list_refresh ()
int | entangle_camera_list_count ()
void | entangle_camera_list_add ()
void | entangle_camera_list_remove ()
EntangleCamera * | entangle_camera_list_get ()
GList * | entangle_camera_list_get_cameras ()
EntangleCamera * | entangle_camera_list_find ()

## Properties

gboolean | active | Read / Write / Construct Only
EntangleDeviceManager * | device-manager | Read

## Signals

void | camera-added | Run First
void | camera-removed | Run First

## Types and Values

#define | ENTANGLE_TYPE_CAMERA_LIST
| EntangleCameraList

## Object Hierarchy

        GObject
        ╰── EntangleCameraList

## Description

The EntangleCameraList object provides a way to enumerate camera devices on the system.

## Functions

### entangle_camera_list_new_active ()

    EntangleCameraList *
    entangle_camera_list_new_active (void);

Create a new camera list for enumerating camera cameras that are connected to the host computer

#### Returns

the new camera list.

[transfer full]

### entangle_camera_list_new_supported ()

    EntangleCameraList *
    entangle_camera_list_new_supported (void);

Create a new camera list for enumerating camera models that are supported by the library.

#### Returns

the new camera list.

[transfer full]

### entangle_camera_list_refresh ()

    gboolean
    entangle_camera_list_refresh (EntangleCameraList *list,
                                  GError **error);

De-intialization the list of cameras

#### Parameters

list | the camera list. | [transfer none]
error | a GError, or NULL |

#### Returns

TRUE if the refresh was successful, FALSE on error

### entangle_camera_list_count ()

    int
    entangle_camera_list_count (EntangleCameraList *list);

Get the total number of cameras currently detected

#### Parameters

list | the camera list. | [transfer none]

#### Returns

the number of cameras

### entangle_camera_list_add ()

    void
    entangle_camera_list_add (EntangleCameraList *list,
                              EntangleCamera *cam);

Adds the camera `cam` to the list `list`

#### Parameters

list | the camera list. | [transfer none]
cam | the camera to add. | [transfer none]

### entangle_camera_list_remove ()

    void
    entangle_camera_list_remove (EntangleCameraList *list,
                                 EntangleCamera *cam);

Removes the camera `cam` from the list `list`

#### Parameters

list | the camera list. | [transfer none]
cam | the camera to remove. | [transfer none]

### entangle_camera_list_get ()

    EntangleCamera *
    entangle_camera_list_get (EntangleCameraList *list,
                              int entry);

Get the camera at position `entry` in the list

#### Parameters

list | the camera list. | [transfer none]
entry | the index of the camera to get |

#### Returns

the camera at position `entry` .

[transfer none]

### entangle_camera_list_get_cameras ()

    GList *
    entangle_camera_list_get_cameras (EntangleCameraList *list);

Get the full list of cameras

#### Parameters

list | the camera list. | [transfer none]

#### Returns

a list of EntangleCamera objects.

[transfer container][element-type EntangleCamera]

### entangle_camera_list_find ()

    EntangleCamera *
    entangle_camera_list_find (EntangleCameraList *list,
                               const char *port);

Get the camera connected to hardware address `port`

#### Parameters

list | the camera list. | [transfer none]
port | the hardware port address. | [transfer none]

#### Returns

the camera connected to `port` , or NULL.

[transfer none]

## Types and Values

### ENTANGLE_TYPE_CAMERA_LIST

    #define ENTANGLE_TYPE_CAMERA_LIST (entangle_camera_list_get_type())

### EntangleCameraList

    typedef struct _EntangleCameraList EntangleCameraList;

## Property Details

### The `“active”` property

      “active”                   gboolean

Track kactive cameras.

Owner: EntangleCameraList

Flags: Read / Write / Construct Only

Default value: FALSE

### The `“device-manager”` property

      “device-manager”           EntangleDeviceManager *

Device manager for detecting cameras.

Owner: EntangleCameraList

Flags: Read

## Signal Details

### The `“camera-added”` signal

    void
    user_function (EntangleCameraList *entanglecameralist,
                   EntangleCamera     *arg1,
                   gpointer            user_data)

Flags: Run First

### The `“camera-removed”` signal

    void
    user_function (EntangleCameraList *entanglecameralist,
                   EntangleCamera     *arg1,
                   gpointer            user_data)

Flags: Run First