| 31 | } |
| 32 | |
| 33 | static GLuint create_texture() |
| 34 | { |
| 35 | GLuint texture; |
| 36 | glGenTextures(1, &texture); |
| 37 | glBindTexture(GL_TEXTURE_2D, texture); |
| 38 | glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR); |
| 39 | glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR); |
| 40 | glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); |
| 41 | glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); |
| 42 | return texture; |
| 43 | } |
| 44 | |
| 45 | void init_webgl(int width, int height) |
| 46 | { |
no test coverage detected