videoaggregator: Expose vmethods to set converters and prepare/clean frames

This gives more flexibility to the subclasses and permits to remove the
GstVideoAggregatorClass->disable_frame_conversion ugly API.

WARNING: This breaks the API as it removes the disable_frame_conversion
field

API:
  + GstVideoAggregatorClass->find_best_format
  + GstVideoAggregatorPadClass->set_format
  + GstVideoAggregatorPadClass->prepare_frame
  + GstVideoAggregatorPadClass->clean_frame

  - GstVideoAggregatorClass->disable_frame_conversion

https://bugzilla.gnome.org/show_bug.cgi?id=740768
This commit is contained in:
Thibault Saunier 2014-11-26 18:24:05 +01:00 committed by Tim-Philipp Müller
parent a6f02d4b29
commit d3fef37d61

View file

@ -87,11 +87,17 @@ static void
gst_gl_mixer_pad_class_init (GstGLMixerPadClass * klass)
{
GObjectClass *gobject_class = (GObjectClass *) klass;
GstVideoAggregatorPadClass *vaggpad_class =
(GstVideoAggregatorPadClass *) klass;
gobject_class->set_property = gst_gl_mixer_pad_set_property;
gobject_class->get_property = gst_gl_mixer_pad_get_property;
gobject_class->finalize = gst_gl_mixer_pad_finalize;
vaggpad_class->set_info = NULL;
vaggpad_class->prepare_frame = NULL;
vaggpad_class->clean_frame = NULL;
}
static void
@ -592,10 +598,10 @@ gst_gl_mixer_class_init (GstGLMixerClass * klass)
agg_class->stop = gst_gl_mixer_stop;
agg_class->start = gst_gl_mixer_start;
videoaggregator_class->disable_frame_conversion = TRUE;
videoaggregator_class->aggregate_frames = gst_gl_mixer_aggregate_frames;
videoaggregator_class->get_output_buffer = gst_gl_mixer_get_output_buffer;
videoaggregator_class->negotiated_caps = _negotiated_caps;
videoaggregator_class->find_best_format = NULL;
g_object_class_install_property (gobject_class, PROP_CONTEXT,
g_param_spec_object ("context",