Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ AChooseSour(3X) — HP-UX 9.10

Media Vault

Software Library

Restoration Projects

Artifacts Sought

AChooseSourceAttributes(3X)

NAME

AChooseSourceAttributes − select attributes to associate with an existing file or a stream

SYNOPSIS

#include <audio/Alib.h>
         <stdio.h> AFileFormat
AChooseSourceAttributes (

Audio * audio,

char * pathname,

FILE * audiofile,

AFileFormat file_format,

AudioAttrMask user_mask,

AudioAttributes * attributes,

long * offset,

long * data_length,

AByteOrder * byte_order,

long * status_return);

DESCRIPTION

AChooseSourceAttributes() selects attributes to associate with an existing file or a stream. 

audio specifies the Audio structure associated with this connection. 

pathname specifies the pathname of the audio file.  Ignored if audiofile is NULL. 

audiofile specifies the file pointer if the source is a file.  If the source is a stream, such as stdin, set audiofile to NULL.

file_format specifies the format of the file.  May be AFFUnknown. 

user_mask specifies which of the audio attributes in the attributes structure have been supplied by the user (mask bit set to 1).  These attributes will be checked for validity, but will not be changed. 

attributes contains user-supplied attributes (if any) as indicated by user_mask. AChooseSourceAttributes will write appropriate values to those attributes not supplied by the user. 

offset receives the location, in bytes, where the audio data begins. 

data_length receives the length, in bytes, of the audio data. 

byte_order receives the byte ordering of the data in the file. 

status_return receives the returned status of the operation, unless it is set to NULL. 

RETURN VALUE

Upon successful completion, AChooseSourceAttributes() returns the format of the file if the source is a file. If the source is a stream or the file format cannot be determined, AFFUnknown is returned. 

ERRORS

If status_return is not set to NULL, one of the following is returned in status_return:

0 AENoError

2 AEBadAudio

6 AEBadFileFormat

7 AEBadDataFormat

11 AEBadFileHdr

17 AEOutOfMemory

EXAMPLE

For an example, see /usr/audio/examples/splayer.c

DEPENDENCIES

This function belongs to the Audio Library of functions that manage connections to an audio server.  The audio server must run on a system that has audio hardware. To find out whether or not your system has audio hardware, refer to the hardware manual that accompanies your system. 

AUTHOR

AChooseSourceAttributes() was developed by HP. 

SEE ALSO

Using the Audio Application Program Interface.

Hewlett-Packard Company  —  HP-UX Release 9.10: April 1995

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026