Anklang-0.3.0.dev712+gdc4e642f anklang-0.3.0.dev712+gdc4e642f
ASE — Anklang Sound Engine (C++)

« « « Anklang Documentation
Loading...
Searching...
No Matches
main.hh
Go to the documentation of this file.
1 // This Source Code Form is licensed MPL-2.0: http://mozilla.org/MPL/2.0
2#ifndef __ASE_MAIN_HH__
3#define __ASE_MAIN_HH__
4
5#include <ase/platform.hh>
6#include <ase/randomhash.hh>
7#include <ase/regex.hh>
8#include <ase/websocket.hh>
9#include <ase/loop.hh>
10#include <ase/callback.hh>
11
12namespace Ase {
13
14// == MainApp ==
15struct MainApp {
16 AudioEngine *engine = nullptr;
17 String pcm_override, midi_override;
18 WebSocketServer *web_socket_server = nullptr;
19 const char *outputfile = nullptr;
21 uint16 websocket_port = 0;
22 int jsonapi_logflags = 1;
23 bool norc = true;
24 bool allow_randomization = true;
25 bool list_drivers = false;
26 bool play_autostart = false;
27 bool no_devices = false;
28 double play_autostop = D64MAX;
29 enum ModeT { SYNTHENGINE, CHECK_INTEGRITY_TESTS };
30 ModeT mode = SYNTHENGINE;
31};
32extern const MainApp &App;
33
34// == Jobs & main loop ==
35extern LoopP main_loop;
36
38void main_loop_wakeup ();
41
44
46struct RtJobQueue { void operator+= (const RtCall&); };
49
50} // Ase
51
52#endif // __ASE_MAIN_HH__
Main handle for AudioProcessor administration and audio rendering.
Definition engine.hh:21
The Anklang C++ API namespace.
Definition api.hh:9
JobQueue main_jobs(call_main_loop)
Execute a job callback in the event loop.
Definition main.hh:43
void main_loop_wakeup()
Wake up the event loop.
Definition main.cc:350
uint16_t uint16
A 16-bit unsigned integer.
Definition cxxaux.hh:23
void main_loop_autostop_mt()
Stop the event loop after a timeout.
Definition main.cc:361
RtJobQueue main_rt_jobs
Queue a callback for the event loop without invoking malloc(), addition is obstruction free.
Definition main.cc:70
Wrap simple callback pointers, without using malloc (obstruction free).
Definition callback.hh:91
Add a simple callback to the event loop, without using malloc (obstruction free).
Definition main.hh:46