add more build controls
[goodguy/history.git] / cinelerra-5.1 / guicast / bctexture.C
index ef77f8ea35422cf07a5e7e06586518f89e098d34..d9bc92d94869d67e314cc907d0495f3b8d16be27 100644 (file)
@@ -231,6 +231,7 @@ void write_ppm(uint8_t *tp, int w, int h, const char *fmt, ...);
 
 void BC_Texture::write_tex(const char *fn)
 {
+#ifdef HAVE_GL
        int prev_id = -1;
        glGetIntegerv(GL_ACTIVE_TEXTURE, &prev_id);
        glActiveTexture(this->texture_id);
@@ -239,6 +240,7 @@ void BC_Texture::write_tex(const char *fn)
        glGetTexImage(GL_TEXTURE_2D, 0, GL_RGB, GL_UNSIGNED_BYTE, img);
        write_ppm(img, w, h, "%s", fn);
        glActiveTexture(prev_id);
+#endif
 }