else
ost->error[i] = -1;
}
+
+ if (ost->frame_rate.num) {
+ pkt->duration = av_rescale_q(1, av_inv_q(ost->frame_rate),
+ ost->st->time_base);
+ }
}
if (bsfc)
}
}
+ if (!j)
+ goto fail;
+
av_sdp_create(avc, j, sdp, sizeof(sdp));
if (!sdp_filename) {
}
}
+fail:
av_freep(&avc);
}
static int compare_int64(const void *a, const void *b)
{
- int64_t va = *(int64_t *)a, vb = *(int64_t *)b;
- return va < vb ? -1 : va > vb ? +1 : 0;
+ return FFDIFFSIGN(*(const int64_t *)a, *(const int64_t *)b);
}
static int init_output_stream(OutputStream *ost, char *error, int error_len)