[commit] r12294 - in freeswitch/trunk: . libs/spandsp/src libs/spandsp/src/msvc libs/spandsp/src/msvc/sys libs/spandsp/src/spandsp libs/spandsp/test-data/etsi/fax libs/spandsp/test-data/itu/fax
Author: mikej Date: Thu Feb 26 10:26:25 2009 New Revision: 12294 Log: update to snapshot spandsp-20090226 plus 2 typo fixes Modified: freeswitch/trunk/libs/spandsp/src/Makefile.am freeswitch/trunk/libs/spandsp/src/msvc/config.h freeswitch/trunk/libs/spandsp/src/msvc/inttypes.h freeswitch/trunk/libs/spandsp/src/msvc/spandsp.h freeswitch/trunk/libs/spandsp/src/msvc/sys/time.h freeswitch/trunk/libs/spandsp/src/spandsp/bit_operations.h freeswitch/trunk/libs/spandsp/src/spandsp/fast_convert.h freeswitch/trunk/libs/spandsp/src/spandsp/telephony.h freeswitch/trunk/libs/spandsp/src/spandsp/version.h freeswitch/trunk/libs/spandsp/src/t30.c freeswitch/trunk/libs/spandsp/test-data/etsi/fax/Makefile.am freeswitch/trunk/libs/spandsp/test-data/itu/fax/Makefile.am Changes in other areas also in this revision: Modified: freeswitch/trunk/ (props changed) Modified: freeswitch/trunk/libs/spandsp/src/Makefile.am ============================================================================== --- freeswitch/trunk/libs/spandsp/src/Makefile.am (original) +++ freeswitch/trunk/libs/spandsp/src/Makefile.am Thu Feb 26 10:26:25 2009 @@ -16,7 +16,7 @@ ## License along with this program; if not, write to the Free Software ## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. ## -## $Id: Makefile.am,v 1.126 2009/02/21 05:39:08 steveu Exp $ +## $Id: Makefile.am,v 1.127 2009/02/25 15:30:21 steveu Exp $ AM_CFLAGS = $(COMP_VENDOR_CFLAGS) AM_LDFLAGS = $(COMP_VENDOR_LDFLAGS) Modified: freeswitch/trunk/libs/spandsp/src/msvc/config.h ============================================================================== --- freeswitch/trunk/libs/spandsp/src/msvc/config.h (original) +++ freeswitch/trunk/libs/spandsp/src/msvc/config.h Thu Feb 26 10:26:25 2009 @@ -10,7 +10,7 @@ * * This file is released in the public domain. * - * $Id: config.h,v 1.3 2009/02/10 13:06:47 steveu Exp $ + * $Id: config.h,v 1.4 2009/02/25 15:30:21 steveu Exp $ */ #if !defined(_MSVC_CONFIG_H_) @@ -37,13 +37,10 @@ #define SPANDSP_USE_EXPORT_CAPABILITY 1 - #define PACKAGE "spandsp" #define VERSION "0.0.6" - - -// Win32/DevStudio compatibility stuff +/* Win32/DevStudio compatibility stuff */ #ifdef _MSC_VER @@ -83,5 +80,4 @@ #endif - #endif Modified: freeswitch/trunk/libs/spandsp/src/msvc/inttypes.h ============================================================================== --- freeswitch/trunk/libs/spandsp/src/msvc/inttypes.h (original) +++ freeswitch/trunk/libs/spandsp/src/msvc/inttypes.h Thu Feb 26 10:26:25 2009 @@ -19,7 +19,6 @@ extern "C" { #endif - typedef unsigned __int8 uint8_t; typedef unsigned __int16 uint16_t; typedef unsigned __int32 uint32_t; @@ -28,6 +27,7 @@ typedef __int16 int16_t; typedef __int32 int32_t; typedef __int64 int64_t; + #define INT16_MAX 0x7fff #define INT16_MIN (-INT16_MAX - 1) Modified: freeswitch/trunk/libs/spandsp/src/msvc/spandsp.h ============================================================================== --- freeswitch/trunk/libs/spandsp/src/msvc/spandsp.h (original) +++ freeswitch/trunk/libs/spandsp/src/msvc/spandsp.h Thu Feb 26 10:26:25 2009 @@ -33,14 +33,13 @@ #define __inline__ __inline #pragma warning(disable:4200) - #undef SPANDSP_USE_FIXED_POINT #undef SPANDSP_MISALIGNED_ACCESS_FAILS #define SPANDSP_USE_EXPORT_CAPABILITY 1 #include <stdlib.h> -#include <msvc\inttypes.h> +#include <msvc/inttypes.h> #include <string.h> #include <limits.h> #include <time.h> Modified: freeswitch/trunk/libs/spandsp/src/msvc/sys/time.h ============================================================================== --- freeswitch/trunk/libs/spandsp/src/msvc/sys/time.h (original) +++ freeswitch/trunk/libs/spandsp/src/msvc/sys/time.h Thu Feb 26 10:26:25 2009 @@ -12,9 +12,10 @@ * */ -struct timeval { - long tv_sec; - long tv_usec; -}; +struct timeval +{ + long int tv_sec; + long int tv_usec; +}; extern void gettimeofday(struct timeval *tv, void *tz); Modified: freeswitch/trunk/libs/spandsp/src/spandsp/bit_operations.h ============================================================================== --- freeswitch/trunk/libs/spandsp/src/spandsp/bit_operations.h (original) +++ freeswitch/trunk/libs/spandsp/src/spandsp/bit_operations.h Thu Feb 26 10:26:25 2009 @@ -22,7 +22,7 @@ * License along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: bit_operations.h,v 1.24 2009/01/31 08:48:11 steveu Exp $ + * $Id: bit_operations.h,v 1.25 2009/02/24 14:14:03 steveu Exp $ */ /*! \file */ @@ -56,13 +56,48 @@ : [res] "=&r" (res) : [bits] "r" (bits)); return 31 - res; -#elif defined(_M_IX86) // Visual Studio x86 +#elif defined(_M_IX86) + /* Visual Studio i386 */ __asm { xor eax, eax dec eax bsr eax, bits } +#elif defined(_M_X64) + /* Visual Studio x86_64 */ + /* TODO: Need the appropriate x86_64 code */ + int res; + + if (bits == 0) + return -1; + res = 0; + if (bits & 0xFFFF0000) + { + bits &= 0xFFFF0000; + res += 16; + } + if (bits & 0xFF00FF00) + { + bits &= 0xFF00FF00; + res += 8; + } + if (bits & 0xF0F0F0F0) + { + bits &= 0xF0F0F0F0; + res += 4; + } + if (bits & 0xCCCCCCCC) + { + bits &= 0xCCCCCCCC; + res += 2; + } + if (bits & 0xAAAAAAAA) + { + bits &= 0xAAAAAAAA; + res += 1; + } + return res; #else int res; Modified: freeswitch/trunk/libs/spandsp/src/spandsp/fast_convert.h ============================================================================== --- freeswitch/trunk/libs/spandsp/src/spandsp/fast_convert.h (original) +++ freeswitch/trunk/libs/spandsp/src/spandsp/fast_convert.h Thu Feb 26 10:26:25 2009 @@ -22,7 +22,7 @@ * License along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: fast_convert.h,v 1.4 2009/02/21 05:39:09 steveu Exp $ + * $Id: fast_convert.h,v 1.5 2009/02/24 14:14:03 steveu Exp $ */ #if !defined(_SPANDSP_FAST_CONVERT_H_) @@ -231,7 +231,8 @@ } #endif -#elif (defined(WIN32) || defined(_WIN32)) && !defined(_WIN64) +#elif defined(_M_IX86) + /* Visual Studio i386 */ /* * Win32 doesn't seem to have the lrint() and lrintf() functions. * Therefore implement inline versions of these functions here. @@ -301,28 +302,19 @@ }; return i; } -#elif defined(WIN64) || defined(_WIN64) +#elif defined(_M_X64) + /* Visual Studio x86_64 */ /* x86_64 machines will do best with a simple assignment. */ #include <intrin.h> __inline long int lrint(double x) { -#ifdef _M_X64 return (long int)_mm_cvtsd_si64x( _mm_loadu_pd ((const double*)&x) ); -#else -#warning "Not Supported: Replacing with a simple C cast." - return (long int) (x); -#endif } __inline long int lrintf(float x) { -#ifdef _M_X64 return _mm_cvt_ss2si( _mm_load_ss((const float*)&x) ); -#else -#warning "Not Supported: Replacing with a simple C cast." - return (long int) (x); -#endif } __inline long int lfastrint(double x) Modified: freeswitch/trunk/libs/spandsp/src/spandsp/telephony.h ============================================================================== --- freeswitch/trunk/libs/spandsp/src/spandsp/telephony.h (original) +++ freeswitch/trunk/libs/spandsp/src/spandsp/telephony.h Thu Feb 26 10:26:25 2009 @@ -22,13 +22,13 @@ * License along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: telephony.h,v 1.16 2009/02/03 16:28:41 steveu Exp $ + * $Id: telephony.h,v 1.17 2009/02/25 15:30:21 steveu Exp $ */ #if !defined(_SPANDSP_TELEPHONY_H_) #define _SPANDSP_TELEPHONY_H_ -#if defined(WIN32) +#if defined(_M_IX86) || defined(_M_X64) #if defined(LIBSPANDSP_EXPORTS) #define SPAN_DECLARE(type) __declspec(dllexport) type __stdcall #define SPAN_DECLARE_NONSTD(type) __declspec(dllexport) type __cdecl Modified: freeswitch/trunk/libs/spandsp/src/spandsp/version.h ============================================================================== --- freeswitch/trunk/libs/spandsp/src/spandsp/version.h (original) +++ freeswitch/trunk/libs/spandsp/src/spandsp/version.h Thu Feb 26 10:26:25 2009 @@ -30,8 +30,8 @@ /* The date and time of the version are in UTC form. */ -#define SPANDSP_RELEASE_DATE 20090221 -#define SPANDSP_RELEASE_TIME 054406 +#define SPANDSP_RELEASE_DATE 20090226 +#define SPANDSP_RELEASE_TIME 121601 #endif /*- End of file ------------------------------------------------------------*/ Modified: freeswitch/trunk/libs/spandsp/src/t30.c ============================================================================== --- freeswitch/trunk/libs/spandsp/src/t30.c (original) +++ freeswitch/trunk/libs/spandsp/src/t30.c Thu Feb 26 10:26:25 2009 @@ -22,7 +22,7 @@ * License along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: t30.c,v 1.286 2009/02/20 12:34:20 steveu Exp $ + * $Id: t30.c,v 1.288 2009/02/26 12:11:51 steveu Exp $ */ /*! \file */ @@ -5353,18 +5353,21 @@ The 2.55s maximum seems to limit signalling frames to no more than 95 octets, including FCS, and flag octets (assuming the use of V.21). */ - if (!ok && s->phase != T30_PHASE_C_ECM_RX) + if (!ok) { span_log(&s->logging, SPAN_LOG_FLOW, "Bad CRC received\n"); - /* We either force a resend, or we wait until a resend occurs through a timeout. */ - if ((s->supported_t30_features & T30_SUPPORT_COMMAND_REPEAT)) + if (s->phase != T30_PHASE_C_ECM_RX) { - s->step = 0; - if (s->phase == T30_PHASE_B_RX) - queue_phase(s, T30_PHASE_B_TX); - else - queue_phase(s, T30_PHASE_D_TX); - send_simple_frame(s, T30_CRP); + /* We either force a resend, or we wait until a resend occurs through a timeout. */ + if ((s->supported_t30_features & T30_SUPPORT_COMMAND_REPEAT)) + { + s->step = 0; + if (s->phase == T30_PHASE_B_RX) + queue_phase(s, T30_PHASE_B_TX); + else + queue_phase(s, T30_PHASE_D_TX); + send_simple_frame(s, T30_CRP); + } } return; } Modified: freeswitch/trunk/libs/spandsp/test-data/etsi/fax/Makefile.am ============================================================================== --- freeswitch/trunk/libs/spandsp/test-data/etsi/fax/Makefile.am (original) +++ freeswitch/trunk/libs/spandsp/test-data/etsi/fax/Makefile.am Thu Feb 26 10:26:25 2009 @@ -16,7 +16,7 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. ## -## $Id: Makefile.am,v 1.3 2009/02/20 12:34:20 steveu Exp $ +## $Id: Makefile.am,v 1.4 2009/02/25 17:52:51 steveu Exp $ AM_CFLAGS = $(COMP_VENDOR_CFLAGS) @@ -37,12 +37,16 @@ EXTRA_DIST = +MAINTAINERCLEANFILES = Makefile.in + +LIBDIR = -L$(top_builddir)/src + nobase_data_DATA = ${ETSI_TEST_PAGES} noinst_PROGRAMS = generate_etsi_300_242_pages generate_etsi_300_242_pages_SOURCES = generate_etsi_300_242_pages.c -generate_etsi_300_242_pages_LDADD = -lspandsp -ltiff +generate_etsi_300_242_pages_LDADD = $(LIBDIR) -lspandsp -ltiff clean: rm -f *.tif *.g3 Modified: freeswitch/trunk/libs/spandsp/test-data/itu/fax/Makefile.am ============================================================================== --- freeswitch/trunk/libs/spandsp/test-data/itu/fax/Makefile.am (original) +++ freeswitch/trunk/libs/spandsp/test-data/itu/fax/Makefile.am Thu Feb 26 10:26:25 2009 @@ -16,7 +16,7 @@ ## License along with this program; if not, write to the Free Software ## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. ## -## $Id: Makefile.am,v 1.4 2009/02/20 12:34:20 steveu Exp $ +## $Id: Makefile.am,v 1.5 2009/02/25 17:52:52 steveu Exp $ AM_CFLAGS = $(COMP_VENDOR_CFLAGS) AM_LDFLAGS = $(COMP_VENDOR_LDFLAGS) @@ -97,6 +97,8 @@ EXTRA_DIST = ${ITU_TEST_PAGES_PBM} +MAINTAINERCLEANFILES = Makefile.in + nobase_data_DATA = itutests.tif \ ${ITU_TEST_PAGES} \ dithered.tif \
participants (1)
-
FreeSWITCH SVN