TachyonUI
0.1.0
High-performance UI for building tools.
Toggle main menu visibility
Loading...
Searching...
No Matches
gui_image.h
Go to the documentation of this file.
1
#pragma once
2
3
#include <stdint.h>
4
5
namespace
tachyon
6
{
9
12
enum class
ImageFormat
13
{
14
UNDEFINED
,
15
R8
,
16
R8_SRGB
,
17
R8G8
,
18
R8G8_SRGB
,
19
R8G8B8
,
20
R8G8B8_SRGB
,
21
R8G8B8A8
,
22
R8G8B8A8_SRGB
23
};
24
26
enum class
Sampler
27
{
28
UNDEFINED
,
29
30
NearestRepeat
,
31
LinearRepeat
,
32
LinearClampToEdge
33
};
34
37
enum
ImageIndex
: uint32_t {
Invalid
= 0 };
38
40
class
Image
{};
41
43
class
ImageSet
44
{
45
public
:
46
virtual
~ImageSet
() {}
48
virtual
void
Clear
() = 0;
50
virtual
ImageIndex
Add
(
Image
* image) = 0;
52
virtual
void
Remove
(
ImageIndex
index) = 0;
53
};
54
55
}
tachyon::ImageSet
The images the shaders can sample, each at an ImageIndex. Implemented by the backend.
Definition
gui_image.h:44
tachyon::ImageSet::Remove
virtual void Remove(ImageIndex index)=0
Frees the index for reuse; the image itself stays.
tachyon::ImageSet::~ImageSet
virtual ~ImageSet()
Definition
gui_image.h:46
tachyon::ImageSet::Add
virtual ImageIndex Add(Image *image)=0
Adds an image (not owned) and returns its index.
tachyon::ImageSet::Clear
virtual void Clear()=0
Removes every image, freeing all indices.
tachyon::Image
An image made by GraphicsContext::CreateImage; the backend defines its contents.
Definition
gui_image.h:40
tachyon::Sampler
Sampler
How an image is filtered and addressed when sampled.
Definition
gui_image.h:27
tachyon::ImageFormat
ImageFormat
Pixel formats for GraphicsContext::CreateImage, 8 bits per channel.
Definition
gui_image.h:13
tachyon::ImageIndex
ImageIndex
Index of an image in the graphics context's image set, as the shaders sample it.
Definition
gui_image.h:37
tachyon::Sampler::NearestRepeat
@ NearestRepeat
Definition
gui_image.h:30
tachyon::Sampler::LinearClampToEdge
@ LinearClampToEdge
Definition
gui_image.h:32
tachyon::Sampler::LinearRepeat
@ LinearRepeat
Definition
gui_image.h:31
tachyon::ImageFormat::UNDEFINED
@ UNDEFINED
Definition
gui_image.h:14
tachyon::ImageFormat::R8G8B8
@ R8G8B8
Definition
gui_image.h:19
tachyon::ImageFormat::R8G8B8A8
@ R8G8B8A8
Definition
gui_image.h:21
tachyon::ImageFormat::R8G8B8A8_SRGB
@ R8G8B8A8_SRGB
Definition
gui_image.h:22
tachyon::ImageFormat::R8G8B8_SRGB
@ R8G8B8_SRGB
Definition
gui_image.h:20
tachyon::ImageFormat::R8G8_SRGB
@ R8G8_SRGB
Definition
gui_image.h:18
tachyon::ImageFormat::R8G8
@ R8G8
Definition
gui_image.h:17
tachyon::ImageFormat::R8_SRGB
@ R8_SRGB
Definition
gui_image.h:16
tachyon::ImageFormat::R8
@ R8
Definition
gui_image.h:15
tachyon::Invalid
@ Invalid
Definition
gui_image.h:37
tachyon
Definition
gui_logging.h:24
gui_core
graphics
gui_image.h
Generated by
1.18.0