Commit 30efd37a authored by Erwan Tulou's avatar Erwan Tulou

core: fix a wrong division

Dividing an unsigned int by 2 is different from dividing an int by 2

This division was the cause for vlc(Win32) displaying a black screen
when zooming exceeded the display size (alt-'o')

Weirdly, there was no problem for Linux !!?? and also no regression :)
parent 3a6ce961
...@@ -255,7 +255,7 @@ void vout_display_PlacePicture(vout_display_place_t *place, ...@@ -255,7 +255,7 @@ void vout_display_PlacePicture(vout_display_place_t *place,
place->x = cfg->display.width - place->width; place->x = cfg->display.width - place->width;
break; break;
default: default:
place->x = (cfg->display.width - place->width) / 2; place->x = ((int)cfg->display.width - (int)place->width) / 2;
break; break;
} }
...@@ -267,7 +267,7 @@ void vout_display_PlacePicture(vout_display_place_t *place, ...@@ -267,7 +267,7 @@ void vout_display_PlacePicture(vout_display_place_t *place,
place->y = cfg->display.height - place->height; place->y = cfg->display.height - place->height;
break; break;
default: default:
place->y = (cfg->display.height - place->height) / 2; place->y = ((int)cfg->display.height - (int)place->height) / 2;
break; break;
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment