Changeset 10945 in ntrip for trunk/BNC/src/rinex/reqcedit.cpp
- Timestamp:
- Jun 24, 2026, 12:43:35 PM (29 hours ago)
- File:
-
- 1 edited
-
trunk/BNC/src/rinex/reqcedit.cpp (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/src/rinex/reqcedit.cpp
r10630 r10945 73 73 } 74 74 _samplingRate = settings.value("reqcSampling").toString().split("sec").first().toDouble(); 75 _minEle = settings.value("reqcMinEle").toDouble(); 75 76 _begTime = bncTime(settings.value("reqcStartDateTime").toString().toLatin1().data()); 76 77 _endTime = bncTime(settings.value("reqcEndDateTime").toString().toLatin1().data()); … … 223 224 t_reqcEdit::initRnxObsFiles(_obsFileNames, _rnxObsFiles, _logStream); 224 225 226 // Read Ephemerides (needed to apply the elevation mask) 227 // ------------------------------------------------------ 228 if (_minEle > 0.0 && _ephs.isEmpty()) { 229 t_reqcEdit::readEphemerides(_navFileNames, _ephs, _logStream, _checkEph); 230 } 231 225 232 // Initialize output observation file 226 233 // ---------------------------------- … … 361 368 if (sec % (int(_samplingRate)*10) == 0) { 362 369 applyLLI(obsFile, epo); 370 if (_minEle > 0.0) { 371 applyElevationMask(obsFile, epo); 372 } 363 373 outObsFile.writeEpoch(epo); 364 374 } … … 518 528 519 529 _lli.clear(); 530 } 531 532 // Remove satellites below the minimum elevation angle 533 //////////////////////////////////////////////////////////////////////////// 534 void t_reqcEdit::applyElevationMask(const t_rnxObsFile* obsFile, 535 t_rnxObsFile::t_rnxEpo* epo) { 536 537 const ColumnVector& xyzSta = obsFile->xyz(); 538 if (xyzSta.size() != 3 || (xyzSta(1) == 0.0 && xyzSta(2) == 0.0 && xyzSta(3) == 0.0)) { 539 return; 540 } 541 542 std::vector<t_rnxObsFile::t_rnxSat> keptSats; 543 for (unsigned iSat = 0; iSat < epo->rnxSat.size(); iSat++) { 544 const t_rnxObsFile::t_rnxSat& rnxSat = epo->rnxSat[iSat]; 545 546 t_eph* eph = 0; 547 for (int ie = 0; ie < _ephs.size(); ie++) { 548 if (_ephs[ie]->prn() == rnxSat.prn) { 549 eph = _ephs[ie]; 550 break; 551 } 552 } 553 if (eph) { 554 ColumnVector xc(6); 555 ColumnVector vv(3); 556 if (eph->getCrd(epo->tt, xc, vv, false) == success) { 557 double rho, eleSat, azSat; 558 topos(xyzSta(1), xyzSta(2), xyzSta(3), xc(1), xc(2), xc(3), rho, eleSat, azSat); 559 if (eleSat * 180.0/M_PI < _minEle) { 560 continue; 561 } 562 } 563 } 564 keptSats.push_back(rnxSat); 565 } 566 epo->rnxSat = keptSats; 520 567 } 521 568
Note:
See TracChangeset
for help on using the changeset viewer.
