3 * Copyright (C) 2016 Igalia
6 * Víctor Manuel Jáquez Leal <vjaquez@igalia.com>
7 * Javier Martin <javiermartin@by.com.es>
9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public
11 * License as published by the Free Software Foundation; either
12 * version 2 of the License, or (at your option) any later version.
14 * This library is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 * Library General Public License for more details.
19 * You should have received a copy of the GNU Library General Public
20 * License along with this library; if not, write to the
21 * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
22 * Boston, MA 02110-1301, USA.
26 #ifndef __GST_KMS_SINK_H__
27 #define __GST_KMS_SINK_H__
29 #include <gst/video/gstvideosink.h>
33 #define GST_TYPE_KMS_SINK \
34 (gst_kms_sink_get_type())
35 #define GST_KMS_SINK(obj) \
36 (G_TYPE_CHECK_INSTANCE_CAST((obj), GST_TYPE_KMS_SINK, GstKMSSink))
37 #define GST_KMS_SINK_CLASS(klass) \
38 (G_TYPE_CHECK_CLASS_CAST((klass), GST_TYPE_KMS_SINK, GstKMSSinkClass))
39 #define GST_IS_KMS_SINK(obj) \
40 (G_TYPE_CHECK_INSTANCE_TYPE((obj), GST_TYPE_KMS_SINK))
41 #define GST_IS_KMS_SINK_CLASS(klass) \
42 (G_TYPE_CHECK_CLASS_TYPE((klass), GST_TYPE_KMS_SINK))
44 typedef struct _GstKMSSink GstKMSSink;
45 typedef struct _GstKMSSinkClass GstKMSSinkClass;
48 GstVideoSink videosink;
58 guint16 hdisplay, vdisplay;
62 gboolean has_prime_import;
63 gboolean has_async_page_flip;
66 gboolean modesetting_enabled;
69 GstCaps *allowed_caps;
71 GstAllocator *allocator;
72 GstBuffer *last_buffer;
73 GstMemory *tmp_kmsmem;
78 guint32 mm_width, mm_height;
84 struct _GstKMSSinkClass {
85 GstVideoSinkClass parent_class;
88 GType gst_kms_sink_get_type (void) G_GNUC_CONST;
92 #endif /* __GST_KMS_SINK_H__ */