| 37 | std::mutex g_mutex; |
| 38 | |
| 39 | void manualErrorCheckAfter(const glbinding::AbstractFunction & function) |
| 40 | { |
| 41 | globjects::Error error = globjects::Error::get(); |
| 42 | |
| 43 | if (!error) |
| 44 | return; |
| 45 | |
| 46 | if (!globjects::Registry::current().isInitialized()) |
| 47 | { |
| 48 | globjects::debug() << "Error during initialization: " << error.name(); |
| 49 | return; |
| 50 | } |
| 51 | |
| 52 | if (!globjects::DebugMessage::isFallbackImplementation()) |
| 53 | return; |
| 54 | |
| 55 | std::stringstream stream; |
| 56 | stream << function.name() << " generated " << error.name(); |
| 57 | |
| 58 | globjects::DebugMessage::insertMessage(GL_DEBUG_SOURCE_API_ARB, GL_DEBUG_TYPE_ERROR_ARB, static_cast<unsigned int>(error.code()), GL_DEBUG_SEVERITY_HIGH_ARB, stream.str()); |
| 59 | } |
| 60 | |
| 61 | void initializeCallbacks() |
| 62 | { |
no test coverage detected