[Bug 765314] player: Add way to override HTTP (+RTSP, etc) user agent
GStreamer (GNOME Bugzilla)
bugzilla at gnome.org
Fri Jul 22 13:42:14 UTC 2016
https://bugzilla.gnome.org/show_bug.cgi?id=765314
--- Comment #6 from Guillaume Desmottes <gdesmott at gnome.org> ---
(In reply to Sebastian Dröge (slomo) from comment #4)
> Review of attachment 331784 [details] [review]:
>
> ::: gst-libs/gst/player/gstplayer.h
> @@ +195,3 @@
> +const gchar * gst_player_get_http_user_agent (GstPlayer *
> player);
> +void gst_player_set_http_user_agent (GstPlayer *
> player,
> + const gchar *agent);
>
> This is not only for HTTP but also for RTSP and probably others.
>
> I think it would also be nice to not add a million such configuration
> functions, but maybe create some kind of "configuration object" instead
> (could be based on a GstStructure like the GstBufferPoolConfig for example)
> for the things that you configure once and don't change during playback.
Makes sense yeah.
Something like this then?
void gst_player_config_set_user_agent (GstStructure *config, const gchar
*user_name);
const gchar * gst_player_config_get_user_agent (GstStructure *config);
void gst_player_set_config (GstPlayer *player, GstStructure *config);
Or something every more generic based on key/value? That would save us from
adding API for each new option but maybe kinda defeat the purpose of GstPlayer
of being a very high level easy API.
> ::: tests/check/libs/player.c
> @@ +1649,3 @@
> + src = gst_bin_get_by_interface (GST_BIN (pipeline), GST_TYPE_URI_HANDLER);
> + /* FIXME: this test is racy: the souphttpsrc element may be destroyed
> before
> + * the error is reported from the player. */
>
> You could connect to source-setup of the pipeline instead maybe
Good idea, that seems to work. Thanks!
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
More information about the gstreamer-bugs
mailing list