2 * Copyright 2013, Mozilla Foundation and contributors
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 #if !defined(WMFAACDecoder_h_)
18 #define WMFAACDecoder_h_
29 HRESULT
Init(int32_t aChannelCount
,
32 UINT32 aUserDataLength
);
34 HRESULT
Input(const uint8_t* aData
,
36 Microseconds aTimestamp
);
38 HRESULT
Output(IMFSample
** aOutput
);
44 UINT32
Channels() const { return mChannels
; }
45 UINT32
Rate() const { return mRate
; }
49 HRESULT
GetOutputSample(IMFSample
** aOutSample
);
50 HRESULT
CreateOutputSample(IMFSample
** aOutSample
);
51 HRESULT
CreateInputSample(const uint8_t* aData
,
53 Microseconds aTimestamp
,
54 IMFSample
** aOutSample
);
56 HRESULT
SetDecoderInputType(int32_t aChannelCount
,
59 UINT32 aUserDataLength
);
60 HRESULT
SetDecoderOutputType();
61 HRESULT
SendMFTMessage(MFT_MESSAGE_TYPE aMsg
, UINT32 aData
);
63 MFT_INPUT_STREAM_INFO mInputStreamInfo
;
64 MFT_OUTPUT_STREAM_INFO mOutputStreamInfo
;
66 CComPtr
<IMFTransform
> mDecoder
;