VolumeData
Date: 2019-10-22

org.jmol.jvxl.data

## Class VolumeData

- java.lang.Object
- - org.jmol.jvxl.data.VolumeData

-     public class VolumeData
      extends java.lang.Object

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `boolean` | `doIterate`
    `private javajs.util.V3` | `edgeVector`
    `private javajs.util.M3` | `inverseMatrix`
    `boolean` | `isPeriodic`
    `private boolean` | `isSquared`
    `javajs.util.P4` | `mappingPlane`
    `(package private) float` | `mappingPlaneNormalMag`
    `float` | `maxGrid`
    `private float` | `maxVectorLength`
    `float` | `minGrid`
    `private float` | `minToPlaneDistance`
    `int` | `nPoints`
    `javajs.util.V3[]` | `oabc`
    `float[]` | `origin`
    `private javajs.util.P3` | `ptTemp`
    `private javajs.util.P3` | `ptXyzTemp`
    `SurfaceReader` | `sr`
    `private javajs.util.P4` | `thePlane`
    `private float` | `thePlaneNormalMag`
    `javajs.util.V3[]` | `unitVolumetricVectors`
    `private javajs.util.M3` | `volumetricMatrix`
    `javajs.util.P3` | `volumetricOrigin`
    `float[]` | `volumetricVectorLengths`
    `javajs.util.V3[]` | `volumetricVectors`
    `int[]` | `voxelCounts`
    `private float[][][]` | `voxelData`
    `private java.util.Map<java.lang.Integer,java.lang.Float>` | `voxelMap`
    `float` | `voxelVolume`
    `java.lang.String` | `xmlData`
    `private int` | `yzCount`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `VolumeData()`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `float` | `calculateFractionalPoint(float cutoff, javajs.util.P3 pointA, javajs.util.P3 pointB, float valueA, float valueB, javajs.util.P3 pt)`
    `float` | `calcVoxelPlaneDistance(int x, int y, int z)`
    `void` | `capData(javajs.util.P4 plane, float cutoff)`
    `float` | `distancePointToPlane(javajs.util.T3 pt)`
    `float` | `distanceToMappingPlane(javajs.util.T3 pt)`
    `void` | `filterData(boolean isSquared, float invertCutoff)`
    `static float` | `getFractional2DValue(float fx, float fy, float x11, float x12, float x21, float x22)`
    `float[]` | `getOriginFloat()`
    `void` | `getPoint(int ipt, javajs.util.P3 pt)`
    `int` | `getPointIndex(int x, int y, int z)`
    `float` | `getToPlaneParameter()`
    `float[]` | `getVolumetricVectorLengths()`
    `int[]` | `getVoxelCounts()`
    `float[][][]` | `getVoxelData()`
    `float` | `getVoxelDataAt(int pt)`
    `float` | `getVoxelValue(int x, int y, int z)`
    `int` | `getYzCount()`
    `boolean` | `hasPlane()`
    `private int` | `indexLower(float x, int xMax)` periodic grids should have val[0] == val[xMax] voxelCount: 1....2....3....4....5 xMax/index: 0....1....2....3....4....
    `private int` | `indexUpper(float x, int xLower, int xMax)`
    `boolean` | `isNearPlane(int x, int y, int z, float toPlaneParameter)`
    `float` | `lookupInterpolatedVoxelValue(javajs.util.T3 point, boolean getSource)`
    `private float` | `mantissa(float f)`
    `(package private) void` | `offsetCenter(javajs.util.P3 center)`
    `void` | `setDataDistanceToPlane(javajs.util.P4 plane)`
    `void` | `setMappingPlane(javajs.util.P4 plane)`
    `private boolean` | `setMatrix()`
    `void` | `setPlaneParameters(javajs.util.P4 plane)`
    `boolean` | `setUnitVectors()`
    `void` | `setVolumetricOrigin(float x, float y, float z)`
    `void` | `setVolumetricVector(int i, float x, float y, float z)`
    `java.lang.String` | `setVolumetricXml()`
    `int` | `setVoxelCounts(int nPointsX, int nPointsY, int nPointsZ)`
    `void` | `setVoxelData(int pt, float value)`
    `void` | `setVoxelDataAsArray(float[][][] voxelData)`
    `void` | `setVoxelMap()`
    `void` | `setVoxelMapValue(int x, int y, int z, float v)` for sparse data mapping, as for a plane
    `void` | `transform(javajs.util.V3 v1, javajs.util.V3 v2)`
    `void` | `voxelPtToXYZ(int x, int y, int z, javajs.util.T3 pt)`
    `void` | `xyzToVoxelPt(float x, float y, float z, javajs.util.T3i pt3i)`

    - ### Methods inherited from class java.lang.Object

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

- - ### Field Detail

    - #### sr

          public SurfaceReader sr

    - #### doIterate

          public boolean doIterate

    - #### volumetricOrigin

          public final javajs.util.P3 volumetricOrigin

    - #### origin

          public final float[] origin

    - #### volumetricVectors

          public final javajs.util.V3[] volumetricVectors

    - #### voxelCounts

          public final int[] voxelCounts

    - #### nPoints

          public int nPoints

    - #### voxelData

          private float[][][] voxelData

    - #### voxelMap

          private java.util.Map<java.lang.Integer,java.lang.Float> voxelMap

    - #### volumetricVectorLengths

          public final float[] volumetricVectorLengths

    - #### maxVectorLength

          private float maxVectorLength

    - #### minToPlaneDistance

          private float minToPlaneDistance

    - #### yzCount

          private int yzCount

    - #### unitVolumetricVectors

          public final javajs.util.V3[] unitVolumetricVectors

    - #### volumetricMatrix

          private final javajs.util.M3 volumetricMatrix

    - #### inverseMatrix

          private final javajs.util.M3 inverseMatrix

    - #### thePlane

          private javajs.util.P4 thePlane

    - #### thePlaneNormalMag

          private float thePlaneNormalMag

    - #### ptXyzTemp

          private final javajs.util.P3 ptXyzTemp

    - #### xmlData

          public java.lang.String xmlData

    - #### mappingPlane

          public javajs.util.P4 mappingPlane

    - #### mappingPlaneNormalMag

          float mappingPlaneNormalMag

    - #### minGrid

          public float minGrid

    - #### maxGrid

          public float maxGrid

    - #### voxelVolume

          public float voxelVolume

    - #### oabc

          public javajs.util.V3[] oabc

    - #### isPeriodic

          public boolean isPeriodic

    - #### isSquared

          private boolean isSquared

    - #### edgeVector

          private final javajs.util.V3 edgeVector

    - #### ptTemp

          private javajs.util.P3 ptTemp

  - ### Constructor Detail

    - #### VolumeData

          public VolumeData()

  - ### Method Detail

    - #### getVoxelData

          public float[][][] getVoxelData()

    - #### setVoxelDataAsArray

          public void setVoxelDataAsArray(float[][][] voxelData)

    - #### hasPlane

          public boolean hasPlane()

    - #### setMappingPlane

          public void setMappingPlane(javajs.util.P4 plane)

    - #### distanceToMappingPlane

          public float distanceToMappingPlane(javajs.util.T3 pt)

    - #### setVolumetricOrigin

          public void setVolumetricOrigin(float x,
                                          float y,
                                          float z)

    - #### getOriginFloat

          public float[] getOriginFloat()

    - #### getYzCount

          public int getYzCount()

    - #### getVolumetricVectorLengths

          public float[] getVolumetricVectorLengths()

    - #### setVolumetricVector

          public void setVolumetricVector(int i,
                                          float x,
                                          float y,
                                          float z)

    - #### getVoxelCounts

          public int[] getVoxelCounts()

    - #### setVoxelCounts

          public int setVoxelCounts(int nPointsX,
                                    int nPointsY,
                                    int nPointsZ)

    - #### getVoxelDataAt

          public float getVoxelDataAt(int pt)

    - #### getPointIndex

          public int getPointIndex(int x,
                                   int y,
                                   int z)

    - #### getPoint

          public void getPoint(int ipt,
                               javajs.util.P3 pt)

    - #### setVoxelData

          public void setVoxelData(int pt,
                                   float value)

    - #### setVoxelMap

          public void setVoxelMap()

    - #### setMatrix

          private boolean setMatrix()

    - #### transform

          public void transform(javajs.util.V3 v1,
                                javajs.util.V3 v2)

    - #### setPlaneParameters

          public void setPlaneParameters(javajs.util.P4 plane)

    - #### calcVoxelPlaneDistance

          public float calcVoxelPlaneDistance(int x,
                                              int y,
                                              int z)

    - #### getToPlaneParameter

          public float getToPlaneParameter()

    - #### isNearPlane

          public boolean isNearPlane(int x,
                                     int y,
                                     int z,
                                     float toPlaneParameter)

    - #### distancePointToPlane

          public float distancePointToPlane(javajs.util.T3 pt)

    - #### voxelPtToXYZ

          public void voxelPtToXYZ(int x,
                                   int y,
                                   int z,
                                   javajs.util.T3 pt)

    - #### setUnitVectors

          public boolean setUnitVectors()

    - #### xyzToVoxelPt

          public void xyzToVoxelPt(float x,
                                   float y,
                                   float z,
                                   javajs.util.T3i pt3i)

    - #### lookupInterpolatedVoxelValue

          public float lookupInterpolatedVoxelValue(javajs.util.T3 point,
                                                    boolean getSource)

    - #### mantissa

          private float mantissa(float f)

    - #### getVoxelValue

          public float getVoxelValue(int x,
                                     int y,
                                     int z)

    - #### getFractional2DValue

          public static float getFractional2DValue(float fx,
                                                   float fy,
                                                   float x11,
                                                   float x12,
                                                   float x21,
                                                   float x22)

    - #### indexLower

          private int indexLower(float x,
                                 int xMax)

      periodic grids should have val[0] == val[xMax] voxelCount: 1....2....3....4....5 xMax/index: 0....1....2....3....4.... nonper. ^ ---> [0,0] ^ --> [4, 4] periodic ^ ---> [3,4] ^ --> [0, 1]
      Parameters:
        `x` -
        `xMax` -
      Returns:
        lower index in range

    - #### indexUpper

          private int indexUpper(float x,
                                 int xLower,
                                 int xMax)

    - #### offsetCenter

          void offsetCenter(javajs.util.P3 center)

    - #### setDataDistanceToPlane

          public void setDataDistanceToPlane(javajs.util.P4 plane)

    - #### filterData

          public void filterData(boolean isSquared,
                                 float invertCutoff)

    - #### capData

          public void capData(javajs.util.P4 plane,
                              float cutoff)

    - #### setVolumetricXml

          public java.lang.String setVolumetricXml()

    - #### setVoxelMapValue

          public void setVoxelMapValue(int x,
                                       int y,
                                       int z,
                                       float v)

      for sparse data mapping, as for a plane
      Parameters:
        `x` -
        `y` -
        `z` -
        `v` -

    - #### calculateFractionalPoint

          public float calculateFractionalPoint(float cutoff,
                                                javajs.util.P3 pointA,
                                                javajs.util.P3 pointB,
                                                float valueA,
                                                float valueB,
                                                javajs.util.P3 pt)