X-Git-Url: http://git.cinelerra-gg.org/git/?a=blobdiff_plain;f=cinelerra-5.0%2Fcinelerra%2Faudioalsa.h;fp=cinelerra-5.0%2Fcinelerra%2Faudioalsa.h;h=0000000000000000000000000000000000000000;hb=30bdb85eb33a8ee7ba675038a86c6be59c43d7bd;hp=8525a248540251f337c75bcc3d1b23532acb3ef8;hpb=52fcc46226f9df46f9ce9d0566dc568455a7db0b;p=goodguy%2Fhistory.git diff --git a/cinelerra-5.0/cinelerra/audioalsa.h b/cinelerra-5.0/cinelerra/audioalsa.h deleted file mode 100644 index 8525a248..00000000 --- a/cinelerra-5.0/cinelerra/audioalsa.h +++ /dev/null @@ -1,69 +0,0 @@ - -/* - * CINELERRA - * Copyright (C) 2008 Adam Williams - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - */ - -#ifndef AUDIOALSA_H -#define AUDIOALSA_H - -#include "adeviceprefs.inc" -#include "arraylist.h" -#include "audiodevice.h" - -#ifdef HAVE_ALSA -#include "alsa/asoundlib.h" - -class AudioALSA : public AudioLowLevel -{ -public: - AudioALSA(AudioDevice *device); - ~AudioALSA(); - - static void list_devices(ArrayList *devices, int pcm_title = 0, int mode = MODEPLAY); - int open_input(); - int open_output(); - int write_buffer(char *buffer, int size); - int read_buffer(char *buffer, int size); - int close_all(); - int close_input(); - int64_t device_position(); - int64_t samples_output() { return samples_written; } - int output_wait(); - int flush_device(); - int interrupt_playback(); - int stop_output(); - -private: - int close_output(); - void translate_name(char *output, char *input, int mode); - snd_pcm_format_t translate_format(int format); - void set_params(snd_pcm_t *dsp, int mode, - int channels, int bits, int samplerate, int samples); - snd_pcm_t* get_output(); - snd_pcm_t* get_input(); - snd_pcm_t *dsp_in, *dsp_out; - int64_t samples_written, buffer_position; - Timer *timer; - int delay, period_size; - Mutex *timer_lock; - int interrupted; -}; - -#endif -#endif