MCPcopy Create free account
hub / github.com/OpenSees/OpenSees / TclFeViewer_setVRP

Function TclFeViewer_setVRP

SRC/tcl/TclFeViewer.cpp:558–594  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

556
557
558int
559TclFeViewer_setVRP(ClientData clientData, Tcl_Interp *interp, int argc,
560 TCL_Char **argv)
561{
562#ifdef _NOGRAPHICS
563 // if no graphics .. just return 0
564 return TCL_OK;
565#else
566 // check destructor has not been called
567 if (theTclFeViewer == 0)
568 return TCL_OK;
569
570 // ensure corrcet num arguments
571 if (argc < 4) {
572 opserr << "WARNING args incorrect - vrp xloc yloc zloc \n";
573 return TCL_ERROR;
574 }
575
576 // get the xLoc, yLoc and zLoc
577 double xLoc, yLoc, zLoc;
578 if (Tcl_GetDouble(interp, argv[1], &xLoc) != TCL_OK) {
579 opserr << "WARNING invalid x_loc - vrp x_loc y_loc z_loc\n";
580 return TCL_ERROR;
581 }
582 if (Tcl_GetDouble(interp, argv[2], &yLoc) != TCL_OK) {
583 opserr << "WARNING invalid y_loc - vrp x_loc y_loc z_loc\n";
584 return TCL_ERROR;
585 }
586 if (Tcl_GetDouble(interp, argv[3], &zLoc) != TCL_OK) {
587 opserr << "WARNING invalid z_loc - vrp x_loc y_loc z_loc\n";
588 return TCL_ERROR;
589 }
590
591 theTclFeViewer->setVRP(float(xLoc),float(yLoc),float(zLoc));
592 return TCL_OK;
593#endif
594}
595
596int
597TclFeViewer_setVPN(ClientData clientData, Tcl_Interp *interp, int argc,

Callers

nothing calls this directly

Calls 1

setVRPMethod · 0.45

Tested by

no test coverage detected