00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef __GPHOTO2_PORT_INFO_LIST_H__
00022 #define __GPHOTO2_PORT_INFO_LIST_H__
00023
00024 typedef enum {
00025 GP_PORT_NONE = 0,
00026 GP_PORT_SERIAL = 1 << 0,
00027 GP_PORT_USB = 1 << 2,
00028 GP_PORT_DISK = 1 << 3
00029 } GPPortType;
00030
00031 typedef struct _GPPortInfo GPPortInfo;
00032 struct _GPPortInfo {
00033 GPPortType type;
00034 char name[64];
00035 char path[64];
00036
00037
00038 char library_filename[1024];
00039 };
00040
00041 #include <gphoto2-port.h>
00042
00043 #ifdef __cplusplus
00044 extern "C" {
00045 #endif
00046
00047
00048 typedef struct _GPPortInfoList GPPortInfoList;
00049
00050 int gp_port_info_list_new (GPPortInfoList **list);
00051 int gp_port_info_list_free (GPPortInfoList *list);
00052
00053 int gp_port_info_list_append (GPPortInfoList *list, GPPortInfo info);
00054
00055 int gp_port_info_list_load (GPPortInfoList *list);
00056
00057 int gp_port_info_list_count (GPPortInfoList *list);
00058
00059 int gp_port_info_list_lookup_path (GPPortInfoList *list, const char *path);
00060 int gp_port_info_list_lookup_name (GPPortInfoList *list, const char *name);
00061
00062 int gp_port_info_list_get_info (GPPortInfoList *list, int n, GPPortInfo *info);
00063
00064
00065 typedef GPPortInfo gp_port_info;
00066
00067 #ifdef __cplusplus
00068 }
00069 #endif
00070
00071 #endif