Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

TclGraphics.C File Reference

#include <stdlib.h>
#include "VMDApp.h"
#include "Molecule.h"
#include "MoleculeList.h"
#include "MaterialList.h"
#include "tcl.h"
#include "TclCommands.h"
#include "Scene.h"
#include "MoleculeGraphics.h"

Go to the source code of this file.

Defines

#define AT_LEAST(n, s)
#define MUST_HAVE(n, s)

Functions

int tcl_graphics_triangle (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_trinorm (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_tricolor (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_cylinder (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_point (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_pickpoint (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_line (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_materials (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_material (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp, MaterialList *mlist)
int tcl_graphics_color (VMDApp *app, MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_cone (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_sphere (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_text (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_spheretube (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_delete (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_replace (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_exists (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics_info (MoleculeGraphics *gmol, int argc, const char *argv[], Tcl_Interp *interp)
int tcl_graphics (VMDApp *app, int molid, int argc, const char *argv[], Tcl_Interp *interp)
int graphics_tcl (ClientData cd, Tcl_Interp *interp, int argc, const char *argv[])


Define Documentation

#define AT_LEAST n,
 
 

Value:

{                                                                 \
  if (argc < n) {                                                 \
    Tcl_SetResult(interp,                                         \
              (char *) "graphics: " s ": not enough parameters",  \
              TCL_STATIC);                                        \
    return TCL_ERROR;                                             \
  }                                                               \
}

Definition at line 34 of file TclGraphics.C.

Referenced by tcl_graphics_cone, tcl_graphics_cylinder, tcl_graphics_line, tcl_graphics_sphere, tcl_graphics_spheretube, and tcl_graphics_text.

#define MUST_HAVE n,
 
 

Value:

{                                                                 \
  if (argc != n) {                                                \
    Tcl_SetResult(interp,                                         \
      (char *) "graphics: " s ": incorrect number of parameters", \
      TCL_STATIC);                                                \
    return TCL_ERROR;                                             \
  }                                                               \
}

Definition at line 45 of file TclGraphics.C.

Referenced by tcl_graphics_color, tcl_graphics_material, tcl_graphics_materials, tcl_graphics_pickpoint, tcl_graphics_point, tcl_graphics_triangle, tcl_graphics_tricolor, and tcl_graphics_trinorm.


Function Documentation

int graphics_tcl ClientData    cd,
Tcl_Interp *    interp,
int    argc,
const char *    argv[]
 

Definition at line 918 of file TclGraphics.C.

References BaseMolecule::id, VMDApp::moleculeList, tcl_graphics, and MoleculeList::top.

int tcl_graphics VMDApp   app,
int    molid,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 820 of file TclGraphics.C.

References MoleculeGraphics::element_id, VMDApp::materialList, MoleculeList::mol_from_id, DrawMolecule::moleculeGraphics, VMDApp::moleculeList, NULL, num, MoleculeGraphics::num_elements, tcl_graphics_color, tcl_graphics_cone, tcl_graphics_cylinder, tcl_graphics_delete, tcl_graphics_exists, tcl_graphics_info, tcl_graphics_line, tcl_graphics_material, tcl_graphics_materials, tcl_graphics_pickpoint, tcl_graphics_point, tcl_graphics_replace, tcl_graphics_sphere, tcl_graphics_spheretube, tcl_graphics_text, tcl_graphics_triangle, tcl_graphics_tricolor, and tcl_graphics_trinorm.

Referenced by graphics_tcl.

int tcl_graphics_color VMDApp   app,
MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 335 of file TclGraphics.C.

References VMDApp::color_index, MAXCOLORS, MUST_HAVE, NULL, and MoleculeGraphics::use_color.

Referenced by tcl_graphics.

int tcl_graphics_cone MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 372 of file TclGraphics.C.

References MoleculeGraphics::add_cone, AT_LEAST, NULL, and tcl_get_vector.

Referenced by tcl_graphics.

int tcl_graphics_cylinder MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 137 of file TclGraphics.C.

References MoleculeGraphics::add_cylinder, AT_LEAST, NULL, and tcl_get_vector.

Referenced by tcl_graphics.

int tcl_graphics_delete MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 748 of file TclGraphics.C.

References MoleculeGraphics::delete_all, and MoleculeGraphics::delete_id.

Referenced by tcl_graphics.

int tcl_graphics_exists MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 782 of file TclGraphics.C.

References MoleculeGraphics::index_id.

Referenced by tcl_graphics.

int tcl_graphics_info MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 800 of file TclGraphics.C.

References MoleculeGraphics::info_id, and NULL.

Referenced by tcl_graphics.

int tcl_graphics_line MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 239 of file TclGraphics.C.

References MoleculeGraphics::add_line, AT_LEAST, NULL, and tcl_get_vector.

Referenced by tcl_graphics.

int tcl_graphics_material MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp,
MaterialList   mlist
[static]
 

Definition at line 313 of file TclGraphics.C.

References mat, MaterialList::material, MaterialList::material_index, MUST_HAVE, and MoleculeGraphics::use_material.

Referenced by tcl_graphics.

int tcl_graphics_materials MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 295 of file TclGraphics.C.

References MUST_HAVE, and MoleculeGraphics::use_materials.

Referenced by tcl_graphics.

int tcl_graphics_pickpoint MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 220 of file TclGraphics.C.

References MoleculeGraphics::add_pickpoint, MUST_HAVE, and tcl_get_vector.

Referenced by tcl_graphics.

int tcl_graphics_point MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 202 of file TclGraphics.C.

References MoleculeGraphics::add_point, MUST_HAVE, and tcl_get_vector.

Referenced by tcl_graphics.

int tcl_graphics_replace MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 767 of file TclGraphics.C.

References MoleculeGraphics::replace_id.

Referenced by tcl_graphics.

int tcl_graphics_sphere MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 440 of file TclGraphics.C.

References MoleculeGraphics::add_sphere, AT_LEAST, NULL, and tcl_get_vector.

Referenced by tcl_graphics.

int tcl_graphics_spheretube MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 552 of file TclGraphics.C.

References MoleculeGraphics::add_spheretube, AT_LEAST, MAXCOLORS, NULL, tcl_get_array, tcl_get_intarray, and tcl_get_vecarray.

Referenced by tcl_graphics.

int tcl_graphics_text MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 496 of file TclGraphics.C.

References MoleculeGraphics::add_text, AT_LEAST, NULL, size, string, and tcl_get_vector.

Referenced by tcl_graphics.

int tcl_graphics_triangle MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 56 of file TclGraphics.C.

References MoleculeGraphics::add_triangle, MUST_HAVE, and tcl_get_vector.

Referenced by tcl_graphics.

int tcl_graphics_tricolor MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 104 of file TclGraphics.C.

References MoleculeGraphics::add_tricolor, MUST_HAVE, and tcl_get_vector.

Referenced by tcl_graphics.

int tcl_graphics_trinorm MoleculeGraphics   gmol,
int    argc,
const char *    argv[],
Tcl_Interp *    interp
[static]
 

Definition at line 77 of file TclGraphics.C.

References MoleculeGraphics::add_trinorm, MUST_HAVE, and tcl_get_vector.

Referenced by tcl_graphics.


Generated on Sat Apr 20 02:44:20 2024 for VMD (current) by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002