# Class IsosurfaceMesh

java.lang.Object
org.jmol.util.MeshSurface
org.jmol.shape.Mesh
org.jmol.shapesurface.IsosurfaceMesh

public class IsosurfaceMesh extends Mesh

## Field Summary

Fields
Modifier and Type
Field
Description
`ColorEncoder`
`colorEncoder`
`int`
`dataType`
`int`
`firstRealVertex`
`boolean`
`hasGridPoints`
`JvxlData`
`jvxlData`
`int`
`vertexIncrement`

### Fields inherited from class Mesh

`atomIndex, bsTemp, cappingObject, checkByteCount, color, colorCommand, colorDensity, colorType, connectedAtoms, diameter, drawTriangles, fillTriangles, frontOnly, hasTranslucentVertices, havePlanarContours, haveXyPoints, hoverLabel, index, insideOut, isModelConnected, isShell, isTwoSided, isValid, lattice, lighting, lineData, linkedMesh, meshColix, modelIndex, normixes, PREVIOUS_MESH_ID, ptCenter, recalcAltVertices, reverseColor, scale3d, scriptCommand, showContourLines, showPoints, showTriangles, slabbingObject, symopColixes, symopNormixes, symops, thisID, title, unitCell, useColix, vAB, visibilityFlags, visible, volumeRenderPointSize, vTemp, width`

### Fields inherited from class MeshSurface

`altVertices, bsDisplay, bsPolygons, bsSlabDisplay, bsSlabGhost, colix, colixBack, colorsExplicit, dataOnly, haveQuads, iA, iB, iC, isColorSolid, isDrawPolygon, isMerged, mat4, mergePolygonCount0, mergeVertexCount0, meshType, normalCount, normals, normalsTemp, normixCount, nSets, oabc, offset, P_CHECK, P_CONTOUR, P_EXPLICIT_COLOR, pc, pcs, pis, polygonCount0, SEED_COUNT, slabColix, slabMeshType, slabOptions, surfaceAtoms, surfaceSet, vc, vcs, vertexCount0, vertexSets, vertexSource, vs, vvs, vwr`

## Method Summary

Modifier and Type
Method
Description
`static void`
`addContourPoints(Lst<Object> v, BS bsContour, int i, SB fData, T3[] vertices, float[] vertexValues, int iA, int iB, int iC, float value)`
`Map<String,BS>`
`copyVertexColorMap()`
`P3[]`
`getBoundingBox()`
`Lst<Object>[]`
`getContours()`
create a set of contour data.
`Object`
`getInfo(boolean isAll)`
`protected float`
`getMinDistance2ForVertexGrouping()`
`Object`
`getPLYData(boolean isBinary)`
`Object`
`getPmeshData(boolean isBinary)`
`float`
`getResolution()`
`SymmetryInterface`
`getUnitCell()`
`float[]`
`getValidValues(BS bs)`
`T3[]`
`getValidVertices(BS bs)`
`BS`
`getVisibleVertexBitSet()`
`protected void`
`merge(MeshData m)`
`void`
`reinitializeLightingAndColor(Viewer vwr)`
`void`
`setBoundingBox(P3[] pts)`
`static void`
`setContourVector(Lst<Object> v, int nPolygons, BS bsContour, float value, short colix, int color, SB fData)`
`void`
`setDiscreteColixes(float[] values, short[] colixes)`
`void`
`setMerged(boolean TF)`
`void`
`setTranslucent(boolean isTranslucent, float iLevel)`
`protected void`
`sumVertexNormals(T3[] vertices, V3[] vectorSums)`
`void`
`updateCoordinates(M4 m, BS bs)`
bs will be null if this is a set from the new isosurface MOVE [mat4] command

### Methods inherited from class Mesh

`checkWithin, clear, clearMesh, getNormals, getNormalsTemp, getOffsetVertices, getRendering, getState, getVertexIndexFromNumber, getVisibleVBS, initialize, mesh1, rotateTranslate, setLighting, setNormixes, setShowWithin, setTokenProperty, setVisibilityFlags, sumVertexNormals2`

### Methods inherited from class MeshSurface

`addPolygon, addPolygonC, addQuad, addTriangle, addTriangleCheck, addV, addVCVal, getFaces, getMeshSlicer, getSlabColor, getSlabType, getSphereData, getSphericalInterpolationFraction, getVertices, invalidatePolygons, newMesh, resetSlab, setABC, setBox, setColix, setColixBack, setPolygonCount, setTranslucentVertices, slabBrillouin, slabPolygonsList`

### Methods inherited from class Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### jvxlData

public JvxlData jvxlData

### vertexIncrement

public int vertexIncrement

### firstRealVertex

public int firstRealVertex

### dataType

public int dataType

### hasGridPoints

public boolean hasGridPoints

### colorEncoder

public ColorEncoder colorEncoder

## Method Details

### getResolution

public float getResolution()

Overrides:
  `getResolution` in class `MeshSurface`

### setTranslucent

public void setTranslucent(boolean isTranslucent, float iLevel)

Overrides:
  `setTranslucent` in class `Mesh`

### setMerged

public void setMerged(boolean TF)

### sumVertexNormals

protected void sumVertexNormals(T3[] vertices, V3[] vectorSums)

Overrides:
  `sumVertexNormals` in class `Mesh`

### getContours

public Lst<Object>[] getContours()
create a set of contour data. Each contour is a Vector containing: 0 Integer number of polygons (length of BitSet) 1 BitSet of critical triangles 2 Float value 3 int[] [colorArgb] 4 StringXBuilder containing encoded data for each segment: char type ('3', '6', '5') indicating which two edges of the triangle are connected: '3' 0x011 AB-BC '5' 0x101 AB-CA '6' 0x110 BC-CA char fraction along first edge (jvxlFractionToCharacter) char fraction along second edge (jvxlFractionToCharacter) 5- stream of pairs of points for rendering

Returns:
  contour vector set

### getPmeshData

public Object getPmeshData(boolean isBinary)

### getPLYData

public Object getPLYData(boolean isBinary)

### setContourVector

public static void setContourVector(Lst<Object> v, int nPolygons, BS bsContour, float value, short colix, int color, SB fData)

### addContourPoints

public static void addContourPoints(Lst<Object> v, BS bsContour, int i, SB fData, T3[] vertices, float[] vertexValues, int iA, int iB, int iC, float value)

### setDiscreteColixes

public void setDiscreteColixes(float[] values, short[] colixes)

### reinitializeLightingAndColor

public void reinitializeLightingAndColor(Viewer vwr)

### getBoundingBox

public P3[] getBoundingBox()

Overrides:
  `getBoundingBox` in class `Mesh`

### setBoundingBox

public void setBoundingBox(P3[] pts)

Overrides:
  `setBoundingBox` in class `MeshSurface`
Parameters:
  `pts` -

### merge

protected void merge(MeshData m)

### getUnitCell

public SymmetryInterface getUnitCell()

Overrides:
  `getUnitCell` in class `Mesh`
Returns:
  unitcell

### getMinDistance2ForVertexGrouping

protected float getMinDistance2ForVertexGrouping()

Overrides:
  `getMinDistance2ForVertexGrouping` in class `Mesh`

### getVisibleVertexBitSet

public BS getVisibleVertexBitSet()

Overrides:
  `getVisibleVertexBitSet` in class `Mesh`

### updateCoordinates

public void updateCoordinates(M4 m, BS bs)
bs will be null if this is a set from the new isosurface MOVE [mat4] command

Parameters:
  `m` -
  `bs` -

### getInfo

public Object getInfo(boolean isAll)

Overrides:
  `getInfo` in class `Mesh`

### getValidValues

public float[] getValidValues(BS bs)

### getValidVertices

public T3[] getValidVertices(BS bs)

### copyVertexColorMap

public Map<String,BS> copyVertexColorMap()