mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-06-07 07:58:51 +00:00
openh264enc: Fix initial time-per-frame calculation
This commit is contained in:
parent
593ed6f3d7
commit
27c0a9306e
1 changed files with 1 additions and 1 deletions
|
@ -770,7 +770,7 @@ gst_openh264enc_handle_frame (GstVideoEncoder * encoder,
|
||||||
openh264enc->frame_count++;
|
openh264enc->frame_count++;
|
||||||
if (frame) {
|
if (frame) {
|
||||||
if (G_UNLIKELY (openh264enc->frame_count == 1)) {
|
if (G_UNLIKELY (openh264enc->frame_count == 1)) {
|
||||||
openh264enc->time_per_frame = (GST_NSECOND / openh264enc->framerate);
|
openh264enc->time_per_frame = (GST_SECOND / openh264enc->framerate);
|
||||||
openh264enc->previous_timestamp = frame->pts;
|
openh264enc->previous_timestamp = frame->pts;
|
||||||
} else {
|
} else {
|
||||||
openh264enc->time_per_frame =
|
openh264enc->time_per_frame =
|
||||||
|
|
Loading…
Reference in a new issue