MCPcopy Create free account
hub / github.com/DragonJoker/RenderGraph / checkTargetColourIsShaderReadOnly

Function checkTargetColourIsShaderReadOnly

test/TestRenderGraph.cpp:19–38  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

17 }
18
19 void checkTargetColourIsShaderReadOnly( [[maybe_unused]] test::TestCounts const & testCounts
20 , crg::FramePass const & framePass
21 , crg::RunnableGraph const &
22 , crg::RecordContext const & context
23 , uint32_t index )
24 {
25 for ( auto attach : framePass.getTargets() )
26 {
27 auto view = attach->view( index );
28
29 if ( attach->isColourOutputImageTarget() )
30 {
31 auto resolved = crg::resolveView( view, index );
32 checkEqual( context.getNextLayoutState( resolved ).layout, crg::ImageLayout::eShaderReadOnly )
33 checkEqual( context.getNextLayoutState( resolved.data->image
34 , resolved.data->info.viewType
35 , getSubresourceRange( resolved ) ).layout, crg::ImageLayout::eShaderReadOnly )
36 }
37 }
38 }
39
40 void checkSampledIsShaderReadOnly( [[maybe_unused]] test::TestCounts const & testCounts
41 , crg::FramePass const & framePass

Callers

nothing calls this directly

Calls 3

viewMethod · 0.80
getNextLayoutStateMethod · 0.45

Tested by

no test coverage detected