Mercurial > hg > piper
changeset 28:4c3ac59c9089
Plugin configuration data
author | Chris Cannam |
---|---|
date | Wed, 09 Mar 2016 14:30:05 +0000 |
parents | 4a33a6bfc4b8 |
children | 216a78d1fa52 |
files | .hgignore examples/pluginconfig.json schema/basic.json schema/pluginconfiguration.json |
diffstat | 4 files changed, 45 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/.hgignore Wed Mar 09 14:30:05 2016 +0000 @@ -0,0 +1,2 @@ +syntax: glob +*~
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/examples/pluginconfig.json Wed Mar 09 14:30:05 2016 +0000 @@ -0,0 +1,1 @@ +{"blockSize": 512, "channelCount": 2, "parameterValues": {"sensitivity": 40, "threshold": 3}, "stepSize": 1024}
--- a/schema/basic.json Tue Mar 08 17:17:57 2016 +0000 +++ b/schema/basic.json Wed Mar 09 14:30:05 2016 +0000 @@ -4,9 +4,16 @@ "description": "schema for the basic part of various Vamp descriptors", "type": "object", "properties": { - "identifier": { "type": "string" }, - "name": { "type": "string" }, - "description": { "type": "string" } + "identifier": { + "type": "string", + "pattern": "^[a-zA-Z0-9_-]+$" + }, + "name": { + "type": "string" + }, + "description": { + "type": "string" + } }, "required": [ "identifier" ], "additionalProperties": false
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/schema/pluginconfiguration.json Wed Mar 09 14:30:05 2016 +0000 @@ -0,0 +1,32 @@ +{ + "id": "http://vamp-plugins.org/json/schema/pluginconfiguration#", + "$schema": "http://json-schema.org/draft-04/schema#", + "description": "schema for a serialised bundle of configuration data associated with a Vamp Plugin", + "type": "object", + "properties": { + "parameterValues": { + "type": "object", + "patternProperties": { + "^[a-zA-Z0-9_-]+$": { + "type": "number" + } + }, + "additionalProperties": false + }, + "currentProgram": { + "type": "string" + }, + "channelCount": { + "type": "integer" + }, + "stepSize": { + "type": "integer" + }, + "blockSize": { + "type": "integer" + } + }, + "required": [ "channelCount", "stepSize", "blockSize" ], + "additionalProperties": false +} +