Flutter Engine
The Flutter Engine
Public Member Functions | Static Public Member Functions | List of all members
impeller::scene::PropertyResolver Class Referenceabstract

#include <property_resolver.h>

Inheritance diagram for impeller::scene::PropertyResolver:
impeller::scene::TimelineResolver impeller::scene::RotationTimelineResolver impeller::scene::ScaleTimelineResolver impeller::scene::TranslationTimelineResolver

Public Member Functions

virtual ~PropertyResolver ()
 
virtual SecondsF GetEndTime ()=0
 
virtual void Apply (AnimationTransforms &target, SecondsF time, Scalar weight)=0
 Resolve and apply the property value to a target node. This operation is additive; a given node property may be amended by many different PropertyResolvers prior to rendering. For example, an AnimationPlayer may blend multiple Animations together by applying several AnimationClips. More...
 

Static Public Member Functions

static std::unique_ptr< TranslationTimelineResolverMakeTranslationTimeline (std::vector< Scalar > times, std::vector< Vector3 > values)
 
static std::unique_ptr< RotationTimelineResolverMakeRotationTimeline (std::vector< Scalar > times, std::vector< Quaternion > values)
 
static std::unique_ptr< ScaleTimelineResolverMakeScaleTimeline (std::vector< Scalar > times, std::vector< Vector3 > values)
 

Detailed Description

Definition at line 25 of file property_resolver.h.

Constructor & Destructor Documentation

◆ ~PropertyResolver()

impeller::scene::PropertyResolver::~PropertyResolver ( )
virtualdefault

Member Function Documentation

◆ Apply()

virtual void impeller::scene::PropertyResolver::Apply ( AnimationTransforms target,
SecondsF  time,
Scalar  weight 
)
pure virtual

Resolve and apply the property value to a target node. This operation is additive; a given node property may be amended by many different PropertyResolvers prior to rendering. For example, an AnimationPlayer may blend multiple Animations together by applying several AnimationClips.

Implemented in impeller::scene::TranslationTimelineResolver, impeller::scene::RotationTimelineResolver, and impeller::scene::ScaleTimelineResolver.

◆ GetEndTime()

virtual SecondsF impeller::scene::PropertyResolver::GetEndTime ( )
pure virtual

◆ MakeRotationTimeline()

std::unique_ptr< RotationTimelineResolver > impeller::scene::PropertyResolver::MakeRotationTimeline ( std::vector< Scalar times,
std::vector< Quaternion values 
)
static

Definition at line 30 of file property_resolver.cc.

31 {
32 FML_DCHECK(times.size() == values.size());
33 auto result =
34 std::unique_ptr<RotationTimelineResolver>(new RotationTimelineResolver());
35 result->times_ = std::move(times);
36 result->values_ = std::move(values);
37 return result;
38}
static SkISize times(const SkISize &size, float factor)
GAsyncResult * result
#define FML_DCHECK(condition)
Definition: logging.h:103

◆ MakeScaleTimeline()

std::unique_ptr< ScaleTimelineResolver > impeller::scene::PropertyResolver::MakeScaleTimeline ( std::vector< Scalar times,
std::vector< Vector3 values 
)
static

Definition at line 40 of file property_resolver.cc.

42 {
43 FML_DCHECK(times.size() == values.size());
44 auto result =
45 std::unique_ptr<ScaleTimelineResolver>(new ScaleTimelineResolver());
46 result->times_ = std::move(times);
47 result->values_ = std::move(values);
48 return result;
49}

◆ MakeTranslationTimeline()

std::unique_ptr< TranslationTimelineResolver > impeller::scene::PropertyResolver::MakeTranslationTimeline ( std::vector< Scalar times,
std::vector< Vector3 values 
)
static

Definition at line 19 of file property_resolver.cc.

20 {
21 FML_DCHECK(times.size() == values.size());
22 auto result = std::unique_ptr<TranslationTimelineResolver>(
23 new TranslationTimelineResolver());
24 result->times_ = std::move(times);
25 result->values_ = std::move(values);
26 return result;
27}

The documentation for this class was generated from the following files: