Lugdunum
0.1.0
include
lug
Graphics
Vulkan
API
CommandPool.hpp
Go to the documentation of this file.
1
#pragma once
2
3
#include <
lug/Graphics/Export.hpp
>
4
#include <
lug/Graphics/Vulkan/Vulkan.hpp
>
5
6
namespace
lug
{
7
namespace
Graphics {
8
namespace
Vulkan
{
9
namespace
API {
10
11
namespace
Builder {
12
class
CommandPool;
13
}
// Builder
14
15
class
Device;
16
class
Queue;
17
18
class
LUG_GRAPHICS_API
CommandPool
{
19
friend
class
Builder::CommandPool
;
20
21
public
:
22
CommandPool
() =
default
;
23
24
CommandPool
(
const
CommandPool
&) =
delete
;
25
// Warning: Don't move CommandPool after creating a CommandBuffer
26
CommandPool
(
CommandPool
&&
CommandPool
);
27
28
CommandPool
& operator=(
const
CommandPool
&) =
delete
;
29
// Warning: Don't move CommandPool after creating a CommandBuffer
30
CommandPool
& operator=(
CommandPool
&&
CommandPool
);
31
32
~
CommandPool
();
33
34
explicit
operator
VkCommandPool()
const
{
35
return
_commandPool;
36
}
37
38
const
Device
* getDevice()
const
;
39
const
Queue
* getQueue()
const
;
40
41
bool
reset(
bool
releaseRessources =
false
)
const
;
42
43
// Warning: Command buffers created with this pool must have been destroyed
44
void
destroy();
45
46
private
:
47
explicit
CommandPool
(VkCommandPool commandPool,
const
Device
*device,
const
Queue
*queue);
48
49
private
:
50
VkCommandPool _commandPool{VK_NULL_HANDLE};
51
const
Device
* _device{
nullptr
};
52
53
const
Queue
* _queue{
nullptr
};
54
};
55
56
#include <
lug/Graphics/Vulkan/API/CommandPool.inl
>
57
58
}
// API
59
}
// Vulkan
60
}
// Graphics
61
}
// lug
lug::Graphics::Vulkan::API::Queue
Definition:
Queue.hpp:16
CommandPool.inl
LUG_GRAPHICS_API
#define LUG_GRAPHICS_API
Definition:
Export.hpp:11
Vulkan
Definition:
Vulkan.hpp:155
lug::Graphics::Vulkan::API::Device
Definition:
Device.hpp:16
lug::Graphics::Vulkan::API::Builder::CommandPool
Definition:
CommandPool.hpp:17
Vulkan.hpp
lug
Definition:
Application.hpp:11
lug::Graphics::Vulkan::API::CommandPool
Definition:
CommandPool.hpp:18
Export.hpp
Generated by
1.8.13