Tizen WASM Player
Tizen TV WebAssembly Media Player extension allowing for a low-level elementary media stream playback.
elementary_media_track_listener.h
Go to the documentation of this file.
1 // Copyright 2020 Samsung Electronics
2 // TizenTV Emscripten extensions are available under two separate licenses, the
3 // MIT license and the University of Illinois/NCSA Open Source License. Both
4 // these licenses can be found in the LICENSE file.
5 
6 #ifndef INCLUDE_SAMSUNG_WASM_ELEMENTARY_MEDIA_TRACK_LISTENER_H_
7 #define INCLUDE_SAMSUNG_WASM_ELEMENTARY_MEDIA_TRACK_LISTENER_H_
8 
9 #include <chrono>
10 #include <cstdint>
11 
12 #include "samsung/wasm/common.h"
14 
15 namespace samsung {
16 namespace wasm {
17 
26  public:
27  virtual ~ElementaryMediaTrackListener() = default;
28 
30  virtual void OnTrackOpen() {}
31 
38 
71  virtual void OnSeek(Seconds /*new_time*/) {}
72 
86  virtual void OnSessionIdChanged(SessionId /*session_id*/) {}
87 
95  virtual void OnAppendError(OperationResult /*operation_result*/) {}
96 };
97 
98 } // namespace wasm
99 } // namespace samsung
100 
101 #endif // INCLUDE_SAMSUNG_WASM_ELEMENTARY_MEDIA_TRACK_LISTENER_H_
virtual void OnTrackClosed(ElementaryMediaTrack::CloseReason)
std::chrono::duration< double > Seconds
Default duration type used throughout the API.
Definition: common.h:53
int32_t SessionId
Definition: session_id.h:25
OperationResult
Enumerates possible outcomes of WASM function calls.
Allows receiving ElementaryMediaTrack events.
virtual void OnTrackOpen()
Fired when the track is ready to accept data.