mirror of
https://github.com/mpv-player/mpv
synced 2024-12-24 07:33:46 +01:00
vo_xv: fix compilation when shared memory header files are not available
This is an extremely obscure situation, but can actually happen on OpenBSD.
This commit is contained in:
parent
9b3bf76d27
commit
413b2e3b0f
@ -229,10 +229,8 @@ static void allocate_xvimage(struct vo *vo, int foo)
|
||||
{
|
||||
struct xvctx *ctx = vo->priv;
|
||||
struct vo_x11_state *x11 = vo->x11;
|
||||
/*
|
||||
* allocate XvImages. FIXME: no error checking, without
|
||||
* mit-shm this will bomb... trzing to fix ::atmos
|
||||
*/
|
||||
// align it for faster OSD rendering (draw_bmp.c swscale usage)
|
||||
int aligned_w = FFALIGN(ctx->image_width, 32);
|
||||
#ifdef HAVE_SHM
|
||||
if (x11->display_is_local && XShmQueryExtension(x11->display))
|
||||
ctx->Shmem_Flag = 1;
|
||||
@ -240,7 +238,6 @@ static void allocate_xvimage(struct vo *vo, int foo)
|
||||
ctx->Shmem_Flag = 0;
|
||||
mp_tmsg(MSGT_VO, MSGL_INFO, "[VO_XV] Shared memory not supported\nReverting to normal Xv.\n");
|
||||
}
|
||||
int aligned_w = FFALIGN(ctx->image_width, 32);
|
||||
if (ctx->Shmem_Flag) {
|
||||
ctx->xvimage[foo] =
|
||||
(XvImage *) XvShmCreateImage(x11->display, x11->xv_port,
|
||||
|
Loading…
Reference in New Issue
Block a user