Ticket #2412: 2412-v1.patch
File 2412-v1.patch, 3.0 KB (added by , 17 years ago) |
---|
-
libs/libmythtv/osdsurface.h
24 24 25 25 void Clear(void); 26 26 void ClearUsed(void); 27 bool IsClear(void) const; 27 28 28 29 bool IntersectsDrawn(QRect &newrect); 29 30 void AddRect(QRect &newrect); … … 35 36 if (change) 36 37 ++revision; 37 38 } 38 int GetRevision( ){ return revision; }39 int GetRevision(void) const { return revision; } 39 40 40 41 void BlendToYV12(unsigned char *yptr, 41 42 unsigned char *uptr, -
libs/libmythtv/osd.h
60 60 61 61 OSDSurface *Display(void); 62 62 63 int GetRevision(void) const; 64 63 65 void ClearAll(const QString &name); 64 66 void ClearAllText(const QString &name); 65 67 void SetText(const QString &name, QMap<QString, QString> &infoMap, -
libs/libmythtv/videoout_xv.cpp
2859 2859 VideoFrame *osdframe = NULL; 2860 2860 int ret = DisplayOSD(xvmc_osd->OSDFrame(), osd, -1, 2861 2861 xvmc_osd->GetRevision()); 2862 OSDSurface *osdsurf = osd->Display(); 2863 if (osdsurf) 2864 xvmc_osd->SetRevision(osdsurf->GetRevision()); 2862 xvmc_osd->SetRevision(osd->GetRevision()); 2865 2863 if (ret >= 0 && xvmc_osd->NeedFrame()) 2866 2864 { 2867 2865 // If there are no available buffer, try to toss old -
libs/libmythtv/osdsurface.cpp
135 135 usedRegions = QRegion(); 136 136 } 137 137 138 bool OSDSurface::IsClear(void) const 139 { 140 return (usedRegions == QRegion()); 141 } 142 138 143 bool OSDSurface::IntersectsDrawn(QRect &newrect) 139 144 { 140 145 QMutexLocker lock(&usedRegionsLock); … … 799 804 800 805 if (startline < 0) startline = 0; 801 806 if (endline >= height) endline = height - 1; 802 if (startcol < 0) endcol = 0;807 if (startcol < 0) startcol = 0; 803 808 if (endcol >= width) endcol = width - 1; 804 809 805 810 unsigned char *src; -
libs/libmythtv/osd.cpp
2474 2474 totalfadetime = 0; 2475 2475 } 2476 2476 2477 int OSD::GetRevision(void) const 2478 { 2479 if (drawSurface) 2480 return drawSurface->GetRevision(); 2481 return 0; 2482 } 2483 2477 2484 OSDSurface *OSD::Display(void) 2478 2485 { 2479 2486 bool anytodisplay = false; … … 2545 2552 2546 2553 m_setsvisible = anytodisplay; 2547 2554 2548 if (m_setsvisible )2555 if (m_setsvisible && !drawSurface->IsClear()) 2549 2556 return drawSurface; 2550 2557 2551 2558 return NULL;