Line data Source code
1 : /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 : /* vim:set ts=2 sw=2 sts=2 et cindent: */
3 : /* This Source Code Form is subject to the terms of the Mozilla Public
4 : * License, v. 2.0. If a copy of the MPL was not distributed with this
5 : * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6 :
7 : #include "OmxDecoderModule.h"
8 :
9 : #include "OmxDataDecoder.h"
10 : #include "OmxPlatformLayer.h"
11 :
12 : namespace mozilla {
13 :
14 : already_AddRefed<MediaDataDecoder>
15 0 : OmxDecoderModule::CreateVideoDecoder(const CreateDecoderParams& aParams)
16 : {
17 : RefPtr<OmxDataDecoder> decoder = new OmxDataDecoder(aParams.mConfig,
18 0 : aParams.mImageContainer);
19 0 : return decoder.forget();
20 : }
21 :
22 : already_AddRefed<MediaDataDecoder>
23 0 : OmxDecoderModule::CreateAudioDecoder(const CreateDecoderParams& aParams)
24 : {
25 : RefPtr<OmxDataDecoder> decoder = new OmxDataDecoder(aParams.mConfig,
26 0 : nullptr);
27 0 : return decoder.forget();
28 : }
29 :
30 : bool
31 0 : OmxDecoderModule::SupportsMimeType(const nsACString& aMimeType,
32 : DecoderDoctorDiagnostics* aDiagnostics) const
33 : {
34 0 : return OmxPlatformLayer::SupportsMimeType(aMimeType);
35 : }
36 :
37 : }
|