8 #include "esp_system.h"
9 #include "esp32-hal-log.h"
11 #elif defined(ESP8266)
13 #elif defined(ARDUINO) && __has_include(<pgmspace.h>)
17 #define VFS_INC_SIZE 10
19 #define MIN(a,b) ((a) < (b) ? (a) : (b))
27 const unsigned char *data;
48 MemoryFS(
const unsigned char *raw=NULL,
unsigned int size=0,
int bytesPerSample=2,
bool swapBytes=
true);
54 bool open(
const char* fileName,
int bytesPerSample=2);
70 static int findByName(
const char * path);
STK in memory File An instance is representing an individual memory array which can be registered wit...
Definition: MemoryFS.h:46
VFS_FD * getFD()
Returns a descriptor with additional information.
static VFS_FD * registerFile(const char *fileName, const unsigned char *raw, unsigned int size)
makes the file available so that the open (by name) operation is working
void close()
sets to open flag to false
size_t getSize()
Determines the size (in samples)
bool fileRead(StkFrames &buffer, unsigned long startFrame, bool doNormalize)
Reads the data into the buffer at the indicated start frame.
bool open(const char *fileName, int bytesPerSample=2)
opens the indicated file
bool isOpen()
checks if the file has been opened
An STK class to handle vectorized audio data.
Definition: Stk.h:287
The STK namespace.
Definition: ADSR.h:8
Simulated File Descriptor of registered virtual "Memory" files.
Definition: MemoryFS.h:25