summaryrefslogtreecommitdiff
path: root/src/server.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/server.cc')
-rw-r--r--src/server.cc13
1 files changed, 9 insertions, 4 deletions
diff --git a/src/server.cc b/src/server.cc
index 72df6b6..cdbe506 100644
--- a/src/server.cc
+++ b/src/server.cc
@@ -31,6 +31,9 @@
/*
* $Log$
+ * Revision 1.21 2005/05/26 21:32:39 deva
+ * *** empty log message ***
+ *
* Revision 1.20 2005/05/26 12:48:36 deva
* *** empty log message ***
*
@@ -173,16 +176,17 @@ void saveFrameAsImage(char* cpr, Frame *f)
ltime->tm_mday);
// Create filename: [serverroot]/[birthmonth]/[cpr]/[cpr]-[date]-[cnt].mpg
- sprintf(fname, "%s/%s/%s/%s-%s-%.3d", root->c_str(), birthmonth, cpr, cpr, date, cnt);
+ sprintf(fname, "%s/%s/%s/%s-%s-%.3d.jpg", root->c_str(), birthmonth, cpr, cpr, date, cnt);
// test filename-[cnt] for existamce cnt++ until not existing.
fp = fopen(fname, "r");
while(fp) {
fclose(fp);
cnt++;
- sprintf(fname, "%s/%s/%s/%s-%s-%.3d", root->c_str(), birthmonth, cpr, cpr, date, cnt);
+ sprintf(fname, "%s/%s/%s/%s-%s-%.3d.jpg", root->c_str(), birthmonth, cpr, cpr, date, cnt);
fp = fopen(fname, "r");
}
+ sprintf(fname, "%s/%s/%s/%s-%s-%.3d", root->c_str(), birthmonth, cpr, cpr, date, cnt);
fprintf(stderr, "Success - using filename: [%s.jpg]\n", fname); fflush(stderr);
imgenc.encode(f, fname, 100); // Quality is between 0...100, where 100 is best.
@@ -274,16 +278,17 @@ MovEncoderThread *newMovEncoder(char* cpr)
ltime->tm_mday);
// Create filename: [serverroot]/[birthmonth]/[cpr]/[cpr]-[date]-[cnt].mpg
- sprintf(fname, "%s/%s/%s/%s-%s-%.3d", root->c_str(), birthmonth, cpr, cpr, date, cnt);
+ sprintf(fname, "%s/%s/%s/%s-%s-%.3d.mpg", root->c_str(), birthmonth, cpr, cpr, date, cnt);
// test filename-[cnt] for existamce cnt++ until not existing.
fp = fopen(fname, "r");
while(fp) {
fclose(fp);
cnt++;
- sprintf(fname, "%s/%s/%s/%s-%s-%.3d", root->c_str(), birthmonth, cpr, cpr, date, cnt);
+ sprintf(fname, "%s/%s/%s/%s-%s-%.3d.mpg", root->c_str(), birthmonth, cpr, cpr, date, cnt);
fp = fopen(fname, "r");
}
+ sprintf(fname, "%s/%s/%s/%s-%s-%.3d", root->c_str(), birthmonth, cpr, cpr, date, cnt);
fprintf(stderr, "Success - using filename: [%s.mpg]\n", fname); fflush(stderr);
enc = new MovEncoderThread(fname);