Returns the sector ID of the _current_ sector. */
| 28 | private: |
| 29 | /* Returns the sector ID of the _current_ sector. */ |
| 30 | int advanceToNextSector() |
| 31 | { |
| 32 | auto previous = tell(); |
| 33 | seekToIndexMark(); |
| 34 | auto now = tell(); |
| 35 | if ((now.ns() - previous.ns()) < 9e6) |
| 36 | { |
| 37 | seekToIndexMark(); |
| 38 | auto next = tell(); |
| 39 | if ((next.ns() - now.ns()) < 9e6) |
| 40 | { |
| 41 | /* We just found sector 0. */ |
| 42 | |
| 43 | _sectorId = 0; |
| 44 | } |
| 45 | else |
| 46 | { |
| 47 | /* Spurious... */ |
| 48 | |
| 49 | seek(now); |
| 50 | } |
| 51 | } |
| 52 | |
| 53 | return _sectorId++; |
| 54 | } |
| 55 | |
| 56 | public: |
| 57 | void beginTrack() override |