diff options
Diffstat (limited to 'libmpcodecs/vf_tfields.c')
-rw-r--r-- | libmpcodecs/vf_tfields.c | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/libmpcodecs/vf_tfields.c b/libmpcodecs/vf_tfields.c index dd754256d5..5ec60e3cde 100644 --- a/libmpcodecs/vf_tfields.c +++ b/libmpcodecs/vf_tfields.c @@ -3,6 +3,7 @@ #include <string.h> #include "config.h" +#include "options.h" #include "mp_msg.h" #include "cpudetect.h" @@ -299,10 +300,9 @@ static void qpel_4tap_C(unsigned char *d, unsigned char *s, int w, int h, int ds static void (*qpel_li)(unsigned char *d, unsigned char *s, int w, int h, int ds, int ss, int up); static void (*qpel_4tap)(unsigned char *d, unsigned char *s, int w, int h, int ds, int ss, int up); -static int continue_buffered_image(struct vf_instance_s *); -extern int correct_pts; +static int continue_buffered_image(struct vf_instance *); -static int put_image(struct vf_instance_s* vf, mp_image_t *mpi, double pts) +static int put_image(struct vf_instance* vf, mp_image_t *mpi, double pts) { vf->priv->buffered_mpi = mpi; vf->priv->buffered_pts = pts; @@ -310,7 +310,9 @@ static int put_image(struct vf_instance_s* vf, mp_image_t *mpi, double pts) return continue_buffered_image(vf); } -static int continue_buffered_image(struct vf_instance_s *vf) +extern const int under_mencoder; + +static int continue_buffered_image(struct vf_instance *vf) { int i=vf->priv->buffered_i; double pts = vf->priv->buffered_pts; @@ -362,10 +364,10 @@ static int continue_buffered_image(struct vf_instance_s *vf) dmpi->stride[2] = 2*mpi->stride[2]; } ret |= vf_next_put_image(vf, dmpi, pts); - if (correct_pts) + if (!under_mencoder) break; else - if (!i) vf_extra_flip(vf); + if (!i) vf_next_control(vf, VFCTRL_FLIP_PAGE, NULL); } break; case 1: @@ -392,10 +394,10 @@ static int continue_buffered_image(struct vf_instance_s *vf) mpi->chroma_width, mpi->chroma_height, (i^!tff)); } ret |= vf_next_put_image(vf, dmpi, pts); - if (correct_pts) + if (!under_mencoder) break; else - if (!i) vf_extra_flip(vf); + if (!i) vf_next_control(vf, VFCTRL_FLIP_PAGE, NULL); } break; case 2: @@ -418,10 +420,10 @@ static int continue_buffered_image(struct vf_instance_s *vf) dmpi->stride[2], mpi->stride[2]*2, (i^!tff)); } ret |= vf_next_put_image(vf, dmpi, pts); - if (correct_pts) + if (!under_mencoder) break; else - if (!i) vf_extra_flip(vf); + if (!i) vf_next_control(vf, VFCTRL_FLIP_PAGE, NULL); } break; } @@ -430,7 +432,7 @@ static int continue_buffered_image(struct vf_instance_s *vf) } #if 0 -static int query_format(struct vf_instance_s* vf, unsigned int fmt) +static int query_format(struct vf_instance* vf, unsigned int fmt) { /* FIXME - figure out which other formats work */ switch (fmt) { @@ -443,7 +445,7 @@ static int query_format(struct vf_instance_s* vf, unsigned int fmt) } #endif -static int config(struct vf_instance_s* vf, +static int config(struct vf_instance* vf, int width, int height, int d_width, int d_height, unsigned int flags, unsigned int outfmt) { @@ -459,7 +461,7 @@ static int config(struct vf_instance_s* vf, return 0; } -static void uninit(struct vf_instance_s* vf) +static void uninit(struct vf_instance* vf) { free(vf->priv); } @@ -499,5 +501,3 @@ const vf_info_t vf_info_tfields = { open, NULL }; - - |