---
name: "plfsurf3d"
section: "3plplot"
platform: "linux"
package: "plplot-doc"
version: "5.10.0+dfsg2-0.4"
release: "Debian 9 (Stretch)"
platforms: ["linux"]
url: "https://new.carta.tech/plfsurf3d"
---

# plfsurf3d(3plplot)

Plot shaded 3-d surface plot

## NAME

**plfsurf3d** - Plot shaded 3-d surface plot

## SYNOPSIS

**plfsurf3d**(*x*, *y*, *zops*, *zp*, *nx*, *ny*, *opt*, *clevel*, *nlevel*)

## DESCRIPTION

Plots a three dimensional shaded surface plot within the environment set up by [**plw3d**(3plplot)](/plw3d/3plplot.md). The surface is defined by the data contained in the 2D  const PLFLT \* const \* matrix or the PLfGrid2 structure *zp*. How the data in  *zp* is rendered is determined by the  *zops* parameter. *zops* is a pointer to a function that reads the data out of the grid structure. The following functions in PLplot core will return an appropriate function pointer:  plf2ops\_c() (use when  *zp* is of type  const PLFLT \* const \*), plf2ops\_grid\_c() (use when  *zp* is a pointer to a row-major PLfGrid2 structure),  plf2ops\_grid\_row\_major() (same as plf2ops\_grid\_c()?) and  plf2ops\_grid\_col\_major() (use when *zp* is a pointer to a  column-major PLfGrid2 structure).  *nx*, *nyoptclevel* and *nlevel* are the same as in for example [**plsurf3d**(3plplot)](/plsurf3d/3plplot.md).

Redacted form? **plfsurf3d(x, y, zops, zp, opt, clevel)**

This function is used in example 8.

## ARGUMENTS

- *x* (const PLFLT \*, input)

  Pointer to set of x coordinate values at which the function is evaluated.

- *y* (const PLFLT \*, input)

  Pointer to set of y coordinate values at which the function is evaluated.

- *zops* (PLF2OPS, input)

  Pointer to a function for processing the data contained in zp.

- *zp* (PLPointer, input)

  Pointer to the data to be plotted, either as a vectored  two-dimensional array with set of function values or as a PLfGrid2 structure.

- *nx* (PLINT, input)

  Number of *x* values at which function is evaluated.

- *ny* (PLINT, input)

  Number of *y* values at which function is evaluated.

- *opt* (PLINT, input)

  Determines the way in which the surface is represented. To specify more than one option just add the options, e.g. FACETED + SURF\_CONT *opt*=FACETED: Network of lines is drawn connecting points at which function is defined.  *opt*=BASE\_CONT: A contour plot is drawn at the base XY plane using parameters *nlevel* and *clevel*.  *opt*=SURF\_CONT: A contour plot is drawn at the surface plane using parameters *nlevel* and *clevel*.  *opt*=DRAW\_SIDES: draws a curtain between the base XY plane and the borders of the plotted function.  *opt*=MAG\_COLOR: the surface is colored according to the value of Z; if MAG\_COLOR is not used, then the default the surface is colored according to the intensity of the reflected light in the surface from a light source whose position is set using [**pllightsource**(3plplot)](/pllightsource/3plplot.md).

- *clevel* (const PLFLT \*, input)

  Pointer to the array that defines the contour level spacing.

- *nlevel* (PLINT, input)

  Number of elements in the clevel array.

## AUTHORS

Many developers (who are credited at http://plplot.sourceforge.net/credits.php) have contributed to PLplot over its long history.

## SEE ALSO

PLplot documentation at http://plplot.sourceforge.net/documentation.php.
