wren
Vulkan-based game engine
Loading...
Searching...
No Matches
image.hpp
Go to the documentation of this file.
1
#pragma once
2
3
#include <vk_mem_alloc.h>
4
5
#include <vulkan/vulkan.hpp>
6
#include <
wren/math/vector.hpp
>
7
#include <
wren/utils/result.hpp
>
8
9
namespace
wren::vk
{
10
11
class
Image
{
12
public
:
13
static
auto
create
(const ::vk::Device& device,
const
VmaAllocator& allocator,
14
const ::vk::Format& format,
const
math::Vec2f
& size,
15
const ::vk::ImageUsageFlags& usage) ->
expected<Image>
;
16
17
[[nodiscard]]
auto
get
()
const
{
return
image_
; }
18
19
private
:
20
VmaAllocation
alloc_
{};
21
::vk::Image
image_
;
22
};
23
24
}
// namespace wren::vk
wren::vk::Image
Definition
image.hpp:11
wren::vk::Image::get
auto get() const
Definition
image.hpp:17
wren::vk::Image::alloc_
VmaAllocation alloc_
Definition
image.hpp:20
wren::vk::Image::image_
::vk::Image image_
Definition
image.hpp:21
wren::vk::Image::create
static auto create(const ::vk::Device &device, const VmaAllocator &allocator, const ::vk::Format &format, const math::Vec2f &size, const ::vk::ImageUsageFlags &usage) -> expected< Image >
Definition
image.cpp:5
wren::vk
Definition
render_pass.hpp:19
wren::expected
std::expected< T, Err > expected
Definition
result.hpp:49
wren::math::Vec2f
Definition
vector.hpp:124
vector.hpp
result.hpp
wren_vk
include
wren
vk
image.hpp
Generated by
1.10.0