2 * Copyright 2012 Samsung Electronics Co., Ltd
\r
4 * Licensed under the Flora License, Version 1.0 (the "License");
\r
5 * you may not use this file except in compliance with the License.
\r
6 * You may obtain a copy of the License at
\r
8 * http://www.tizenopensource.org/license
\r
10 * Unless required by applicable law or agreed to in writing, software
\r
11 * distributed under the License is distributed on an "AS IS" BASIS,
\r
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
\r
13 * See the License for the specific language governing permissions and
\r
14 * limitations under the License.
\r
21 #include <media_content_type.h>
\r
22 #include <media_filter.h>
\r
23 #include <media_image.h>
\r
24 #include <media_video.h>
\r
25 #include <media_info.h>
\r
26 #include <media_folder.h>
\r
27 #include <eina_list.h>
\r
29 #define FREE_DATA(ptr) \
\r
38 #define GE_TYPE_ALBUM (0x55551)
\r
39 #define GE_TYPE_MEDIA (0x55553)
\r
43 GE_PHONE, /**< Stored only in phone */
\r
44 GE_MMC, /**< Stored only in MMC */
\r
45 GE_SYSTEM, /**< Stored in ALL*/
\r
49 typedef struct _ge_album_t ge_album_s;
\r
50 typedef struct _ge_media_t ge_media_s;
\r
51 typedef struct _ge_image_t ge_image_s;
\r
52 typedef struct _ge_video_t ge_video_s;
\r
54 struct _ge_album_t {
\r
55 int gtype; /*self-defination type, when free this struct space, use it*/
\r
56 media_folder_h folder_h; /*the handle of operating this folder*/
\r
57 char *uuid; /*folder UUID*/
\r
58 char *display_name; /*album name*/
\r
59 char *path; /*the full path of this folder*/
\r
60 int type; /*storage type*/
\r
61 time_t mtime; /*modified time*/
\r
62 int count; /*the media count in this folder*/
\r
63 char *thumb_url; /**< thumbnail full path */
\r
64 void *_reserved; /*reserved*/
\r
67 struct _ge_media_t {
\r
68 int gtype; /*self-defination type, when free this struct space, use it*/
\r
69 media_info_h media_h; /*the handle of operating this media*/
\r
70 char *uuid; /*meida id*/
\r
71 int type; /*meida type, image or video*/
\r
72 char *thumb_url; /*the thumbnail full path of this meida file*/
\r
73 char *file_url; /*the full path of this meida file*/
\r
74 time_t mtime; /*modified time*/
\r
75 char *album_uuid; /*folder UUID*/
\r
76 char *display_name; /*item name*/
\r
79 ge_image_s *image_info; /*image information*/
\r
80 ge_video_s *video_info; /*video information*/
\r
82 void *_reserved; /*reserved*/
\r
85 struct _ge_image_t {
\r
86 char *media_uuid; /*media uuid*/
\r
87 image_meta_h image_h; /*the handle of operating this image*/
\r
88 media_content_orientation_e orientation; /*the orientation of this image*/
\r
89 void *_reserved; /*reserved*/
\r
92 struct _ge_video_t {
\r
93 char *media_uuid; /*media uuid*/
\r
94 video_meta_h video_h; /*the handle of operating this video*/
\r
95 char *title; /*the title of video*/
\r
96 time_t last_played_pos; /*the last played position*/
\r
97 int duration; /*the duration of this video*/
\r
98 int bookmarks; /*whether exist bookmarks*/
\r
99 void *_reserved; /*reserved*/
\r
102 int _ge_data_type_new_media(ge_media_s **item);
\r
103 int _ge_data_type_new_album(ge_album_s **album);
\r
104 int _ge_data_type_free_media_list(Eina_List **list);
\r
105 int _ge_data_type_free_album_list(Eina_List **list);
\r
106 int _ge_data_type_free_geitem(void **item);
\r