[FFmpeg-devel] [PATCH 24/25] avcodec/v4l2_buffers: extract v4l2_timebase constant
Aman Gupta
ffmpeg at tmm1.net
Tue Sep 3 04:02:29 EEST 2019
From: Aman Gupta <aman at tmm1.net>
Signed-off-by: Aman Gupta <aman at tmm1.net>
---
libavcodec/v4l2_buffers.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/libavcodec/v4l2_buffers.c b/libavcodec/v4l2_buffers.c
index d8cec06cb3..8424fbcd3e 100644
--- a/libavcodec/v4l2_buffers.c
+++ b/libavcodec/v4l2_buffers.c
@@ -42,6 +42,7 @@
#include "v4l2_m2m.h"
#define USEC_PER_SEC 1000000
+static AVRational v4l2_timebase = { 1, USEC_PER_SEC };
static inline V4L2m2mContext *buf_to_m2mctx(V4L2Buffer *buf)
{
@@ -68,7 +69,6 @@ static inline AVRational v4l2_get_timebase(V4L2Buffer *avbuf)
static inline void v4l2_set_pts(V4L2Buffer *out, int64_t pts)
{
- AVRational v4l2_timebase = { 1, USEC_PER_SEC };
int64_t v4l2_pts;
if (pts == AV_NOPTS_VALUE)
@@ -82,7 +82,6 @@ static inline void v4l2_set_pts(V4L2Buffer *out, int64_t pts)
static inline int64_t v4l2_get_pts(V4L2Buffer *avbuf)
{
- AVRational v4l2_timebase = { 1, USEC_PER_SEC };
int64_t v4l2_pts;
/* convert pts back to encoder timebase */
--
2.20.1
More information about the ffmpeg-devel
mailing list