[FFmpeg-cvslog] vdpau: do not use buggy HEVC support by default
ffmpeg | branch: master | wm4 | Sat Jul 1 11:40:10 2017 +0200| [64ecb78b7179cab2dbdf835463104679dbb7c895] | committer: wm4 vdpau: do not use buggy HEVC support by default NVIDIA broke its own API when using VDPAU decoding. If you retrieve the decoded YUV data, or if you map the surfaces with GL interop, the result are interlacing artifacts. The only way to get non-broken data is by using the vdpau video mixer to convert it to RGB. There is no way to block the non-working operations in a reasonable way (a VdpVideoSurface has to support all operations). NVIDIA refuses to fix this issue (they "fixed" it by making it work with the video mixer, but the rest is still broken). There is no sign of that changing. Do not use HEVC by default with the generic hwaccle API. Detect whether it's the NVIDIA native implementation, and exit with an error. (The same thing work with the MESA implementation.) As an escape hatch and to allow applications to use the decoder if they really want to (perhaps because they make sure to explicitly use the video mixer), reuse AV_HWACCEL_FLAG_ALLOW_PROFILE_MISMATCH to disable this check. Once NVIDIA fixes the bug, working driver versions could be detected, and it could be allowed again. > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=64ecb78b7179cab2dbdf835463104679dbb7c895 --- libavcodec/vdpau.c | 19 +++ 1 file changed, 19 insertions(+) diff --git a/libavcodec/vdpau.c b/libavcodec/vdpau.c index 9c7804a287..42ebddbeee 100644 --- a/libavcodec/vdpau.c +++ b/libavcodec/vdpau.c @@ -127,6 +127,8 @@ int ff_vdpau_common_init(AVCodecContext *avctx, VdpDecoderProfile profile, VdpVideoSurfaceQueryCapabilities *surface_query_caps; VdpDecoderQueryCapabilities *decoder_query_caps; VdpDecoderCreate *create; +VdpGetInformationString *info; +const char *info_string; void *func; VdpStatus status; VdpBool supported; @@ -209,6 +211,23 @@ int ff_vdpau_common_init(AVCodecContext *avctx, VdpDecoderProfile profile, return AVERROR(ENOTSUP); status = vdctx->get_proc_address(vdctx->device, + VDP_FUNC_ID_GET_INFORMATION_STRING, + &func); +if (status != VDP_STATUS_OK) +return vdpau_error(status); +else +info = func; + +status = info(&info_string); +if (status != VDP_STATUS_OK) +return vdpau_error(status); +if (avctx->codec_id == AV_CODEC_ID_HEVC && strncmp(info_string, "NVIDIA ", 7) == 0 && +!(avctx->hwaccel_flags & AV_HWACCEL_FLAG_ALLOW_PROFILE_MISMATCH)) { +av_log(avctx, AV_LOG_VERBOSE, "HEVC with NVIDIA VDPAU drivers is buggy, skipping.\n"); +return AVERROR(ENOTSUP); +} + +status = vdctx->get_proc_address(vdctx->device, VDP_FUNC_ID_VIDEO_SURFACE_QUERY_CAPABILITIES, &func); if (status != VDP_STATUS_OK) ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] avfomat/hlsenc: support fmp4 format in hls
ffmpeg | branch: master | Steven Liu | Mon Jul 3 20:20:44 2017 +0800| [274bd1670b9c85e24f37d08f9043dd82e0a28c67] | committer: Steven Liu avfomat/hlsenc: support fmp4 format in hls add the fmp4 format into hlsenc because the fmp4 format add into hls from version 7. the spec link is: https://tools.ietf.org/html/draft-pantos-http-live-streaming-20 and the describe on WWDC https://developer.apple.com/videos/play/wwdc2017/515/ Signed-off-by: Steven Liu > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=274bd1670b9c85e24f37d08f9043dd82e0a28c67 --- doc/muxers.texi | 17 libavformat/hlsenc.c | 107 +++ 2 files changed, 108 insertions(+), 16 deletions(-) diff --git a/doc/muxers.texi b/doc/muxers.texi index 0866142d43..94472cef44 100644 --- a/doc/muxers.texi +++ b/doc/muxers.texi @@ -614,6 +614,23 @@ in the playlist. Hex-coded 16byte initialization vector for every segment instead of the autogenerated ones. +@item hls_segment_type @var{flags} +Possible values: + +@table @samp +@item mpegts +If this flag is set, the hls segment files will format to mpegts. +the mpegts files is used in all hls versions. + +@item fmp4 +If this flag is set, the hls segment files will format to fragment mp4 looks like dash. +the fmp4 files is used in hls after version 7. + +@end table + +@item hls_fmp4_init_filename @var{filename} +set filename to the fragment files header file, default filename is @file{init.mp4}. + @item hls_flags @var{flags} Possible values: diff --git a/libavformat/hlsenc.c b/libavformat/hlsenc.c index 40143c86aa..a49b594ad2 100644 --- a/libavformat/hlsenc.c +++ b/libavformat/hlsenc.c @@ -88,6 +88,11 @@ typedef enum HLSFlags { } HLSFlags; typedef enum { +SEGMENT_TYPE_MPEGTS, +SEGMENT_TYPE_FMP4, +} SegmentType; + +typedef enum { PLAYLIST_TYPE_NONE, PLAYLIST_TYPE_EVENT, PLAYLIST_TYPE_VOD, @@ -115,6 +120,9 @@ typedef struct HLSContext { uint32_t flags;// enum HLSFlags uint32_t pl_type; // enum PlaylistType char *segment_filename; +char *fmp4_init_filename; +int segment_type; +int fmp4_init_mode; int use_localtime; ///< flag to expand filename with localtime int use_localtime_mkdir;///< flag to mkdir dirname in timebased filename @@ -256,6 +264,16 @@ fail: return -1; } +static void write_styp(AVIOContext *pb) +{ +avio_wb32(pb, 24); +ffio_wfourcc(pb, "styp"); +ffio_wfourcc(pb, "msdh"); +avio_wb32(pb, 0); /* minor */ +ffio_wfourcc(pb, "msdh"); +ffio_wfourcc(pb, "msix"); +} + static int hls_delete_old_segments(AVFormatContext *s, HLSContext *hls) { HLSSegment *segment, *previous_segment = NULL; @@ -508,6 +526,7 @@ static int read_chomp_line(AVIOContext *s, char *buf, int maxlen) static int hls_mux_init(AVFormatContext *s) { +AVDictionary *options = NULL; HLSContext *hls = s->priv_data; AVFormatContext *oc; AVFormatContext *vtt_oc = NULL; @@ -553,7 +572,35 @@ static int hls_mux_init(AVFormatContext *s) } hls->start_pos = 0; hls->new_start = 1; +hls->fmp4_init_mode = 0; +if (hls->segment_type == SEGMENT_TYPE_FMP4) { +hls->fmp4_init_mode = 1; +if ((ret = s->io_open(s, &oc->pb, hls->fmp4_init_filename, AVIO_FLAG_WRITE, NULL)) < 0) { +av_log(s, AV_LOG_ERROR, "Failed to open segment '%s'\n", hls->fmp4_init_filename); +return ret; +} + +if (hls->format_options_str) { +ret = av_dict_parse_string(&hls->format_options, hls->format_options_str, "=", ":", 0); +if (ret < 0) { +av_log(s, AV_LOG_ERROR, "Could not parse format options list '%s'\n", + hls->format_options_str); +return ret; +} +} + +av_dict_copy(&options, hls->format_options, 0); +av_dict_set(&options, "fflags", "-autobsf", 0); +av_dict_set(&options, "movflags", "frag_custom+dash+delay_moov", 0); +ret = avformat_init_output(oc, &options); +if (av_dict_count(options)) { +av_log(s, AV_LOG_ERROR, "Some of the provided format options in '%s' are not recognized\n", hls->format_options_str); +av_dict_free(&options); +return AVERROR(EINVAL); +} +av_dict_free(&options); +} return 0; } @@ -922,6 +969,9 @@ static void write_m3u8_head_block(HLSContext *hls, AVIOContext *out, int version } avio_printf(out, "#EXT-X-TARGETDURATION:%d\n", target_duration); avio_printf(out, "#EXT-X-MEDIA-SEQUENCE:%"PRId64"\n", sequence); +if (hls->segment_type == SEGMENT_TYPE_FMP4) { +avio_printf(out, "#EXT-X-MAP:URI=\"%s\"\n", hls->fmp4_init_filename); +} av_log(hls, AV_LOG_VERBOSE, "EXT-X-MEDIA-SEQUENCE:%"PRId64"\n", sequence); } @@ -961,6 +1011,10 @@ static int hls_window(AVFormatContext *s, int last) sequence = 0; } +if (hls
[FFmpeg-cvslog] checkasm: add sbrdsp tests
ffmpeg | branch: master | Matthieu Bouron | Fri Jun 9 09:34:12 2017 +| [7864e07f4af248d35a1e81d6d5c435f4cd2023e1] | committer: Matthieu Bouron checkasm: add sbrdsp tests > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=7864e07f4af248d35a1e81d6d5c435f4cd2023e1 --- tests/checkasm/Makefile | 3 +- tests/checkasm/checkasm.c | 1 + tests/checkasm/checkasm.h | 1 + tests/checkasm/sbrdsp.c | 298 ++ 4 files changed, 302 insertions(+), 1 deletion(-) diff --git a/tests/checkasm/Makefile b/tests/checkasm/Makefile index 638e811931..60e80ab738 100644 --- a/tests/checkasm/Makefile +++ b/tests/checkasm/Makefile @@ -13,7 +13,8 @@ AVCODECOBJS-$(CONFIG_VP8DSP)+= vp8dsp.o AVCODECOBJS-$(CONFIG_VIDEODSP) += videodsp.o # decoders/encoders -AVCODECOBJS-$(CONFIG_AAC_DECODER) += aacpsdsp.o +AVCODECOBJS-$(CONFIG_AAC_DECODER) += aacpsdsp.o \ + sbrdsp.o AVCODECOBJS-$(CONFIG_ALAC_DECODER) += alacdsp.o AVCODECOBJS-$(CONFIG_DCA_DECODER) += synth_filter.o AVCODECOBJS-$(CONFIG_JPEG2000_DECODER) += jpeg2000dsp.o diff --git a/tests/checkasm/checkasm.c b/tests/checkasm/checkasm.c index e66744b162..29f201b1b3 100644 --- a/tests/checkasm/checkasm.c +++ b/tests/checkasm/checkasm.c @@ -67,6 +67,7 @@ static const struct { #if CONFIG_AVCODEC #if CONFIG_AAC_DECODER { "aacpsdsp", checkasm_check_aacpsdsp }, +{ "sbrdsp", checkasm_check_sbrdsp }, #endif #if CONFIG_ALAC_DECODER { "alacdsp", checkasm_check_alacdsp }, diff --git a/tests/checkasm/checkasm.h b/tests/checkasm/checkasm.h index dfb0ce561c..fa51e71e4b 100644 --- a/tests/checkasm/checkasm.h +++ b/tests/checkasm/checkasm.h @@ -50,6 +50,7 @@ void checkasm_check_hevc_idct(void); void checkasm_check_jpeg2000dsp(void); void checkasm_check_llviddsp(void); void checkasm_check_pixblockdsp(void); +void checkasm_check_sbrdsp(void); void checkasm_check_synth_filter(void); void checkasm_check_v210enc(void); void checkasm_check_vp8dsp(void); diff --git a/tests/checkasm/sbrdsp.c b/tests/checkasm/sbrdsp.c new file mode 100644 index 00..038318e021 --- /dev/null +++ b/tests/checkasm/sbrdsp.c @@ -0,0 +1,298 @@ +/* + * This file is part of FFmpeg. + * + * FFmpeg is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * FFmpeg is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with FFmpeg; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + */ + +#include "libavcodec/sbrdsp.h" + +#include "checkasm.h" + +#define randomize(buf, len) do {\ +int i; \ +for (i = 0; i < len; i++) { \ +const INTFLOAT f = (INTFLOAT)rnd() / UINT_MAX; \ +(buf)[i] = f; \ +} \ +} while (0) + +#define EPS 0.0001 + +static void test_sum64x5(void) +{ +LOCAL_ALIGNED_16(INTFLOAT, dst0, [64 + 256]); +LOCAL_ALIGNED_16(INTFLOAT, dst1, [64 + 256]); + +declare_func(void, INTFLOAT *z); + +randomize((INTFLOAT *)dst0, 64 + 256); +memcpy(dst1, dst0, (64 + 256) * sizeof(INTFLOAT)); +call_ref(dst0); +call_new(dst1); +if (!float_near_abs_eps_array(dst0, dst1, EPS, 64 + 256)) +fail(); +bench_new(dst1); +} + +static void test_sum_square(void) +{ +INTFLOAT res0; +INTFLOAT res1; +LOCAL_ALIGNED_16(INTFLOAT, src, [256], [2]); + +declare_func(INTFLOAT, INTFLOAT (*x)[2], int n); + +randomize((INTFLOAT *)src, 256 * 2); +res0 = call_ref(src, 256); +res1 = call_new(src, 256); +if (!float_near_abs_eps(res0, res1, EPS)) +fail(); +bench_new(src, 256); +} + +static void test_neg_odd_64(void) +{ +LOCAL_ALIGNED_16(INTFLOAT, dst0, [64]); +LOCAL_ALIGNED_16(INTFLOAT, dst1, [64]); + +declare_func(void, INTFLOAT *x); + +randomize((INTFLOAT *)dst0, 64); +memcpy(dst1, dst0, (64) * sizeof(INTFLOAT)); +call_ref(dst0); +call_new(dst1); +if (!float_near_abs_eps_array(dst0, dst1, EPS, 64)) +fail(); +bench_new(dst1); +} + +static void test_qmf_pre_shuffle(void) +{ +LOCAL_ALIGNED_16(INTFLOAT, dst0, [128]); +LOCAL_ALIGNED_16(INTFLOAT, dst1, [128]); + +declare_func(void, INTFLOAT *z); + +randomize((INTFLOAT *)dst0, 128); +memcpy(dst1, dst0, (128) * sizeof(
[FFmpeg-cvslog] lavc/aarch64: add sbrdsp neon implementation
ffmpeg | branch: master | Matthieu Bouron | Tue May 23 14:29:35 2017 +| [0a24d7ca831b85db18593e5f18d765adb40e5cd9] | committer: Matthieu Bouron lavc/aarch64: add sbrdsp neon implementation autocorrelate_c: 644.0 autocorrelate_neon: 420.0 hf_apply_noise_0_c: 1688.5 hf_apply_noise_0_neon: 1498.6 hf_apply_noise_1_c: 1691.2 hf_apply_noise_1_neon: 1500.6 hf_apply_noise_2_c: 1688.1 hf_apply_noise_2_neon: 1500.3 hf_apply_noise_3_c: 1696.6 hf_apply_noise_3_neon: 1502.2 hf_g_filt_c: 2117.8 hf_g_filt_neon: 1218.7 hf_gen_c: 4573.4 hf_gen_neon: 2461.0 neg_odd_64_c: 72.0 neg_odd_64_neon: 64.7 qmf_deint_bfly_c: 1107.6 qmf_deint_bfly_neon: 291.6 qmf_deint_neg_c: 210.4 qmf_deint_neg_neon: 107.4 qmf_post_shuffle_c: 163.0 qmf_post_shuffle_neon: 107.7 qmf_pre_shuffle_c: 120.5 qmf_pre_shuffle_neon: 110.7 sum64x5_c: 1361.6 sum64x5_neon: 435.4 sum_square_c: 1686.4 sum_square_neon: 787.2 > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=0a24d7ca831b85db18593e5f18d765adb40e5cd9 --- libavcodec/aarch64/Makefile | 4 +- libavcodec/aarch64/sbrdsp_init_aarch64.c | 70 +++ libavcodec/aarch64/sbrdsp_neon.S | 327 +++ libavcodec/sbrdsp.h | 1 + libavcodec/sbrdsp_template.c | 2 + 5 files changed, 403 insertions(+), 1 deletion(-) diff --git a/libavcodec/aarch64/Makefile b/libavcodec/aarch64/Makefile index d440b1b18a..72080c2dbb 100644 --- a/libavcodec/aarch64/Makefile +++ b/libavcodec/aarch64/Makefile @@ -11,7 +11,8 @@ OBJS-$(CONFIG_NEON_CLOBBER_TEST)+= aarch64/neontest.o OBJS-$(CONFIG_VIDEODSP) += aarch64/videodsp_init.o # decoders/encoders -OBJS-$(CONFIG_AAC_DECODER) += aarch64/aacpsdsp_init_aarch64.o +OBJS-$(CONFIG_AAC_DECODER) += aarch64/aacpsdsp_init_aarch64.o \ + aarch64/sbrdsp_init_aarch64.o OBJS-$(CONFIG_DCA_DECODER) += aarch64/synth_filter_init.o OBJS-$(CONFIG_RV40_DECODER) += aarch64/rv40dsp_init_aarch64.o OBJS-$(CONFIG_VC1DSP) += aarch64/vc1dsp_init_aarch64.o @@ -28,6 +29,7 @@ ARMV8-OBJS-$(CONFIG_VIDEODSP) += aarch64/videodsp.o # NEON optimizations # subsystems +NEON-OBJS-$(CONFIG_AAC_DECODER) += aarch64/sbrdsp_neon.o NEON-OBJS-$(CONFIG_FFT) += aarch64/fft_neon.o NEON-OBJS-$(CONFIG_FMTCONVERT) += aarch64/fmtconvert_neon.o NEON-OBJS-$(CONFIG_H264CHROMA) += aarch64/h264cmc_neon.o diff --git a/libavcodec/aarch64/sbrdsp_init_aarch64.c b/libavcodec/aarch64/sbrdsp_init_aarch64.c new file mode 100644 index 00..9c967990df --- /dev/null +++ b/libavcodec/aarch64/sbrdsp_init_aarch64.c @@ -0,0 +1,70 @@ +/* + * This file is part of FFmpeg. + * + * FFmpeg is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * FFmpeg is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with FFmpeg; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + +#include "config.h" +#include "libavutil/aarch64/cpu.h" +#include "libavutil/attributes.h" +#include "libavcodec/sbrdsp.h" + +void ff_sbr_sum64x5_neon(float *z); +float ff_sbr_sum_square_neon(float (*x)[2], int n); +void ff_sbr_neg_odd_64_neon(float *x); +void ff_sbr_qmf_pre_shuffle_neon(float *z); +void ff_sbr_qmf_post_shuffle_neon(float W[32][2], const float *z); +void ff_sbr_qmf_deint_neg_neon(float *v, const float *src); +void ff_sbr_qmf_deint_bfly_neon(float *v, const float *src0, const float *src1); +void ff_sbr_hf_g_filt_neon(float (*Y)[2], const float (*X_high)[40][2], + const float *g_filt, int m_max, intptr_t ixh); +void ff_sbr_hf_gen_neon(float (*X_high)[2], const float (*X_low)[2], +const float alpha0[2], const float alpha1[2], +float bw, int start, int end); +void ff_sbr_autocorrelate_neon(const float x[40][2], float phi[3][2][2]); +void ff_sbr_hf_apply_noise_0_neon(float Y[64][2], const float *s_m, + const float *q_filt, int noise, + int kx, int m_max); +void ff_sbr_hf_apply_noise_1_neon(float Y[64][2], const float *s_m, + const float *q_filt, int noise, + int kx, int m_max); +void ff_sbr_hf_apply_noise_2_neon(float Y[64][2], const float *s_m, + const float *q_filt, int noise, +
[FFmpeg-cvslog] lavc/mediacodec: add missing newline on warning
ffmpeg | branch: master | Aman Gupta | Mon Jul 3 11:07:36 2017 -0700| [6d4a686d45218fd9ac312fd3f3056680ce169d40] | committer: Matthieu Bouron lavc/mediacodec: add missing newline on warning Signed-off-by: Matthieu Bouron > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=6d4a686d45218fd9ac312fd3f3056680ce169d40 --- libavcodec/mediacodecdec_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/mediacodecdec_common.c b/libavcodec/mediacodecdec_common.c index 1263188d34..f88b2cde54 100644 --- a/libavcodec/mediacodecdec_common.c +++ b/libavcodec/mediacodecdec_common.c @@ -478,7 +478,7 @@ int ff_mediacodec_dec_init(AVCodecContext *avctx, MediaCodecDecContext *s, profile = ff_AMediaCodecProfile_getProfileFromAVCodecContext(avctx); if (profile < 0) { -av_log(avctx, AV_LOG_WARNING, "Unsupported or unknown profile"); +av_log(avctx, AV_LOG_WARNING, "Unsupported or unknown profile\n"); } s->codec_name = ff_AMediaCodecList_getCodecNameByType(mime, profile, 0, avctx); ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
[FFmpeg-cvslog] lavc/mediacodec: rescale pts before decoding for both hw and sw buffers
ffmpeg | branch: master | Aman Gupta | Mon Jul 3 09:21:50 2017 -0700| [aad79e4323bb03837cc6611b99b72c1cf1a7b6f6] | committer: Matthieu Bouron lavc/mediacodec: rescale pts before decoding for both hw and sw buffers Replicates the logic used in the wrap_hw_buffer path to wrap_sw_buffer as well. Fixes decoding issues observed on AMLogic devices with OMX.amlogic.mpeg2.decoder.awesome, where the decoder would spit out a constant stream of "mPtsRecoveryCount" errors and decoded frames were returned in the incorrect order. Signed-off-by: Matthieu Bouron > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=aad79e4323bb03837cc6611b99b72c1cf1a7b6f6 --- libavcodec/mediacodecdec_common.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/libavcodec/mediacodecdec_common.c b/libavcodec/mediacodecdec_common.c index f88b2cde54..afa054f83e 100644 --- a/libavcodec/mediacodecdec_common.c +++ b/libavcodec/mediacodecdec_common.c @@ -282,10 +282,16 @@ static int mediacodec_wrap_sw_buffer(AVCodecContext *avctx, * on the last avpacket received which is not in sync with the frame: * * N avpackets can be pushed before 1 frame is actually returned * * 0-sized avpackets are pushed to flush remaining frames at EOS */ -frame->pts = info->presentationTimeUs; +if (avctx->pkt_timebase.num && avctx->pkt_timebase.den) { +frame->pts = av_rescale_q(info->presentationTimeUs, + av_make_q(1, 100), + avctx->pkt_timebase); +} else { +frame->pts = info->presentationTimeUs; +} #if FF_API_PKT_PTS FF_DISABLE_DEPRECATION_WARNINGS -frame->pkt_pts = info->presentationTimeUs; +frame->pkt_pts = frame->pts; FF_ENABLE_DEPRECATION_WARNINGS #endif frame->pkt_dts = AV_NOPTS_VALUE; @@ -613,7 +619,7 @@ int ff_mediacodec_dec_decode(AVCodecContext *avctx, MediaCodecDecContext *s, memcpy(data, pkt->data + offset, size); offset += size; -if (s->surface && avctx->pkt_timebase.num && avctx->pkt_timebase.den) { +if (avctx->pkt_timebase.num && avctx->pkt_timebase.den) { pts = av_rescale_q(pts, avctx->pkt_timebase, av_make_q(1, 100)); } ___ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog