Le 2014-12-11 04:28, Vittorio Giovara a écrit :
diff --git a/libavcodec/vdpau.c b/libavcodec/vdpau.c index ccb3352..edf09f1 100644 --- a/libavcodec/vdpau.c +++ b/libavcodec/vdpau.c @@ -64,6 +64,21 @@ static int vdpau_error(VdpStatus status) } }+int av_vdpau_get_surface_parameters(AVCodecContext *avctx, VdpChromaType *type, + uint32_t *width, uint32_t *height)+{ + /* XXX: only 8-bits YCbCr 4:2:0 is supported yet */ + if (type) + *type = VDP_CHROMA_TYPE_420; + /* See <vdpau/vdpau.h> for per-type alignment constraints. */ + if (width) + *width = (avctx->coded_width + 1) & ~1; + if (height) + *height = (avctx->coded_height + 3) & ~3; + + return 0; +}this function seems to never fail, maybe it's fine to make it void?
I would rather not. We could (later) redefine the function to return an error in cases where it currently is undefined for instance.
-- Rémi Denis-Courmont _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
