Resources::Resources():
default_tex_filter(Texture::can_generate_mipmap() ? LINEAR_MIPMAP_LINEAR : LINEAR),
+ default_tex_anisotropy(1.0f),
srgb_conversion(false),
resource_manager(0)
{
default_tex_filter = tf;
}
+void Resources::set_default_texture_anisotropy(float a)
+{
+ default_tex_anisotropy = a;
+}
+
void Resources::set_srgb_conversion(bool c)
{
srgb_conversion = c;
else
tex->set_mag_filter(default_tex_filter);
tex->set_min_filter(default_tex_filter);
+ tex->set_max_anisotropy(default_tex_anisotropy);
if(resource_manager)
resource_manager->set_resource_location(*tex, *this, name);
{
private:
TextureFilter default_tex_filter;
+ float default_tex_anisotropy;
bool srgb_conversion;
ResourceManager *resource_manager;
static const DataFile::CollectionSource &get_builtins();
void set_default_texture_filter(TextureFilter);
+ void set_default_texture_anisotropy(float);
/** Enables or disables sRGB conversion. If enabled, textures and material
colors are converted from sRGB to linear color space when loaded. */