Mercurial > hg > audiostuff
comparison spandsp-0.0.6pre17/src/spandsp/private/t38_non_ecm_buffer.h @ 4:26cd8f1ef0b1
import spandsp-0.0.6pre17
| author | Peter Meerwald <pmeerw@cosy.sbg.ac.at> |
|---|---|
| date | Fri, 25 Jun 2010 15:50:58 +0200 |
| parents | |
| children |
comparison
equal
deleted
inserted
replaced
| 3:c6c5a16ce2f2 | 4:26cd8f1ef0b1 |
|---|---|
| 1 /* | |
| 2 * SpanDSP - a series of DSP components for telephony | |
| 3 * | |
| 4 * private/t38_non_ecm_buffer.h - A rate adapting buffer for T.38 non-ECM image | |
| 5 * and TCF data | |
| 6 * | |
| 7 * Written by Steve Underwood <steveu@coppice.org> | |
| 8 * | |
| 9 * Copyright (C) 2005, 2006, 2007, 2008 Steve Underwood | |
| 10 * | |
| 11 * All rights reserved. | |
| 12 * | |
| 13 * This program is free software; you can redistribute it and/or modify | |
| 14 * it under the terms of the GNU Lesser General Public License version 2.1, | |
| 15 * as published by the Free Software Foundation. | |
| 16 * | |
| 17 * This program is distributed in the hope that it will be useful, | |
| 18 * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
| 19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
| 20 * GNU Lesser General Public License for more details. | |
| 21 * | |
| 22 * You should have received a copy of the GNU Lesser General Public | |
| 23 * License along with this program; if not, write to the Free Software | |
| 24 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | |
| 25 * | |
| 26 * $Id: t38_non_ecm_buffer.h,v 1.2.4.1 2009/12/19 06:43:28 steveu Exp $ | |
| 27 */ | |
| 28 | |
| 29 #if !defined(_SPANDSP_PRIVATE_T38_NON_ECM_BUFFER_H_) | |
| 30 #define _SPANDSP_PRIVATE_T38_NON_ECM_BUFFER_H_ | |
| 31 | |
| 32 /*! \brief A flow controlled non-ECM image data buffer, for buffering T.38 to analogue | |
| 33 modem data. | |
| 34 */ | |
| 35 struct t38_non_ecm_buffer_state_s | |
| 36 { | |
| 37 /*! \brief Minimum number of bits per row, used when fill bits are being deleted on the | |
| 38 link, and restored at the emitting gateway. */ | |
| 39 int min_bits_per_row; | |
| 40 | |
| 41 /*! \brief non-ECM modem transmit data buffer. */ | |
| 42 uint8_t data[T38_NON_ECM_TX_BUF_LEN]; | |
| 43 /*! \brief The current write point in the buffer. */ | |
| 44 int in_ptr; | |
| 45 /*! \brief The current read point in the buffer. */ | |
| 46 int out_ptr; | |
| 47 /*! \brief The location of the most recent EOL marker in the buffer. */ | |
| 48 int latest_eol_ptr; | |
| 49 /*! \brief The number of bits to date in the current row, used when min_row_bits is | |
| 50 to be applied. */ | |
| 51 int row_bits; | |
| 52 | |
| 53 /*! \brief The bit stream entering the buffer, used to detect EOLs */ | |
| 54 unsigned int bit_stream; | |
| 55 /*! \brief The non-ECM flow control fill octet (0xFF before the first data, and 0x00 | |
| 56 once data has started). */ | |
| 57 uint8_t flow_control_fill_octet; | |
| 58 /*! \brief A code for the phase of input buffering, from initial all ones to completion. */ | |
| 59 int input_phase; | |
| 60 /*! \brief TRUE is the end of non-ECM data indication has been received. */ | |
| 61 int data_finished; | |
| 62 /*! \brief The current octet being transmitted from the buffer. */ | |
| 63 unsigned int octet; | |
| 64 /*! \brief The current bit number in the current non-ECM octet. */ | |
| 65 int bit_no; | |
| 66 /*! \brief TRUE if in image data mode, as opposed to TCF mode. */ | |
| 67 int image_data_mode; | |
| 68 | |
| 69 /*! \brief The number of octets input to the buffer. */ | |
| 70 int in_octets; | |
| 71 /*! \brief The number of rows input to the buffer. */ | |
| 72 int in_rows; | |
| 73 /*! \brief The number of non-ECM fill octets generated for minimum row bits | |
| 74 purposes. */ | |
| 75 int min_row_bits_fill_octets; | |
| 76 /*! \brief The number of octets output from the buffer. */ | |
| 77 int out_octets; | |
| 78 /*! \brief The number of rows output from the buffer. */ | |
| 79 int out_rows; | |
| 80 /*! \brief The number of non-ECM fill octets generated for flow control | |
| 81 purposes. */ | |
| 82 int flow_control_fill_octets; | |
| 83 }; | |
| 84 | |
| 85 #endif | |
| 86 /*- End of file ------------------------------------------------------------*/ |
