#include <blit_pass_vk.h>
|
| ~BlitPassVK () override |
|
virtual | ~BlitPass () |
|
void | SetLabel (std::string label) |
|
bool | AddCopy (std::shared_ptr< Texture > source, std::shared_ptr< Texture > destination, std::optional< IRect > source_region=std::nullopt, IPoint destination_origin={}, std::string label="") |
| Record a command to copy the contents of one texture to another texture. The blit area is limited by the intersection of the texture coverage with respect the source region and destination origin. No work is encoded into the command buffer at this time.
|
|
bool | AddCopy (std::shared_ptr< Texture > source, std::shared_ptr< DeviceBuffer > destination, std::optional< IRect > source_region=std::nullopt, size_t destination_offset=0, std::string label="") |
| Record a command to copy the contents of the buffer to the texture. No work is encoded into the command buffer at this time.
|
|
bool | AddCopy (BufferView source, std::shared_ptr< Texture > destination, IPoint destination_origin={}, std::string label="") |
| Record a command to copy the contents of the buffer to the texture. No work is encoded into the command buffer at this time.
|
|
bool | GenerateMipmap (std::shared_ptr< Texture > texture, std::string label="") |
| Record a command to generate all mip levels for a texture. No work is encoded into the command buffer at this time.
|
|
|
bool | IsValid () const override |
|
void | OnSetLabel (std::string label) override |
|
bool | EncodeCommands (const std::shared_ptr< Allocator > &transients_allocator) const override |
| Encode the recorded commands to the underlying command buffer.
|
|
bool | OnCopyTextureToTextureCommand (std::shared_ptr< Texture > source, std::shared_ptr< Texture > destination, IRect source_region, IPoint destination_origin, std::string label) override |
|
bool | OnCopyTextureToBufferCommand (std::shared_ptr< Texture > source, std::shared_ptr< DeviceBuffer > destination, IRect source_region, size_t destination_offset, std::string label) override |
|
bool | OnCopyBufferToTextureCommand (BufferView source, std::shared_ptr< Texture > destination, IPoint destination_origin, std::string label) override |
|
bool | OnGenerateMipmapCommand (std::shared_ptr< Texture > texture, std::string label) override |
|
Definition at line 18 of file blit_pass_vk.h.
◆ ~BlitPassVK()
impeller::BlitPassVK::~BlitPassVK |
( |
| ) |
|
|
overridedefault |
◆ EncodeCommands()
bool impeller::BlitPassVK::EncodeCommands |
( |
const std::shared_ptr< Allocator > & |
transients_allocator | ) |
const |
|
overrideprivatevirtual |
Encode the recorded commands to the underlying command buffer.
- Parameters
-
transients_allocator | The transients allocator. |
- Returns
- If the commands were encoded to the underlying command buffer.
Implements impeller::BlitPass.
Definition at line 31 of file blit_pass_vk.cc.
32 {
34
36 return false;
37 }
38
39 auto command_buffer = command_buffer_.lock();
40 if (!command_buffer) {
41 return false;
42 }
43 auto encoder = command_buffer->GetEncoder();
45 return false;
46 }
47
48 for (auto& command : commands_) {
50 return false;
51 }
52 }
53
54 return true;
55}
bool IsValid() const override
#define TRACE_EVENT0(category_group, name)
◆ IsValid()
bool impeller::BlitPassVK::IsValid |
( |
| ) |
const |
|
overrideprivatevirtual |
◆ OnCopyBufferToTextureCommand()
bool impeller::BlitPassVK::OnCopyBufferToTextureCommand |
( |
BufferView |
source, |
|
|
std::shared_ptr< Texture > |
destination, |
|
|
IPoint |
destination_origin, |
|
|
std::string |
label |
|
) |
| |
|
overrideprivatevirtual |
Implements impeller::BlitPass.
Definition at line 96 of file blit_pass_vk.cc.
100 {
101 auto command = std::make_unique<BlitCopyBufferToTextureCommandVK>();
102
104 command->destination = std::move(destination);
105 command->destination_origin = destination_origin;
106 command->label = std::move(label);
107
108 commands_.push_back(std::move(command));
109 return true;
110}
◆ OnCopyTextureToBufferCommand()
bool impeller::BlitPassVK::OnCopyTextureToBufferCommand |
( |
std::shared_ptr< Texture > |
source, |
|
|
std::shared_ptr< DeviceBuffer > |
destination, |
|
|
IRect |
source_region, |
|
|
size_t |
destination_offset, |
|
|
std::string |
label |
|
) |
| |
|
overrideprivatevirtual |
Implements impeller::BlitPass.
Definition at line 77 of file blit_pass_vk.cc.
82 {
83 auto command = std::make_unique<BlitCopyTextureToBufferCommandVK>();
84
86 command->destination = std::move(destination);
87 command->source_region = source_region;
88 command->destination_offset = destination_offset;
89 command->label = std::move(label);
90
91 commands_.push_back(std::move(command));
92 return true;
93}
◆ OnCopyTextureToTextureCommand()
bool impeller::BlitPassVK::OnCopyTextureToTextureCommand |
( |
std::shared_ptr< Texture > |
source, |
|
|
std::shared_ptr< Texture > |
destination, |
|
|
IRect |
source_region, |
|
|
IPoint |
destination_origin, |
|
|
std::string |
label |
|
) |
| |
|
overrideprivatevirtual |
Implements impeller::BlitPass.
Definition at line 58 of file blit_pass_vk.cc.
63 {
64 auto command = std::make_unique<BlitCopyTextureToTextureCommandVK>();
65
67 command->destination = std::move(destination);
68 command->source_region = source_region;
69 command->destination_origin = destination_origin;
70 command->label = std::move(label);
71
72 commands_.push_back(std::move(command));
73 return true;
74}
◆ OnGenerateMipmapCommand()
bool impeller::BlitPassVK::OnGenerateMipmapCommand |
( |
std::shared_ptr< Texture > |
texture, |
|
|
std::string |
label |
|
) |
| |
|
overrideprivatevirtual |
Implements impeller::BlitPass.
Definition at line 113 of file blit_pass_vk.cc.
114 {
115 auto command = std::make_unique<BlitGenerateMipmapCommandVK>();
116
118 command->label = std::move(label);
119
120 commands_.push_back(std::move(command));
121 return true;
122}
◆ OnSetLabel()
void impeller::BlitPassVK::OnSetLabel |
( |
std::string |
label | ) |
|
|
overrideprivatevirtual |
◆ CommandBufferVK
The documentation for this class was generated from the following files: