AronaCore/core/rhi/texture.h

23 lines
502 B
C++

#pragma once
#include "imgui.h"
#include <string>
#include "render_resource.h"
class texture : public render_resource {
public:
texture(): width_(0), height_(0) {
}
virtual bool init_data(const unsigned char *data, int width, int height) = 0;
[[nodiscard]] virtual bool is_valid() const = 0;
[[nodiscard]] int get_width() const override { return width_; }
[[nodiscard]] int get_height() const override { return height_; }
protected:
int width_;
int height_;
};