--- linuxsampler/trunk/Documentation/lscp.xml 2007/12/05 22:57:03 1553 +++ linuxsampler/trunk/Documentation/lscp.xml 2007/12/06 01:38:31 1554 @@ -16,7 +16,7 @@ to an annoying "missing Normative/Informative References" error message --> - + LinuxSampler Control Protocol + S: OK + + + Example (Windows): + + + C: LOAD INSTRUMENT 'D:/MySounds/cello.gig' 0 0 + S: OK @@ -5733,7 +5741,7 @@ Where <instr> is the absolute path name of the instrument and - <desc> is the new description for the instrument + <desc> is the new description for the instrument (encapsulated into apostrophes, supporting escape sequences as described in chapter "Character Set and Escape Sequences"). @@ -5976,7 +5984,7 @@ FORMAT INSTRUMENTS_DB - + Possible Answers: @@ -6073,8 +6081,187 @@ - +
+ You can query detailed informations about files located + at the same system where the sampler instance is running on. + Using this command set allows to retrieve file informations + even remotely from another machine. + +
+ The front-end can retrieve the amount of instruments + within a given instrument file by sending the + following command: + + + GET FILE INSTRUMENTS <filename> + + + Where <filename> is the name of the instrument + file (encapsulated into apostrophes, supporting escape + sequences as described in chapter + "Character Set and Escape + Sequences"). + + The sampler will try to ask all sampler engines, + whether they support the given file and ask the first + engine with a positive answer for the amount of + instruments. + + Possible Answers: + + + On success, the sampler will answer by + returning the amount of instruments. + + "ERR:<error-code>:<error-message>" - + + if the file could not be handled + + + + + + Examples: + + + C: "GET FILE INSTRUMENTS 'D:/Sounds/Foo.gig'" + S: "10" + + +
+ +
+ The front-end can retrieve a list of all instruments + within a given instrument file by sending the + following command: + + + LIST FILE INSTRUMENTS <filename> + + + Where <filename> is the name of the instrument + file (encapsulated into apostrophes, supporting escape + sequences as described in chapter + "Character Set and Escape + Sequences"). + + The sampler will try to ask all sampler engines, + whether they support the given file and ask the first + engine with a positive answer for a list of IDs for the + instruments in the given file. + + Possible Answers: + + + On success, the sampler will answer by + returning a comma separated list of + instrument IDs. + + "ERR:<error-code>:<error-message>" - + + if the file could not be handled + + + + + + Examples: + + + C: "LIST FILE INSTRUMENTS 'D:/Sounds/Foo.gig'" + S: "0,1,2,3,4,5,6,7,8,9" + + +
+ +
+ The front-end can retrieve detailed informations + about a specific instrument within a given instrument + file by sending the following command: + + + GET FILE INSTRUMENT INFO <filename> + <instr-id> + + + Where <filename> is the name of the instrument + file (encapsulated into apostrophes, supporting escape + sequences as described in chapter + "Character Set and Escape + Sequences") and <instr-id> is the numeric + instrument ID as returned by the + + "LIST FILE INSTRUMENTS" command. + + The sampler will try to ask all sampler engines, + whether they support the given file and ask the first + engine with a positive answer for informations about the + specific instrument in the given file. + + Possible Answers: + + + LinuxSampler will answer by sending a <CRLF> separated list. + Each answer line begins with the settings category name + followed by a colon and then a space character <SP> and finally + the info character string to that setting category. At the + moment the following categories are defined: + + + + NAME - + + name of the instrument as + stored in the instrument file + + + FORMAT_FAMILY - + + name of the sampler format + of the given instrument + + + FORMAT_VERSION - + + version of the sampler format + the instrumen is stored as + + + PRODUCT - + + official product name of the + instrument as stored in the file + + + + ARTISTS - + + artists / sample library + vendor of the instrument + + + + + + + The mentioned fields above don't have to be in particular order. + + Example: + + + C: "GET FILE INSTRUMENT INFO 'D:/Sounds/Foo.gig' 0" + S: "NAME: Lunatic Loops" +    "FORMAT_FAMILY: GIG" +    "FORMAT_VERSION: 3" +    "PRODUCT: The Backbone Bongo Beats" +    "ARTISTS: Jimmy the Fish" +    "." + + +
+
+
The grammar of the control protocol as descibed in @@ -6895,6 +7082,9 @@ "MOVE DB_INSTRUMENT_DIRECTORY" "COPY DB_INSTRUMENT" "COPY DB_INSTRUMENT_DIRECTORY" + "GET FILE INSTRUMENTS" + "LIST FILE INSTRUMENTS" + "GET FILE INSTRUMENT INFO" Note that the forward slash character ('/') has a special meaning in filename / path based arguments: it acts as separator of the nodes in @@ -6905,6 +7095,16 @@ + Note for Windows: file path arguments in LSCP are expected + to use forward slashes as directory node separator similar + to Unix based operating systems. In contrast to Unix however + a Windows typical drive character is expected to be + prefixed to the path. That is an original Windows file path + like "D:\Sounds\My.gig" would become in LSCP: + "D:/Sounds/My.gig". + + + The following LSCP commands even support escape sequences as part of at least one of their text-based arguments (i.e. entity name, description) and / or may contain escape sequences in at least one of