source: nanovis/branches/1.2/Command.h @ 6632

Last change on this file since 6632 was 6620, checked in by ldelgass, 7 years ago

remove old read loop in nanovis

  • Property svn:eol-style set to native
File size: 1.6 KB
Line 
1/* -*- mode: c++; c-basic-offset: 4; indent-tabs-mode: nil -*- */
2/*
3 * Copyright (c) 2004-2013  HUBzero Foundation, LLC
4 *
5 * Authors:
6 *   Wei Qiao <qiaow@purdue.edu>
7 *   Insoo Woo <iwoo@purdue.edu>
8 *   George A. Howlett <gah@purdue.edu>
9 *   Leif Delgass <ldelgass@purdue.edu>
10 */
11#ifndef NV_COMMAND_H
12#define NV_COMMAND_H
13
14#include <unistd.h>
15#include <sys/time.h>
16
17#include <tcl.h>
18
19#include "ResponseQueue.h"
20
21namespace Rappture {
22class Buffer;
23}
24
25namespace nv {
26
27class ReadBuffer;
28class Volume;
29
30#ifdef USE_THREADS
31extern void queueResponse(const void *bytes, size_t len,
32                          Response::AllocationType allocType,
33                          Response::ResponseType type = Response::DATA);
34#else
35extern ssize_t SocketWrite(const void *bytes, size_t len);
36#endif
37
38extern bool SocketRead(char *bytes, size_t len);
39
40extern int processCommands(Tcl_Interp *interp,
41                           ReadBuffer *inBufPtr,
42                           int fdOut,
43                           struct timeval *timeout);
44
45extern int handleError(Tcl_Interp *interp,
46                       int status,
47                       int fdOut);
48
49extern void initTcl(Tcl_Interp *interp, ClientData clientData);
50
51extern int GetAxisFromObj(Tcl_Interp *interp, Tcl_Obj *objPtr,
52                          int *axisVal);
53
54extern int GetBooleanFromObj(Tcl_Interp *interp, Tcl_Obj *objPtr,
55                             bool *boolVal);
56
57extern int GetDataStream(Tcl_Interp *interp, Rappture::Buffer &buf, int nBytes);
58
59extern int GetFloatFromObj(Tcl_Interp *interp, Tcl_Obj *objPtr,
60                           float *floatVal);
61
62}
63
64#endif
Note: See TracBrowser for help on using the repository browser.