()
| 2070 | |
| 2071 | |
| 2072 | protected int validateFramebuffer() { |
| 2073 | int status = checkFramebufferStatus(FRAMEBUFFER); |
| 2074 | if (status == FRAMEBUFFER_COMPLETE) { |
| 2075 | return 0; |
| 2076 | } else if (status == FRAMEBUFFER_UNDEFINED) { |
| 2077 | System.err.println(String.format(FRAMEBUFFER_ERROR, |
| 2078 | "framebuffer undefined")); |
| 2079 | } else if (status == FRAMEBUFFER_INCOMPLETE_ATTACHMENT) { |
| 2080 | System.err.println(String.format(FRAMEBUFFER_ERROR, |
| 2081 | "incomplete attachment")); |
| 2082 | } else if (status == FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT) { |
| 2083 | System.err.println(String.format(FRAMEBUFFER_ERROR, |
| 2084 | "incomplete missing attachment")); |
| 2085 | } else if (status == FRAMEBUFFER_INCOMPLETE_DIMENSIONS) { |
| 2086 | System.err.println(String.format(FRAMEBUFFER_ERROR, |
| 2087 | "incomplete dimensions")); |
| 2088 | } else if (status == FRAMEBUFFER_INCOMPLETE_FORMATS) { |
| 2089 | System.err.println(String.format(FRAMEBUFFER_ERROR, |
| 2090 | "incomplete formats")); |
| 2091 | } else if (status == FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER) { |
| 2092 | System.err.println(String.format(FRAMEBUFFER_ERROR, |
| 2093 | "incomplete draw buffer")); |
| 2094 | } else if (status == FRAMEBUFFER_INCOMPLETE_READ_BUFFER) { |
| 2095 | System.err.println(String.format(FRAMEBUFFER_ERROR, |
| 2096 | "incomplete read buffer")); |
| 2097 | } else if (status == FRAMEBUFFER_UNSUPPORTED) { |
| 2098 | System.err.println(String.format(FRAMEBUFFER_ERROR, |
| 2099 | "framebuffer unsupported")); |
| 2100 | } else if (status == FRAMEBUFFER_INCOMPLETE_MULTISAMPLE) { |
| 2101 | System.err.println(String.format(FRAMEBUFFER_ERROR, |
| 2102 | "incomplete multisample buffer")); |
| 2103 | } else if (status == FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS) { |
| 2104 | System.err.println(String.format(FRAMEBUFFER_ERROR, |
| 2105 | "incomplete layer targets")); |
| 2106 | } else { |
| 2107 | System.err.println(String.format(FRAMEBUFFER_ERROR, |
| 2108 | "unknown error " + status)); |
| 2109 | } |
| 2110 | return status; |
| 2111 | } |
| 2112 | |
| 2113 | protected boolean isES() { |
| 2114 | return getString(VERSION).trim().toLowerCase().contains("opengl es"); |
no test coverage detected