glDeleteTextures(1, &id);
}
+DataType Texture::get_alloc_type(PixelFormat fmt)
+{
+ return (fmt==DEPTH_COMPONENT ? UNSIGNED_SHORT : UNSIGNED_BYTE);
+}
+
void Texture::update_parameter(int mask) const
{
if(TexUnit::current().get_texture()!=this)
void Texture::set_compare_enabled(bool c)
{
- static Require _req(ARB_shadow);
+ if(c)
+ static Require _req(ARB_shadow);
compare = c;
update_parameter(COMPARE);
}