[FFmpeg-devel] [PATCH] HWAccel infrastructure (take 7.2)
Gwenole Beauchesne
gbeauchesne
Tue Feb 24 15:51:48 CET 2009
On Tue, 24 Feb 2009, Michael Niedermayer wrote:
>> +/**
>> + * Allowed pixel formats for H.263 codec (4:2:0 chroma format)
>> + * Note: HW accelerated formats shall come first
>> + */
>> +static const enum PixelFormat h263_pixfmt_list_420[] = {
>> + PIX_FMT_YUV420P,
>> + PIX_FMT_NONE
>> +};
>> +
>> +/**
>> + * Allowed pixel formats for MPEG-4 codec (4:2:0 chroma format)
>> + * Note: HW accelerated formats shall come first
>> + */
>> +static const enum PixelFormat mpeg4_pixfmt_list_420[] = {
>> + PIX_FMT_YUV420P,
>> + PIX_FMT_NONE
>> +};
>
> duplicate
Please think N+1 or N+2. This will be filled in differently in next patch,
thus making them smaller...
>> +/** Returns the pixel format list for the specified codec (4:2:0 chroma format) */
>> +static inline const enum PixelFormat *get_pixfmt_list(enum CodecID codec_id)
>> +{
>> + switch (codec_id) {
>> + case CODEC_ID_H263: return h263_pixfmt_list_420;
>> + case CODEC_ID_MPEG4: return mpeg4_pixfmt_list_420;
>> + default: assert(0);
>> + }
>> + return NULL;
>> +}
>> +
>> av_cold int ff_h263_decode_init(AVCodecContext *avctx)
>> {
>> MpegEncContext *s = avctx->priv_data;
>
> this makes no sense
but to suit space and indentation satanists (fit one line instead of
spanning it all over several lines).
More information about the ffmpeg-devel
mailing list