@@ -27,14 +27,15 @@ class Window {
27
27
* @param height The height of the window.
28
28
* @param title The desired title of the window.
29
29
* @param flags The ConfigFlags to set prior to initializing the window. See SetConfigFlags for more details.
30
+ * @param logLevel The the current threshold (minimum) log level
30
31
*
31
32
* @see ::SetConfigFlags()
32
33
* @see ConfigFlags
33
34
*
34
35
* @throws raylib::RaylibException Thrown if the window failed to initiate.
35
36
*/
36
- Window (int width, int height, const std::string& title = " raylib" , unsigned int flags = 0 ) {
37
- Init (width, height, title, flags);
37
+ Window (int width, int height, const std::string& title = " raylib" , unsigned int flags = 0 , TraceLogLevel logLevel = LOG_ALL ) {
38
+ Init (width, height, title, flags, logLevel );
38
39
}
39
40
40
41
/* *
@@ -55,10 +56,11 @@ class Window {
55
56
*
56
57
* @throws raylib::RaylibException Thrown if the window failed to initiate.
57
58
*/
58
- static void Init (int width = 800 , int height = 450 , const std::string& title = " raylib" , unsigned int flags = 0 ) {
59
+ static void Init (int width = 800 , int height = 450 , const std::string& title = " raylib" , unsigned int flags = 0 , TraceLogLevel logLevel = LOG_ALL ) {
59
60
if (flags != 0 ) {
60
61
::SetConfigFlags (flags);
61
62
}
63
+ ::SetTraceLogLevel (logLevel);
62
64
::InitWindow (width, height, title.c_str());
63
65
if (!::IsWindowReady ()) {
64
66
throw RaylibException (" Failed to create Window" );
0 commit comments