- int unwrapped_timecode = timecode;
- if (dropped_frames > FPS * 2) {
- fprintf(stderr, "Card %d lost more than two seconds (or time code jumping around), resetting resampler\n",
- card_index);
+ // Number of samples per frame if we need to insert silence.
+ // (Could be nonintegral, but resampling will save us then.)
+ int silence_samples = OUTPUT_FREQUENCY * frame_rate_den / frame_rate_nom;
+
+ if (dropped_frames > MAX_FPS * 2) {
+ fprintf(stderr, "Card %d lost more than two seconds (or time code jumping around; from 0x%04x to 0x%04x), resetting resampler\n",
+ card_index, card->last_timecode, timecode);