JWAVE User Guide > JWAVE Convenience Wrappers > JWAVE_SURFACE Function   
  

JWAVE_SURFACE Function   
This JWAVE wrapper function provides a convenient interface to the PV‑WAVE SURFACE procedure. This function always returns a Viewable object (a surface plot) to the JWAVE Java client.
Parameters
This section lists the parameters that the JWAVE_SURFACE wrapper can retrieve, unpack, and use to produce a surface plot. These parameters correspond to the parameters and keywords of the PV‑WAVE SURFACE procedure. You must set these parameters in the client application with the JWaveView.setParam method.
Z—(required) A 2D array containing the values that make up the surface. If X and Y are supplied, the surface is plotted as a function of the X,Y locations specified by their contents. Otherwise, the surface is generated as a function of the array index of each element of Z.
X—A 1D or 2D array specifying the x-coordinates for the surface.
*If X is a 1D array, each element of X specifies the x-coordinate for a column of Z. For example, x(0) specifies the x-coordinate for z(0, *).
*If X is a 2D array, each element of X specifies the x-coordinate of the corresponding point in z (xij specifies the x-coordinate for zij).
Y—A 1D or 2D array specifying the y-coordinates for the surface.
*If Y is a 1D array, each element of y specifies the y-coordinate for a row of Z. For example, y(0) specifies the y-coordinate for z (*, 0).
*If Y is a 2D array, each element of Y specifies the y-coordinate of the corresponding point in z (yij specifies the y-coordinate for zij).
Keyword Parameters
This section lists the keyword parameters that can be retrieved and unpacked in this wrapper function.
Ctable—A PV‑WAVE color table to use for shading, an integer between 0 and 16. See the LOAD_JWAVECT command. (Default: 0—gray-scale)
Mesh—Boolean, indicating whether to draw a mesh surface (will overlay mesh on shading, if shaded). (Default: 1)
Nx, Ny—If set, Z (and X, Y, and Shades) are interpolated from their given size into these dimensions.
Shaded—Boolean, indicating whether to shade the surface with light source. See also Ctable and Shaded. (Default: 0)
Shades—An array expression, of the same dimensions as z, containing the color index at each point. The shading of each pixel is interpolated from the surrounding Shades values. For most displays, this parameter should be scaled into the range of bytes. If this keyword is omitted, light source shading is used. Will be scaled to fit in the range of colors used by Ctable. (Default: no shading)
For detailed information on the keywords listed in the following table, refer to Keyword and Named Color Parameters.
 
Ax
Subtitle
[XYZ]Range
Az
Thick
[XYZ]Style
Charsize
Tickformat
[XYZ]Tickformat
Charthick
Ticklen
[XYZ]Ticklen
Clip
Title
[XYZ]Tickname
Gridstyle
[XYZ]Charsize
[XYZ]Ticks
Noclip
[XYZ]Gridstyle
[XYZ]Tickv
Position
[XYZ]Margin
[XYZ]Title
Skirt
[XYZ]Minor
ZAxis
Named Color Parameters
These parameters must be set by the JWAVE client Java application with the JWaveView.setNamedColor method.
 
Background
Bottom
Color
Returns
This wrapper returns a Viewable object (of a surface plot) to the JWAVE Java client application.
Example
In the client Java application, the setParam method is used to set the parameters to be passed to this JWAVE wrapper on the server. JWAVE_SURFACE unpacks the parameters and builds a PV‑WAVE SURFACE command to produce a surface plot.
These lines of Java code set the name of the wrapper function and some parameters. These lines of code would appear in the JWAVE client application.
JWaveView myJWaveView = new JWaveView(connection, ”JWAVE_SURFACE”) 
myJWaveView.JWaveView.setParam(”X”, elev_data); 
myJWaveView.JWaveView.setParam(”CHARSIZE”, 2); 
myJWaveView.JWaveView.setParam(”TITLE”, ”Snow Depth”); 
myJWaveView.setNamedColor(”BACKGROUND”, java.awt.Color.blue); 
See Also
For more information on using JWAVE wrapper functions, see JWAVE Server Development.
For more information on the PV‑WAVE SURFACE procedure, see the PV‑WAVE Reference.

Version 3.6
Copyright © 2017, Rogue Wave Software, Inc. All Rights Reserved.