summaryrefslogtreecommitdiff
path: root/ui/svgIcon.h
blob: 94948bd84dff3a36ae62654eefd8f11c36bdea44 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#pragma once

#include "gfx/gl/glTexture.h"
#include <config/types.h>
#include <filesystem>
#include <imgui.h>
#include <lunasvg.h>

class SvgIcon {
public:
	SvgIcon(ImageDimensions, const std::filesystem::path &);

	ImTextureID operator*() const;

private:
	friend struct LoadFromFile; // Test case verifying size/content
	glTexture<GL_TEXTURE_2D> texture;
};