blob: 8068a1905d89f65bc9b673dd2c5106fc6ca7f545 (
plain)
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
|
// Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "media/base/media_resource.h"
namespace media {
MediaResource::MediaResource() {}
MediaResource::~MediaResource() {}
MediaUrlParams MediaResource::GetMediaUrlParams() const {
NOTREACHED();
return MediaUrlParams{GURL(), GURL()};
}
MediaResource::Type MediaResource::GetType() const {
return STREAM;
}
DemuxerStream* MediaResource::GetFirstStream(DemuxerStream::Type type) {
const auto& streams = GetAllStreams();
for (auto* stream : streams) {
if (stream->type() == type)
return stream;
}
return nullptr;
}
} // namespace media
|