[M120 Migration][hbbtv] Audio tracks count notification
[platform/framework/web/chromium-efl.git] / media / base / pipeline.h
index 8204732..359e52e 100644 (file)
@@ -31,6 +31,35 @@ namespace media {
 class CdmContext;
 class Demuxer;
 
+enum TRACKCMD { SETTEXT, SETAUDIO, SETVIDEO, SETINBAND, SETCUE };
+
+struct InbandTextInfo {
+  std::string info;
+  int band_type;
+  int action;
+};
+
+struct TrackInfo {
+  std::string id;
+  std::string kind;
+  std::string label;
+  std::string language;
+  bool enabled;
+};
+
+struct InbandCueInfo {
+  std::string info;
+  int id;
+  int band_type;
+  int stime;
+  int etime;
+};
+
+struct MediaTrackInfo {
+  TRACKCMD cmd;
+  void* info;
+};
+
 class MEDIA_EXPORT Pipeline {
  public:
   class Client {
@@ -59,6 +88,11 @@ class MEDIA_EXPORT Pipeline {
     virtual void OnBufferingStateChange(BufferingState state,
                                         BufferingStateChangeReason reason) = 0;
 
+#if BUILDFLAG(IS_TIZEN_TV)
+    virtual void NotifyTrackInfoToBrowser(int active_track_id) {}
+    virtual void AddTrackInfo(MediaTrackInfo trackinfo) {}
+#endif
+
     // Executed whenever the presentation duration changes.
     virtual void OnDurationChange() = 0;
 
@@ -91,6 +125,10 @@ class MEDIA_EXPORT Pipeline {
 
 #if defined(TIZEN_MULTIMEDIA)
     virtual void OnRequestSuspend(bool resource_conflicted) = 0;
+    virtual void OnSeekableTimeChange(base::TimeDelta min_time,
+                                      base::TimeDelta max_time,
+                                      bool is_live) = 0;
+    virtual void OnLivePlaybackComplete() = 0;
 #endif
   };
 
@@ -275,6 +313,17 @@ class MEDIA_EXPORT Pipeline {
 #if defined(TIZEN_VIDEO_HOLE)
   virtual void SetMediaGeometry(const gfx::RectF rect_f) = 0;
 #endif
+#if BUILDFLAG(IS_TIZEN_TV)
+  virtual void SetContentMimeType(const std::string& mime_type) = 0;
+  virtual void AudioTracksCountChanged(unsigned count) = 0;
+  virtual void SetParentalRatingResult(bool is_pass) = 0;
+  virtual void SetActiveTextTrack(int id, bool is_in_band) = 0;
+  virtual void SetActiveAudioTrack(int index) = 0;
+  virtual void SetActiveVideoTrack(int index) = 0;
+  virtual void SetPreferTextLanguage(const std::string& lang) = 0;
+  virtual double GetStartDate() = 0;
+  virtual void DestroyPlayerSync(base::OnceClosure cb) = 0;
+#endif
 };
 
 }  // namespace media