Remove model id on c++ side constructor, use index as storepath

This commit is contained in:
msqr1
2024-10-03 19:24:57 -07:00
parent 30228eb0c1
commit 0d1acd0ebd
10 changed files with 18 additions and 21 deletions

View File

@@ -8,12 +8,6 @@
#include "emscripten/console.h"
namespace fs = std::filesystem;
struct AudioData {
float* data;
int len;
AudioData(int start, int len) : data{reinterpret_cast<float*>(start)}, len{len} {}
};
enum Event {
// Shared
status,
@@ -30,6 +24,12 @@ enum UntarStatus {
FailedWrite,
FailedClose
};
struct AudioData {
float* data;
int len;
AudioData(int start, int len) : data{reinterpret_cast<float*>(start)}, len{len} {}
};
#ifndef MAX_WORKERS
#define MAX_WORKERS 1
#endif
@@ -43,6 +43,6 @@ struct WorkerPool {
};
extern "C" void fireEv(int idx, int typeIdx, const char* content = nullptr);
int untar(unsigned char* tar, int tarSize, const std::string& storepath);
int untar(unsigned char* tar, int tarSize, const char* storepath);
extern WorkerPool globalPool;