-
Notifications
You must be signed in to change notification settings - Fork 18
/
Copy pathmedia_notes.puml
127 lines (98 loc) · 2.68 KB
/
media_notes.puml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
@startuml
abstract MediaObject #BED2E8 {
size() : Size
state() : Pending/Ready/Error
type() : Bitmap/Video/AVG
url() : String
}
interface MediaComponentTrait {
mMediaObjects : MediaObjectPtr[]
getSources() : string[]
pendingMediaReturned( MediaObjectPtr )
mediaType() : Bitmap/Video/AVG
}
MediaComponentTrait "1" *- "N" MediaObject : >
abstract MediaManager #BED2E8 {
request( URL, type ) : MediaObjectPtr
makePlayer() : MediaPlayerPtr
}
MediaComponentTrait <|- VectorGraphicComponent
MediaComponentTrait <|-- ImageComponent
MediaComponentTrait <|-- VideoComponent
object MediaObjectFilter #F8B395 {
mediaObject : MediaObjectPtr
}
MediaObjectFilter "1" *-- "1" MediaObject : >
object MediaSource {
object : MediaObjectPtr
url : string
description : string
duration : int
repeatCount : int
entities : Object
offset : int
}
MediaSource *-- MediaObject : >
abstract MediaPlayer #BED2E8 {
tracks : MediaTrack[]
setTracks( MediaTrack[] )
controlMedia( CommandControlMedia )
playMedia( foreground/background/mute, Source )
hasEvents() : bool
popEvent() : Event
release()
}
note right of MediaPlayer
Changes here must be thread-safe.
setTracks can be called by Core
controlMedia/playMedia are connected
to Events. The "Callback" object is
used to queue up changes in core.
end note
object MediaTrack #BED2E8 {
object : MediaObject
duration : int
repeatCount : int
offset : int
}
MediaPlayer "1" *-- "N" MediaTrack : >
MediaTrack "1" *-- "1" MediaObject : >
MediaManager ..> MediaObject
MediaManager ..> MediaPlayer
object VideoNode #F8B395 {
player : MediaPlayerPtr
bounds : Rect
align : top/left/etc.
scale : none/fit/fill/etc.
}
VideoNode "1" *-- "1" MediaPlayer : >
class ImageComponent
class VectorGraphicComponent
class VideoComponent {
sources : MediaSource[]
player : MediaPlayerPtr
}
VideoComponent "1" *-- "N" MediaSource : >
VideoComponent "1" *-- "1" MediaPlayer : >
VideoComponent ..> VideoNode
ImageComponent ..> MediaObjectFilter
class ViewHostMediaManager #A5CC7E
note right: Installed by RootConfig
ViewHostMediaManager --|> MediaManager
'MediaManager <|-- ViewHostMediaManager
class ViewHostMediaObject #A5CC7E
note right of ViewHostMediaObject
Concrete implementation provided
by the view host. This references
the actual bitmap data.
end note
MediaObject <|-- ViewHostMediaObject
class ViewHostMediaPlayer #A5CC7E
note right of ViewHostMediaPlayer
Concrete implementation provided
by the view host. This references the
OS resources for playing video.
end note
MediaPlayer <|-- ViewHostMediaPlayer
hide empty members
@enduml