mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-20 07:16:55 +00:00
omxaacenc: Implement ::get_num_samples() vfunc
This commit is contained in:
parent
d1e1980e01
commit
0928205ed4
1 changed files with 12 additions and 0 deletions
|
@ -39,6 +39,8 @@ static gboolean gst_omx_aac_enc_set_format (GstOMXAudioEnc * enc,
|
|||
GstOMXPort * port, GstAudioState * state);
|
||||
static GstCaps *gst_omx_aac_enc_get_caps (GstOMXAudioEnc * enc,
|
||||
GstOMXPort * port, GstAudioState * state);
|
||||
static guint gst_omx_aac_enc_get_num_samples (GstOMXAudioEnc * enc,
|
||||
GstOMXPort * port, GstAudioState * state, GstOMXBuffer * buf);
|
||||
|
||||
enum
|
||||
{
|
||||
|
@ -156,6 +158,8 @@ gst_omx_aac_enc_class_init (GstOMXAACEncClass * klass)
|
|||
|
||||
audioenc_class->set_format = GST_DEBUG_FUNCPTR (gst_omx_aac_enc_set_format);
|
||||
audioenc_class->get_caps = GST_DEBUG_FUNCPTR (gst_omx_aac_enc_get_caps);
|
||||
audioenc_class->get_num_samples =
|
||||
GST_DEBUG_FUNCPTR (gst_omx_aac_enc_get_num_samples);
|
||||
|
||||
audioenc_class->default_src_template_caps = "audio/mpeg, "
|
||||
"mpegversion=(int){2, 4}, "
|
||||
|
@ -430,3 +434,11 @@ gst_omx_aac_enc_get_caps (GstOMXAudioEnc * enc, GstOMXPort * port,
|
|||
|
||||
return caps;
|
||||
}
|
||||
|
||||
static guint
|
||||
gst_omx_aac_enc_get_num_samples (GstOMXAudioEnc * enc, GstOMXPort * port,
|
||||
GstAudioState * state, GstOMXBuffer * buf)
|
||||
{
|
||||
/* FIXME: Depends on the profile at least */
|
||||
return 1024;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue