Ticket #2903: mythtv-0.21-interlaced-display-rate.2.patch
File mythtv-0.21-interlaced-display-rate.2.patch, 1.1 KB (added by , 11 years ago) |
---|
-
libs/libmythtv/videoout_xv.cpp
67 67 #define round(x) ((int) ((x) + 0.5)) 68 68 #endif 69 69 70 #ifndef V_INTERLACE 71 #define V_INTERLACE (0x010) 72 #endif 73 70 74 #ifndef XVMC_CHROMA_FORMAT_420 71 75 #define XVMC_CHROMA_FORMAT_420 0x00000001 72 76 #endif … … 365 369 366 370 rate = (dot_clock * 1000.0) / rate; 367 371 372 // For an interlaced display mode, we want the refresh rate to be the field 373 // rate, so that we can use an x2 deinterlacer. It may be the case that some 374 // drivers (possibly openchrome) use false mode lines, with a doubled clock 375 // rate, so as to make the frame rate calculation produce the field rate. 376 // We check for 25 or 30 to avoid twice doubling in that case. 377 if (((mode_line.flags & V_INTERLACE) != 0) && 378 rate > 24.5 && rate < 30.5) 379 { 380 VERBOSE(VB_GENERAL, "Doubling refresh rate for interlaced display mode"); 381 382 rate *= 2; 383 } 384 368 385 // Assume 60Hz if rate isn't good: 369 386 if (rate < 20 || rate > 200) 370 387 {