23 #ifndef INCLUDED_BAZ_FILE_SOURCE_H 24 #define INCLUDED_BAZ_FILE_SOURCE_H 26 #include <gnuradio/sync_block.h> 40 typedef boost::shared_ptr<file_source>
sptr;
57 static sptr make(
size_t itemsize,
const char *filename,
bool repeat =
false,
long offset = 0,
const char *timing_filename = NULL,
bool pad =
false,
double rate = 0.0,
bool auto_load =
true,
const std::vector<std::string>& files = std::vector<std::string>());
65 virtual bool seek(
long seek_point) = 0;
66 virtual bool seek(
long seek_point,
int whence) = 0;
74 virtual void open(
const char *filename,
bool repeat =
false,
long offset = 0,
const char *timing_filename = NULL,
bool pad =
false,
double rate = 0.0,
bool auto_load =
true,
const std::vector<std::string>& files = std::vector<std::string>()) = 0;
79 virtual void close() = 0;
81 virtual size_t offset() = 0;
82 virtual size_t file_offset() = 0;
83 virtual double time(
bool relative =
false,
bool raw =
false) = 0;
84 virtual double sample_rate() = 0;
85 virtual double sample_count(
bool raw =
false) = 0;
86 virtual double duration() = 0;
87 virtual size_t file_index() = 0;
88 virtual std::string file_path() = 0;
89 virtual std::vector<std::string> files() = 0;
Read stream from file.
Definition: baz_file_source.h:35
boost::shared_ptr< file_source > sptr
Definition: baz_file_source.h:40
Definition: baz_additive_scrambler_bb.h:28
#define BAZ_API
Definition: config.h:8