00001 #ifndef PLAYBACKCONFIG_H 00002 #define PLAYBACKCONFIG_H 00003 00004 #include "audiodevice.inc" 00005 #include "bcwindowbase.inc" 00006 #include "defaults.inc" 00007 #include "maxchannels.h" 00008 #include "playbackconfig.inc" 00009 00010 // This structure is passed to the driver for configuration during playback 00011 class AudioOutConfig 00012 { 00013 public: 00014 AudioOutConfig(int duplex); 00015 ~AudioOutConfig(); 00016 00017 int operator!=(AudioOutConfig &that); 00018 int operator==(AudioOutConfig &that); 00019 AudioOutConfig& operator=(AudioOutConfig &that); 00020 void copy_from(AudioOutConfig *src); 00021 int load_defaults(Defaults *defaults); 00022 int save_defaults(Defaults *defaults); 00023 // Total channels in do_channels 00024 int total_playable_channels(); 00025 int playable_channel_number(int number); 00026 // Total channels device can handle 00027 int total_output_channels(); 00028 00029 int fragment_size; 00030 00031 // Which channels to send output to 00032 int do_channel[MAXCHANNELS]; 00033 00034 // Offset for synchronization in seconds 00035 float audio_offset; 00036 00037 // Change default titles for duplex 00038 int duplex; 00039 int driver; 00040 int oss_enable[MAXDEVICES]; 00041 char oss_out_device[MAXDEVICES][BCTEXTLEN]; 00042 int oss_out_channels[MAXDEVICES]; 00043 int oss_out_bits; 00044 00045 00046 00047 char esound_out_server[BCTEXTLEN]; 00048 int esound_out_port; 00049 00050 // ALSA options 00051 char alsa_out_device[BCTEXTLEN]; 00052 int alsa_out_channels; 00053 int alsa_out_bits; 00054 int interrupt_workaround; 00055 00056 // Firewire options 00057 int firewire_channels; 00058 int firewire_channel; 00059 int firewire_port; 00060 int firewire_frames; 00061 char firewire_path[BCTEXTLEN]; 00062 int firewire_syt; 00063 00064 00065 // DV1394 options 00066 int dv1394_channels; 00067 int dv1394_channel; 00068 int dv1394_port; 00069 int dv1394_frames; 00070 char dv1394_path[BCTEXTLEN]; 00071 int dv1394_syt; 00072 }; 00073 00074 // This structure is passed to the driver 00075 class VideoOutConfig 00076 { 00077 public: 00078 VideoOutConfig(); 00079 ~VideoOutConfig(); 00080 00081 int operator!=(VideoOutConfig &that); 00082 int operator==(VideoOutConfig &that); 00083 VideoOutConfig& operator=(VideoOutConfig &that); 00084 void copy_from(VideoOutConfig *src); 00085 int load_defaults(Defaults *defaults); 00086 int save_defaults(Defaults *defaults); 00087 int total_playable_channels(); 00088 char* get_path(); 00089 00090 int driver; 00091 char lml_out_device[BCTEXTLEN]; 00092 char buz_out_device[BCTEXTLEN]; 00093 // Entry in the buz channel table 00094 int buz_out_channel; 00095 int buz_swap_fields; 00096 00097 // X11 options 00098 char x11_host[BCTEXTLEN]; 00099 int x11_use_fields; 00100 // Values for x11_use_fields 00101 enum 00102 { 00103 USE_NO_FIELDS, 00104 USE_EVEN_FIRST, 00105 USE_ODD_FIRST 00106 }; 00107 00108 00109 // Which channels to send output to 00110 int do_channel[MAXCHANNELS]; 00111 00112 // Picture quality 00113 int brightness; 00114 int hue; 00115 int color; 00116 int contrast; 00117 int whiteness; 00118 00119 // Firewire options 00120 int firewire_channel; 00121 int firewire_port; 00122 char firewire_path[BCTEXTLEN]; 00123 int firewire_syt; 00124 00125 // DV1394 options 00126 int dv1394_channel; 00127 int dv1394_port; 00128 char dv1394_path[BCTEXTLEN]; 00129 int dv1394_syt; 00130 }; 00131 00132 class PlaybackConfig 00133 { 00134 public: 00135 PlaybackConfig(); 00136 ~PlaybackConfig(); 00137 00138 PlaybackConfig& operator=(PlaybackConfig &that); 00139 void copy_from(PlaybackConfig *src); 00140 int load_defaults(Defaults *defaults); 00141 int save_defaults(Defaults *defaults); 00142 00143 char hostname[BCTEXTLEN]; 00144 int port; 00145 00146 AudioOutConfig *aconfig; 00147 VideoOutConfig *vconfig; 00148 }; 00149 00150 00151 #endif
1.4.4