changeset 30008:26fb866475a7

Slightly increase hardware decoding performance by always using more video surfaces than absolutely necessary. I will revert if somebody reports real-world resource issues introduced by this commit.
author cehoyos
date Thu, 17 Dec 2009 13:23:15 +0000
parents f66242c2b3b2
children 88e9eee4089e
files libvo/vo_vdpau.c
diffstat 1 files changed, 0 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/libvo/vo_vdpau.c	Thu Dec 17 10:57:40 2009 +0000
+++ b/libvo/vo_vdpau.c	Thu Dec 17 13:23:15 2009 +0000
@@ -153,7 +153,6 @@
 static int                                deint;
 static int                                deint_type;
 static int                                deint_counter;
-static int                                deint_buffer_past_frames;
 static int                                pullup;
 static float                              denoise;
 static float                              sharpen;
@@ -1024,13 +1023,11 @@
     if (IMGFMT_IS_VDPAU(image_format)) {
         struct vdpau_render_state *rndr = mpi->priv;
         vid_surface_num = rndr - surface_render;
-        if (deint_buffer_past_frames) {
             mpi->usage_count++;
             if (deint_mpi[1])
                 deint_mpi[1]->usage_count--;
             deint_mpi[1] = deint_mpi[0];
             deint_mpi[0] = mpi;
-        }
     } else if (image_format == IMGFMT_BGRA) {
         VdpStatus vdp_st;
         VdpRect r = {0, 0, vid_width, vid_height};
@@ -1232,7 +1229,6 @@
     deint = 0;
     deint_type = 3;
     deint_counter = 0;
-    deint_buffer_past_frames = 0;
     deint_mpi[0] = deint_mpi[1] = NULL;
     chroma_deint = 1;
     pullup  = 0;
@@ -1247,8 +1243,6 @@
     }
     if (deint)
         deint_type = deint;
-    if (deint > 1)
-        deint_buffer_past_frames = 1;
     if (colorspace < 0 || colorspace > 3) {
         mp_msg(MSGT_VO, MSGL_WARN, "[vdpau] Invalid color space specified, "
                "using BT.601\n");
@@ -1343,7 +1337,6 @@
                                                          features,
                                                          feature_enables);
             CHECK_ST_WARNING("Error changing deinterlacing settings")
-            deint_buffer_past_frames = 1;
         }
         return VO_TRUE;
     case VOCTRL_PAUSE: