5 #include "flutter/testing/testing.h"
6 #include "gtest/gtest.h"
18 GTEST_SKIP() <<
"Test only applies to Vulkan";
21 auto allocator = std::make_shared<RenderTargetAllocator>(
22 GetContext()->GetResourceAllocator());
25 allocator->CreateOffscreenMSAA(*GetContext(), {100, 100}, 1);
26 std::shared_ptr<Texture> resolve_texture =
33 auto buffer = GetContext()->CreateCommandBuffer();
34 auto render_pass = buffer->CreateRenderPass(render_target);
39 render_pass->EncodeCommands();
40 EXPECT_TRUE(GetContext()->GetCommandQueue()->Submit({buffer}).ok());
43 auto buffer_2 = GetContext()->CreateCommandBuffer();
44 auto render_pass_2 = buffer_2->CreateRenderPass(render_target);
46 EXPECT_TRUE(render_pass_2->EncodeCommands());
47 EXPECT_TRUE(GetContext()->GetCommandQueue()->Submit({buffer_2}).ok());
52 GTEST_SKIP() <<
"Test only applies to Vulkan";
55 auto allocator = std::make_shared<RenderTargetAllocator>(
56 GetContext()->GetResourceAllocator());
59 allocator->CreateOffscreen(*GetContext(), {100, 100}, 1);
60 std::shared_ptr<Texture> color_texture =
67 auto buffer = GetContext()->CreateCommandBuffer();
68 auto render_pass = buffer->CreateRenderPass(render_target);
73 render_pass->EncodeCommands();
74 EXPECT_TRUE(GetContext()->GetCommandQueue()->Submit({buffer}).ok());
77 auto buffer_2 = GetContext()->CreateCommandBuffer();
78 auto render_pass_2 = buffer_2->CreateRenderPass(render_target);
80 EXPECT_TRUE(render_pass_2->EncodeCommands());
81 EXPECT_TRUE(GetContext()->GetCommandQueue()->Submit({buffer_2}).ok());
static TextureVK & Cast(Texture &base)
ColorAttachment GetColorAttachment(size_t index) const
Get the color attachment at [index].
SharedHandleVK< vk::RenderPass > GetCachedRenderPass() const
SharedHandleVK< vk::Framebuffer > GetCachedFramebuffer() const
TEST_P(AiksTest, DrawAtlasNoColor)
std::shared_ptr< Texture > resolve_texture
std::shared_ptr< Texture > texture