Terminal emulator object. This object is responsible for the creation and management of Halt objects that in turn create and manage OpenGL resources directly.
More...
#include <Terminal.h>
List of all members.
Public Member Functions |
| HALT_API | Terminal (int width, int height, int depth, const CharacterSize &cdim) |
| | Creates a terminal object.
|
| HALT_API void | Clear (int z) |
| | Clears an entire layer to null. This uses cell value 0.
|
| HALT_API void | Fill (int value, int color, int x1, int y1, int x2, int y2, int z) |
| | Writes a rectangle to the terminal buffer.
|
| HALT_API void | Put (int value, int color, int x, int y, int z) |
| | Writes a single character to the terminal buffer.
|
| HALT_API void | PutString (const char *value, int color, int x, int y, int z) |
| | Writes an entire string to the terminal buffer, starting at the point denoted by x and y.
|
|
HALT_API void | Draw () |
| | Renders the terminal buffer.
|
| HALT_API void | SetTexture (unsigned int handle) |
| | Sets the texture used to render cell values from.
|
| HALT_API void | SetShader (TerminalShader *shader) |
| | Sets the currently active terminal shader.
|
| HALT_API void | SetCharacterMap (CharacterMap *map) |
| | Sets the character map to use when translating cell values to texture coordinates.
|
| HALT_API int | GetWidth () const |
| | Gets the width of the terminal in cells.
|
| HALT_API int | GetHeight () const |
| | Gets the height of the terminal in cells.
|
| HALT_API int | GetDepth () const |
| | Gets the depth of the terminal in cells.
|
Detailed Description
Terminal emulator object. This object is responsible for the creation and management of Halt objects that in turn create and manage OpenGL resources directly.
Constructor & Destructor Documentation
Creates a terminal object.
- Parameters:
-
| width | Width of the terminal in cells. |
| height | Height of the terminal in cells. |
| depth | Depth of the terminal in cells. |
| cdim | Dimension of a cell in pixels. |
Member Function Documentation
Clears an entire layer to null. This uses cell value 0.
- Parameters:
-
Writes a rectangle to the terminal buffer.
- Parameters:
-
| value | Cell value to use in the fill process. |
| color | Color of the cell. |
| x1 | Top left corner of the fill area on the X-axis. |
| y1 | Top left corner of the fill area on the Y-axis. |
| x2 | Bottom right corner of the fill area on the X-axis. |
| y2 | Bottom right corner of the fill area on the Y-axis. |
| z | Layer to perform the fill operation on. |
Gets the depth of the terminal in cells.
- Returns:
- The depth of the terminal in cells.
Gets the height of the terminal in cells.
- Returns:
- The height of the terminal in cells.
Gets the width of the terminal in cells.
- Returns:
- The width of the terminal in cells.
Writes a single character to the terminal buffer.
- Parameters:
-
| value | Cell value to write. |
| color | Color of the cell. |
| x | Where to write the character on the X-axis. |
| y | Where to write the character on the Y-axis. |
| z | Which layer to write the character to. |
Writes an entire string to the terminal buffer, starting at the point denoted by x and y.
- Parameters:
-
| value | String to write. The cell values used are determined by the current character map. |
| color | Color of the cells to write. |
| x | Where to start writing the string on the X-axis. |
| y | Where to start writing the string on the Y-axis. |
| z | Which layer to write the character to. |
Sets the character map to use when translating cell values to texture coordinates.
- Parameters:
-
| map | Pointer to the character map to be used. |
- See also:
- CharacterMap
Sets the currently active terminal shader.
- Parameters:
-
| shader | Pointer to the shader to be used. To disable terminal shaders, use NULL or 0. |
- See also:
- TerminalShader
Sets the texture used to render cell values from.
- Parameters:
-
| handle | OpenGL texture handle of the texture to use. |
The documentation for this class was generated from the following files: