00001 #ifndef CDRIPPER_H
00002 #define CDRIPPER_H
00003
00004 #include "pluginaclient.h"
00005
00006 #include <linux/cdrom.h>
00007
00008 #define NFRAMES 2
00009 #define FRAMESIZE 2352
00010
00011
00012 class CDRipMain : public PluginAClient
00013 {
00014 public:
00015 CDRipMain(PluginServer *server);
00016 ~CDRipMain();
00017
00018 char* plugin_title();
00019 int is_realtime();
00020 int is_multichannel();
00021 int get_parameters();
00022 int start_loop();
00023 int stop_loop();
00024 int process_loop(double **plugin_buffer, int64_t &write_length);
00025 int load_defaults();
00026 int save_defaults();
00027
00028 BC_Hash *defaults;
00029
00030
00031 int track1, min1, sec1, track2, min2, sec2;
00032 char device[BCTEXTLEN];
00033 int64_t startlba, endlba;
00034 int cdrom;
00035 int get_toc();
00036 int open_drive();
00037 int close_drive();
00038
00039
00040 struct cdrom_read_audio arg;
00041 int FRAME;
00042 int previewing;
00043 int64_t fragment_length;
00044 int64_t total_length;
00045 int endofselection;
00046 int i, j, k, l, attempts;
00047 int64_t fragment_samples;
00048 int64_t currentlength;
00049 int64_t startlba_fragment;
00050 char *buffer;
00051 int16_t *buffer_channel;
00052 double *output_buffer;
00053 MainProgressBar *progress;
00054 };
00055
00056
00057 #endif