| OLD | NEW |
| 1 /* | 1 /* |
| 2 * H.26L/H.264/AVC/JVT/14496-10/... encoder/decoder | 2 * H.26L/H.264/AVC/JVT/14496-10/... encoder/decoder |
| 3 * Copyright (c) 2003 Michael Niedermayer <michaelni@gmx.at> | 3 * Copyright (c) 2003 Michael Niedermayer <michaelni@gmx.at> |
| 4 * | 4 * |
| 5 * This file is part of FFmpeg. | 5 * This file is part of FFmpeg. |
| 6 * | 6 * |
| 7 * FFmpeg is free software; you can redistribute it and/or | 7 * FFmpeg is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Lesser General Public | 8 * modify it under the terms of the GNU Lesser General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2.1 of the License, or (at your option) any later version. | 10 * version 2.1 of the License, or (at your option) any later version. |
| (...skipping 3674 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3685 } | 3685 } |
| 3686 #endif /* TEST */ | 3686 #endif /* TEST */ |
| 3687 | 3687 |
| 3688 | 3688 |
| 3689 av_cold void ff_h264_free_context(H264Context *h) | 3689 av_cold void ff_h264_free_context(H264Context *h) |
| 3690 { | 3690 { |
| 3691 int i; | 3691 int i; |
| 3692 | 3692 |
| 3693 free_tables(h); //FIXME cleanup init stuff perhaps | 3693 free_tables(h); //FIXME cleanup init stuff perhaps |
| 3694 | 3694 |
| 3695 if (!h->s.context_initialized) |
| 3696 return; |
| 3697 |
| 3695 for(i = 0; i < MAX_SPS_COUNT; i++) | 3698 for(i = 0; i < MAX_SPS_COUNT; i++) |
| 3696 av_freep(h->sps_buffers + i); | 3699 av_freep(h->sps_buffers + i); |
| 3697 | 3700 |
| 3698 for(i = 0; i < MAX_PPS_COUNT; i++) | 3701 for(i = 0; i < MAX_PPS_COUNT; i++) |
| 3699 av_freep(h->pps_buffers + i); | 3702 av_freep(h->pps_buffers + i); |
| 3700 } | 3703 } |
| 3701 | 3704 |
| 3702 av_cold int ff_h264_decode_end(AVCodecContext *avctx) | 3705 av_cold int ff_h264_decode_end(AVCodecContext *avctx) |
| 3703 { | 3706 { |
| 3704 H264Context *h = avctx->priv_data; | 3707 H264Context *h = avctx->priv_data; |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3738 ff_h264_decode_init, | 3741 ff_h264_decode_init, |
| 3739 NULL, | 3742 NULL, |
| 3740 ff_h264_decode_end, | 3743 ff_h264_decode_end, |
| 3741 decode_frame, | 3744 decode_frame, |
| 3742 CODEC_CAP_DR1 | CODEC_CAP_DELAY | CODEC_CAP_HWACCEL_VDPAU, | 3745 CODEC_CAP_DR1 | CODEC_CAP_DELAY | CODEC_CAP_HWACCEL_VDPAU, |
| 3743 .flush= flush_dpb, | 3746 .flush= flush_dpb, |
| 3744 .long_name = NULL_IF_CONFIG_SMALL("H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10
(VDPAU acceleration)"), | 3747 .long_name = NULL_IF_CONFIG_SMALL("H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10
(VDPAU acceleration)"), |
| 3745 .pix_fmts = (const enum PixelFormat[]){PIX_FMT_VDPAU_H264, PIX_FMT_NONE}, | 3748 .pix_fmts = (const enum PixelFormat[]){PIX_FMT_VDPAU_H264, PIX_FMT_NONE}, |
| 3746 }; | 3749 }; |
| 3747 #endif | 3750 #endif |
| OLD | NEW |