Tscope source
We added this page to the site as a reference manual only tells you what a function
should do. In case of doubt, the source will tell you what a function actually
does.
The Tscope source is split into several files. All files can be viewed in highlighted html
on this page, and are available as ASCII text files in the src and include directories of the
Tscope distribution.
- screen.h and
screen.c contain the
functions that control the graphics mode, i.e. the refreshrate, color depth, resolution,
double buffering etc.
- graphics.h and
graphics.c contain the
functions that control some graphics parameters, like the drawing color, fill mode, font,
etc.
- coordinates.h
and coordinates.c define
the different coordinate systems supported by Tscope.
- textio.h and
textio.c contain functions
for putting formatted text on the screen and reading formatted text from the keyboard.
- draw.h and draw.c contain functions for drawing
simple shapes like lines, circles etc.
- timer.h and
timer.c provide timer
functions. They do not rely on other Tscope functions, and can be used in combination with
any randomization or graphics rendering functions.
- random.h and
random.c provide
randomization functions. They do not rely on other Tscope functions, and can be used in
combination with any timing or graphics rendering functions.
- mouse.h and
mouse.c provide mouse
support.
- blit.h and blit.c contain functions for making,
reading and manipulating bitmaps.
- sound.h and
sound.c contain functions
for playing .wav files, and generating simple sounds.
- sound2.h and
sound2.c define the new
(experimental) sound API.
- tscope.h is the
main header file. All it does is including the libraries tscope is dependent on, and
including the header files of the different modules.
- internal.h and
internal.c define some
internal variables and functions. Normally, they are not needed by or visible to the user.
Including
include/internal.h
in your program will make them visible to you. You
only need these functions and variables if you want to write a Tscope add-on.