Flutter Impeller
framebuffer_blend_contents.h
Go to the documentation of this file.
1
// Copyright 2013 The Flutter Authors. All rights reserved.
2
// Use of this source code is governed by a BSD-style license that can be
3
// found in the LICENSE file.
4
5
#ifndef FLUTTER_IMPELLER_ENTITY_CONTENTS_FRAMEBUFFER_BLEND_CONTENTS_H_
6
#define FLUTTER_IMPELLER_ENTITY_CONTENTS_FRAMEBUFFER_BLEND_CONTENTS_H_
7
8
#include <memory>
9
10
#include "
impeller/entity/contents/color_source_contents.h
"
11
#include "
impeller/entity/entity.h
"
12
13
namespace
impeller
{
14
15
enum class
BlendSelectValues
{
16
kScreen
= 0,
17
kOverlay
,
18
kDarken
,
19
kLighten
,
20
kColorDodge
,
21
kColorBurn
,
22
kHardLight
,
23
kSoftLight
,
24
kDifference
,
25
kExclusion
,
26
kMultiply
,
27
kHue
,
28
kSaturation
,
29
kColor
,
30
kLuminosity
,
31
};
32
33
class
FramebufferBlendContents
final :
public
ColorSourceContents
{
34
public
:
35
FramebufferBlendContents
();
36
37
~FramebufferBlendContents
()
override
;
38
39
const
Geometry
*
GetGeometry
()
const override
;
40
41
void
SetBlendMode
(
BlendMode
blend_mode);
42
43
void
SetChildContents
(std::shared_ptr<Contents> child_contents);
44
45
private
:
46
// |Contents|
47
std::optional<Rect> GetCoverage(
const
Entity
& entity)
const override
;
48
49
// |Contents|
50
bool
Render(
const
ContentContext
& renderer,
51
const
Entity
& entity,
52
RenderPass
& pass)
const override
;
53
54
BlendMode
blend_mode_;
55
std::shared_ptr<Contents> child_contents_;
56
57
FramebufferBlendContents
(
const
FramebufferBlendContents
&) =
delete
;
58
59
FramebufferBlendContents
& operator=(
const
FramebufferBlendContents
&) =
delete
;
60
};
61
62
}
// namespace impeller
63
64
#endif
// FLUTTER_IMPELLER_ENTITY_CONTENTS_FRAMEBUFFER_BLEND_CONTENTS_H_
impeller::ColorSourceContents
Definition:
color_source_contents.h:38
impeller::ContentContext
Definition:
content_context.h:122
impeller::Entity
Definition:
entity.h:26
impeller::FramebufferBlendContents
Definition:
framebuffer_blend_contents.h:33
impeller::FramebufferBlendContents::SetChildContents
void SetChildContents(std::shared_ptr< Contents > child_contents)
Definition:
framebuffer_blend_contents.cc:24
impeller::FramebufferBlendContents::GetGeometry
const Geometry * GetGeometry() const override
Get the geometry that this contents will use to render.
Definition:
framebuffer_blend_contents.cc:16
impeller::FramebufferBlendContents::~FramebufferBlendContents
~FramebufferBlendContents() override
impeller::FramebufferBlendContents::SetBlendMode
void SetBlendMode(BlendMode blend_mode)
Definition:
framebuffer_blend_contents.cc:20
impeller::FramebufferBlendContents::FramebufferBlendContents
FramebufferBlendContents()
impeller::Geometry
Definition:
geometry.h:50
impeller::RenderPass
Render passes encode render commands directed as one specific render target into an underlying comman...
Definition:
render_pass.h:30
color_source_contents.h
entity.h
impeller
Definition:
allocation.cc:12
impeller::BlendMode
BlendMode
Definition:
color.h:58
impeller::BlendSelectValues
BlendSelectValues
Definition:
framebuffer_blend_contents.h:15
impeller::BlendSelectValues::kExclusion
@ kExclusion
impeller::BlendSelectValues::kSaturation
@ kSaturation
impeller::BlendSelectValues::kColorBurn
@ kColorBurn
impeller::BlendSelectValues::kLighten
@ kLighten
impeller::BlendSelectValues::kHue
@ kHue
impeller::BlendSelectValues::kMultiply
@ kMultiply
impeller::BlendSelectValues::kColorDodge
@ kColorDodge
impeller::BlendSelectValues::kScreen
@ kScreen
impeller::BlendSelectValues::kLuminosity
@ kLuminosity
impeller::BlendSelectValues::kSoftLight
@ kSoftLight
impeller::BlendSelectValues::kDifference
@ kDifference
impeller::BlendSelectValues::kOverlay
@ kOverlay
impeller::BlendSelectValues::kColor
@ kColor
impeller::BlendSelectValues::kHardLight
@ kHardLight
impeller::BlendSelectValues::kDarken
@ kDarken
impeller
entity
contents
framebuffer_blend_contents.h
Generated by
1.9.1