json is loading, but does nothing yet
This commit is contained in:
+33
-49
@@ -27,64 +27,48 @@ using json = nlohmann::json;
|
||||
#include <math.h>
|
||||
#include "libremidi/libremidi.hpp"
|
||||
|
||||
enum Distribution {GEOMETRIC, ROUNDROBIN, RANDOM};
|
||||
|
||||
// Types
|
||||
|
||||
/*class GraphItem;*/
|
||||
/*class Node;*/
|
||||
/*class Edge;*/
|
||||
/*class Signal;*/
|
||||
|
||||
#define RANGE_FILTER(L) std::ranges::views::filter(L)
|
||||
|
||||
/*typedef std::shared_ptr<GraphItem> SPTR_GraphItem;*/
|
||||
/*typedef std::shared_ptr<Node> SPTR_Node;*/
|
||||
/*typedef std::shared_ptr<Edge> SPTR_Edge;*/
|
||||
/**/
|
||||
/*typedef std::shared_ptr<Signal> SPTR_Signal;*/
|
||||
/**/
|
||||
/*typedef std::vector<SPTR_GraphItem> VEC_SPTR_GraphItem;*/
|
||||
/*typedef std::vector<SPTR_Node> VEC_SPTR_Node;*/
|
||||
/*typedef std::vector<SPTR_Edge> VEC_SPTR_Edge;*/
|
||||
/*typedef std::vector<SPTR_Signal> VEC_SPTR_Signal;*/
|
||||
namespace VISEQ::GRAPH::NODES {
|
||||
enum Distribution {GEOMETRIC, ROUNDROBIN, RANDOM};
|
||||
}
|
||||
|
||||
// App Settings
|
||||
struct AppSettings{
|
||||
int mode = 0;
|
||||
int width;
|
||||
int height;
|
||||
float grid;
|
||||
float bpm;
|
||||
float fps;
|
||||
float speed = 16.0f;
|
||||
int gui_selected_midi_out;
|
||||
};
|
||||
namespace VISEQ::APP{
|
||||
struct AppSettings{
|
||||
int mode = 0;
|
||||
int width;
|
||||
int height;
|
||||
float grid;
|
||||
float bpm;
|
||||
float fps;
|
||||
float speed = 16.0f;
|
||||
int gui_selected_midi_out;
|
||||
};
|
||||
}
|
||||
|
||||
namespace VISEQ::GRAPH{
|
||||
enum GraphItemType {NODE, EDGE};
|
||||
enum NodeType {OSCNODE, MIDINODE};
|
||||
}
|
||||
|
||||
|
||||
// Graph
|
||||
namespace VISEQ::MIDI{
|
||||
struct MidiOutPort{
|
||||
libremidi::output_port port;
|
||||
int number;
|
||||
bool enabled;
|
||||
};
|
||||
|
||||
enum GraphItemType {NODE, EDGE};
|
||||
enum NodeType {OSCNODE, MIDINODE};
|
||||
struct MidiOut{
|
||||
libremidi::midi_out out;
|
||||
int number;
|
||||
};
|
||||
|
||||
// MIDI
|
||||
NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE(MidiOut, number)
|
||||
NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE(MidiOutPort, number, enabled)
|
||||
|
||||
struct MidiOutPort{
|
||||
libremidi::output_port port;
|
||||
int number;
|
||||
bool enabled;
|
||||
};
|
||||
|
||||
struct MidiOut{
|
||||
libremidi::midi_out out;
|
||||
int number;
|
||||
};
|
||||
|
||||
NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE(MidiOut, number)
|
||||
NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE(MidiOutPort, number, enabled)
|
||||
|
||||
namespace MIDI{
|
||||
inline std::vector<std::string> Fractions = {"1/32","1/16","3/32","1/8","5/32","3/16","7/32","1/4","9/32","5/16","11/32","3/8","13/32","7/16","15/32","1/2","17/32","9/16","19/32","5/8","21/32","11/16","23/32","3/4","25/32","13/16","27/32","7/8","29/32","15/16","31/32","1/1"};
|
||||
|
||||
inline std::vector<std::string> Notes = {
|
||||
"C-1", "C#-1", "D-1", "D#-1", "E-1", "F-1", "F#-1", "G-1",
|
||||
"G#-1", "A-1", "A#-1", "B-1", "C0", "C#0", "D0", "D#0",
|
||||
|
||||
Reference in New Issue
Block a user