/* This file is term3d.h. It can be #include'd in either C or C++. */ #ifndef TERM3DH #define TERM3DH /* These two functions must be called in pairs. */ void term3d_construct(const char *ip, unsigned short port); void term3d_destruct(void); /* Legal x values go from 0 to term3d_xmax() - 1 inclusive. Legal y values go from 0 to term3d_ymax() - 1 inclusive. Legal z values go from 0 to term3d_zmax() - 1 inclusive. */ unsigned term3d_xmax(void); /* number of columns */ unsigned term3d_ymax(void); /* number of rows */ unsigned term3d_zmax(void); /* number of planes */ /* Display a character or string on the screen. */ void term3d_put (unsigned x, unsigned y, unsigned z, char c); void term3d_puts(unsigned x, unsigned y, unsigned z, const char *s); /* Return the character at the given position on the screen. */ char term3d_get(unsigned x, unsigned y, unsigned z); /* Return the key the user pressed. If no key was pressed, return '\0' immediately. */ char term3d_key(void); void term3d_wait(int milliseconds); /* 1000 milliseconds == 1 second */ void term3d_beep(void); #endif