diff options
author | nvidia <nvidia@nvidia.com> | 2015-11-04 15:57:23 +0000 |
---|---|---|
committer | Javier Jardón <jjardon@gnome.org> | 2015-11-04 16:07:49 +0000 |
commit | 72cd0878cf111dd1ec4081ece6d188122a293d64 (patch) | |
tree | 41c772015ff05a956e794fb3f419e00348e339bf /omx/gstomxvideodec.h | |
parent | f3f9330332050f6e18b8fbeabf3791604b862ab0 (diff) | |
download | gst-omx-72cd0878cf111dd1ec4081ece6d188122a293d64.tar.gz |
Add NVIDIA omx implementationbaserock/1.0.0.1/tegra
Diffstat (limited to 'omx/gstomxvideodec.h')
-rw-r--r-- | omx/gstomxvideodec.h | 45 |
1 files changed, 38 insertions, 7 deletions
diff --git a/omx/gstomxvideodec.h b/omx/gstomxvideodec.h index 3978865..c3601dc 100644 --- a/omx/gstomxvideodec.h +++ b/omx/gstomxvideodec.h @@ -1,6 +1,7 @@ /* * Copyright (C) 2011, Hewlett-Packard Development Company, L.P. * Author: Sebastian Dröge <sebastian.droege@collabora.co.uk>, Collabora Ltd. + * Copyright (c) 2013 - 2015, NVIDIA CORPORATION. All rights reserved. * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -32,7 +33,6 @@ #include "gstomx.h" G_BEGIN_DECLS - #define GST_TYPE_OMX_VIDEO_DEC \ (gst_omx_video_dec_get_type()) #define GST_OMX_VIDEO_DEC(obj) \ @@ -45,10 +45,19 @@ G_BEGIN_DECLS (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_OMX_VIDEO_DEC)) #define GST_IS_OMX_VIDEO_DEC_CLASS(obj) \ (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_OMX_VIDEO_DEC)) - typedef struct _GstOMXVideoDec GstOMXVideoDec; typedef struct _GstOMXVideoDecClass GstOMXVideoDecClass; + +#ifdef USE_OMX_TARGET_TEGRA +typedef enum +{ + BUF_EGL, + BUF_NVMM, + BUF_NB +} NvBufType; +#endif + struct _GstOMXVideoDec { GstVideoDecoder parent; @@ -56,7 +65,7 @@ struct _GstOMXVideoDec /* < protected > */ GstOMXComponent *dec; GstOMXPort *dec_in_port, *dec_out_port; - + GstBufferPool *in_port_pool, *out_port_pool; /* < private > */ @@ -78,9 +87,20 @@ struct _GstOMXVideoDec gboolean eos; GstFlowReturn downstream_flow_ret; + +#ifdef USE_OMX_TARGET_TEGRA + gboolean use_omxdec_res; + gboolean full_frame_data; + gboolean disable_dpb; + guint32 skip_frames; +#endif + #ifdef USE_OMX_TARGET_RPI GstOMXComponent *egl_render; GstOMXPort *egl_in_port, *egl_out_port; +#endif + +#if defined (USE_OMX_TARGET_RPI) || defined (USE_OMX_TARGET_TEGRA) gboolean eglimage; #endif }; @@ -91,13 +111,24 @@ struct _GstOMXVideoDecClass GstOMXClassData cdata; - gboolean (*is_format_change) (GstOMXVideoDec * self, GstOMXPort * port, GstVideoCodecState * state); - gboolean (*set_format) (GstOMXVideoDec * self, GstOMXPort * port, GstVideoCodecState * state); - GstFlowReturn (*prepare_frame) (GstOMXVideoDec * self, GstVideoCodecFrame *frame); + gboolean (*is_format_change) (GstOMXVideoDec * self, GstOMXPort * port, + GstVideoCodecState * state); + gboolean (*set_format) (GstOMXVideoDec * self, GstOMXPort * port, + GstVideoCodecState * state); + GstFlowReturn (*prepare_frame) (GstOMXVideoDec * self, + GstVideoCodecFrame * frame); }; GType gst_omx_video_dec_get_type (void); -G_END_DECLS +OMX_ERRORTYPE gst_omx_set_full_frame_data_property (OMX_HANDLETYPE omx_handle); + +typedef enum +{ + GST_DECODE_ALL, + GST_SKIP_NON_REF_FRAMES, + GST_DECODE_KEY_FRAMES +} GstVideoSkipFrames; +G_END_DECLS #endif /* __GST_OMX_VIDEO_DEC_H__ */ |