Logo Search packages:      
Sourcecode: aften version File versions  Download package

pcmfile.h File Reference


Detailed Description

Aften: A/52 audio encoder Copyright (c) 2007 Justin Ruggles

This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA

raw PCM file i/o header

Definition in file pcmfile.h.

#include "common.h"
#include "byteio.h"
#include "formats.h"

Go to the source code of this file.

Classes

struct  PcmFile

Defines

#define PCM_MAX_CHANNELS   6
#define PCM_MAX_READ   240000
#define PCM_SEEK_CUR   1
#define PCM_SEEK_END   2
#define PCM_SEEK_SET   0
#define WAVE_FORMAT_EXTENSIBLE   0xFFFE
#define WAVE_FORMAT_IEEEFLOAT   0x0003
#define WAVE_FORMAT_PCM   0x0001

Enumerations

enum  PcmByteOrder { PCM_BYTE_ORDER_LE = 0, PCM_BYTE_ORDER_BE = 1 }
enum  PcmSampleFormat {
  PCM_SAMPLE_FMT_UNKNOWN = -1, PCM_SAMPLE_FMT_U8 = 0, PCM_SAMPLE_FMT_S8, PCM_SAMPLE_FMT_S16,
  PCM_SAMPLE_FMT_S20, PCM_SAMPLE_FMT_S24, PCM_SAMPLE_FMT_S32, PCM_SAMPLE_FMT_FLT,
  PCM_SAMPLE_FMT_DBL
}
enum  PcmSampleType { PCM_SAMPLE_TYPE_INT = 0, PCM_SAMPLE_TYPE_FLOAT }

Functions

int pcm_get_default_ch_mask (int channels)
void pcmfile_close (PcmFile *pf)
int pcmfile_init (PcmFile *pf, FILE *fp, enum PcmSampleFormat read_format, int file_format)
uint64_t pcmfile_position (PcmFile *pf)
uint64_t pcmfile_position_time_ms (PcmFile *pf)
void pcmfile_print (PcmFile *pf, FILE *st)
int pcmfile_read_samples (PcmFile *pf, void *buffer, int num_samples)
int pcmfile_seek_samples (PcmFile *pf, int64_t offset, int whence)
int pcmfile_seek_set (PcmFile *pf, uint64_t dest)
int pcmfile_seek_time_ms (PcmFile *pf, int64_t offset, int whence)
void pcmfile_set_read_format (PcmFile *pf, enum PcmSampleFormat read_format)
void pcmfile_set_source_format (PcmFile *pf, enum PcmSampleFormat fmt)
void pcmfile_set_source_params (PcmFile *pf, int ch, enum PcmSampleFormat fmt, int order, int sr)


Generated by  Doxygen 1.6.0   Back to index