Beispiel #1
0
static struct mp_image *d3d11va_allocate_image(struct lavc_ctx *s, int w, int h)
{
    struct priv *p = s->hwdec_priv;
    struct mp_image *img = mp_image_pool_get_no_alloc(p->decoder->pool,
                                                      IMGFMT_D3D11VA, w, h);
    if (!img)
        MP_ERR(p, "Failed to get free D3D11VA surface\n");
    return img;
}
Beispiel #2
0
static struct mp_image *dxva2_allocate_image(struct lavc_ctx *s, int w, int h)
{
    struct priv *p = s->hwdec_priv;
    struct mp_image *img = mp_image_pool_get_no_alloc(p->decoder_pool,
                                                      IMGFMT_DXVA2, w, h);
    if (!img)
        MP_ERR(p, "Failed to allocate additional DXVA2 surface.\n");
    return img;
}