4 #include "bitspopup.inc"
6 #include "filesndfile.h"
11 // The following libsndfile files have to be modified to support VFS.
12 // They need to use FILE * instead of file descriptors.
13 // open doesn't seem to be overridable.
18 class FileSndFile
: public FileBase
21 FileSndFile(Asset
*asset
, File
*file
);
24 static int check_sig(Asset
*asset
);
25 int open_file(int rd
, int wr
);
27 int set_audio_position(int64_t sample
);
28 int read_samples(double *buffer
, int64_t len
);
29 int write_samples(double **buffer
, int64_t len
);
30 void format_to_asset();
31 void asset_to_format();
33 static void get_parameters(BC_WindowBase
*parent_window
,
35 BC_WindowBase
* &format_window
,
39 // File must be opened here to get the VFS override. libsndfile-1.0.5 uses
40 // open instead of fopen.
44 // Temp for interleaved channels
46 int64_t temp_allocated
;
51 class SndFileHILO
: public BC_Radial
54 SndFileHILO(SndFileConfig
*gui
, int x
, int y
);
59 class SndFileLOHI
: public BC_Radial
62 SndFileLOHI(SndFileConfig
*gui
, int x
, int y
);
68 class SndFileConfig
: public BC_Window
71 SndFileConfig(BC_WindowBase
*parent_window
, Asset
*asset
);
77 BC_WindowBase
*parent_window
;
78 BitsPopup
*bits_popup
;