Files
UnrealEngineUWP/Engine/Source/Runtime/AudioCodecEngine/Private/DecoderInputBackCompat.h
jimmy smith 39745ac8ae WavePlayer Backcompat with old ICompressedAudioInfo
#rb ethan.geller phil.popp aaron.mcleran
#jira UEAU-591

[CL 14275071 by jimmy smith in ue5-main branch]
2020-09-08 18:12:55 -04:00

44 lines
1.0 KiB
C++

// Copyright Epic Games, Inc. All Rights Reserved.
#pragma once
#include "IAudioCodec.h"
#include "UObject/NameTypes.h"
#include "AudioDecompress.h"
class ICompressedAudioInfo; // Forward declares.
namespace Audio
{
struct FBackCompatInput : public IDecoderInput
{
FName OldFormatName;
TWeakObjectPtr<const USoundWave> Wave;
mutable FFormatDescriptorSection Desc;
mutable TUniquePtr<ICompressedAudioInfo> OldInfoObject;
FBackCompatInput(
FName InOldFormatName,
const USoundWave* InWave)
: OldFormatName(InOldFormatName)
, Wave(MakeWeakObjectPtr(InWave))
{
}
bool HasError() const override;
bool IsEndOfStream() const override;
ICompressedAudioInfo* GetInfo(
FFormatDescriptorSection* OutDescriptor = nullptr) const;
bool FindSection(FEncodedSectionBase& OutSection) override;
int64 Tell() const override;
TArrayView<const uint8> PeekNextPacket(
int32 InMaxPacketLength) const override;
TArrayView<const uint8> PopNextPacket(
int32 InPacketSize) override;
};
}