From 883f0c74c15a9b04e7266472ccce4c43a540d8d4 Mon Sep 17 00:00:00 2001 From: Joe White Date: Fri, 17 Aug 2018 21:53:42 +0100 Subject: [PATCH 1/9] added python requirements info for pip --- requirements.txt | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 requirements.txt diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 00000000..ba31d543 --- /dev/null +++ b/requirements.txt @@ -0,0 +1,2 @@ +enum==0.4.4 +Jinja2==2.7.3 \ No newline at end of file From e9a16dd19de4336cf711fba64e496953900efee0 Mon Sep 17 00:00:00 2001 From: Joe White Date: Fri, 17 Aug 2018 22:04:13 +0100 Subject: [PATCH 2/9] updated README installation info --- README.md | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 141d88f9..03054409 100644 --- a/README.md +++ b/README.md @@ -13,9 +13,15 @@ It has since then been expanded to provide further support for many different pl ## Requirements * python 2.7 - - `enum` - - `jinja2` - - `nose2` + - `enum` for error reporting + - `jinja2` for templating + - `nose2` for tests + +## Installation + +`$ git clone https://github.com/enzienaudio/hvcc.git` +`$ cd hvcc/` +`$ pip2.7 install -r requirements.txt` ## Usage From c83f8ae3cef60782916ce966d2ad9cbe741f58a2 Mon Sep 17 00:00:00 2001 From: Joe White Date: Fri, 17 Aug 2018 22:04:57 +0100 Subject: [PATCH 3/9] nit --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 03054409..9ce21ed6 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,9 @@ It has since then been expanded to provide further support for many different pl ## Installation `$ git clone https://github.com/enzienaudio/hvcc.git` + `$ cd hvcc/` + `$ pip2.7 install -r requirements.txt` ## Usage From a34b2feaa9be8de118060ea021cc794f096e216e Mon Sep 17 00:00:00 2001 From: Joe White Date: Fri, 17 Aug 2018 22:23:20 +0100 Subject: [PATCH 4/9] added more info about hvcc parameters --- README.md | 64 ++++++++++++++++++++++++------------------------------- 1 file changed, 28 insertions(+), 36 deletions(-) diff --git a/README.md b/README.md index 9ce21ed6..11c0c793 100644 --- a/README.md +++ b/README.md @@ -13,9 +13,9 @@ It has since then been expanded to provide further support for many different pl ## Requirements * python 2.7 - - `enum` for error reporting - - `jinja2` for templating - - `nose2` for tests + - `enum` (for error reporting) + - `jinja2` (for generator templating) + - `nose2` (for tests) ## Installation @@ -46,6 +46,7 @@ As seen in the above command, typical output of `hvcc` is split into several dir The `-o` or `--out_dir` parameter will specify where the output files are placed after a successful compile. For example: + `$ python2.7 hvcc.py ~/myProject/_main.pd -o ~/Desktop/somewhere/else/` Will place all the generated files in `~/Desktop/somewhere/else/`. @@ -56,40 +57,31 @@ The `-n` or `--name` parameter can be used to easily namespace the generated cod `$ python2.7 hvcc.py ~/myProject/_main.pd -o ~/Desktop/somewhere/else/ -n mySynth` +### `-g` Generators + +TODO + +### `-p` Search Paths + +`hvcc` will iterate through various directories when resolving patch objects and abstractions. The `-p` or `--search_paths` argument can be used to add additional folder for `hvcc` to look in. + +This can be handy when using a third-party patch library for example https://github.com/enzienaudio/heavylib. + +`$ python2.7 hvcc.py ~/myProject/_main.pd -o ~/Desktop/somewhere/else/ -n mySynth -p "[~/Workspace/Projects/Enzien/heavylib/, ~/Desktop/myLib/]"` + +### `--copyright` User Copyright + +By default all the generated source files via `hvcc` will have the following copyright text applied to the top of the file: + +`Copyright (c) 2018 Enzien Audio, Ltd.` + +This can be changed with `--copyright` parameter + +`$ python2.7 hvcc.py ~/myProject/_main.pd -o ~/Desktop/somewhere/else/ -n mySynth --copyright "Copyright (c) Los Pollos Hermanos 2019"` + ### `--help` -`hvcc` has a number of commandline paramters. You can see them all here: -``` -$ python2.7 hvcc.py --help - -usage: hvcc.py [-h] [-o OUT_DIR] [-p SEARCH_PATHS [SEARCH_PATHS ...]] - [-n NAME] [-g GEN [GEN ...]] [--results_path RESULTS_PATH] [-v] - [--copyright COPYRIGHT] - in_path - -This is the Enzien Audio Heavy compiler. It compiles supported dataflow -languages into C, and other supported frameworks. - -positional arguments: - in_path The input dataflow file. - -optional arguments: - -h, --help show this help message and exit - -o OUT_DIR, --out_dir OUT_DIR - Build output path. - -p SEARCH_PATHS [SEARCH_PATHS ...], --search_paths SEARCH_PATHS [SEARCH_PATHS ...] - Add a list of directories to search through for - abstractions. - -n NAME, --name NAME Provides a name for the generated Heavy context. - -g GEN [GEN ...], --gen GEN [GEN ...] - List of generator outputs: unity, wwise, js, vst2, fabric - --results_path RESULTS_PATH - Write results dictionary to the given path as a JSON- - formatted string. Target directory will be created if - it does not exist. - -v, --verbose Show debugging information. - --copyright COPYRIGHT - A string indicating the owner of the copyright. -``` + +Displays all the available parameters and options for hvcc. ## Documentation From 95050695495428d4e993a207337f9b479cdc816d Mon Sep 17 00:00:00 2001 From: Joe White Date: Fri, 17 Aug 2018 22:50:56 +0100 Subject: [PATCH 5/9] nit --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 11c0c793..6981cf56 100644 --- a/README.md +++ b/README.md @@ -63,7 +63,7 @@ TODO ### `-p` Search Paths -`hvcc` will iterate through various directories when resolving patch objects and abstractions. The `-p` or `--search_paths` argument can be used to add additional folder for `hvcc` to look in. +`hvcc` will iterate through various directories when resolving patch objects and abstractions. The `-p` or `--search_paths` argument can be used to add additional folders for `hvcc` to look in. This can be handy when using a third-party patch library for example https://github.com/enzienaudio/heavylib. From a3771cd4b117f24c5f0e3606c650b4727870ea8a Mon Sep 17 00:00:00 2001 From: Joe White Date: Wed, 22 Aug 2018 12:50:44 +0100 Subject: [PATCH 6/9] added information about -g parameter and licensing --- README.md | 33 +++++++++++++++++++++++++++++++-- docs/01.introduction.md | 13 ++++++++++--- 2 files changed, 41 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 6981cf56..2ae03961 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ It has since then been expanded to provide further support for many different pl * python 2.7 - `enum` (for error reporting) - `jinja2` (for generator templating) - - `nose2` (for tests) + - `nose2` (for tests, optional) ## Installation @@ -59,7 +59,36 @@ The `-n` or `--name` parameter can be used to easily namespace the generated cod ### `-g` Generators -TODO +Once `hvcc` has generated internal information about the patch the `-g` or `--gen` parameter can be used to specify the output files it should generate. By default it will always include `c` for the C/C++ source files and additional generators can specified for certain framework targets. + +For example: + +`$ python2.7 hvcc.py ~/myProject/_main.pd -o ~/Desktop/somewhere/else/ -n mySynth -g unity` + +Will also generate a `unity` section in the output directory contain all the build projects and source files to compile a Unity plugin. + +It is also possible to pass a list of generators: + +`$ python2.7 hvcc.py ~/myProject/_main.pd -o ~/Desktop/somewhere/else/ -n mySynth -g unity wwise js` + +Available generator options: + +* `c` + +* `bela` + +* `fabric` + +* `js` + +* `pdext` + +* `unity` + +* `vst2` + +* `wwise` + ### `-p` Search Paths diff --git a/docs/01.introduction.md b/docs/01.introduction.md index 3c186288..6659b4e6 100644 --- a/docs/01.introduction.md +++ b/docs/01.introduction.md @@ -9,12 +9,10 @@ Heavy makes use of modern software principles to generate highly optimised C/C++ ## Supported Patch Formats -Currently Heavy supports uploading Pure Data (.pd) patch files. +Currently Heavy supports compiling Pure Data (.pd) patch files. However it's important to note that Pd is merely used as a front-end authoring editor, Heavy does not make use of any Pure Data code, and it is entirely unrelated to the embeddable Pd engine, [libpd](https://github.com/libpd/libpd). -Future versions of Heavy may support different audio patching languages. - ## What is Pure Data? [Pure Data](http://msp.ucsd.edu/software.html) (Pd) is an open source visual programming environment for real-time time audio and music creation. @@ -47,4 +45,13 @@ Heavy-generated code comes pre-optimised for architectures that can take advanta ## Licensing +In general `hvcc` is free to use, though please be aware of the following licences applied to particular parts of the system. + +All the `hvcc` python compiler code is [GPLv3](https://github.com/enzienaudio/hvcc/blob/master/LICENSE). + +The files that `hvcc` generates are split into two types: + +* [Static DSP code](https://github.com/enzienaudio/hvcc/tree/master/generators/ir2c/static) is independent of the input patch contents and provides the basic DSP functionality with which generated output can link against. It has a [BSD](https://github.com/enzienaudio/hvcc/blob/master/generators/ir2c/static/HeavyContext.hpp#L2) licence. + +* Generated code is all the source files that use information pertaining to the input patch, for example `Heavy_{{name}}.cpp`. By default all these files will have a `Copyright (c) 2018 Enzien Audio, Ltd` header, but this can be modified with the [user copyright argument](https://github.com/enzienaudio/hvcc#--copyright-user-copyright). From 2f2c36323e9bae12ae3dd71fc433e2b4eba6b65a Mon Sep 17 00:00:00 2001 From: Joe White Date: Wed, 22 Aug 2018 12:51:22 +0100 Subject: [PATCH 7/9] nit --- README.md | 7 ------- 1 file changed, 7 deletions(-) diff --git a/README.md b/README.md index 2ae03961..f4cbf19c 100644 --- a/README.md +++ b/README.md @@ -74,19 +74,12 @@ It is also possible to pass a list of generators: Available generator options: * `c` - * `bela` - * `fabric` - * `js` - * `pdext` - * `unity` - * `vst2` - * `wwise` From 317a19c1b00bd3b1590bf246c399089436594169 Mon Sep 17 00:00:00 2001 From: Joe White Date: Wed, 22 Aug 2018 12:53:50 +0100 Subject: [PATCH 8/9] nit --- docs/01.introduction.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/01.introduction.md b/docs/01.introduction.md index 6659b4e6..6b3f7a75 100644 --- a/docs/01.introduction.md +++ b/docs/01.introduction.md @@ -51,7 +51,7 @@ All the `hvcc` python compiler code is [GPLv3](https://github.com/enzienaudio/hv The files that `hvcc` generates are split into two types: -* [Static DSP code](https://github.com/enzienaudio/hvcc/tree/master/generators/ir2c/static) is independent of the input patch contents and provides the basic DSP functionality with which generated output can link against. It has a [BSD](https://github.com/enzienaudio/hvcc/blob/master/generators/ir2c/static/HeavyContext.hpp#L2) licence. +* [Static](https://github.com/enzienaudio/hvcc/tree/master/generators/ir2c/static): this code is independent of the input patch contents and provides the basic DSP functionality with which generated output can link against. It has a [BSD](https://github.com/enzienaudio/hvcc/blob/master/generators/ir2c/static/HeavyContext.hpp#L2) licence. -* Generated code is all the source files that use information pertaining to the input patch, for example `Heavy_{{name}}.cpp`. By default all these files will have a `Copyright (c) 2018 Enzien Audio, Ltd` header, but this can be modified with the [user copyright argument](https://github.com/enzienaudio/hvcc#--copyright-user-copyright). +* Generated: this relates to all the source files that use information about the input patch, for example `Heavy_{{name}}.cpp`. By default all these files will have a `Copyright (c) 2018 Enzien Audio, Ltd` header, but this can be modified with the [user copyright argument](https://github.com/enzienaudio/hvcc#--copyright-user-copyright). From 9c1733812414c1af101956cb4b14ca422921a821 Mon Sep 17 00:00:00 2001 From: Joe White Date: Sat, 25 Aug 2018 16:49:23 +0100 Subject: [PATCH 9/9] added information about changing Wwise SDK version target --- docs/06.wwise.md | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/docs/06.wwise.md b/docs/06.wwise.md index dd78fb3e..a5bcd334 100755 --- a/docs/06.wwise.md +++ b/docs/06.wwise.md @@ -2,14 +2,9 @@ ## Version Support -See the table below for heavy and Wwise version compatibility: - -| heavy version | Wwise version | -| --- | --- | -| >= r2017.09 | Wwise 2017 | -| r2017.06 | Wwise 2016 | -| r2017.02 | Wwise 2016 | -| <= r2016.11 | Wwise 2015 | +`hvcc` will generate a Wwise plugin project that links against a particular Wwise SDK version. + +The default is currently `2017.2.2.6553`, however if it's necessary to link against a different Wwise SDK, change the value of `wwise_sdk_version` in the c2wwise generator (found [here](https://github.com/enzienaudio/hvcc/blob/master/generators/c2wwise/c2wwise.py#L58)) to the required SDK version string. ## Source Generator or FX Unit