#include <DrawMolItem.h>
Inheritance diagram for DrawMolItem:

Public Types | |
| enum | RegenChoices { NO_REGEN = 0, MOL_REGEN = 1, SEL_REGEN = 2, REP_REGEN = 4, COL_REGEN = 8 } |
| Keep track of whether and why we have to regenerate rendering lists In particular, MOL_REGEN means molecular data has changed, whereas if all we did was change from one timestep to another, and nothing in the timestep has changed, then the update_ts flag is changed instead. The idea is that when we implement cached geometry for multiple frames, or a draw all frames option, we don't want to recreate the geometry unnecessarily. More... | |
Public Methods | |
| DrawMolItem (const char *, DrawMolecule *, AtomColor *, AtomRep *, AtomSel *) | |
| virtual | ~DrawMolItem (void) |
| int | change_color (AtomColor *) |
| change coloring method. More... | |
| int | change_rep (AtomRep *) |
| change representation method. More... | |
| int | change_sel (const char *) |
| change atom selection. More... | |
| void | force_recalc (int) |
| force a recalculation of everything. More... | |
| int | atom_displayed (int) |
| if Nth atom is displayed in ANY rep. More... | |
| int | representation_index (void) |
| which representation this is. More... | |
| int | set_smoothing (int n) |
| int | get_smoothing () const |
| void | set_drawframes (const char *frames) |
| Controls for drawing a subset of the molecule's frames. Pass a list of frames to be drawn, or "now" to draw just the current frame (the default). Always succeeds, invalid or out of range frames are ignored. More... | |
| const char * | get_drawframes () const |
| void | set_pbc (int) |
| Controls for display of periodic boundary conditions. Uses the PBC_x defines in VMDDisplayList. More... | |
| int | get_pbc () const |
| void | set_pbc_images (int) |
| Set the number of of periodic image replicas. Must be 1 or higher. More... | |
| int | get_pbc_images () const |
| void | change_pbc () |
| the pbc parameters in Timestep have changed; update the transformation matrices accordingly (but no need to regenerate display lists). More... | |
| void | change_ss () |
| the secondary structure for the molecule has changed. More... | |
| void | change_ts () |
| the currently displayed timestep has changed. More... | |
| void | change_traj () |
| timesteps have been added or removed from the parent molecule. More... | |
| virtual void | prepare () |
| prepare for drawing, do updates. More... | |
| virtual int | pickable_on () |
| override pickable_on so that it returns true only when both the rep and the molecule are on. More... | |
| virtual void | pick_start (PickMode *p, DisplayDevice *d, int btn, int tag, const int *cell, int dim, const float *pos) |
| When picked, pass my parent molecule to the pick mode. More... | |
| virtual void | pick_move (PickMode *p, DisplayDevice *d, int tag, int dim, const float *pos) |
| When picked, pass my parent molecule to the pick mode. More... | |
| virtual void | pick_end (PickMode *p, DisplayDevice *d) |
| When picked, pass my parent molecule to the pick mode. More... | |
Public Attributes | |
| AtomColor * | atomColor |
| atom coloring method to use. More... | |
| AtomRep * | atomRep |
| atom representation to use. More... | |
| AtomSel * | atomSel |
| atom selection to use. More... | |
| int | repNumber |
| current representation ID. More... | |
| char | commentBuffer [1024] |
| buffer for comments. More... | |
| char * | name |
| name of rep, used to identify uniquely. More... | |
Protected Methods | |
| virtual void | do_color_changed (int) |
| virtual void | do_color_rgb_changed (int) |
| virtual void | do_color_scale_changed () |
Protected Attributes | |
| float | spline_basis [4][4] |
| spline basis used for ribbons/tubes. More... | |
Definition at line 51 of file DrawMolItem.h.
|
|
Keep track of whether and why we have to regenerate rendering lists In particular, MOL_REGEN means molecular data has changed, whereas if all we did was change from one timestep to another, and nothing in the timestep has changed, then the update_ts flag is changed instead. The idea is that when we implement cached geometry for multiple frames, or a draw all frames option, we don't want to recreate the geometry unnecessarily.
Definition at line 314 of file DrawMolItem.h. |
|
||||||||||||||||||||||||
|
Definition at line 50 of file DrawMolItem.C. References atomColor, atomRep, atomSel, COL_REGEN, create_modified_CR_spline_basis, Displayable::isOn, MAXCOLORS, MOL_REGEN, name, BaseMolecule::nAtoms, NULL, SEL_REGEN, spline_basis, and stringdup. |
|
|
Definition at line 97 of file DrawMolItem.C. References atomColor, atomRep, atomSel, name, NULL, and ResizeArray< TubeIndexList * >::num. |
|
|
if Nth atom is displayed in ANY rep.
Definition at line 1016 of file DrawMolItem.C. References atomSel, BaseMolecule::nAtoms, NULL, and AtomSel::on. |
|
|
change coloring method.
Definition at line 841 of file DrawMolItem.C. References atomColor, and COL_REGEN. Referenced by DrawMolecule::change_rep, do_color_changed, and do_color_rgb_changed. |
|
|
the pbc parameters in Timestep have changed; update the transformation matrices accordingly (but no need to regenerate display lists).
Definition at line 370 of file DrawMolItem.h. Referenced by DrawMolecule::change_pbc, and set_pbc. |
|
|
change representation method.
Definition at line 952 of file DrawMolItem.C. References atomRep, Surf::clear, MSMSInterface::clear, AtomRep::method, AtomRep::MSMS, NULL, ResizeArray< TubeIndexList * >::num, AtomRep::ORBITAL, REP_REGEN, AtomRep::STRUCTURE, AtomRep::SURF, and AtomRep::TUBE. Referenced by DrawMolecule::change_rep. |
|
|
change atom selection.
Definition at line 1000 of file DrawMolItem.C. References atomSel, AtomSel::change, AtomSel::NO_PARSE, DrawMolecule::notify, and SEL_REGEN. Referenced by DrawMolecule::change_rep. |
|
|
the secondary structure for the molecule has changed.
Definition at line 373 of file DrawMolItem.h. Referenced by DrawMolecule::recalc_ss. |
|
|
timesteps have been added or removed from the parent molecule.
Definition at line 379 of file DrawMolItem.h. |
|
|
the currently displayed timestep has changed.
Definition at line 376 of file DrawMolItem.h. Referenced by DrawMolecule::change_ts. |
|
|
Reimplemented from Displayable. Definition at line 789 of file DrawMolItem.C. References atomColor, Scene::category_index, change_color, COL_REGEN, AtomColor::current_color_use, and Displayable::scene. |
|
|
Reimplemented from Displayable. Definition at line 803 of file DrawMolItem.C. References atomColor, Scene::category_index, Scene::category_item_value, change_color, COL_REGEN, AtomColor::color, BaseMolecule::nAtoms, and Displayable::scene. |
|
|
Reimplemented from Displayable. Definition at line 831 of file DrawMolItem.C. References atomColor, COL_REGEN, AtomColor::find, and AtomColor::uses_colorscale. |
|
|
force a recalculation of everything.
Definition at line 1011 of file DrawMolItem.C. Referenced by DrawMolecule::force_recalc, VMDApp::molrep_reset_scaleminmax, VMDApp::molrep_set_colorupdate, VMDApp::molrep_set_scaleminmax, and VMDApp::molrep_set_smoothing. |
|
|
Definition at line 357 of file DrawMolItem.h. Referenced by VMDApp::molrep_get_drawframes, and GraphicsFltkMenu::update_rep. |
|
|
Definition at line 155 of file DrawMolItem.C. References Displayable::cmdList, and VMDDisplayList::pbc. Referenced by VMDApp::molrep_get_pbc, and GraphicsFltkMenu::update_pbc. |
|
|
Definition at line 165 of file DrawMolItem.C. References Displayable::cmdList, and VMDDisplayList::npbc. Referenced by VMDApp::molrep_get_pbc_images, and GraphicsFltkMenu::update_pbc. |
|
|
Definition at line 349 of file DrawMolItem.h. Referenced by VMDApp::molrep_get_smoothing, VMDApp::molrep_set_smoothing, and GraphicsFltkMenu::update_rep. |
|
||||||||||||
|
When picked, pass my parent molecule to the pick mode.
Reimplemented from Pickable. Definition at line 403 of file DrawMolItem.h. References PickMode::pick_molecule_end. |
|
||||||||||||||||||||||||
|
When picked, pass my parent molecule to the pick mode.
Reimplemented from Pickable. Definition at line 398 of file DrawMolItem.h. References PickMode::pick_molecule_move. |
|
||||||||||||||||||||||||||||||||
|
When picked, pass my parent molecule to the pick mode.
Reimplemented from Pickable. Definition at line 392 of file DrawMolItem.h. References PickMode::pick_molecule_start. |
|
|
override pickable_on so that it returns true only when both the rep and the molecule are on.
Reimplemented from Displayable. Definition at line 3101 of file DrawMolItem.C. References Displayable::displayed. |
|
|
prepare for drawing, do updates.
Reimplemented from Displayable. Definition at line 862 of file DrawMolItem.C. References atomColor, atomRep, Displayable::cmdList, COL_REGEN, Displayable::displayed, Molecule::file_in_progress, AtomRep::method, AtomColor::method, MOL_REGEN, Displayable::need_matrix_recalc, AtomRep::NEWCARTOON, VMDDisplayList::pbc, AtomColor::PHYSICALTIME, AtomColor::STRUCTURE, AtomRep::STRUCTURE, AtomColor::THROB, AtomColor::TIMESTEP, AtomColor::USER, AtomColor::USER2, AtomColor::USER3, AtomColor::USER4, and AtomColor::VELOCITY. |
|
|
which representation this is.
Definition at line 851 of file DrawMolItem.C. References DrawMolecule::component, and DrawMolecule::components. |
|
|
Controls for drawing a subset of the molecule's frames. Pass a list of frames to be drawn, or "now" to draw just the current frame (the default). Always succeeds, invalid or out of range frames are ignored.
Definition at line 239 of file DrawMolItem.C. References MOL_REGEN, and stringdup. Referenced by VMDApp::molrep_set_drawframes. |
|
|
Controls for display of periodic boundary conditions. Uses the PBC_x defines in VMDDisplayList.
Definition at line 145 of file DrawMolItem.C. References change_pbc, Displayable::cmdList, DrawMolecule::notify, and VMDDisplayList::pbc. Referenced by VMDApp::molrep_set_pbc. |
|
|
Set the number of of periodic image replicas. Must be 1 or higher.
Definition at line 159 of file DrawMolItem.C. References Displayable::cmdList, Displayable::need_matrix_recalc, DrawMolecule::notify, and VMDDisplayList::npbc. Referenced by VMDApp::molrep_set_pbc_images. |
|
|
Definition at line 342 of file DrawMolItem.h. Referenced by VMDApp::molrep_set_smoothing. |
|
|
atom coloring method to use.
Definition at line 53 of file DrawMolItem.h. Referenced by add_rep_to_browser, change_color, do_color_changed, do_color_rgb_changed, do_color_scale_changed, DrawMolItem, molinfo_get, VMDApp::molrep_get_color, VMDApp::molrep_get_colorupdate, VMDApp::molrep_get_scaleminmax, VMDApp::molrep_reset_scaleminmax, VMDApp::molrep_set_colorupdate, VMDApp::molrep_set_scaleminmax, prepare, GraphicsFltkMenu::update_rep, and ~DrawMolItem. |
|
|
atom representation to use.
Definition at line 54 of file DrawMolItem.h. Referenced by add_rep_to_browser, change_rep, DrawMolItem, molinfo_get, VMDApp::molrep_get_style, prepare, GraphicsFltkMenu::update_rep, and ~DrawMolItem. |
|
|
atom selection to use.
Definition at line 55 of file DrawMolItem.h. Referenced by add_rep_to_browser, Tool::assign_rep, atom_displayed, change_sel, DrawMolItem, molinfo_get, VMDApp::molrep_get_selection, VMDApp::molrep_get_selupdate, VMDApp::molrep_numselected, VMDApp::molrep_set_selupdate, PickModeMoveRep::rotate, Tool::target, PickModeMoveRep::translate, Tool::tug, GraphicsFltkMenu::update_rep, and ~DrawMolItem. |
|
|
buffer for comments.
Definition at line 57 of file DrawMolItem.h. |
|
|
name of rep, used to identify uniquely.
Definition at line 59 of file DrawMolItem.h. Referenced by Tool::assign_rep, DrawMolItem, DrawMolecule::get_component_name, and ~DrawMolItem. |
|
|
current representation ID.
Definition at line 56 of file DrawMolItem.h. |
|
|
spline basis used for ribbons/tubes.
Definition at line 409 of file DrawMolItem.h. Referenced by DrawMolItem. |
1.2.14 written by Dimitri van Heesch,
© 1997-2002