LiteFX::Rendering::IBarrier::transition¶
Inserts an image barrier that blocks access to a sub-resource range of image of the types contained in accessAfter for subsequent commands until previous commands have finished accesses contained in accessBefore and transitions the sub-resource into layout.
Synopsis¶
Declared in <litefx/rendering_api.hpp>
[[dllimport, dllexport]] constexpr void transition(
IImage const& image,
UInt32 level,
UInt32 levels,
UInt32 layer,
UInt32 layers,
UInt32 plane,
ResourceAccess accessBefore,
ResourceAccess accessAfter,
ImageLayout fromLayout,
ImageLayout toLayout);
Description¶
This overload let's you explicitly specify the fromLayout. This is required, if you use any external transition mechanism that causes the engine to lose track of the image layout. If you are not running into issues with the other overloads, you probably do not want to call this method.
Parameters¶
| Name | Description |
|---|---|
| image | The image resource to transition. |
| level | The base mip-map level of the sub-resource range. |
| levels | The number of mip-map levels of the sub-resource range. |
| layer | The base array layer of the sub-resource range. |
| layers | The number of array layer of the sub-resource range. |
| plane | The plane of the sub-resource. |
| accessBefore | The access types previous commands have to finish. |
| accessAfter | The access types that subsequent commands continue with. |
| fromLayout | The image layout to transition from. |
| toLayout | The image layout to transition into. |