UnityMol  1.0.25beta
UMol.UnityMolStructure Class Reference

Part of the SMCRA data structure, UnityMolStructure stores the models of the structure More...

Public Types

enum  MolecularType { MolecularType.standard, MolecularType.Martini, MolecularType.OPEP, MolecularType.HIRERNA }
 

Public Member Functions

 UnityMolStructure (List< UnityMolModel > listModels, string nameStructure)
 UnityMolStructure constructor taking a list of models as arg More...
 
 UnityMolStructure (UnityMolModel newModel, string nameStructure)
 UnityMolStructure constructor taking a model as arg More...
 
void updateAtomRepValues ()
 Update atom radii and colors of all atoms based on the detected structure molecular type (Martini/HireRNA...) More...
 
void readTrajectoryXDR (string trajPath)
 
void unloadTrajectoryXDR ()
 
void readDX (string dxPath)
 
void unloadDX ()
 
void createModelPlayer ()
 
void modelNext (bool forward=true, bool loop=true)
 
void setModel (int modelId)
 
void trajNext (bool forward=true, bool loop=true)
 
void trajNextSmooth (float t, bool forward=true, bool loop=true, bool newFrame=false)
 
void trajSetFrame (int idF)
 
void updateRepresentations (bool trajectory=true)
 Update positions of GameObject recorded in atomToGo and update representations with new positions More...
 
void trajUpdateAtomPositions ()
 Updates each atom position of the current model of the structure based on the trajectory Uses center of gravity from the first model of the structure ! More...
 
void createTrajectoryPlayer ()
 
List< UnityMolStructuresplitModelsInStructures ()
 Split different models read in a file into several UnityMolStructure More...
 
UnityMolAtom findAtomInModel (UnityMolModel newModel, UnityMolAtom prevAtom, bool strict=false)
 Find the corresponding atom from a model to a different model Returns null if not found More...
 
UnityMolSelection ToSelectionAll ()
 Outputs a UnityMolSelection of all the atoms of the structure, including the atoms of the different models More...
 
UnityMolSelection ToSelection ()
 Outputs a UnityMolSelection of all the atoms of the current model of structure More...
 
string ToSelectionName ()
 
string formatName (int length)
 
void AddAtom (UnityMolAtom toAdd, string modelName, string chainName)
 
Vector3 [] getColliderPositions ()
 
GameObject [] getAtomGos ()
 
void disconnectIMD ()
 

Public Attributes

List< UnityMolModelmodels
 Store all the models of the structure More...
 
string name
 Parsed structure name More...
 
string uniqueName
 Unique structure name More...
 
MolecularType structureType = MolecularType.standard
 Identified type of molecular structure (all-atoms/Martini/Hire-RNA/OPEP) More...
 
List< UnityMolRepresentationrepresentations
 List of representations for this structure More...
 
bool trajectoryLoaded = false
 Trajectory loaded for this structure More...
 
List< Vector3trajAtomPositions
 Atom positions used when reading a trajectory file More...
 
XDRFileReader xdr
 Trajectory reader using xdrfile library More...
 
ArtemisManager artemisM
 Trajectory reader using xdrfile library More...
 
TrajectoryPlayer trajPlayer
 Trajectory player calling trajNext from a monobehaviour Update loop More...
 
DXReader dxr
 Dx file reader More...
 
bool ssInfoFromFile = false
 Secondary structures were parsed More...
 
int currentModelId = 0
 Current model id used More...
 
ModelsPlayer modelsPlayer
 Monobehaviour script to read models like trajectories More...
 
int groupID = 0
 Id of the group used to move the molecules More...
 
Dictionary< UnityMolAtom, GameObject > atomToGo
 Associates a GameObject with an UnityMolAtom More...
 

Properties

UnityMolModel currentModel [get]
 Current model used More...
 
int Count [get]
 Returns the number of atoms in the current model More...
 
int Length [get]
 Returns the number of atoms in the current model More...
 

Detailed Description

Part of the SMCRA data structure, UnityMolStructure stores the models of the structure

Member Enumeration Documentation

◆ MolecularType

Enumerator
standard 
Martini 
OPEP 
HIRERNA 

Constructor & Destructor Documentation

◆ UnityMolStructure() [1/2]

UMol.UnityMolStructure.UnityMolStructure ( List< UnityMolModel listModels,
string  nameStructure 
)

UnityMolStructure constructor taking a list of models as arg

◆ UnityMolStructure() [2/2]

UMol.UnityMolStructure.UnityMolStructure ( UnityMolModel  newModel,
string  nameStructure 
)

UnityMolStructure constructor taking a model as arg

Member Function Documentation

◆ AddAtom()

void UMol.UnityMolStructure.AddAtom ( UnityMolAtom  toAdd,
string  modelName,
string  chainName 
)

◆ createModelPlayer()

void UMol.UnityMolStructure.createModelPlayer ( )

◆ createTrajectoryPlayer()

void UMol.UnityMolStructure.createTrajectoryPlayer ( )

◆ disconnectIMD()

void UMol.UnityMolStructure.disconnectIMD ( )

◆ findAtomInModel()

UnityMolAtom UMol.UnityMolStructure.findAtomInModel ( UnityMolModel  newModel,
UnityMolAtom  prevAtom,
bool  strict = false 
)

Find the corresponding atom from a model to a different model Returns null if not found

◆ formatName()

string UMol.UnityMolStructure.formatName ( int  length)

◆ getAtomGos()

GameObject [] UMol.UnityMolStructure.getAtomGos ( )

◆ getColliderPositions()

Vector3 [] UMol.UnityMolStructure.getColliderPositions ( )

◆ modelNext()

void UMol.UnityMolStructure.modelNext ( bool  forward = true,
bool  loop = true 
)

◆ readDX()

void UMol.UnityMolStructure.readDX ( string  dxPath)

◆ readTrajectoryXDR()

void UMol.UnityMolStructure.readTrajectoryXDR ( string  trajPath)

◆ setModel()

void UMol.UnityMolStructure.setModel ( int  modelId)

◆ splitModelsInStructures()

List<UnityMolStructure> UMol.UnityMolStructure.splitModelsInStructures ( )

Split different models read in a file into several UnityMolStructure

◆ ToSelection()

UnityMolSelection UMol.UnityMolStructure.ToSelection ( )

Outputs a UnityMolSelection of all the atoms of the current model of structure

◆ ToSelectionAll()

UnityMolSelection UMol.UnityMolStructure.ToSelectionAll ( )

Outputs a UnityMolSelection of all the atoms of the structure, including the atoms of the different models

◆ ToSelectionName()

string UMol.UnityMolStructure.ToSelectionName ( )

◆ trajNext()

void UMol.UnityMolStructure.trajNext ( bool  forward = true,
bool  loop = true 
)

◆ trajNextSmooth()

void UMol.UnityMolStructure.trajNextSmooth ( float  t,
bool  forward = true,
bool  loop = true,
bool  newFrame = false 
)

◆ trajSetFrame()

void UMol.UnityMolStructure.trajSetFrame ( int  idF)

◆ trajUpdateAtomPositions()

void UMol.UnityMolStructure.trajUpdateAtomPositions ( )

Updates each atom position of the current model of the structure based on the trajectory Uses center of gravity from the first model of the structure !

◆ unloadDX()

void UMol.UnityMolStructure.unloadDX ( )

◆ unloadTrajectoryXDR()

void UMol.UnityMolStructure.unloadTrajectoryXDR ( )

◆ updateAtomRepValues()

void UMol.UnityMolStructure.updateAtomRepValues ( )

Update atom radii and colors of all atoms based on the detected structure molecular type (Martini/HireRNA...)

◆ updateRepresentations()

void UMol.UnityMolStructure.updateRepresentations ( bool  trajectory = true)

Update positions of GameObject recorded in atomToGo and update representations with new positions

Member Data Documentation

◆ artemisM

ArtemisManager UMol.UnityMolStructure.artemisM

Trajectory reader using xdrfile library

◆ atomToGo

Dictionary<UnityMolAtom, GameObject> UMol.UnityMolStructure.atomToGo

Associates a GameObject with an UnityMolAtom

◆ currentModelId

int UMol.UnityMolStructure.currentModelId = 0

Current model id used

◆ dxr

DXReader UMol.UnityMolStructure.dxr

Dx file reader

◆ groupID

int UMol.UnityMolStructure.groupID = 0

Id of the group used to move the molecules

◆ models

List<UnityMolModel> UMol.UnityMolStructure.models

Store all the models of the structure

◆ modelsPlayer

ModelsPlayer UMol.UnityMolStructure.modelsPlayer

Monobehaviour script to read models like trajectories

◆ name

string UMol.UnityMolStructure.name

Parsed structure name

◆ representations

List<UnityMolRepresentation> UMol.UnityMolStructure.representations

List of representations for this structure

◆ ssInfoFromFile

bool UMol.UnityMolStructure.ssInfoFromFile = false

Secondary structures were parsed

◆ structureType

MolecularType UMol.UnityMolStructure.structureType = MolecularType.standard

Identified type of molecular structure (all-atoms/Martini/Hire-RNA/OPEP)

◆ trajAtomPositions

List<Vector3> UMol.UnityMolStructure.trajAtomPositions

Atom positions used when reading a trajectory file

◆ trajectoryLoaded

bool UMol.UnityMolStructure.trajectoryLoaded = false

Trajectory loaded for this structure

◆ trajPlayer

TrajectoryPlayer UMol.UnityMolStructure.trajPlayer

Trajectory player calling trajNext from a monobehaviour Update loop

◆ uniqueName

string UMol.UnityMolStructure.uniqueName

Unique structure name

◆ xdr

XDRFileReader UMol.UnityMolStructure.xdr

Trajectory reader using xdrfile library

Property Documentation

◆ Count

int UMol.UnityMolStructure.Count
get

Returns the number of atoms in the current model

◆ currentModel

UnityMolModel UMol.UnityMolStructure.currentModel
get

Current model used

◆ Length

int UMol.UnityMolStructure.Length
get

Returns the number of atoms in the current model


The documentation for this class was generated from the following file: