| 344 | } |
| 345 | |
| 346 | void Framebuffer::printStatus(bool onlyErrors) const |
| 347 | { |
| 348 | GLenum status = checkStatus(); |
| 349 | |
| 350 | if (onlyErrors && status == GL_FRAMEBUFFER_COMPLETE) return; |
| 351 | |
| 352 | if (status == GL_FRAMEBUFFER_COMPLETE) |
| 353 | { |
| 354 | info() << glbinding::Meta::getString(GL_FRAMEBUFFER_COMPLETE); |
| 355 | } |
| 356 | else |
| 357 | { |
| 358 | std::stringstream ss; |
| 359 | ss.flags(std::ios::hex | std::ios::showbase); |
| 360 | ss << static_cast<unsigned int>(status); |
| 361 | |
| 362 | critical() << glbinding::Meta::getString(status) << " (" << ss.str() << ")"; |
| 363 | } |
| 364 | } |
| 365 | |
| 366 | void Framebuffer::addAttachment(FramebufferAttachment * attachment) |
| 367 | { |