Update License
[platform/framework/web/livebox-viewer.git] / include / fb.h
1 /*
2  * Copyright 2013  Samsung Electronics Co., Ltd
3  *
4  * Licensed under the Flora License, Version 1.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.tizenopensource.org/license
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 struct fb_info;
18
19 enum buffer_type { /*!< Must have to be sync with libprovider, liblivebox-viewer */
20         BUFFER_TYPE_FILE,
21         BUFFER_TYPE_SHM,
22         BUFFER_TYPE_PIXMAP,
23         BUFFER_TYPE_ERROR,
24 };
25
26 extern int fb_init(void *disp);
27 extern int fb_fini(void);
28 extern const char *fb_id(struct fb_info *info);
29 extern int fb_get_size(struct fb_info *info, int *w, int *h);
30 extern int fb_sync(struct fb_info *info);
31 extern int fb_size(struct fb_info *info);
32 extern int fb_refcnt(void *data);
33 extern int fb_is_created(struct fb_info *info);
34
35 extern struct fb_info *fb_create(const char *filename, int w, int h);
36 extern int fb_destroy(struct fb_info *info);
37
38 extern void *fb_acquire_buffer(struct fb_info *info);
39 extern int fb_release_buffer(void *data);
40
41 /* End of a file */