brintos

brintos / linux-shallow public Read only

0
0
Text · 2.7 KiB · 77fb866 Raw
87 lines · c
1/* SPDX-License-Identifier: LGPL-2.1+ WITH Linux-syscall-note */2/*3 * audio.h - DEPRECATED MPEG-TS audio decoder API4 *5 * NOTE: should not be used on future drivers6 *7 * Copyright (C) 2000 Ralph  Metzler <ralph@convergence.de>8 *                  & Marcus Metzler <marcus@convergence.de>9 *                    for convergence integrated media GmbH10 */11 12#ifndef _DVBAUDIO_H_13#define _DVBAUDIO_H_14 15#include <linux/types.h>16 17typedef enum {18	AUDIO_SOURCE_DEMUX, /* Select the demux as the main source */19	AUDIO_SOURCE_MEMORY /* Select internal memory as the main source */20} audio_stream_source_t;21 22 23typedef enum {24	AUDIO_STOPPED,      /* Device is stopped */25	AUDIO_PLAYING,      /* Device is currently playing */26	AUDIO_PAUSED        /* Device is paused */27} audio_play_state_t;28 29 30typedef enum {31	AUDIO_STEREO,32	AUDIO_MONO_LEFT,33	AUDIO_MONO_RIGHT,34	AUDIO_MONO,35	AUDIO_STEREO_SWAPPED36} audio_channel_select_t;37 38 39typedef struct audio_mixer {40	unsigned int volume_left;41	unsigned int volume_right;42  /* what else do we need? bass, pass-through, ... */43} audio_mixer_t;44 45 46typedef struct audio_status {47	int                    AV_sync_state;  /* sync audio and video? */48	int                    mute_state;     /* audio is muted */49	audio_play_state_t     play_state;     /* current playback state */50	audio_stream_source_t  stream_source;  /* current stream source */51	audio_channel_select_t channel_select; /* currently selected channel */52	int                    bypass_mode;    /* pass on audio data to */53	audio_mixer_t	       mixer_state;    /* current mixer state */54} audio_status_t;                              /* separate decoder hardware */55 56 57/* for GET_CAPABILITIES and SET_FORMAT, the latter should only set one bit */58#define AUDIO_CAP_DTS    159#define AUDIO_CAP_LPCM   260#define AUDIO_CAP_MP1    461#define AUDIO_CAP_MP2    862#define AUDIO_CAP_MP3   1663#define AUDIO_CAP_AAC   3264#define AUDIO_CAP_OGG   6465#define AUDIO_CAP_SDDS 12866#define AUDIO_CAP_AC3  25667 68#define AUDIO_STOP                 _IO('o', 1)69#define AUDIO_PLAY                 _IO('o', 2)70#define AUDIO_PAUSE                _IO('o', 3)71#define AUDIO_CONTINUE             _IO('o', 4)72#define AUDIO_SELECT_SOURCE        _IO('o', 5)73#define AUDIO_SET_MUTE             _IO('o', 6)74#define AUDIO_SET_AV_SYNC          _IO('o', 7)75#define AUDIO_SET_BYPASS_MODE      _IO('o', 8)76#define AUDIO_CHANNEL_SELECT       _IO('o', 9)77#define AUDIO_GET_STATUS           _IOR('o', 10, audio_status_t)78 79#define AUDIO_GET_CAPABILITIES     _IOR('o', 11, unsigned int)80#define AUDIO_CLEAR_BUFFER         _IO('o',  12)81#define AUDIO_SET_ID               _IO('o', 13)82#define AUDIO_SET_MIXER            _IOW('o', 14, audio_mixer_t)83#define AUDIO_SET_STREAMTYPE       _IO('o', 15)84#define AUDIO_BILINGUAL_CHANNEL_SELECT _IO('o', 20)85 86#endif /* _DVBAUDIO_H_ */87