- Timestamp:
- Oct 2, 2008, 4:38:03 PM (16 years ago)
- Location:
- trunk/BNC
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/bncgetthread.cpp
r1145 r1146 507 507 } 508 508 else if (_rawInpFile) { 509 const qint64 maxBytes = 10 000;509 const qint64 maxBytes = 1024; 510 510 nBytes = maxBytes; 511 511 } … … 521 521 else if (_rawInpFile) { 522 522 nBytes = _rawInpFile->read(data, nBytes); 523 cout << "nBytes = " << nBytes << endl;524 523 if (nBytes <= 0) { 525 524 cout << "no more data" << endl; -
trunk/BNC/bncmain.cpp
r1140 r1146 59 59 int main(int argc, char *argv[]) { 60 60 61 bool GUIenabled = true; 61 bool GUIenabled = true; 62 bool fileInput = false; 63 QByteArray fileName; 64 QByteArray format; 65 62 66 for (int ii = 1; ii < argc; ii++) { 63 if (Q String(argv[ii]) == "-nw") {67 if (QByteArray(argv[ii]) == "-nw") { 64 68 GUIenabled = false; 65 69 break; 70 } 71 } 72 73 for (int ii = 1; ii < argc; ii++) { 74 if (QByteArray(argv[ii]) == "-file" || QByteArray(argv[ii]) == "--file") { 75 GUIenabled = false; 76 fileInput = true; 77 if (ii+1 < argc) { 78 fileName = QByteArray(argv[ii+1]); 79 } 80 } 81 if (QByteArray(argv[ii]) == "-format" || QByteArray(argv[ii]) == "--format") { 82 GUIenabled = false; 83 fileInput = true; 84 if (ii+1 < argc) { 85 format = QByteArray(argv[ii+1]); 86 } 66 87 } 67 88 } … … 130 151 ((bncApp*)qApp)->slotMessage("============ Start BNC ============"); 131 152 132 if (false) { 133 bncGetThread* getThread = new bncGetThread("SASS0.raw","RTCM_3"); 153 if (fileInput) { 154 if (fileName.isEmpty() || format.isEmpty()) { 155 cout << "Usage: bnc --file <fileName> --format <RTIGS | RTCM_2 | RTCM_3>" << endl; 156 exit(0); 157 } 158 159 bncGetThread* getThread = new bncGetThread(fileName, format); 134 160 app.connect(getThread, SIGNAL(newMessage(QByteArray)), 135 161 &app, SLOT(slotMessage(const QByteArray)));
Note:
See TracChangeset
for help on using the changeset viewer.