public class DeformableMesh3D extends Object
Modifier and Type | Field and Description |
---|---|
double |
ALPHA |
double |
BETA |
int[] |
connection_index |
List<Connection3D> |
connections |
DeformableMeshDataObject |
data_object |
double |
GAMMA |
List<Node3D> |
nodes |
static double[] |
ORIGIN |
double[] |
positions |
int[] |
triangle_index |
List<Triangle3D> |
triangles |
Constructor and Description |
---|
DeformableMesh3D(double[] positions,
int[] connection_indices,
int[] triangle_indices) |
DeformableMesh3D(List<double[]> node_positions,
List<int[]> connection_indices,
List<int[]> triangle_indices)
Creates a deformable mesh in 3d.
|
Modifier and Type | Method and Description |
---|---|
void |
addExternalEnergy(ExternalEnergy energy) |
List<double[]> |
calculateCurvature() |
ArrayList<double[]> |
calculateIntensity(MeshImageStack stack,
double thickness)
Thickness is in um.
|
ArrayList<double[]> |
calculateNormalScan(MeshImageStack stack,
double thickness) |
ArrayList<double[]> |
calculateStress() |
double |
calculateVolume() |
double |
calculateVolume(double[] dir) |
void |
clearEnergies() |
void |
confine(Box3D box) |
void |
create3DObject() |
DeformableMesh3D |
createSubMesh(List<Node3D> nodes)
Creates a mesh consisting of all the provided nodes, and their immediate neighbors.
|
Map<Connection3D,Set<Connection3D>> |
getAdjacencyMap(Map<Node3D,List<Connection3D>> connectionMap) |
Box3D |
getBoundingBox() |
Color |
getColor() |
List<Node3D> |
getConnectedNodes() |
List<Connection3D> |
getConnections() |
double[] |
getCoordinates(int dex) |
Map<Node3D,List<Connection3D>> |
getCurvatureMap() |
List<ExternalEnergy> |
getExternalEnergies() |
List<Connection3D> |
getOutterBounds() |
boolean |
isSelected() |
boolean |
isShowSurface() |
static DeformableMesh3D |
loadMesh(double[] positions,
int[] connection_indices,
int[] triangle_indices) |
Runnable |
partialUpdate()
Performs the bulk of calculations for doing an update.
|
void |
removeExternalEnergy(ExternalEnergy energy) |
void |
resetPositions() |
void |
reshape() |
void |
rotate(double[] axis,
double[] center,
double angle) |
void |
scale(double v,
double[] center) |
void |
setColor(Color color) |
void |
setPositions(double[] positions) |
void |
setSelected(boolean selected) |
void |
setShowSurface(boolean showSurface) |
void |
syncConnectionIndices() |
void |
syncTriangleIndices() |
void |
translate(double[] displacement)
Moves all of the nodes in this mesh by the displacement value.
|
void |
update() |
void |
updatePositionBuffer(double[] new_data) |
public double GAMMA
public double ALPHA
public double BETA
public List<Triangle3D> triangles
public List<Connection3D> connections
public double[] positions
public int[] connection_index
public int[] triangle_index
public DeformableMeshDataObject data_object
public static final double[] ORIGIN
public DeformableMesh3D(List<double[]> node_positions, List<int[]> connection_indices, List<int[]> triangle_indices)
node_positions
- collection of double arrays were each array should be {x,y,z}connection_indices
- collection of indexes that indicate connections between nodes.public DeformableMesh3D(double[] positions, int[] connection_indices, int[] triangle_indices)
public static DeformableMesh3D loadMesh(double[] positions, int[] connection_indices, int[] triangle_indices)
public void syncConnectionIndices()
public void syncTriangleIndices()
public void create3DObject()
public void reshape()
public Runnable partialUpdate()
public void update()
public void addExternalEnergy(ExternalEnergy energy)
public void removeExternalEnergy(ExternalEnergy energy)
public void clearEnergies()
public double calculateVolume()
public double calculateVolume(double[] dir)
public ArrayList<double[]> calculateIntensity(MeshImageStack stack, double thickness)
stack
- source of image datathickness
- thickness to be measured.public ArrayList<double[]> calculateStress()
public List<double[]> calculateCurvature()
public void scale(double v, double[] center)
public void rotate(double[] axis, double[] center, double angle)
public void translate(double[] displacement)
displacement
- xyz displacement values.public ArrayList<double[]> calculateNormalScan(MeshImageStack stack, double thickness)
public void updatePositionBuffer(double[] new_data)
public Box3D getBoundingBox()
public List<Connection3D> getConnections()
public void resetPositions()
public void setPositions(double[] positions)
public double[] getCoordinates(int dex)
public Map<Node3D,List<Connection3D>> getCurvatureMap()
public void confine(Box3D box)
public Map<Connection3D,Set<Connection3D>> getAdjacencyMap(Map<Node3D,List<Connection3D>> connectionMap)
public void setShowSurface(boolean showSurface)
public boolean isShowSurface()
public void setColor(Color color)
public Color getColor()
public boolean isSelected()
public void setSelected(boolean selected)
public List<Connection3D> getOutterBounds()
public List<ExternalEnergy> getExternalEnergies()
public DeformableMesh3D createSubMesh(List<Node3D> nodes)
nodes
- selected nodes that will be deformable in the sub mesh.Copyright © 2013–2022 Francis Crick Institute. All rights reserved.