Hi Michael,
this patch contains (additionally to the stuff which I posted already a few
days ago... in case you missed it in the other thread) the fix for Davids
problem concerning the chapter marks!
ciao,
Raph
--- svn/ChangeLog 2007-12-08 12:11:13.000000000 +0100
+++ r108-formattag/ChangeLog 2007-12-12 00:26:25.000000000 +0100
@@ -1,3 +1,11 @@
+2007-12-08 Ralph Glasstetter <[EMAIL PROTECTED]> (mr)
+ * src/dvbcut.cpp
+ Added format option to <expfile>-tag of project files
+ Fixed a chapterlist bug
+
+ * src/settings.cpp
+ Empty defaults for pipe settings
+
2007-12-06 Ralph Glasstetter <[EMAIL PROTECTED]> (mr)
* src/settings.cpp
diff -Naur svn/src/dvbcut.cpp r108-formattag/src/dvbcut.cpp
--- svn/src/dvbcut.cpp 2007-12-08 12:11:13.000000000 +0100
+++ r108-formattag/src/dvbcut.cpp 2007-12-12 00:46:17.000000000 +0100
@@ -369,7 +369,7 @@
QImage p;
int pic, i, nr;
- bool ok;
+ bool ok=false;
for (std::vector<int>::iterator it = piclist.begin(); it != piclist.end(); ++it) {
if(samples>1 && range>0)
@@ -734,6 +734,8 @@
if ((pos=expcmd.find("%OUTPUT%"))!=std::string::npos)
expcmd.replace(pos,8,expfilen);
+ if ((pos=expcmd.find("%CHAPTERS%"))!=std::string::npos)
+ expcmd.replace(pos,10,chapterstring);
pos=expcmd.find(' ');
std::string which="which "+expcmd.substr(0,pos)+" >/dev/null";
@@ -1635,6 +1637,12 @@
QString qs = e.attribute("path");
if (!qs.isEmpty())
expfilename = (const char*)qs;
+ qs = e.attribute("format");
+ bool okay=false;
+ if (!qs.isEmpty()) {
+ int val = qs.toInt(&okay,0);
+ if(okay) exportformat = val;
+ }
}
}
// try old-style project file format
@@ -2105,7 +2113,7 @@
chapterlist.push_back(0);
- int startpic, stoppic, outpics=0;
+ int startpic, stoppic, outpics=0, lastchapter=-2;
pts_t startpts, stoppts, outpts=0;
bool realzero=false;
@@ -2128,6 +2136,9 @@
startpts=eli.getpts();
if (startpic==0)
realzero=true;
+ // did we have a chapter in the eventlist directly before?
+ if(lastchapter==startpic)
+ chapterlist.push_back(outpts);
}
break;
case EventListItem::stop:
@@ -2143,6 +2154,7 @@
}
break;
case EventListItem::chapter:
+ lastchapter=eli.getpicture();
if (startpic>=0)
chapterlist.push_back(eli.getpts()-startpts+outpts);
break;
diff -Naur svn/src/settings.cpp r108-formattag/src/settings.cpp
--- svn/src/settings.cpp 2007-12-08 12:11:13.000000000 +0100
+++ r108-formattag/src/settings.cpp 2007-12-08 13:00:47.000000000 +0100
@@ -182,9 +182,9 @@
pipe_format.push_back(format);
QString key = "/" + QString::number(++i);
beginGroup(key);
- command = readEntry("/command");
- post = readEntry("/post");
- label = readEntry("/label");
+ command = readEntry("/command","");
+ post = readEntry("/post","");
+ label = readEntry("/label","");
format = readNumEntry("/format", 0);
endGroup(); // key
}
-------------------------------------------------------------------------
SF.Net email is sponsored by:
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
DVBCUT-user mailing list
DVBCUT-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dvbcut-user