• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* GStreamer NVENC plugin
2  * Copyright (C) 2015 Centricular Ltd
3  *
4  * This library is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Library General Public
6  * License as published by the Free Software Foundation; either
7  * version 2 of the License, or (at your option) any later version.
8  *
9  * This library is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12  * Library General Public License for more details.
13  *
14  * You should have received a copy of the GNU Library General Public
15  * License along with this library; if not, write to the
16  * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17  * Boston, MA 02110-1301, USA.
18  */
19 
20 #ifndef __GST_NV_H264_ENC_H_INCLUDED__
21 #define __GST_NV_H264_ENC_H_INCLUDED__
22 
23 #include "gstnvbaseenc.h"
24 
25 #define GST_TYPE_NV_H264_ENC \
26   (gst_nv_h264_enc_get_type())
27 #define GST_NV_H264_ENC(obj) \
28   (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_NV_H264_ENC,GstNvH264Enc))
29 #define GST_NV_H264_ENC_CLASS(klass) \
30   (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_NV_H264_ENC,GstNvH264EncClass))
31 #define GST_NV_H264_ENC_GET_CLASS(obj) \
32   (G_TYPE_INSTANCE_GET_CLASS((obj),GST_TYPE_NV_H264_ENC,GstNvH264EncClass))
33 #define GST_IS_NV_H264_ENC(obj) \
34   (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_NV_H264_ENC))
35 #define GST_IS_NV_H264_ENC_CLASS(obj) \
36   (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_NV_H264_ENC))
37 
38 typedef struct {
39   GstNvBaseEnc base_nvenc;
40 
41   /* the supported input formats */
42   GValue        * supported_profiles;             /* OBJECT LOCK */
43 
44   GstVideoCodecState *input_state;
45   gboolean            gl_input;
46 
47   /* supported interlacing input modes.
48    * 0 = none, 1 = fields, 2 = interleaved */
49   gint            interlace_modes;
50 } GstNvH264Enc;
51 
52 typedef struct {
53   GstNvBaseEncClass video_encoder_class;
54 } GstNvH264EncClass;
55 
56 G_GNUC_INTERNAL
57 GType gst_nv_h264_enc_get_type (void);
58 
59 #endif /* __GST_NV_H264_ENC_H_INCLUDED__ */
60