[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdenonbeta/kwintv3/qtvision
From: George Staikos <staikos () kde ! org>
Date: 2004-01-05 23:29:19
Message-ID: 20040105232919.E041B9096 () office ! kde ! org
[Download RAW message or body]
CVS commit by staikos:
Make snapshots slightly more reliable on unreliable video sources
M +8 -1 qtvision.cpp 1.149
--- kdenonbeta/kwintv3/qtvision/qtvision.cpp #1.148:1.149
@@ -737,5 +737,12 @@ void QtVision::setGuiFactory(KXMLGUIFact
void QtVision::snapshot()
{
- if (_srcm->snapshot( grabPix )) {
+ bool rc = false;
+
+ // Try up to 5 times to get a snapshot
+ for (int i = 0; i < 5 && !rc; ++i) {
+ rc = _srcm->snapshot( grabPix );
+ }
+
+ if (rc) {
QString mf = _cfg->snapshotPath + QString("qtvision-snapshot-%1.png").arg(_grabNumber++);
while (QFileInfo(mf).exists()) {
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic