source: trunk/packages/vizservers/nanovis/protocol-nanovis.txt @ 4063

Last change on this file since 4063 was 4063, checked in by ldelgass, 6 years ago

Remove some more Rappture deps from nanovis

  • Property svn:eol-style set to native
File size: 8.7 KB
3 Copyright (C) 2004-2013  HUBzero Foundation, LLC
6Protocol for nanovis render server. 
8Commands take the general form of command and arguments using Tcl syntax and are
9terminated by a newline.  Some command arguments expect a Tcl list which can be
10sent by enclosing the list in curly braces to prevent the interpreter from
11splitting the list into multiple arguments.  Likewise, strings with spaces
12should be quoted or enclosed in curly braces.  In the documentation below,
13arguments are indicated by angle brackets and optional arguments are surrounded
14by question marks -- the brackets and question marks are not part of the
15protocol and should not be included in argument strings.  The arguments shown
16in angle brackets should be replaced with a string (where there are fixed
17choices this document indicates valid values by separating them with pipe
18symbols), a list in Tcl syntax, or a numeric value.  Boolean arguments can take
19the form of 0|1, true|false, or yes|no.  Since the protocol commands are
20executed in a Tcl interpreter, Tcl code such as math expressions in expr
21commands enclosed in square brackets are also allowed.  Since the interpreter
22is a "safe" interpreter, some Tcl commands that could cause security issues may
23not be available for use.
25Some commands such as the 'flowvis add' commands create Tcl objects within the
26server's interpreter.  The name sent as an argument when adding the object can
27then be used as a protocol command.  For example, the string sent as the <name>
28argument to 'flowvis add' can then be used in place of <flowObj> in the commands
29documented below.  The flow object name also creates a volume name that can
30be used in volume and cutplane commands, but in that case the name is used as
31an argument to the volume or cutplane commands rather than as the command
34When binary data is to be sent, it should follow the newline after a command
35that indicates incoming data including a byte count argument.
[3605]40axis visible <bool>
[3362]42camera angle <xAngle> <yAngle> <zAngle>
[3478]43       ** Deprecated, use camera orient **
[2892]44camera orient <quatW> <quatX> <quatY> <quatZ>
45camera pan <x> <y>
[3362]46camera pos <x> <y> <z>
[3478]47camera reset <?all?>
[2892]48camera zoom <factor>
[3605]50clientinfo <list>
[3605]52cutplane position <relval> <x|y|z> <?names?>
53         Set the position of a volume cutplane.  Names is
54         an optional list of volume names.
55         relval = [0,1]
56cutplane state <bool> <x|y|z> <?names?>
57         Set the axis (normal) of a volume cutplane.  Names is
58         an optional list of volume names.
60flow add <name> <?option value...?>
61         <name> is an object name to use in <flowObj> commands
62         In addition, a volume is added with the same name
63         which can be used in volume and cutplane commands
64         see '<flowObj> configure' for switch options
65flow delete <names>
66flow exists <name>
[3605]67     This doesn't currently produce a response, it only returns a boolean
68     within the server's interpreter
[2892]69flow goto <nSteps>
[3567]70flow names
[3605]71     This doesn't currently produce a response, it only returns a Tcl list
72     within the server's interpreter
[2892]73flow next
74flow reset
75flow video <token> <?switches...?>
76     -bitrate <val>
77     -format <mpeg|theora|mov>
78     -framerate <val>
79     -height <val>
80     -numframes <val>
81     -width <val>
83<flowObj> box add <name> <?switches...?>
84          See '<flowObj> box configure' for switches
85<flowObj> box configure <name> <?switches...?>
86         -color <{r g b a}>
87         -corner1 <{x y z}>
88         -corner2 <{x y z}>
89         -hide <bool>
90         -linewidth <val>
[3567]91<flowObj> box delete <names>
92<flowObj> box names
[3605]93          This doesn't currently produce a response, it only returns a Tcl list
94          within the server's interpreter
96<flowObj> configure <?option value...?>
[3362]97          -ambient <val>
[2892]98          -arrows <bool>
99          -axis <x|y|z>
100          -diffuse <val>
101          -hide <bool>
[3605]102          -light2side <bool>
[2892]103          -opacity <val>
104          -outline <bool>
105          -position <val|%val>
[3630]106           val = world coordinate, or %val = [0,100]
[2892]107          -slice <bool>
[3362]108          -specularExp <val>
109          -specularLevel <val>
[2892]110          -transferfunction <name>
111          -volume <bool>
112<flowObj> data follows <nbytes> <numComponents>
113          Send flow data.  Data bytes follow the newline after the command
114<flowObj> legend <w> <h>
[2892]116<flowObj> particles add <name> <?switches?>
117          see '<flowObj> particles configure' for switches
118<flowObj> particles configure <name> <?switches?>
119          -axis <x|y|z>
120          -color <{r g b a}>
121          -hide <bool>
122          -position <val|%val>
123           val = [0,100], or %val = [0,1]
124          -size <val>
[3567]125<flowObj> particles delete <names>
126<flowObj> particles names
[3605]127          This doesn't currently produce a response, it only returns a Tcl list
128          within the server's interpreter
[3605]130grid axiscolor <red> <green> <blue> <?alpha?>
131grid axisname <x|y|z> <name> <units>
132grid linecolor <red> <green> <blue> <?alpha?>
133grid visible <bool>
135heightmap create <heightmapName> <xMin> <yMin> <xMax> <yMax> <xNum> <yNum> <valueList>
136heightmap cull <none|back|front>
137heightmap data follows <nBytes> <heightmapName>
138          After newline following command, nBytes of data are sent
139heightmap data visible <bool> <?heightmapNames?>
140heightmap legend <heightmapName> <width> <height>
141heightmap linecontour color <red> <green> <blue> <?heightmapNames?>
142heightmap linecontour visible <bool> <?heightmapNames?>
143heightmap opacity <value> <?heightmapNames?>
144heightmap polygon <wireframe|fill>
145          **Warning: This is a global setting**
146heightmap shading <flat|smooth>
147          **Warning: This is a global setting**
148heightmap transfunc <transferFunctionName> <?heightmapNames?>
150legend <transferfunc name> <width> <height>
151       Request render of transfer function
153screen bgcolor <r> <g> <b>
154       Set screen background color
155screen size <width> <height>
156       Set size of rendered images
159         Render a 2k x 2k image (offscreen buffer). Response image data is tagged
160         as '-type print'
162transfunc define <name> {colors} {alpha}
163          colors => 1 line each of "value r g b"
164          alpha => 1 line each of "value alpha"
165          value => [0,1]
167up <x|y|z|-x|-y|-z>
168   Set orientation of volumes
170volume animation capture <numframes> <?filename?>
171       This is not fully implemented.  Rendered frames are not returned
172       to the client.
173volume animation clear
174volume animation start
175volume animation stop
176volume animation volumes <?names?>
178volume data follows <nbytes> <name>
179volume data state <bool> <?names?>
180volume delete <names>
[2892]181volume exists <name>
[3605]182       This doesn't currently produce a response, it only returns a boolean
183       within the server's interpreter
184volume names
185       This doesn't currently produce a response, it only returns a Tcl list
186       within the server's interpreter
[2892]187volume outline color <r> <g> <b> <?names?>
[3605]188volume outline state <bool> <?names?>
189volume outline visible <bool> <?names?>
[3362]190volume shading ambient <value> <?names?>
[2892]191volume shading diffuse <value> <?names?>
192volume shading isosurface <bool> <?names?>
[3605]193volume shading light2side <bool> <?names?>
[2892]194volume shading opacity <value> <?names?>
[3362]195volume shading specularExp <value> <?names?>
196volume shading specularLevel <value> <?names?>
[2892]197volume shading transfunc <tfName> <?names?>
198volume state <bool> <?names?>
203nv>legend <volume> <min> <max> <nbytes>
[3605]204  (followed by bytes)
206nv>image -type image -bytes <nbytes>
[3605]207  (followed by bytes)
209nv>image -type print -bytes <nbytes>
[3605]210  (followed by bytes)
212nv>image -type movie -token <token> -bytes <nbytes>
213  (followed by bytes)
[2953]215nv>data tag <dataobj-tag> min <val> max <val> vmin <val> vmax <val>
216   The min,max data values for the data object and the cumulative volume data
217   min,max over all volumes
[3605]219nv>data tag <flow-tag> min <val> max <val>
220   Sent after a "<flowObj> data follows...".  Min,max values are for the
221   magnitude of the vector field.
224Error Replies:
[3478]226nv>viserror -bytes <nbytes>
227   <multi-line error string of nbytes>
Note: See TracBrowser for help on using the repository browser.