Skip to main content
Module: LCKOboe | Version: 1.0 | Platforms: Android

Overview

LCKOboe provides low-latency microphone capture on Android using Google’s Oboe audio library. It is microphone-only; pair it with LCKFMOD or LCKWwise for game audio capture.

Supported Channels

ChannelSupportedDescription
GameNoUse LCKFMOD, LCKWwise, or LCKUnrealAudio
MicrophoneYesLow-latency Android mic via Oboe
VoiceChatNoUse LCKVivox

FLCKOboeSource

Audio source class that captures microphone input on Android through the Oboe library. Implements ILCKFeatureInstance.
class FLCKOboeSource : public ILCKFeatureInstance
{
public:
    // ILCKFeatureInstance interface
    virtual bool StartCapture() noexcept override;
    virtual bool StartCapture(TLCKAudioChannelsMask Channels) noexcept override;
    virtual void StopCapture() noexcept override;
    virtual float GetVolume() const noexcept override;
    virtual const FString& GetSourceName() const noexcept override;

protected:
    TLCKAudioChannelsMask SupportedChannels = ELCKAudioChannel::Microphone;
};

ILCKFeatureInstance Methods

MethodBehavior
StartCapture()Opens Oboe audio stream and begins microphone recording
StartCapture(Channels)Begins capture if Microphone is in the requested channel mask
StopCapture()Closes the Oboe stream and stops recording
GetVolume()Returns current RMS volume of microphone input (0.0-1.0)
GetSourceName()Returns "LCKOboe"
Android microphone capture requires the RECORD_AUDIO permission. Ensure your app requests this permission at runtime before calling StartCapture().

FLCKOboeModule

Module that manages the lifecycle of FLCKOboeSource.
class FLCKOboeModule : public IModuleInterface
{
public:
    virtual void StartupModule() override;
    virtual void ShutdownModule() override;

private:
    TSharedPtr<FLCKOboeSource> FeatureInstance;
};

IMPLEMENT_MODULE(FLCKOboeModule, LCKOboe)
On startup, the module creates an FLCKOboeSource and registers it as a modular feature. The module only loads on Android; it is excluded from other platforms at build time.

Log Category

DECLARE_LOG_CATEGORY_EXTERN(LogLCKOboe, Log, All);