Re: Gst::PlayBin2::create() error: *** glibc detected *** ./main: malloc(): memory corruption (fast): 0x00000000009b71d0 ***



On 17/12/2012 14:06, Chow Loong Jin wrote:
> On 17/12/2012 13:51, José Alburquerque wrote:
>> One possibility is that a playbin2 signal that gstreamermm expects to exist has
>> been removed in the existing gst-plugins-base package of the run system.  By any
>> chance, are the versions of GStreamer and gst-base-plugins on the system 1.0 or
>> greater?  gstreamermm-0.10.x versions will most likely not work with the 1.0.x
>> versions.
> 
> We've got both gst 1.0 and 0.10 here in separate packages, with libgstreamermm
> linking against 0.10.
> 
> Speaking of which, is there a gstreamermm 1.0 coming soon?


I just looked further into the issue, and figured that this was caused by a
struct size difference -- gstplaybin2.c from gst-plugins-base-0.10 has:

----8<----
struct _GstPlayBinClass
{
  GstPipelineClass parent_class;

  /* notify app that the current uri finished decoding and it is possible to
   * queue a new one for gapless playback */
  void (*about_to_finish) (GstPlayBin * playbin);

  /* notify app that number of audio/video/text streams changed */
  void (*video_changed) (GstPlayBin * playbin);
  void (*audio_changed) (GstPlayBin * playbin);
  void (*text_changed) (GstPlayBin * playbin);

  /* notify app that the tags of audio/video/text streams changed */
  void (*video_tags_changed) (GstPlayBin * playbin, gint stream);
  void (*audio_tags_changed) (GstPlayBin * playbin, gint stream);
  void (*text_tags_changed) (GstPlayBin * playbin, gint stream);

  /* get audio/video/text tags for a stream */
  GstTagList *(*get_video_tags) (GstPlayBin * playbin, gint stream);
  GstTagList *(*get_audio_tags) (GstPlayBin * playbin, gint stream);
  GstTagList *(*get_text_tags) (GstPlayBin * playbin, gint stream);

  /* get the last video frame and convert it to the given caps */
  GstBuffer *(*convert_frame) (GstPlayBin * playbin, GstCaps * caps);

  /* get audio/video/text pad for a stream */
  GstPad *(*get_video_pad) (GstPlayBin * playbin, gint stream);
  GstPad *(*get_audio_pad) (GstPlayBin * playbin, gint stream);
  GstPad *(*get_text_pad) (GstPlayBin * playbin, gint stream);
};
---->8----

whereas playbin2.cc from gstreamermm has:
----8<----
struct _GstPlayBin2Class
{
  GstPipelineClass parent_class;
  void (*about_to_finish) (GstPlayBin2* element);
  void (*video_changed) (GstPlayBin2* element);
  void (*audio_changed) (GstPlayBin2* element);
  void (*text_changed) (GstPlayBin2* element);
  void (*video_tags_changed) (GstPlayBin2* element, gint arg0);
  void (*audio_tags_changed) (GstPlayBin2* element, gint arg0);
  void (*text_tags_changed) (GstPlayBin2* element, gint arg0);
  void (*source_setup) (GstPlayBin2* element, GstElement* arg0);
  GstTagList* (*get_video_tags) (GstPlayBin2* element, gint arg0);
  GstTagList* (*get_audio_tags) (GstPlayBin2* element, gint arg0);
  GstTagList* (*get_text_tags) (GstPlayBin2* element, gint arg0);
  GstBuffer* (*convert_frame) (GstPlayBin2* element, GstCaps* arg0);
  GstPad* (*get_video_pad) (GstPlayBin2* element, gint arg0);
  GstPad* (*get_audio_pad) (GstPlayBin2* element, gint arg0);
  GstPad* (*get_text_pad) (GstPlayBin2* element, gint arg0);
};
---->8----

It looks like the "source_setup" member is missing from gstreamermm. The
situation looks pretty ugly, really. Must this struct definition really be
duplicated across two different codebases?

-- 
Kind regards,
Loong Jin

Attachment: signature.asc
Description: OpenPGP digital signature



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]