23 texture_desc.
size = {100, 100};
28 GetContext()->GetResourceAllocator()->CreateTexture(texture_desc);
37 GetContentContext().GetRenderTargetCache()->CreateOffscreenMSAA(
41 auto recording_pass = std::make_shared<RecordingRenderPass>(
44 ASSERT_TRUE(contents.
Render(GetContentContext(), {}, *recording_pass));
45 const std::vector<Command>& commands = recording_pass->GetCommands();
47 ASSERT_EQ(commands.size(), 1u);
49 EXPECT_TRUE(commands[0].
pipeline->GetDescriptor().GetLabel().find(
50 "TextureFill Pipeline") != std::string::npos);
55 GetContentContext().GetTiledTexturePipeline(options));
58 recording_pass->EncodeCommands();
68 <<
"External OES textures are only valid for the OpenGLES backend.";
72 texture_desc.
size = {100, 100};
77 GetContext()->GetResourceAllocator()->CreateTexture(texture_desc);
81 contents->SetStrictSourceRect(
false);
86 GetContentContext().GetRenderTargetCache()->CreateOffscreenMSAA(
91 ASSERT_TRUE(contents->Render(GetContentContext(), {}, *
render_pass));
92 const std::vector<Command>& commands =
render_pass->GetCommands();
94 ASSERT_EQ(commands.size(), 1u);
99 GetContentContext().GetTiledTextureExternalPipeline(options));
std::shared_ptr< Context > GetContext() const
static std::shared_ptr< TextureContents > MakeRect(Rect destination)
bool Render(const ContentContext &renderer, const Entity &entity, RenderPass &pass) const override
void SetTexture(std::shared_ptr< Texture > texture)
PrimitiveType primitive_type
A lightweight object that describes the attributes of a texture that can then used an allocator to cr...