Tizen 2.0 Release
[framework/multimedia/gstreamer-vaapi.git] / gst-libs / gst / vaapi / gstvaapidisplay_drm.h
1 /*
2  *  gstvaapidisplay_drm.h - VA/DRM display abstraction
3  *
4  *  Copyright (C) 2012 Intel Corporation
5  *
6  *  This library is free software; you can redistribute it and/or
7  *  modify it under the terms of the GNU Lesser General Public License
8  *  as published by the Free Software Foundation; either version 2.1
9  *  of the License, or (at your option) any later version.
10  *
11  *  This library is distributed in the hope that it will be useful,
12  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  *  Lesser General Public License for more details.
15  *
16  *  You should have received a copy of the GNU Lesser General Public
17  *  License along with this library; if not, write to the Free
18  *  Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
19  *  Boston, MA 02110-1301 USA
20  */
21
22 #ifndef GST_VAAPI_DISPLAY_DRM_H
23 #define GST_VAAPI_DISPLAY_DRM_H
24
25 #include <gst/vaapi/gstvaapidisplay.h>
26
27 G_BEGIN_DECLS
28
29 #define GST_VAAPI_TYPE_DISPLAY_DRM \
30     (gst_vaapi_display_drm_get_type())
31
32 #define GST_VAAPI_DISPLAY_DRM(obj)                              \
33     (G_TYPE_CHECK_INSTANCE_CAST((obj),                          \
34                                 GST_VAAPI_TYPE_DISPLAY_DRM,     \
35                                 GstVaapiDisplayDRM))
36
37 #define GST_VAAPI_DISPLAY_DRM_CLASS(klass)                      \
38     (G_TYPE_CHECK_CLASS_CAST((klass),                           \
39                              GST_VAAPI_TYPE_DISPLAY_DRM,        \
40                              GstVaapiDisplayDRMClass))
41
42 #define GST_VAAPI_IS_DISPLAY_DRM(obj) \
43     (G_TYPE_CHECK_INSTANCE_TYPE((obj), GST_VAAPI_TYPE_DISPLAY_DRM))
44
45 #define GST_VAAPI_IS_DISPLAY_DRM_CLASS(klass) \
46     (G_TYPE_CHECK_CLASS_TYPE((klass), GST_VAAPI_TYPE_DISPLAY_DRM))
47
48 #define GST_VAAPI_DISPLAY_DRM_GET_CLASS(obj)                    \
49     (G_TYPE_INSTANCE_GET_CLASS((obj),                           \
50                                GST_VAAPI_TYPE_DISPLAY_DRM,      \
51                                GstVaapiDisplayDRMClass))
52
53 typedef struct _GstVaapiDisplayDRM              GstVaapiDisplayDRM;
54 typedef struct _GstVaapiDisplayDRMPrivate       GstVaapiDisplayDRMPrivate;
55 typedef struct _GstVaapiDisplayDRMClass         GstVaapiDisplayDRMClass;
56
57 /**
58  * GstVaapiDisplayDRM:
59  *
60  * VA/DRM display wrapper.
61  */
62 struct _GstVaapiDisplayDRM {
63     /*< private >*/
64     GstVaapiDisplay parent_instance;
65
66     GstVaapiDisplayDRMPrivate *priv;
67 };
68
69
70 /**
71  * GstVaapiDisplayDRMClass:
72  *
73  * VA/DRM display wrapper clas.
74  */
75 struct _GstVaapiDisplayDRMClass {
76     /*< private >*/
77     GstVaapiDisplayClass parent_class;
78 };
79
80 GType
81 gst_vaapi_display_drm_get_type(void) G_GNUC_CONST;
82
83 GstVaapiDisplay *
84 gst_vaapi_display_drm_new(const gchar *device_path);
85
86 GstVaapiDisplay *
87 gst_vaapi_display_drm_new_with_device(gint device);
88
89 gint
90 gst_vaapi_display_drm_get_device(GstVaapiDisplayDRM *display);
91
92 const gchar *
93 gst_vaapi_display_drm_get_device_path(GstVaapiDisplayDRM *display);
94
95 G_END_DECLS
96
97 #endif /* GST_VAAPI_DISPLAY_DRM_H */