AUMAKEELEMENTIMPORTDEVICE(3nas)
β¨ NAME β¨
AuMakeElementImportDevice β bestie, this is the one that initializes an ImportDevice element π (and yes, it's a page from the Library Functions Manual, we're fancy like that)
π SYNOPSIS π
#include <audio/audiolib.h>
AuMakeElementImportDevice(element, sample_rate, device, num_samples,
num_actions, actions)
AuElement *element; /* RETURN */
unsigned short sample_rate;
AuDeviceID device;
AuUint32 num_samples;
int num_actions;
AuElementAction *actions;
πΈ ARGUMENTS πΈ
elementβ the glow-up happens here, bestie. It returns the initialized element. Main character energy: it's aRETURNvalue, so that's where the finished product lands πsample_rateβ the sample rate of the audio data. That's it, that's the vibe.deviceβ the ID of the device we're reading the audio data from. Like, which device are we pulling from, not pushing to. Important distinction, iykyk.num_samplesβ how many samples to read from the device. And listen: if you want unlimited samples, you passAuUnlimitedSamples. No cap, literally unlimited π¦num_actionsβ the number of actions sitting inactions.actionsβ the list of actions to associate with this element. You can init the entries in this list withAuMakeChangeStateAction,AuMakeSendNotifyAction, andAuMakeNoopAction. Also, it may beNULLβ so it's optional, she's flexible β¨
π DESCRIPTION π
Okay so here's the tea, bestie β
AuMakeElementImportDevice sets the type member of element to AuElementTypeImportDevice, and then initializes the importdevice member of element using the remaining arguments. Two members, one function call, she's efficient like that π
Heads up: AuMakeElementImportDevice is implemented as a macro. So don't come for her expecting a real function, that's just the way she is π
π SEE ALSO π
Squad goals, here's the whole friend group:
AuMakeElementAddConstantAuMakeElementBundleAuMakeElementExportBucketAuMakeElementExportClientAuMakeElementExportDeviceAuMakeElementExportMonitorAuMakeElementImportBucketAuMakeElementImportClientAuMakeElementImportWaveFormAuMakeElementMultiplyConstantAuMakeElementSum
And the mothership herself:
audiolibβ Network Audio System C Language Interface π
okay that's the whole page, you ate it, go build something iconic π«Ά
signing off from the audiolib - element initialization corner of the manual, version 1.9.4 β mwah πβ¨
π¦ where this page comes from
- debian bookworm: libaudio-dev 1.9.4-7
- debian trixie: libaudio-dev 1.9.4-9
- ubuntu jammy: libaudio-dev 1.9.4-7build1
- ubuntu noble: libaudio-dev 1.9.4-8
- ubuntu questing: libaudio-dev 1.9.4-9
- ubuntu resolute: libaudio-dev 1.9.4-9.2
- ubuntu stonking: libaudio-dev 1.9.4-9.2
- copyright 1994 Steven King
- Copyright 1993 Network Computing Devices, Inc
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms