r125: This commit was manufactured by cvs2svn to create tag 'r1_1_7-last'.
[cinelerra_cv/mob.git] / hvirtual / cinelerra / filesndfile.h
blobe98ef92e95adf6976d2b47c9192270aa87fa5804
1 #ifndef FILESNDFILE_H
2 #define FILESNDFILE_H
4 #include "bitspopup.inc"
5 #include "filebase.h"
6 #include "filesndfile.h"
7 #include "sndfile.h"
9 class FileSndFile : public FileBase
11 public:
12 FileSndFile(Asset *asset, File *file);
13 ~FileSndFile();
15 static int check_sig(Asset *asset);
16 int open_file(int rd, int wr);
17 int close_file();
18 int set_audio_position(int64_t sample);
19 int read_samples(double *buffer, int64_t len);
20 int write_samples(double **buffer, int64_t len);
21 void format_to_asset();
22 void asset_to_format();
24 static void get_parameters(BC_WindowBase *parent_window,
25 Asset *asset,
26 BC_WindowBase* &format_window,
27 int audio_options,
28 int video_options);
30 SNDFILE *fd;
31 SF_INFO fd_config;
32 // Temp for interleaved channels
33 double *temp_double;
34 int64_t temp_allocated;
37 class SndFileConfig;
39 class SndFileHILO : public BC_Radial
41 public:
42 SndFileHILO(SndFileConfig *gui, int x, int y);
43 int handle_event();
44 SndFileConfig *gui;
47 class SndFileLOHI : public BC_Radial
49 public:
50 SndFileLOHI(SndFileConfig *gui, int x, int y);
51 int handle_event();
52 SndFileConfig *gui;
56 class SndFileConfig : public BC_Window
58 public:
59 SndFileConfig(BC_WindowBase *parent_window, Asset *asset);
60 ~SndFileConfig();
62 int create_objects();
63 int close_event();
65 BC_WindowBase *parent_window;
66 BitsPopup *bits_popup;
67 SndFileHILO *hilo;
68 SndFileLOHI *lohi;
69 Asset *asset;
72 #endif