// this is weird. but it seems to put a new frame onto the queue
void QuickSyncEncoderImpl::storage_task_enqueue(storage_task task)
{
+ assert(task.pts >= task.dts);
lock_guard<mutex> lock(storage_task_queue_mutex);
storage_task_queue.push(move(task));
storage_task_queue_changed.notify_all();
void Mux::add_packet(const AVPacket &pkt, int64_t pts, int64_t dts, AVRational timebase, int stream_index_override)
{
+ assert(pts >= dts);
+
AVPacket pkt_copy;
av_init_packet(&pkt_copy);
if (av_packet_ref(&pkt_copy, &pkt) < 0) {