Menu

#33 Reduce delay in displaying video frames

open
Bugfix (15)
5
2007-06-02
2007-06-02
Robert
No

I noticed in the main loop that it always delays displaying each field by one fieldtime from when it is available. This patch removes the delay so each field is displayed slightly sooner. This gives better audio/video synchronisation for me (TV card type: saaa7134).

It is also much better when playing a games console through tvtime as you want minimum latency between pressing a button and seeing the result.

Patch is against tvtime-1.0.2, but should work on other versions.

Discussion

  • Robert

    Robert - 2007-06-02

    nodelay patch

     
  • Billy Biggs

    Billy Biggs - 2007-07-22

    Logged In: YES
    user_id=153320
    Originator: NO

    This does not make sense at all. Without the delay, fields won't be shown at an even rate.

    If you're seeing audio sync problems, it's because too much delay is being introduced by the system, and this is not the right fix.

     
  • Robert

    Robert - 2007-07-24

    Logged In: YES
    user_id=1121906
    Originator: YES

    They are displayed at an even rate for me - everything moves smoothly.

    I made this patch because I have a Wii, which I play through tvtime (I have no TV separate from my PC to save space). With games you want the minimum possible delay to make the controls feel more responsive. At first I assumed the delay was needed for AV sync and intended to make it a configurable option. I had thought that the AV sync on analogue TV was OK previously. However, when I tried it on analogue TV I thought it was better synchronised without the delay so I just made no-delay the default and not configurable.

    I understand your logic - the delay guarantees the fields will be displayed at specific times. However, without the delay the fields are still showed at an even rate, as long as time taken by the code that is executed before each field is the same. The main thing that has to be executed is the deinterlacer, and that takes the same amount of time for each field.

    There is a bit more code to be executed before displaying the top field but it is all 'if' statements that will usually evaluate to false and do nothing. I suppose it could be improved slightly by moving some of that code to after the top field is shown and changing how the delay before the second field is calculated.

     

Log in to post a comment.