~ubuntu-branches/ubuntu/karmic/motion/karmic-proposed

« back to all changes in this revision

Viewing changes to video_freebsd.h

  • Committer: Bazaar Package Importer
  • Author(s): Juan Angulo Moreno
  • Date: 2008-06-10 09:15:47 UTC
  • mfrom: (4.1.4 intrepid)
  • Revision ID: james.westby@ubuntu.com-20080610091547-2dcuzqpznlivgvxl
Tags: 3.2.9-4
* Fixed errors in the file debian/rules that affected the non-apply of 
  two patches (01_ffmpeg_creation_update_API.dpatch and 
  02_webhttpd_security_video2_backport.dpatch) (Closes: #484566).
* Bumped Standards-Version to 3.8.0. No changes to package necessary.

Show diffs side-by-side

added added

removed removed

Lines of Context:
12
12
 
13
13
#ifndef WITHOUT_V4L
14
14
 
 
15
#ifdef OLD_BKTR
15
16
#include <machine/ioctl_meteor.h>
16
17
#include <machine/ioctl_bt848.h>
 
18
#else
 
19
#include <dev/bktr/ioctl_meteor.h>
 
20
#include <dev/bktr/ioctl_bt848.h>
 
21
#endif
 
22
 
17
23
 
18
24
#endif
19
25
 
30
36
#define TV_INPUT_PALNCOMB BT848_IFORM_F_RSVD
31
37
*/
32
38
 
 
39
/* video4linux error codes */
 
40
#define V4L_GENERAL_ERROR    0x01          /* binary 000001 */
 
41
#define V4L_BTTVLOST_ERROR   0x05          /* binary 000101 */
 
42
#define V4L_FATAL_ERROR      -1
 
43
 
33
44
#define NORM_DEFAULT    0x00800 // METEOR_FMT_AUTOMODE 
34
45
#define NORM_PAL        0x00200 // METEOR_FMT_PAL 
35
46
#define NORM_NTSC       0x00100 // METEOR_FMT_NTSC 
36
47
#define NORM_SECAM      0x00400 // METEOR_FMT_SECAM
37
48
#define NORM_PAL_NC     0x00200 // METEOR_FMT_PAL /* Greyscale howto ?! FIXME */
38
49
 
 
50
#define NORM_DEFAULT_NEW         BT848_IFORM_F_AUTO 
 
51
#define NORM_PAL_NEW             BT848_IFORM_F_PALBDGHI 
 
52
#define NORM_NTSC_NEW            BT848_IFORM_F_NTSCM
 
53
#define NORM_SECAM_NEW           BT848_IFORM_F_SECAM                    
 
54
#define NORM_PAL_NC_NEW          BT848_IFORM_F_AUTO /* FIXME */ 
 
55
 
 
56
#define PAL     0
 
57
#define NTSC    1
 
58
#define SECAM   2
 
59
#define PAL_NC  3       
 
60
 
 
61
#define PAL_HEIGHT 576
 
62
#define SECAM_HEIGHT 576
 
63
#define NTSC_HEIGHT 480
 
64
 
 
65
#define BSD_VIDFMT_NONE       0
 
66
#define BSD_VIDFMT_YV12       1
 
67
#define BSD_VIDFMT_I420       2
 
68
#define BSD_VIDFMT_YV16       3
 
69
#define BSD_VIDFMT_YUY2       4
 
70
#define BSD_VIDFMT_UYVY       5
 
71
#define BSD_VIDFMT_RV15       6
 
72
#define BSD_VIDFMT_RV16       7
 
73
#define BSD_VIDFMT_LAST       8
 
74
 
 
75
 
39
76
#define IN_DEFAULT      0 
40
77
#define IN_COMPOSITE    0
41
78
#define IN_TV           1
42
79
#define IN_COMPOSITE2   2
43
80
#define IN_SVIDEO       3
44
81
 
 
82
#define CAPTURE_SINGLE    0
 
83
#define CAPTURE_CONTINOUS 1
45
84
 
46
85
#define VIDEO_DEVICE "/dev/bktr0"
47
 
#define TUNER_DEVICE "/dev/turner0"
48
 
 
 
86
#define TUNER_DEVICE "/dev/tuner0"
49
87
 
50
88
struct video_dev {
51
89
        int fd_bktr;
52
90
        int fd_tuner;
53
 
        char *video_device;
54
 
        char *tuner_device;
55
 
        int input;
 
91
        const char *video_device;
 
92
        const char *tuner_device;
 
93
        unsigned short input;
 
94
        unsigned short norm;
56
95
        int width;
57
96
        int height;
58
97
        int contrast;
59
 
        int chroma;
 
98
        int saturation;
 
99
        int hue;
60
100
        int brightness;
61
101
        int channel;
62
102
        int channelset;
69
109
        
70
110
        /* Device type specific stuff: */
71
111
#ifndef WITHOUT_V4L     
72
 
        /* v4l */
 
112
        int capture_method;     
73
113
        int v4l_fmt;
74
 
        int v4l_read_img;
75
114
        unsigned char *v4l_buffers[2];
76
115
        int v4l_curbuffer;
77
116
        int v4l_maxbuffer;
81
120
 
82
121
/* video functions, video_freebsd.c */
83
122
int vid_start(struct context *);
84
 
int vid_next(struct context *, char *map);
 
123
int vid_next(struct context *, unsigned char *map);
85
124
 
86
125
#ifndef WITHOUT_V4L
87
 
void vid_init(struct context *);
 
126
void vid_init(void);
88
127
void vid_close(void);
89
128
void vid_cleanup(void);
90
129
#endif
91
130
 
92
 
/* Network camera functions, netcam.c */
93
 
int netcam_start(struct context *);
94
 
int netcam_next(struct context *, unsigned char *);
95
 
 
96
131
#endif /* _INCLUDE_VIDEO_FREEBSD_H */