7 #ifndef MEDIA_BASE_STREAM_INFO_H_
8 #define MEDIA_BASE_STREAM_INFO_H_
13 #include "packager/base/memory/ref_counted.h"
15 namespace edash_packager {
25 class StreamInfo :
public base::RefCountedThreadSafe<StreamInfo> {
31 const std::string& codec_string,
32 const std::string& language,
33 const uint8_t* extra_data,
34 size_t extra_data_size,
42 virtual std::string
ToString()
const;
44 StreamType stream_type()
const {
return stream_type_; }
45 uint32_t track_id()
const {
return track_id_; }
46 uint32_t time_scale()
const {
return time_scale_; }
47 uint64_t duration()
const {
return duration_; }
48 const std::string& codec_string()
const {
return codec_string_; }
49 const std::string& language()
const {
return language_; }
51 bool is_encrypted()
const {
return is_encrypted_; }
53 const std::vector<uint8_t>& extra_data()
const {
return extra_data_; }
55 void set_duration(
int duration) { duration_ = duration; }
57 void set_extra_data(
const std::vector<uint8_t>& data) { extra_data_ = data; }
59 void set_codec_string(
const std::string& codec_string) {
60 codec_string_ = codec_string;
63 void set_language(
const std::string& language) { language_ = language; }
66 friend class base::RefCountedThreadSafe<StreamInfo>;
67 virtual ~StreamInfo();
71 StreamType stream_type_;
77 std::string codec_string_;
78 std::string language_;
85 std::vector<uint8_t> extra_data_;
95 #endif // MEDIA_BASE_STREAM_INFO_H_