I have a C++ audio project that is a Score-Based Music System for offline computation…
- User
I have a C++ audio project that is a Score-Based Music System for offline computation and audio rendering. It is based on two distinct scores, that actually are text files, one that contains the DAG of the instrument and one with the parametric of that instrument. I implemented two distinct front-end compiler, namely the lexer and the parser to read them distinctly, plus I wrote a Mediator class that acts as linker between them while implementing a semantic analysis. The mechanism is quite simple but ATM works. I also unit tested it even if I am lacking a bit of integration tests. It also contains a back-end part for the audio processing management but actually I do not have any audio processors stable implemented. I have the opportunity to join a small conference called Integrated Multidisciplinary Music Dictionary, that seems to fit this work. Indeed, I am wondering to write a small article to present the work in progress. I am considering to propose a two=page article that fits in the category poster presentation at the conference. I would present only this front-end part, while leaving for the future the description of the audio back-end. I would receive from you feedback about this actual topic plus some proposal or ideas about what can be a good naming for the actual presentation, especially if you find appropriate the description I propose about the two front-end compiler as naming of the chain lexer, parser and semantic analysis inside the linker (Mediator class) of the two.
- Assistant
- User
Do you think Front-End Compiler is a coherent name for the structure I am proposing?
- Assistant
The term "Front-End Compiler" typically refers to the part of a compiler that processes source code to produce an intermediate representation. This usually involves lexical analysis, parsing, and semantic analysis, which aligns well with the components of your system: the lexer, parser, and the semantic analysis via the Mediator class.
Given that your structure deals with reading and interpreting musical scores, the term "Front-End Compiler" is indeed coherent. It communicates that your system processes textual input (scores) in a manner analogous to how a programming language compiler processes source code. Your description—focusing on the analysis and linking of two distinct scores—supports this naming by highlighting the transformation of human-readable input into a form that your system can operate on.
If you want to emphasize the musical and multidisciplinary nature of the system, you might add a qualifier or a more descriptive title, such as:
- "Front-End Compiler for Musical Score Interpretation"
- "Musical Score Front-End Compiler System"
- "Front-End Compiler in a Score-Based Music System"
These variations maintain the integrity of the term while potentially enhancing clarity for audiences at the conference.
- User
Let me provide you an example and please provide feedback if the description I provided you is aligned with the example I am providing. // instrument.txt AudioSystem as; SinOsc osc; WriteSF writer; osc -> writer; // parameters.txt double frequency_ = 440; AudioSystem::as T = 1000; AudioSystem::as SR = 48000; SinOsc::osc frequency = frequency_; WriteSF::writer filename = "testOsc.wav";
Assume that in the Back-End I have an oscillator generator called SinOsc that is registered in a Factory class, that has a parameter called frequency that is a double, and a Write SoundFiles class that has the parameter filename that is the string of the filename to be created. AudioSystem is the container of the processing and contains the time of the total duration, in this case 1 sec, and the sampling rate as variable, both double. Note: in this moment the compiler accepts double or strings as type.
- Assistant
- User
Let me answer to your Feedback: Parameters and Types. Yes, it is actually what the semantic analyzer does, to handle type validation and error checking. Given the previous example, this modification // parameters.txt SinOsc::osc frequency = "frequency"; // or "440"; for instance
throws a semantic error. Given these considerations, please provide any additional check you think the semantic analyzer can do in this context.
- Assistant