14 #include "../include/tscope5/display.h"
15 #include "../include/tscope5/display_internal.h"
16 #include "../include/tscope5/system_internal.h"
32 ts5_log(TS5_LOGLEVEL_6,
"%s: ts5_check_display\n", calling_function);
53 ts5_log(TS5_LOGLEVEL_6,
"%s: ts5_check_display2\n", calling_function);
55 if (display < 0 || display > _ts5_status.num_displays) {
56 ts5_fatal(
"%s: display index not valid\n", calling_function);
78 ts5_log(TS5_LOGLEVEL_1,
"Uninstalling Tscope5 displays\n");
84 for (i = 0; i < _ts5_status.num_displays; i++) {
86 if (_ts5_status.display[i].display_mode == TS5_FULLSCREEN_WINDOW) {
87 al_toggle_display_flag(_ts5_data.display[i],
88 ALLEGRO_FULLSCREEN_WINDOW, 0);
91 al_destroy_display(_ts5_data.display[i]);
92 al_destroy_bitmap(_ts5_data.display_buffer[i]);
93 al_destroy_bitmap(_ts5_data.display_backup[i]);
96 al_free(_ts5_data.display);
97 al_free(_ts5_data.display_buffer);
98 al_free(_ts5_data.display_backup);
99 al_free(_ts5_status.display);
101 _ts5_status.display = NULL;
102 _ts5_data.display = NULL;
103 _ts5_data.display_buffer = NULL;
104 _ts5_data.display_backup = NULL;
105 _ts5_data.target = NULL;
109 _ts5_status.num_displays = 0;
110 _ts5_status.active_display = -1;
int _ts5_is_tscope5_installed
Is Tscope5 installed?
void ts5_check_display(char *calling_function)
Do some checks at the start of each display function.
void ts5_check_display2(char *calling_function, const int display)
Do some checks at the start of each display function.
int _ts5_is_display_installed
Is the display subsystem installed?w.
void ts5_uninstall_displays()
Close all open displays.
void ts5_log(const unsigned int level, const char *format,...)
Send info to a logging window.
void ts5_install_tscope5(char *calling_function)
Install Tscope5.
void ts5_fatal(const char *format,...)
Exit safely with an error message.