Changeset 1237 for trunk/packages/vizservers
- Timestamp:
- Nov 25, 2008, 10:01:15 AM (16 years ago)
- Location:
- trunk/packages/vizservers/nanovis
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/packages/vizservers/nanovis/Command.cpp
r1236 r1237 727 727 Tcl_Obj *const *objv) 728 728 { 729 float x, y;730 if (( GetFloatFromObj(interp, objv[2], &x) != TCL_OK) ||731 ( GetFloatFromObj(interp, objv[3], &y) != TCL_OK)) {729 int x, y; 730 if ((Tcl_GetIntFromObj(interp, objv[2], &x) != TCL_OK) || 731 (Tcl_GetIntFromObj(interp, objv[3], &y) != TCL_OK)) { 732 732 return TCL_ERROR; 733 733 } -
trunk/packages/vizservers/nanovis/nanovis.cpp
r1236 r1237 444 444 445 445 static void 446 NanoVis::pan(int dx, int dy)446 NanoVis::pan(int x, int y) 447 447 { 448 448 float x, y; … … 456 456 fprintf(stderr, "x=%f, y=%f\n", x, y); 457 457 458 cam->x( cam->x()+ x);459 cam->y( cam->y()+ y);458 cam->x(def_eye_x + x); 459 cam->y(def_eye_y + y); 460 460 fprintf(stderr, "set eye to %f %f\n", cam->x(), cam->y()); 461 461 462 cam->xAim( cam->xAim()+ x);463 cam->yAim( cam->yAim()+ y);462 cam->xAim(def_target_x + x); 463 cam->yAim(def_target_y + y); 464 464 fprintf(stderr, "set aim to %f %f\n", cam->xAim(), cam->yAim()); 465 465 }
Note: See TracChangeset
for help on using the changeset viewer.