diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2011-10-31 02:26:37 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2011-10-31 02:26:47 +0100 |
commit | 0489af478e5f490aee2d96daa29043b590c8d280 (patch) | |
tree | 4b87c989fd78132150f8bed362d19d081ac50e47 /libavcodec/libdiracdec.c | |
parent | e484b64ce37e7bc7556c6113ce6f10671e20f61f (diff) | |
parent | 45235d69c271966409cdd3eaa022258c22e04fdb (diff) | |
download | ffmpeg-0489af478e5f490aee2d96daa29043b590c8d280.tar.gz |
Merge remote-tracking branch 'qatar/master'
* qatar/master:
libdirac/libschroedinger: Drop unnecessary symbol prefixes.
cmdutils: check fread() return value
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/libdiracdec.c')
-rw-r--r-- | libavcodec/libdiracdec.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/libavcodec/libdiracdec.c b/libavcodec/libdiracdec.c index 24a4a06929..ed8b16d6dc 100644 --- a/libavcodec/libdiracdec.c +++ b/libavcodec/libdiracdec.c @@ -37,34 +37,34 @@ #include <libdirac_decoder/dirac_parser.h> /** contains a single frame returned from Dirac */ -typedef struct FfmpegDiracDecoderParams { +typedef struct DiracDecoderParams { /** decoder handle */ dirac_decoder_t* p_decoder; /** buffer to hold decoded frame */ unsigned char* p_out_frame_buf; -} FfmpegDiracDecoderParams; +} DiracDecoderParams; /** * returns FFmpeg chroma format */ -static enum PixelFormat GetFfmpegChromaFormat(dirac_chroma_t dirac_pix_fmt) +static enum PixelFormat get_chroma_format(dirac_chroma_t dirac_pix_fmt) { - int num_formats = sizeof(ffmpeg_dirac_pixel_format_map) / - sizeof(ffmpeg_dirac_pixel_format_map[0]); + int num_formats = sizeof(dirac_pixel_format_map) / + sizeof(dirac_pixel_format_map[0]); int idx; for (idx = 0; idx < num_formats; ++idx) - if (ffmpeg_dirac_pixel_format_map[idx].dirac_pix_fmt == dirac_pix_fmt) - return ffmpeg_dirac_pixel_format_map[idx].ff_pix_fmt; + if (dirac_pixel_format_map[idx].dirac_pix_fmt == dirac_pix_fmt) + return dirac_pixel_format_map[idx].ff_pix_fmt; return PIX_FMT_NONE; } static av_cold int libdirac_decode_init(AVCodecContext *avccontext) { - FfmpegDiracDecoderParams *p_dirac_params = avccontext->priv_data; + DiracDecoderParams *p_dirac_params = avccontext->priv_data; p_dirac_params->p_decoder = dirac_decoder_init(avccontext->debug); if (!p_dirac_params->p_decoder) @@ -80,7 +80,7 @@ static int libdirac_decode_frame(AVCodecContext *avccontext, const uint8_t *buf = avpkt->data; int buf_size = avpkt->size; - FfmpegDiracDecoderParams *p_dirac_params = avccontext->priv_data; + DiracDecoderParams *p_dirac_params = avccontext->priv_data; AVPicture *picture = data; AVPicture pic; int pict_size; @@ -117,7 +117,7 @@ static int libdirac_decode_frame(AVCodecContext *avccontext, avccontext->height = src_params->height; avccontext->width = src_params->width; - avccontext->pix_fmt = GetFfmpegChromaFormat(src_params->chroma); + avccontext->pix_fmt = get_chroma_format(src_params->chroma); if (avccontext->pix_fmt == PIX_FMT_NONE) { av_log(avccontext, AV_LOG_ERROR, "Dirac chroma format %d not supported currently\n", @@ -174,7 +174,7 @@ static int libdirac_decode_frame(AVCodecContext *avccontext, static av_cold int libdirac_decode_close(AVCodecContext *avccontext) { - FfmpegDiracDecoderParams *p_dirac_params = avccontext->priv_data; + DiracDecoderParams *p_dirac_params = avccontext->priv_data; dirac_decoder_close(p_dirac_params->p_decoder); av_freep(&p_dirac_params->p_out_frame_buf); @@ -198,7 +198,7 @@ AVCodec ff_libdirac_decoder = { .name = "libdirac", .type = AVMEDIA_TYPE_VIDEO, .id = CODEC_ID_DIRAC, - .priv_data_size = sizeof(FfmpegDiracDecoderParams), + .priv_data_size = sizeof(DiracDecoderParams), .init = libdirac_decode_init, .close = libdirac_decode_close, .decode = libdirac_decode_frame, |