Improved code generator for Faust

Programming applications for making music on Linux.

Moderators: MattKingUSA, khz

Post Reply
jpcima
Established Member
Posts: 5
Joined: Tue Aug 13, 2019 6:18 am

Improved code generator for Faust

Post by jpcima »

Hello. I'm working on some projects which use increasingly more faust code for processing.
It's very good, I found however that these generated files are not easy to work with.
When I've examined some projects as zam-plugins and guitarix, the method for integrating faust is based on a transforming script, or a simple copy-pasting.

I thought of it, and made a tool for myself to generate with the least amount of hacks possible.
What I did essentially, it's to extract code and metadata out of faust's codegen and XML, and then I passed this entire data into a template engine.
By this method, the code is directly like I want out of the program, and is remade by a single rule of Makefile.

The program is located here, and I completed adding a manual today. Examples are included and buildable in the sources.
https://github.com/jpcima/faustpp
CrocoDuck
Established Member
Posts: 1133
Joined: Sat May 05, 2012 6:12 pm
Been thanked: 17 times

Re: Improved code generator for Faust

Post by CrocoDuck »

Good stuff! I love Faust.

By the way, the topic of integrating Faust code in other C++ code in a "faustian" way was covered at the IFC 2018. Here, if I remember properly.
User avatar
marbangens
Established Member
Posts: 56
Joined: Fri Nov 16, 2018 8:39 pm
Been thanked: 6 times

Re: Improved code generator for Faust

Post by marbangens »

Cool 8) Must try Faust, thanks
sletz
Posts: 1
Joined: Wed Sep 11, 2019 1:36 pm

Re: Improved code generator for Faust

Post by sletz »

"I found however that these generated files are not easy to work with."

Usually you should not have to "hack" the generated code, but develop a C++ wrapper class. They are several way to do that. What is the exact problem you want to solve ?
Post Reply