MCPcopy Create free account
hub / github.com/NVIDIA/cuda-samples / checkStatus

Method checkStatus

Common/rendercheck_gles.h:978–1017  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

976 }
977
978 virtual bool checkStatus(const char *zfile, int line, bool silent) {
979 GLenum status;
980 status = (GLenum)glCheckFramebufferStatus(GL_FRAMEBUFFER);
981
982 if (status != GL_FRAMEBUFFER_COMPLETE) {
983 printf("<%s : %d> - this one ", zfile, line);
984 }
985
986 switch (status) {
987 case GL_FRAMEBUFFER_COMPLETE:
988 break;
989
990 case GL_FRAMEBUFFER_UNSUPPORTED:
991 if (!silent) {
992 printf("Unsupported framebuffer format\n");
993 }
994
995 return false;
996
997 case GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT:
998 if (!silent) {
999 printf("Framebuffer incomplete, missing attachment\n");
1000 }
1001
1002 return false;
1003
1004 case GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT:
1005 if (!silent) {
1006 printf("Framebuffer incomplete, duplicate attachment\n");
1007 }
1008
1009 return false;
1010
1011 default:
1012 assert(0);
1013 return false;
1014 }
1015
1016 return true;
1017 }
1018
1019 // bind to the FrameBuffer Object
1020 void bindRenderPath() { glBindFramebuffer(GL_FRAMEBUFFER, m_fboData.fb); }

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected