Update Ghoul repository to show milliseconds in log timestamps

Add log information to the SceneGraphnode to show initialization and OpenGL initialization of nodes
This commit is contained in:
Alexander Bock
2018-07-16 17:44:50 -04:00
parent 001935a139
commit 2751ee327c
3 changed files with 62 additions and 48 deletions

View File

@@ -207,7 +207,8 @@ SceneGraphNode::SceneGraphNode()
SceneGraphNode::~SceneGraphNode() {} // NOLINT
void SceneGraphNode::initialize() {
LDEBUG(fmt::format("Initialize: {}", identifier()));
LDEBUG(fmt::format("Initializing: {}", identifier()));
if (_renderable) {
_renderable->initialize();
}
@@ -222,17 +223,23 @@ void SceneGraphNode::initialize() {
_transform.scale->initialize();
}
_state = State::Initialized;
LDEBUG(fmt::format("Finished initializing: {}", identifier()));
}
void SceneGraphNode::initializeGL() {
LDEBUG(fmt::format("Initializing GL: {}", identifier()));
if (_renderable) {
_renderable->initializeGL();
}
_state = State::GLInitialized;
LDEBUG(fmt::format("Finished initializating GL: {}", identifier()));
}
void SceneGraphNode::deinitialize() {
LDEBUG(fmt::format("Deinitialize: {}", identifier()));
LDEBUG(fmt::format("Deinitializing: {}", identifier()));
setScene(nullptr);
@@ -241,12 +248,18 @@ void SceneGraphNode::deinitialize() {
}
clearChildren();
_parent = nullptr;
LDEBUG(fmt::format("Finished deinitializing: {}", identifier()));
}
void SceneGraphNode::deinitializeGL() {
LDEBUG(fmt::format("Deinitializing GL: {}", identifier()));
if (_renderable) {
_renderable->deinitializeGL();
}
LDEBUG(fmt::format("Finished deinitializing GL: {}", identifier()));
}
void SceneGraphNode::traversePreOrder(const std::function<void(SceneGraphNode*)>& fn) {

View File

@@ -28,51 +28,52 @@ function (set_openspace_compile_settings project)
if (MSVC)
target_compile_options(
${project}
PRIVATE
"/ZI" # Edit and continue support
"/MP" # Multi-threading support
"/W4" # Highest warning level
"/w44062" # enumerator 'identifier' in a switch of enum 'enumeration' is not handled
"/wd4127" # conditional expression is constant
"/wd4201" # nonstandard extension used : nameless struct/union
"/w44255" # 'function': no function prototype given: converting '()' to '(void)'
"/w44263" # 'function': member function does not override any base class virtual member function
"/w44264" # 'virtual_function': no override available for virtual member function from base 'class'; function is hidden
"/w44265" # 'class': class has virtual functions, but destructor is not virtual
"/w44266" # 'function': no override available for virtual member function from base 'type'; function is hidden
"/w44289" # nonstandard extension used : 'var' : loop control variable declared in the for-loop is used outside the for-loop scope
"/w44296" # 'operator': expression is always false
"/w44311" # 'variable' : pointer truncation from 'type' to 'type'
"/w44339" # 'type' : use of undefined type detected in CLR meta-data - use of this type may lead to a runtime exception
"/w44342" # behavior change: 'function' called, but a member operator was called in previous versions
"/w44350" # behavior change: 'member1' called instead of 'member2'
"/w44431" # missing type specifier - int assumed. Note: C no longer supports default-int
"/w44471" # a forward declaration of an unscoped enumeration must have an underlying type (int assumed)
"/wd4505" # unreferenced local function has been removed
"/w44545" # expression before comma evaluates to a function which is missing an argument list
"/w44546" # function call before comma missing argument list
"/w44547" # 'operator': operator before comma has no effect; expected operator with side-effect
"/w44548" # expression before comma has no effect; expected expression with side-effect
"/w44549" # 'operator': operator before comma has no effect; did you intend 'operator'?
"/w44555" # expression has no effect; expected expression with side-effect
# This is disabled until GLM is updated to version 0.9.9 that removes occurrance of this warning
# "/w44574" # 'identifier' is defined to be '0': did you mean to use '#if identifier'?
"/w44608" # 'symbol1' has already been initialized by another union member in the initializer list, 'symbol2'
"/w44619" # #pragma warning: there is no warning number 'number'
"/w44628" # digraphs not supported with -Ze. Character sequence 'digraph' not interpreted as alternate token for 'char'
"/w44640" # 'instance': construction of local static object is not thread-safe
"/w44905" # wide string literal cast to 'LPSTR'
"/w44906" # string literal cast to 'LPWSTR'
"/w44946" # reinterpret_cast used between related classes: 'class1' and 'class2'
"/w44986" # 'symbol': exception specification does not match previous declaration
"/w44988" # 'symbol': variable declared outside class/function scope
"/std:c++latest"
"/permissive-"
"/Zc:twoPhase-" # Used to prevent C:\Program Files (x86)\Windows Kits\8.1\Include\um\combaseapi.h(229): error C2187: syntax error: 'identifier' was unexpected here
# This is a bug in Visual Studio 15.3 and can be removed with the next version:
# https://developercommunity.visualstudio.com/content/problem/94419/vs-2017-153-with-permissive-shows-error-c2187-in-c.html
"/Zc:strictStrings-" # Windows header don't adhere to this
${project}
PRIVATE
"/ZI" # Edit and continue support
"/MP" # Multi-threading support
"/W4" # Highest warning level
"/w44062" # enumerator 'identifier' in a switch of enum 'enumeration' is not handled
"/wd4127" # conditional expression is constant
"/wd4201" # nonstandard extension used : nameless struct/union
"/w44255" # 'function': no function prototype given: converting '()' to '(void)'
"/w44263" # 'function': member function does not override any base class virtual member function
"/w44264" # 'virtual_function': no override available for virtual member function from base 'class'; function is hidden
"/w44265" # 'class': class has virtual functions, but destructor is not virtual
"/w44266" # 'function': no override available for virtual member function from base 'type'; function is hidden
"/w44289" # nonstandard extension used : 'var' : loop control variable declared in the for-loop is used outside the for-loop scope
"/w44296" # 'operator': expression is always false
"/w44311" # 'variable' : pointer truncation from 'type' to 'type'
"/w44339" # 'type' : use of undefined type detected in CLR meta-data - use of this type may lead to a runtime exception
"/w44342" # behavior change: 'function' called, but a member operator was called in previous versions
"/w44350" # behavior change: 'member1' called instead of 'member2'
"/w44431" # missing type specifier - int assumed. Note: C no longer supports default-int
"/w44471" # a forward declaration of an unscoped enumeration must have an underlying type (int assumed)
"/wd4505" # unreferenced local function has been removed
"/w44545" # expression before comma evaluates to a function which is missing an argument list
"/w44546" # function call before comma missing argument list
"/w44547" # 'operator': operator before comma has no effect; expected operator with side-effect
"/w44548" # expression before comma has no effect; expected expression with side-effect
"/w44549" # 'operator': operator before comma has no effect; did you intend 'operator'?
"/w44555" # expression has no effect; expected expression with side-effect
# This is disabled until GLM is updated to version 0.9.9 that removes occurrance of this warning
# "/w44574" # 'identifier' is defined to be '0': did you mean to use '#if identifier'?
"/w44608" # 'symbol1' has already been initialized by another union member in the initializer list, 'symbol2'
"/w44619" # #pragma warning: there is no warning number 'number'
"/w44628" # digraphs not supported with -Ze. Character sequence 'digraph' not interpreted as alternate token for 'char'
"/w44640" # 'instance': construction of local static object is not thread-safe
"/w44905" # wide string literal cast to 'LPSTR'
"/w44906" # string literal cast to 'LPWSTR'
"/w44946" # reinterpret_cast used between related classes: 'class1' and 'class2'
"/w44986" # 'symbol': exception specification does not match previous declaration
"/w44988" # 'symbol': variable declared outside class/function scope
"/std:c++latest"
"/permissive-"
"/Zc:twoPhase-" # Used to prevent C:\Program Files (x86)\Windows Kits\8.1\Include\um\combaseapi.h(229): error C2187: syntax error: 'identifier' was unexpected here
# This is a bug in Visual Studio 15.3 and can be removed with the next version:
# https://developercommunity.visualstudio.com/content/problem/94419/vs-2017-153-with-permissive-shows-error-c2187-in-c.html
"/Zc:strictStrings-" # Windows header don't adhere to this
"/Zc:__cplusplus" # Correctly set the __cplusplus macro
)
if (OPENSPACE_WARNINGS_AS_ERRORS)
target_compile_options(${project} PRIVATE "/WX")