AuSoundRecordToFile(3)
π AuSoundRecordToFile(3) π
okay bestie, welcome to the Library Functions Manual section, we're talking AuSoundRecordToFile today and honestly? she's a baddie. π
β¨ Name β¨
AuSoundRecordToFile β create a flow to record to a file. that's it, that's the whole vibe, she makes flows and she writes files. π
πΈ Synopsis πΈ
#include <audio/audiolib.h>
#include <audio/soundlib.h>
AuEventHandlerRec *AuSoundRecordToFile(server, filename, source, gain,
callback, callback_data, mode, file_format, comment, rate, data_format,
flow, volume_mult_elem, status)
AuServer *server;
char *filename;
AuDeviceID source;
AuFixedPoint gain;
void (*callback) (AuServer *, AuEventHandlerRec *, AuEvent *,
AuPointer);
AuPointer callback_data;
int mode;
int file_format;
char *comment;
AuUint32 rate;
int data_format;
AuFlowID *flow; /* RETURN */
int *volume_mult_elem; /* RETURN */
AuStatus *status; /* RETURN */
look at that signature. thirteen arguments. she's high maintenance but she's worth it. π«Ά
π¦ Arguments π¦
serverβ the connection to the audio server. your whole link to the audio world, no server no party. πfilenameβ the name of the file you're recording into. yes, literally just the filename. iconic behavior.sourceβ which input device to use. pick your fave.gainβ the gain for the input device. turn it up, turn it down, you do you.callbackβ the procedure that gets called for any extra event processing. your little helper on standby.callback_dataβ any extra arguments you want passed along to that callback. snack for the helper. πmodeβ the line mode for the input device. currently these line modes are defined:AuDeviceInputModeNone,AuDeviceInputModeLineIn,AuDeviceInputModeMicrophone. microphone mode is giving main character energy fr. π€file_formatβ the file format. currently supported:SoundFileFormatSnd,SoundFileFormatVoc,SoundFileFormatWave,SoundFileFormatAiff,SoundFileFormatSvx. five formats, all valid, all slaying. β¨commentβ a comment to be embedded in the file. like a little note in a locker, but for audio metadata. πrateβ the sample rate to record at. numbers, we love her.data_formatβ the data format. currently these are defined:AuFormatULAW8,AuFormatLinearUnsigned8,AuFormatLinearSigned8,AuFormatLinearSigned16MSB,AuFormatLinearUnsigned16MSB,AuFormatSignedLinear16LSB, andAuFormatLinearUnsigned16LSB. seven of them, count 'em. πflowβ if it's non-NULL, it returns the flow ID. (RETURNbtw)volume_mult_elemβ according to the comment in the source, this is not implemented. not me getting a parameter that literally does nothing π ngl that's kind of a mood though. (RETURN)statusβ if it's non-NULL, it flushes the output buffer and returns the status from the server. (RETURN)
π Description π
AuSoundRecordToFile creates a flow to record from source to filename, and it returns a pointer to the event handler it created. if something went wrong? you get NULL. no cap.
π Errors π
AuBadDevice.
that's the one. the whole list. she's concise. π
π₯ See Also π₯
AuSoundRecordAuSoundRecordToBucketAuSoundRecordToDataAuSoundRecordToFileNaudiolibβ Network Audio System C Language Interface
lowkey the whole friend group is here. go read them too, bestie. π§
and that's the page!! this came from soundlib, version 1.9.5, dated AuSoundRecordToFile(3) β so yeah, you're getting the classic. stay slay, go record some audio, and remember: flush your buffers. πβ¨π
π¦ where this page comes from
- fedora 43: nas-devel 1.9.5-11.fc41 Β· MIT
- fedora 43: nas-devel 1.9.5-11.fc41 Β· MIT
- fedora 43: nas-devel 1.9.5-14.fc43 Β· MIT
- fedora 43: nas-devel 1.9.5-14.fc43 Β· MIT
- fedora 44: nas-devel 1.9.5-15.fc44 Β· MIT
- fedora 44: nas-devel 1.9.5-15.fc44 Β· MIT
- 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