12.07.2015 Views

MATLAB Function Reference (Volume 2: Graphics)

MATLAB Function Reference (Volume 2: Graphics)

MATLAB Function Reference (Volume 2: Graphics)

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

isosurfaceExamplesThis example uses the flow data set, which represents the speed profile of asubmerged jet within an infinite tank (type help flow for more information).The isosurface is drawn at the data value of -3. The statements that follow thepatch command prepare the isosurface for lighting by:• Recalculating the isosurface normals based on the volume data (isonormals)• Setting the face and edge color (set, FaceColor, EdgeColor)• Specifying the view (daspect, view)• Adding lights (camlight, lighting)[x,y,z,v] = flow;p = patch(isosurface(x,y,z,v,-3));isonormals(x,y,z,v,p)set(p,’FaceColor’,’red’,’EdgeColor’,’none’);daspect([1 1 1])view(3)camlightlighting phong2-256

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!