]> git.tdb.fi Git - libs/gl.git/blobdiff - source/core/texture2d.h
Use size_t to store sizes of buffers and such
[libs/gl.git] / source / core / texture2d.h
index 4f0bde26960c0db5f4dee5c9a0edd381f86e285e..c6654df69222859a0a284c468c9859a737127d8c 100644 (file)
@@ -32,12 +32,11 @@ public:
        };
 
 private:
-       unsigned width;
-       unsigned height;
-       unsigned levels;
+       unsigned width = 0;
+       unsigned height = 0;
+       unsigned levels = 0;
 
 public:
-       Texture2D();
        virtual ~Texture2D();
 
        /** Defines storage structure for the texture.  If lv is zero, the number
@@ -62,8 +61,6 @@ public:
        image must match the defined storage. */
        virtual void image(const Graphics::Image &, unsigned lv = 0);
 
-       using Texture::image;
-
        unsigned get_width() const { return width; }
        unsigned get_height() const { return height; }
 
@@ -73,7 +70,7 @@ private:
 
 public:
        virtual Resource::AsyncLoader *load(IO::Seekable &, const Resources * = 0);
-       virtual std::uint64_t get_data_size() const;
+       virtual std::size_t get_data_size() const;
        using Texture2DBackend::unload;
 };