MCPcopy Create free account
hub / github.com/HandBrake/HandBrake / removeVideoJitter

Function removeVideoJitter

libhb/sync.c:847–867  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

845}
846
847static void removeVideoJitter( sync_stream_t * stream, int stop )
848{
849 int ii;
850 hb_buffer_t * buf;
851 double frame_duration, next_pts;
852
853 frame_duration = 90000. * stream->common->job->title->vrate.den /
854 stream->common->job->title->vrate.num;
855
856 buf = hb_list_item(stream->in_queue, 0);
857 buf->s.start = stream->next_pts;
858 next_pts = stream->next_pts + frame_duration;
859 for (ii = 1; ii <= stop; ii++)
860 {
861 buf->s.duration = frame_duration;
862 buf->s.stop = next_pts;
863 buf = hb_list_item(stream->in_queue, ii);
864 buf->s.start = next_pts;
865 next_pts += frame_duration;
866 }
867}
868
869// Look for a sequence of packets whose duration as measure by
870// vrate closely matches the duration as measured by timestamp

Callers 1

dejitterVideoFunction · 0.85

Calls 1

hb_list_itemFunction · 0.85

Tested by

no test coverage detected