CMU462 Library Documentation  1.0
15-462/15-662: Computer Graphics (Fall 2015)
console.h
1 #ifndef CMU462_CONSOLE_H
2 #define CMU462_CONSOLE_H
3 
4 #include <ostream>
5 
6 #define ANSI_RESET "\x1b[0m"
7 #define ANSI_R "\x1b[31m"
8 #define ANSI_G "\x1b[32m"
9 #define ANSI_B "\x1b[34m"
10 #define ANSI_C "\x1b[36m"
11 #define ANSI_M "\x1b[35m"
12 #define ANSI_Y "\x1b[33m"
13 
14 #define out_msg(s) std::cout << ANSI_B << "[CMU462] " << ANSI_RESET << s << std::endl << std::flush
15 #define out_wrn(s) std::cout << ANSI_Y << "[CMU462] " << ANSI_RESET << s << std::endl << std::flush
16 #define out_err(s) std::cout << ANSI_R << "[CMU462] " << ANSI_RESET << s << std::endl << std::flush
17 
18 #endif // CMU462_CONSOLE_H