summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJonathan Sieber <mail@strfry.org>2017-07-10 10:28:59 +0200
committerAlfred E. Heggestad <alfred.heggestad@gmail.com>2017-07-10 10:28:59 +0200
commit0806171f16d34791a3025c25c38edcb76a70c107 (patch)
treefc3fbc79a273023f1431d1f194b45c358739ea3f /src
parent49df75bec3fb305a4c2f50d966ea15c3f1dd52b9 (diff)
Make sdl2 Fullscreen Mode configurable (#279)
* vidisp: add fullscreen flag * Add video_fullscreen option
Diffstat (limited to 'src')
-rw-r--r--src/config.c5
-rw-r--r--src/video.c1
2 files changed, 5 insertions, 1 deletions
diff --git a/src/config.c b/src/config.c
index 9f2de5d..960861c 100644
--- a/src/config.c
+++ b/src/config.c
@@ -61,6 +61,7 @@ static struct config core_config = {
352, 288,
500000,
25,
+ true,
},
#endif
@@ -212,6 +213,7 @@ int config_parse_conf(struct config *cfg, const struct conf *conf)
}
(void)conf_get_u32(conf, "video_bitrate", &cfg->video.bitrate);
(void)conf_get_u32(conf, "video_fps", &cfg->video.fps);
+ (void)conf_get_bool(conf, "video_fullscreen", &cfg->video.fullscreen);
#else
(void)size;
#endif
@@ -470,7 +472,8 @@ static int core_config_template(struct re_printf *pf, const struct config *cfg)
"#video_display\t\t%s\n"
"video_size\t\t%dx%d\n"
"video_bitrate\t\t%u\n"
- "video_fps\t\t%u\n",
+ "video_fps\t\t%u\n"
+ "video_fullscreen\t\tyes\n",
default_video_device(),
default_video_display(),
cfg->video.width, cfg->video.height,
diff --git a/src/video.c b/src/video.c
index 32b256f..8818631 100644
--- a/src/video.c
+++ b/src/video.c
@@ -871,6 +871,7 @@ static int set_vidisp(struct vrx *vrx)
vrx->vidisp = mem_deref(vrx->vidisp);
vrx->vidisp_prm.view = NULL;
+ vrx->vidisp_prm.fullscreen = vrx->video->cfg.fullscreen;
vd = (struct vidisp *)vidisp_find(baresip_vidispl(),
vrx->video->cfg.disp_mod);