ladybird/Libraries/LibMedia/Audio/PlaybackStream.cpp
Timothy Flynn dfa727a4d4 LibMedia: Remove preprocessor chain when initializing audio streams
Instead of having to duplicate the audio stream backend conditions, just
define PlaybackStream::create in each audio backend implementation file.
We provide a weak definition in PlaybackStream.cpp as the fallback.
2024-12-25 12:00:43 +01:00

16 lines
399 B
C++

/*
* Copyright (c) 2023, Gregory Bertilson <zaggy1024@gmail.com>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#include "PlaybackStream.h"
namespace Audio {
ErrorOr<NonnullRefPtr<PlaybackStream>> __attribute__((weak)) PlaybackStream::create(OutputState, u32, u8, u32, AudioDataRequestCallback&&)
{
return Error::from_string_literal("Audio output is not available for this platform");
}
}