diff options
author | Diego Biurrun <diego@biurrun.de> | 2010-03-12 17:29:19 +0000 |
---|---|---|
committer | Diego Biurrun <diego@biurrun.de> | 2010-03-12 17:29:19 +0000 |
commit | 4f4e40085fccde622ef0c257559f414b575d6816 (patch) | |
tree | 6bdcbdf5bab486e9926d9b91c750dbcf2cf81e9c /libavdevice | |
parent | 2138dc99fc2623117c3336d94b3164d18dd0f8b2 (diff) | |
download | ffmpeg-4f4e40085fccde622ef0c257559f414b575d6816.tar.gz |
Replace BSD-specific integer types by their POSIX equivalents.
Mark bktr_init function as av_cold.
Tested to work by Michael Kostylev on the NetBSD FATE box.
Originally committed as revision 22487 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavdevice')
-rw-r--r-- | libavdevice/bktr.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/libavdevice/bktr.c b/libavdevice/bktr.c index e294ee49a4..942f58dd9e 100644 --- a/libavdevice/bktr.c +++ b/libavdevice/bktr.c @@ -45,6 +45,7 @@ #include <sys/mman.h> #include <sys/time.h> #include <signal.h> +#include <stdint.h> #include <strings.h> typedef struct { @@ -53,7 +54,7 @@ typedef struct { int width, height; int frame_rate; int frame_rate_base; - u_int64_t per_frame; + uint64_t per_frame; } VideoData; @@ -80,7 +81,7 @@ static int bktr_dev[] = { METEOR_DEV0, METEOR_DEV1, METEOR_DEV2, uint8_t *video_buf; size_t video_buf_size; -u_int64_t last_frame_time; +uint64_t last_frame_time; volatile sig_atomic_t nsignals; @@ -90,7 +91,7 @@ static void catchsignal(int signal) return; } -static int bktr_init(const char *video_device, int width, int height, +static av_cold int bktr_init(const char *video_device, int width, int height, int format, int *video_fd, int *tuner_fd, int idev, double frequency) { struct meteor_geomet geo; @@ -204,9 +205,9 @@ static int bktr_init(const char *video_device, int width, int height, return 0; } -static void bktr_getframe(u_int64_t per_frame) +static void bktr_getframe(uint64_t per_frame) { - u_int64_t curtime; + uint64_t curtime; curtime = av_gettime(); if (!last_frame_time @@ -265,7 +266,7 @@ static int grab_read_header(AVFormatContext *s1, AVFormatParameters *ap) s->height = height; s->frame_rate = frame_rate; s->frame_rate_base = frame_rate_base; - s->per_frame = ((u_int64_t)1000000 * s->frame_rate_base) / s->frame_rate; + s->per_frame = ((uint64_t)1000000 * s->frame_rate_base) / s->frame_rate; st->codec->codec_type = CODEC_TYPE_VIDEO; st->codec->pix_fmt = PIX_FMT_YUV420P; |