Date: Wed, 12 Feb 2003 06:36:32 +0100 (MET) From: Peter B <pb@ludd.luth.se> To: freebsd-multimedia@freebsd.org Subject: ffmpeg patches to enable bt878 tv-capture Message-ID: <200302120536.h1C5aWD24746@brother.ludd.luth.se>
next in thread | raw e-mail | index | archive | help
This patch on the port "multimedia/ffmpeg" in the directory
ffmpeg/work/ffmpeg-0.4.6/libavformat
Fixes:
Input mode to PAL.
Input device to TV.
Ability to capture from userland.
Proper handling of open() failures.
*** grab_bsdbktr.c.bak Wed Feb 12 05:12:29 2003
--- grab_bsdbktr.c Wed Feb 12 05:42:51 2003
***************
*** 52,62 ****
#define NTSC_HEIGHT 480
#ifndef VIDEO_FORMAT
! #define VIDEO_FORMAT NTSC
#endif
#ifndef VIDEO_INPUT
! #define VIDEO_INPUT METEOR_INPUT_DEV0;
#endif
static UINT8 *video_buf;
--- 52,64 ----
#define NTSC_HEIGHT 480
#ifndef VIDEO_FORMAT
! //#define VIDEO_FORMAT NTSC
! #define VIDEO_FORMAT PAL
#endif
#ifndef VIDEO_INPUT
! //#define VIDEO_INPUT METEOR_INPUT_DEV0;
! #define VIDEO_INPUT METEOR_INPUT_DEV1;
#endif
static UINT8 *video_buf;
***************
*** 87,98 ****
height = s->height;
s->last_frame_time = 0;
! s->tuner_fd = open ("/dev/tuner0", O_RDWR);
if (s->tuner_fd < 0) {
perror("Warning: Tuner not opened continuing");
}
! video_fd = open(video_device, O_RDWR);
if (video_fd < 0) {
perror(video_device);
return -EIO;
--- 89,103 ----
height = s->height;
s->last_frame_time = 0;
! // s->tuner_fd = open ("/dev/tuner0", O_RDWR);
! s->tuner_fd = open ("/dev/tuner0", O_RDONLY);
if (s->tuner_fd < 0) {
perror("Warning: Tuner not opened continuing");
+ exit(-1);
}
! // video_fd = open(video_device, O_RDWR);
! video_fd = open(video_device, O_RDONLY);
if (video_fd < 0) {
perror(video_device);
return -EIO;
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-multimedia" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200302120536.h1C5aWD24746>
