Re: gstreamermm option group does not init



Marcus Brinkmann wrote:
I hate my idea already.  The same user data is also used for the error
hook (not a big problem, but wrapping it requires yet another getter
function), and also for each G_OPTION_ARG_CALLBACK option, and we
definitely don't want to wrap each of those.  Bummer.  The proper
solution is to have different user data for different purposes, but
that is a slightly bigger change on which the glib people might have
some opinions.  This will probably slow things down.

So, here is the work around:  After parsing options, I call:

  int argc_hack = 0;
  char *argv_hack = NULL;
  Gst::init (argc_hack, argv_hack);

You have to do this now, but after a fix, you probably wont need a hack. One possibility to getting rid of the hack would be to override the Gst::init() method with no arguments thus removing the need for the extra variables. While you think about your solution, other ideas may also surface and this can certainly be corrected.

Which completes initialization.  By the way, I didn't get a response
with regards to the discrepancy of initialization calls in Gst::init
vs Gst::init_check.  Not that I know much about what these functions
do, but init and init_check look kinda out of sync.

The Gst::init_check() method was simply overlooked. It is fixed in svn. Thanks.

I totally agree that getting GOption integration to work properly is
not a high priority item.  I'll wait a couple of days, and if no other
ideas pop up I will add the end result of the discussion plus the work
around to the bug report for reference at a later time.

Thanks,
Marcus

--
José Alburquerque
jaalburquerque cox net



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