Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Composition.h
Go to the documentation of this file.
1/*
2 * Copyright 2019 Google Inc.
3 *
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
6 */
7
8#ifndef SkottieComposition_DEFINED
9#define SkottieComposition_DEFINED
10
12#include "include/core/SkSize.h"
15#include "src/core/SkTHash.h"
16
17#include <cstddef>
18#include <vector>
19
20namespace skjson {
21class ObjectValue;
22}
23namespace sksg {
24class RenderNode;
25class Transform;
26} // namespace sksg
27
28namespace skottie {
29namespace internal {
30class AnimationBuilder;
31
33public:
36
38
39 LayerBuilder* layerBuilder(int layer_index);
40
41private:
42 const sk_sp<sksg::Transform>& getCameraTransform() const { return fCameraTransform; }
43
44 friend class LayerBuilder;
45
46 const SkSize fSize;
47
48 std::vector<LayerBuilder> fLayerBuilders;
49 skia_private::THashMap<int, size_t> fLayerIndexMap; // Maps layer "ind" to layer builder index.
50
51 sk_sp<sksg::Transform> fCameraTransform;
52
53 size_t fMotionBlurSamples = 1;
54 float fMotionBlurAngle = 0,
55 fMotionBlurPhase = 0;
56};
57
58} // namespace internal
59} // namespace skottie
60
61#endif // SkottieComposition_DEFINED
LayerBuilder * layerBuilder(int layer_index)
Definition build.py:1
Definition Skottie.h:32
skgpu::graphite::Transform Transform