15 {
16 static constexpr char json[] =
17 R"({
18 "v": "5.2.1",
19 "w": 100,
20 "h": 100,
21 "fr": 10,
22 "ip": 0,
23 "op": 100,
24 "assets": [
25 {
26 "id": "audio_0",
27 "p" : "audio.mp3",
28 "u" : "assets/"
29 }
30 ],
31 "layers": [
32 {
33 "ty" : 6,
34 "ind" : 0,
35 "ip" : 20,
36 "op" : 70,
37 "refId": "audio_0"
38 },
39 {
40 "ty" : 6,
41 "ind" : 0,
42 "ip" : 50,
43 "op" : 80,
44 "refId": "audio_0"
45 },
46 {
47 "ty": 1,
48 "ip": 0,
49 "op": 100,
50 "sw": 100,
51 "sh": 100,
52 "sc": "#ffffff"
53 }
54 ]
55 })";
56
58 public:
59 bool isPlaying() const { return fCurrentTime >= 0; }
60 float currentTime() const { return fCurrentTime; }
61
62 private:
63 void seek(
float t)
override {
64 fCurrentTime = t;
65 }
66
67 float fCurrentTime = 0;
68 };
69
71 public:
73
74 const std::vector<sk_sp<MockTracker>>& tracks() const { return fTracks; }
75
76 private:
79 const char id[]) override {
83
84 fTracks.push_back(sk_make_sp<MockTracker>());
85
86 return fTracks.back();
87 }
88
90 std::vector<sk_sp<MockTracker>> fTracks;
91 };
92
94 auto rp = sk_make_sp<MockResourceProvider>(r);
95
#define REPORTER_ASSERT(r, cond,...)
virtual void seek(float t)=0
virtual sk_sp< ExternalTrackAsset > loadAudioAsset(const char[], const char[], const char[])
DlVertices::Builder Builder
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir path
DEF_SWITCHES_START aot vmservice shared library name