labels follow edits fix, group only ungrouped edits, add reset to 7 plugins, add...
[goodguy/cinelerra.git] / cinelerra-5.1 / cinelerra / recordconfig.h
1
2 /*
3  * CINELERRA
4  * Copyright (C) 2008 Adam Williams <broadcast at earthling dot net>
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2 of the License, or
9  * (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
19  *
20  */
21
22 #ifndef RECORDCONFIG_H
23 #define RECORDCONFIG_H
24
25 #include "playbackconfig.inc"
26 #include "bcwindowbase.inc"
27 #include "recordaudio.inc"
28 #include "recordvideo.inc"
29 #include "bchash.inc"
30
31 // This structure is passed to the driver
32 class AudioInConfig
33 {
34         friend class RecordAudio;
35 public:
36         AudioInConfig();
37         ~AudioInConfig();
38
39         AudioInConfig& operator=(AudioInConfig &that);
40         void copy_from(AudioInConfig *src);
41         int load_defaults(BC_Hash *defaults);
42         int save_defaults(BC_Hash *defaults);
43
44 // Determine if the two devices need to be opened in duplex mode
45         static int is_duplex(AudioInConfig *in, AudioOutConfig *out);
46
47         int driver;
48         int oss_enable[MAXDEVICES];
49         char oss_in_device[MAXDEVICES][BCTEXTLEN];
50         int oss_in_bits;
51
52         int firewire_port, firewire_channel;
53         char firewire_path[BCTEXTLEN];
54
55         char esound_in_server[BCTEXTLEN];
56         int esound_in_port;
57         char alsa_in_device[BCTEXTLEN];
58         int alsa_in_bits;
59         char dvb_in_adapter[BCTEXTLEN];
60         int dvb_in_device;
61         int in_samplerate;
62         int dvb_in_bits;
63         int v4l2_in_bits;
64
65 // This should come from EDLSession::recording_format
66         int channels;
67         int follow_audio;
68         int map51_2;
69         double rec_gain;
70 };
71
72 // This structure is passed to the driver
73 class VideoInConfig
74 {
75         friend class RecordVideo;
76 public:
77         VideoInConfig();
78         ~VideoInConfig();
79
80         VideoInConfig& operator=(VideoInConfig &that);
81         void copy_from(VideoInConfig *src);
82         int load_defaults(BC_Hash *defaults);
83         int save_defaults(BC_Hash *defaults);
84         const char *get_path();
85         static const char *default_video_device;
86
87         int driver;
88         char v4l2_in_device[BCTEXTLEN];
89         char v4l2jpeg_in_device[BCTEXTLEN];
90         int v4l2jpeg_in_fields;
91         char v4l2mpeg_in_device[BCTEXTLEN];
92         char screencapture_display[BCTEXTLEN];
93         int firewire_port, firewire_channel;
94         char firewire_path[BCTEXTLEN];
95         char dvb_in_adapter[BCTEXTLEN];
96         int dvb_in_device;
97
98 // number of frames to read from device during video recording.
99         int capture_length;
100 // Dimensions of captured frame
101         int w, h;
102 // Frame rate of captured frames
103         float in_framerate;
104 // update default config after probe
105         int follow_video;
106 };
107
108
109 #endif