From 2efd119bbe485c70f637efc8ba089eca61808711 Mon Sep 17 00:00:00 2001 From: Steven Walters Date: Tue, 13 Apr 2010 08:44:37 -0400 Subject: [PATCH] Make interlaced detection in avisynth only apply to field-based input Fixes improper flagging of progressive sources. --- input/avs.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/input/avs.c b/input/avs.c index 59634f4f..9e3aa55b 100644 --- a/input/avs.c +++ b/input/avs.c @@ -233,6 +233,8 @@ static int open_file( char *psz_filename, hnd_t *p_handle, video_info_t *info, c return -1; } res = update_clip( h, &vi, tmp, res ); + info->interlaced = 1; + info->tff = avs_is_tff( vi ); } if( vi->width&1 || vi->height&1 ) { @@ -240,14 +242,6 @@ static int open_file( char *psz_filename, hnd_t *p_handle, video_info_t *info, c vi->width, vi->height ); return -1; } - /* bff/tff flags in avisynth are not technically mutually exclusive, which can lead to both being set. - * avisynth's own functions enact mutual exclusion, but source filters are not guaranteed to do this. */ - int tff = avs_is_tff( vi ); - if( avs_is_bff( vi ) ^ tff ) - { - info->interlaced = 1; - info->tff = !!tff; - } /* always call ConvertToYV12 to convert non YV12 planar colorspaces to YV12 when user's AVS supports them, as all planar colorspaces are flagged as YV12. If it is already YV12 in this case, the call does nothing */ if( !avs_is_yv12( vi ) || avs_version >= AVS_INTERFACE_OTHER_PLANAR ) -- 2.47.3