summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2016-04-26 13:59:06 +0200
committerwm4 <wm4@nowhere>2016-04-26 13:59:06 +0200
commitdfa88271a2c76bfbd4dbc3fc87ee81bd0a74ec8e (patch)
treebf340f69df46d665bd869cbe1e76d8a4ac76c790
parent8ffd2f1dd429cd1ca0e7e0ef48aa15584a599264 (diff)
downloadmpv-dfa88271a2c76bfbd4dbc3fc87ee81bd0a74ec8e.tar.bz2
mpv-dfa88271a2c76bfbd4dbc3fc87ee81bd0a74ec8e.tar.xz
vp_rpi: fix indentation
This also moves the p->background check into the top if (the code effectively didn't do anything when this false).
-rw-r--r--video/out/vo_rpi.c18
1 files changed, 8 insertions, 10 deletions
diff --git a/video/out/vo_rpi.c b/video/out/vo_rpi.c
index 7ba3e8ba68..b192476e52 100644
--- a/video/out/vo_rpi.c
+++ b/video/out/vo_rpi.c
@@ -255,16 +255,15 @@ static int create_overlays(struct vo *vo)
struct priv *p = vo->priv;
destroy_overlays(vo);
- if (vo->opts->fullscreen) {
- // Use the whole screen.
- VC_RECT_T dst = {.width = p->w, .height = p->h};
- VC_RECT_T src = {.width = 1 << 16, .height = 1 << 16};
- VC_DISPMANX_ALPHA_T alpha = {
- .flags = DISPMANX_FLAGS_ALPHA_FIXED_ALL_PIXELS,
- .opacity = 0xFF,
- };
+ if (vo->opts->fullscreen && p->background) {
+ // Use the whole screen.
+ VC_RECT_T dst = {.width = p->w, .height = p->h};
+ VC_RECT_T src = {.width = 1 << 16, .height = 1 << 16};
+ VC_DISPMANX_ALPHA_T alpha = {
+ .flags = DISPMANX_FLAGS_ALPHA_FIXED_ALL_PIXELS,
+ .opacity = 0xFF,
+ };
- if (p->background) {
p->window = vc_dispmanx_element_add(p->update, p->display,
p->background_layer,
&dst, 0, &src,
@@ -275,7 +274,6 @@ static int create_overlays(struct vo *vo)
return -1;
}
}
- }
if (p->enable_osd) {
VC_RECT_T dst = {.x = p->x, .y = p->y,