Module: LCKUnrealAudio | Version: 0.9.2 | Platforms: All
Overview
LCKUnrealAudio provides native Unreal Engine audio capture, supporting both game audio output and microphone input using Unreal’s built-in audio systems.
Supported Channels
| Channel | Supported | Description |
|---|
Game | Yes | Unreal Audio submix capture |
Microphone | Yes | Unreal Audio microphone capture |
VoiceChat | No | Use LCKVivox for voice chat |
Dependencies
// Add to your .Build.cs
PublicDependencyModuleNames.AddRange(new string[] {
"LCKUnrealAudio",
"LCKAudio"
});
Automatic Integration
The plugin automatically registers itself with the LCK audio system when the module loads. No manual initialization is required.
Blueprint Functions
Returns the current Unreal Audio sample rate.UFUNCTION(BlueprintPure, Category = "LCK Audio")
static int32 GetUnrealAudioSamplerate();
Usage
#include "LCKUnrealAudioBPL.h"
// Get sample rate for encoder configuration
int32 SampleRate = ULCKUnrealAudioBPL::GetUnrealAudioSamplerate();
// Configure encoder with matching rate
FLCKRecorderParams Params;
Params.Samplerate = SampleRate;
Source Implementation
class FLCKUnrealAudioSource : public ILCKAudioSource
{
public:
FLCKUnrealAudioSource();
~FLCKUnrealAudioSource();
bool StartCapture() noexcept override;
bool StartCapture(TLCKAudioChannelsMask Channels) noexcept override;
void StopCapture() noexcept override;
const FString& GetSourceName() const noexcept override;
float GetVolume() const noexcept override;
private:
TUniquePtr<Audio::FAudioCapture> MicrophoneCapture;
TSharedPtr<FLCKUnrealAudioListener, ESPMode::ThreadSafe> GameAudioListener;
bool bIsMicrophoneCapturing = false;
int32 Samplerate = 48000;
int32 ChannelsCount = 1;
};
Configuration
Project Settings
Ensure audio capture is enabled in your project settings:
- Edit > Project Settings > Platforms > Windows/Android
- Enable “Audio Capture” in the Audio section
Submix Setup
For game audio capture, the plugin hooks into Unreal’s master submix. No additional configuration is needed for default behavior.
For custom submix routing, create a custom submix and route game audio through it, then configure the plugin to capture from that submix.
Microphone Permissions
Windows
No special permissions required. Microphone access is granted at the OS level.
Android
Add to your AndroidManifest.xml:
<uses-permission android:name="android.permission.RECORD_AUDIO"/>
On Android, consider using LCKOboe for lower latency microphone capture instead of LCKUnrealAudio.
Log Category
DECLARE_LOG_CATEGORY_EXTERN(LogLCKUnrealAudio, Log, All);
See Also