}
scoped_refptr<StreamParserBuffer> StreamParserBuffer::CreateEOSBuffer() {
- return make_scoped_refptr(new StreamParserBuffer(NULL, 0, NULL, 0, false));
+ return make_scoped_refptr(new StreamParserBuffer(NULL, 0, NULL, 0, false,
+ DemuxerStream::UNKNOWN, 0));
}
scoped_refptr<StreamParserBuffer> StreamParserBuffer::CopyFrom(
- const uint8* data, int data_size, bool is_keyframe) {
+ const uint8* data, int data_size, bool is_keyframe, Type type,
+ TrackId track_id) {
return make_scoped_refptr(
- new StreamParserBuffer(data, data_size, NULL, 0, is_keyframe));
+ new StreamParserBuffer(data, data_size, NULL, 0, is_keyframe, type,
+ track_id));
}
scoped_refptr<StreamParserBuffer> StreamParserBuffer::CopyFrom(
const uint8* data, int data_size,
- const uint8* side_data, int side_data_size, bool is_keyframe) {
+ const uint8* side_data, int side_data_size,
+ bool is_keyframe, Type type, TrackId track_id) {
return make_scoped_refptr(
new StreamParserBuffer(data, data_size, side_data, side_data_size,
- is_keyframe));
+ is_keyframe, type, track_id));
}
base::TimeDelta StreamParserBuffer::GetDecodeTimestamp() const {
StreamParserBuffer::StreamParserBuffer(const uint8* data, int data_size,
const uint8* side_data,
- int side_data_size, bool is_keyframe)
+ int side_data_size, bool is_keyframe,
+ Type type, TrackId track_id)
: DecoderBuffer(data, data_size, side_data, side_data_size),
is_keyframe_(is_keyframe),
decode_timestamp_(kNoTimestamp()),
- config_id_(kInvalidConfigId) {
+ config_id_(kInvalidConfigId),
+ type_(type),
+ track_id_(track_id) {
// TODO(scherkus): Should DataBuffer constructor accept a timestamp and
// duration to force clients to set them? Today they end up being zero which
// is both a common and valid value and could lead to bugs.