EdgeForm

The next cell displays the usage message for EdgeForm.

? EdgeForm

EdgeForm[g] is a three-dimensional graphics directive which specifies that edges of polygons are to be drawn using the graphics directive or list of graphics directives g.

The usage message for EdgeForm indicates  EdgeForm is a "three-dimensional graphics directive" this indicates it can be used inside Graphics3D and with functions that produce Graphics3D expressions.  ParametricPlot3D produces Graphics3D, and it's usage message indicates that ParametricPlot3D[{fx,fy,fz,s},{x,xmin,xmax},{ymin,ymax}] produces a plot shaded according to the color specification (s).  Here (s) can be a single three-dimensional graphics directive or a list of three-dimensional graphics directives.

Consider the next cell where the default EdgeForm around polygons is used.

ParametricPlot3D[{x, y, Sin[x y/3]}, {x, 0, 3}, {y, 0, 3}] ;

The next cell makes the same graphic except no edges are drawn around the polygons.

ParametricPlot3D[{x, y, Sin[x y/3], EdgeForm[]}, {x, 0, 3}, {y, 0, 3}] ;

The next cell plots the same function using a gray edges around the polygons.

RowBox[{RowBox[{ParametricPlot3D, [, RowBox[{RowBox[{{, RowBox[{x, ,, y, ,, Sin[x y/3], ,, Row ... x[{EdgeForm, [, RowBox[{GrayLevel, [, 0.5, ]}], ]}]}], }}], ,, {x, 0, 3}, ,, {y, 0, 3}}], ]}], ;}]

The next cell uses colored edges where the color varies as a function of x and y.

ParametricPlot3D[{x, y, Sin[x y/3], EdgeForm[RGBColor[1 - x/3, 1 - y/3, 0]]},  {x, 0, 3}, {y, 0, 3}] ;

The next cell uses thick colored edges where the color varies as a function of x and y.

ParametricPlot3D[{x, y, Sin[x y/3], EdgeForm[{RGBColor[1 - x/3, 1 - y/3, 0], AbsoluteThickness[4]}] },  {x, 0, 3}, {y, 0, 3}, PlotPoints->8] ;

An example is given below where EdgeForm is used with Grapgics3D.  Here EdgeForm[] indicates no edges should be drawn around the polygons.

Needs["Graphics`Shapes`"] Show[Graphics3D[{EdgeForm[], Torus[]}]] ;

In the next cell Gray edges around the polygons are used.

RowBox[{RowBox[{Show, [, RowBox[{Graphics3D, [, RowBox[{{, RowBox[{RowBox[{EdgeForm, [, RowBox ... hickness, [, 0.01, ]}], ,, RowBox[{GrayLevel, [, 0.5, ]}]}], ]}], ,, Torus[]}], }}], ]}], ]}], ;}]

Keep in mind that DensityPlot, ListDensityPlot, ListPlot3D, Plot and Plot3D don't produce Graphics3D expressions.  Instead one should use the options Mesh and MeshStyle to get similar results with DensityPlot, ListDensityPlot, ListPlot3D, Plot and Plot3D.


Created by Mathematica  (May 16, 2004)

Back to Ted’s Tricks index page