Merge pull request #7683 from zzmp/clean/texture

Remove unused static method gpu::Texture
This commit is contained in:
Seth Alves 2016-04-18 10:25:53 -07:00
commit dea748d132
2 changed files with 1 additions and 10 deletions

View file

@ -221,13 +221,6 @@ Texture* Texture::create(Type type, const Element& texelFormat, uint16 width, ui
return tex;
}
Texture* Texture::createFromStorage(Storage* storage) {
Texture* tex = new Texture();
tex->_storage.reset(storage);
storage->assignTexture(tex);
return tex;
}
Texture::Texture():
Resource()
{

View file

@ -260,7 +260,7 @@ public:
Stamp bumpStamp() { return ++_stamp; }
protected:
Stamp _stamp = 0;
Texture* _texture = nullptr;
Texture* _texture = nullptr; // Points to the parent texture (not owned)
Texture::Type _type = Texture::TEX_2D; // The type of texture is needed to know the number of faces to expect
std::vector<std::vector<PixelsPointer>> _mips; // an array of mips, each mip is an array of faces
@ -280,8 +280,6 @@ public:
static Texture* create3D(const Element& texelFormat, uint16 width, uint16 height, uint16 depth, const Sampler& sampler = Sampler());
static Texture* createCube(const Element& texelFormat, uint16 width, const Sampler& sampler = Sampler());
static Texture* createFromStorage(Storage* storage);
Texture();
Texture(const Texture& buf); // deep copy of the sysmem texture
Texture& operator=(const Texture& buf); // deep copy of the sysmem texture