From c45ffc2ca9f3b96f1eb04093cf75837da8e6ee4d Mon Sep 17 00:00:00 2001 From: Juan Linietsky Date: Fri, 1 May 2015 12:16:51 -0300 Subject: [PATCH] -fixed old condition in TextureFrame that caused bugs in materials, closes #1742 --- drivers/gles2/rasterizer_gles2.cpp | 1 - scene/gui/texture_frame.cpp | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/gles2/rasterizer_gles2.cpp b/drivers/gles2/rasterizer_gles2.cpp index feff49c1def..4acac957c84 100644 --- a/drivers/gles2/rasterizer_gles2.cpp +++ b/drivers/gles2/rasterizer_gles2.cpp @@ -1263,7 +1263,6 @@ void RasterizerGLES2::texture_set_flags(RID p_texture,uint32_t p_flags) { p_flags&=VS::TEXTURE_FLAG_FILTER;//can change only filter } - glActiveTexture(GL_TEXTURE0); glBindTexture(texture->target, texture->tex_id); uint32_t cube = texture->flags & VS::TEXTURE_FLAG_CUBEMAP; diff --git a/scene/gui/texture_frame.cpp b/scene/gui/texture_frame.cpp index 73081f9d5bf..931fb1cb1a2 100644 --- a/scene/gui/texture_frame.cpp +++ b/scene/gui/texture_frame.cpp @@ -88,8 +88,8 @@ void TextureFrame::set_texture(const Ref& p_tex) { texture=p_tex; update(); - if (texture.is_valid()) - texture->set_flags(texture->get_flags()&(~Texture::FLAG_REPEAT)); //remove repeat from texture, it looks bad in sprites + //if (texture.is_valid()) + // texture->set_flags(texture->get_flags()&(~Texture::FLAG_REPEAT)); //remove repeat from texture, it looks bad in sprites minimum_size_changed(); }