mirror of
https://gitlab.xiph.org/xiph/ezstream.git
synced 2025-02-02 15:07:45 -05:00
Set usage flags for each format
This mirrors shout_set_format() behavior for the most part.
This commit is contained in:
parent
bee5067209
commit
c9426f2373
7
NEWS
7
NEWS
@ -1,3 +1,10 @@
|
||||
Changes in 1.NNN, released on YYYY-MM-DD:
|
||||
|
||||
* Fix regression when streaming formats other than Ogg (e.g. MP3). From
|
||||
zygmund2000 on Github (#30) and Roland Hermans on GitLab (#2271).
|
||||
|
||||
|
||||
|
||||
Changes in 1.0.2, released on 2021-02-12:
|
||||
|
||||
* Fix a crash, if metadata placeholders are configured for input files
|
||||
|
12
src/stream.c
12
src/stream.c
@ -216,7 +216,8 @@ _stream_cfg_stream(struct stream *s, cfg_stream_t cfg_stream)
|
||||
switch (cfg_stream_get_format(cfg_stream)) {
|
||||
case CFG_STREAM_OGG:
|
||||
if (SHOUTERR_SUCCESS !=
|
||||
shout_set_content_format(s->shout, SHOUT_FORMAT_OGG, 0, NULL)) {
|
||||
shout_set_content_format(s->shout, SHOUT_FORMAT_OGG,
|
||||
SHOUT_USAGE_UNKNOWN, NULL)) {
|
||||
log_error("stream: %s: format: %s: %s",
|
||||
s->name, cfg_stream_get_format_str(cfg_stream),
|
||||
shout_get_error(s->shout));
|
||||
@ -225,7 +226,8 @@ _stream_cfg_stream(struct stream *s, cfg_stream_t cfg_stream)
|
||||
break;
|
||||
case CFG_STREAM_MP3:
|
||||
if (SHOUTERR_SUCCESS !=
|
||||
shout_set_content_format(s->shout, SHOUT_FORMAT_MP3, 0, NULL)) {
|
||||
shout_set_content_format(s->shout, SHOUT_FORMAT_MP3,
|
||||
SHOUT_USAGE_AUDIO, NULL)) {
|
||||
log_error("stream: %s: format: %s: %s",
|
||||
s->name, cfg_stream_get_format_str(cfg_stream),
|
||||
shout_get_error(s->shout));
|
||||
@ -234,7 +236,8 @@ _stream_cfg_stream(struct stream *s, cfg_stream_t cfg_stream)
|
||||
break;
|
||||
case CFG_STREAM_WEBM:
|
||||
if (SHOUTERR_SUCCESS !=
|
||||
shout_set_content_format(s->shout, SHOUT_FORMAT_WEBM, 0, NULL)) {
|
||||
shout_set_content_format(s->shout, SHOUT_FORMAT_WEBM,
|
||||
SHOUT_USAGE_AUDIO|SHOUT_USAGE_VISUAL, NULL)) {
|
||||
log_error("stream: %s: format: %s: %s",
|
||||
s->name, cfg_stream_get_format_str(cfg_stream),
|
||||
shout_get_error(s->shout));
|
||||
@ -244,7 +247,8 @@ _stream_cfg_stream(struct stream *s, cfg_stream_t cfg_stream)
|
||||
#ifdef SHOUT_FORMAT_MATROSKA
|
||||
case CFG_STREAM_MATROSKA:
|
||||
if (SHOUTERR_SUCCESS !=
|
||||
shout_set_content_format(s->shout, SHOUT_FORMAT_MATROSKA, 0, NULL)) {
|
||||
shout_set_content_format(s->shout, SHOUT_FORMAT_MATROSKA,
|
||||
SHOUT_USAGE_AUDIO|SHOUT_USAGE_VISUAL, NULL)) {
|
||||
log_error("stream: %s: format: %s: %s",
|
||||
s->name, cfg_stream_get_format_str(cfg_stream),
|
||||
shout_get_error(s->shout));
|
||||
|
Loading…
Reference in New Issue
Block a user