2019-01-06 05:53:24 +01:00
|
|
|
// Copyright 2019 Citra Emulator Project
|
|
|
|
// Licensed under GPLv2 or any later version
|
|
|
|
// Refer to the license.txt file included.
|
2018-12-19 17:12:57 +01:00
|
|
|
#pragma once
|
|
|
|
|
2019-01-06 05:53:24 +01:00
|
|
|
#include "common/common_types.h"
|
2018-12-19 17:12:57 +01:00
|
|
|
|
|
|
|
struct ADTSData {
|
2023-05-10 01:35:49 +02:00
|
|
|
u8 header_length;
|
2018-12-19 17:12:57 +01:00
|
|
|
bool MPEG2;
|
2019-01-06 05:53:24 +01:00
|
|
|
u8 profile;
|
|
|
|
u8 channels;
|
|
|
|
u8 channel_idx;
|
|
|
|
u8 framecount;
|
|
|
|
u8 samplerate_idx;
|
|
|
|
u32 length;
|
|
|
|
u32 samplerate;
|
2018-12-19 17:12:57 +01:00
|
|
|
};
|
|
|
|
|
2019-02-09 05:22:14 +01:00
|
|
|
ADTSData ParseADTS(const char* buffer);
|
2019-01-29 05:47:41 +01:00
|
|
|
|
2018-12-19 17:12:57 +01:00
|
|
|
// last two bytes of MF AAC decoder user data
|
2019-01-29 05:47:41 +01:00
|
|
|
// see https://docs.microsoft.com/en-us/windows/desktop/medfound/aac-decoder#example-media-types
|
2019-02-09 19:59:00 +01:00
|
|
|
u16 MFGetAACTag(const ADTSData& input);
|