home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD1.iso / GFX / MPEG / mpeg3play.lha / mpeg3play / src / common.h < prev    next >
Encoding:
C/C++ Source or Header  |  1997-02-11  |  20.1 KB  |  600 lines

  1. /**********************************************************************
  2.  * ISO MPEG Audio Subgroup Software Simulation Group (1996)
  3.  * ISO 13818-3 MPEG-2 Audio Decoder - Lower Sampling Frequency Extension
  4.  *
  5.  * $Id: common.h,v 1.3 1996/03/28 03:13:37 rowlands Exp $
  6.  *
  7.  * $Log: common.h,v $
  8.  * Revision 1.3  1996/03/28 03:13:37  rowlands
  9.  * Merged layers 1-2 and layer 3 revisions
  10.  *
  11.  * Revision 1.2  1996/02/14 05:18:36  rowlands
  12.  * Cleanups.
  13.  *
  14.  * Revision 1.1  1996/02/14 03:45:52  rowlands
  15.  * Initial revision
  16.  *
  17.  * Received from FhG
  18.  **********************************************************************/
  19. /**********************************************************************
  20.  *   date   programmers         comment                               *
  21.  * 2/25/91  Doulas Wong,        start of version 1.0 records          *
  22.  *          Davis Pan                                                 *
  23.  * 5/10/91  W. Joseph Carter    Reorganized & renamed all ".h" files  *
  24.  *                              into "common.h" and "encoder.h".      *
  25.  *                              Ported to Macintosh and Unix.         *
  26.  *                              Added additional type definitions for *
  27.  *                              AIFF, double/SANE and "bitstream.c".  *
  28.  *                              Added function prototypes for more    *
  29.  *                              rigorous type checking.               *
  30.  * 27jun91  dpwe (Aware)        Added "alloc_*" defs & prototypes     *
  31.  *                              Defined new struct 'frame_params'.    *
  32.  *                              Changed info.stereo to info.mode_ext  *
  33.  *                              #define constants for mode types      *
  34.  *                              Prototype arguments if PROTO_ARGS     *
  35.  * 5/28/91  Earle Jennings      added MS_DOS definition               *
  36.  *                              MsDos function prototype declarations *
  37.  * 7/10/91  Earle Jennings      added FLOAT definition as double      *
  38.  *10/ 3/91  Don H. Lee          implemented CRC-16 error protection   *
  39.  * 2/11/92  W. Joseph Carter    Ported new code to Macintosh.  Most   *
  40.  *                              important fixes involved changing     *
  41.  *                              16-bit ints to long or unsigned in    *
  42.  *                              bit alloc routines for quant of 65535 *
  43.  *                              and passing proper function args.     *
  44.  *                              Removed "Other Joint Stereo" option   *
  45.  *                              and made bitrate be total channel     *
  46.  *                              bitrate, irrespective of the mode.    *
  47.  *                              Fixed many small bugs & reorganized.  *
  48.  *                              Modified some function prototypes.    *
  49.  *                              Changed BUFFER_SIZE back to 4096.     *
  50.  * 7/27/92  Michael Li          (re-)Ported to MS-DOS                 *
  51.  * 7/27/92  Masahiro Iwadare    Ported to Convex                      *
  52.  * 8/07/92  mc@tv.tek.com                                             *
  53.  * 8/10/92  Amit Gulati         Ported to the AIX Platform (RS6000)   *
  54.  *                              AIFF string constants redefined       *
  55.  * 8/27/93 Seymour Shlien,      Fixes in Unix and MSDOS ports,        *
  56.  *         Daniel Lauzon, and                                         *
  57.  *         Bill Truerniet                                             *
  58.  *--------------------------------------------------------------------*
  59.  * 4/23/92  J. Pineda           Added code for Layer III.             *
  60.  * 11/9/92  Amit Gulati         Added defines for layerIII stereo     *
  61.  *                              modes.                                *
  62.  *  8/24/93 Masahiro Iwadare    Included IS modification in Layer III.*
  63.  *                              Changed for 1 pass decoding.          *
  64.  *  9/07/93 Toshiyuki Ishino    Integrated Layer III with Ver 3.9.    *
  65.  *--------------------------------------------------------------------*
  66.  * 11/20/93 Masahiro Iwadare    Integrated Layer III with Ver 4.0.    *
  67.  *--------------------------------------------------------------------*
  68.  *  7/14/94 Juergen Koller      Fix for HPUX an IRIX in AIFF-Strings  *
  69.  *--------------------------------------------------------------------*
  70.  *  6/12/95 Soeren H. Nielsen   Bug fix in new_ext().                 *
  71.  *  7/11/95 Soeren H. Nielsen   Added defs. for MPEG-2 LSF            *
  72.  *--------------------------------------------------------------------*
  73.  *          Roland Bitto    Adapted to MPEG2 low sampling rate    *
  74.  *--------------------------------------------------------------------*
  75.  * 12/16/96 Johan Hagman    Adapted for Solaris (mpeg3play 0.9)   *
  76.  **********************************************************************/
  77.  
  78. #ifndef COMMON_H
  79. #define COMMON_H
  80.  
  81. /***********************************************************************
  82. *
  83. *  Global Conditional Compile Switches
  84. *
  85. ***********************************************************************/
  86.  
  87. /* #define    UNIX        Unix conditional compile switch */
  88. /* #define    MACINTOSH    Macintosh conditional compile switch */
  89. /* #define    MS_DOS        IBM PC conditional compile switch */
  90. /* #define    MSC60        Compiled for MS_DOS with MSC v6.0 */
  91. /* #define    AIX        AIX conditional compile switch    */
  92. /* #define    CONVEX        CONVEX conditional compile switch */
  93. /* #define    SOLARIS        Solaris conditional compile switch */
  94.  
  95. #if defined(MSC60) 
  96. #ifndef MS_DOS
  97. #define MS_DOS
  98. #endif
  99. #ifndef PROTO_ARGS
  100. #define PROTO_ARGS
  101. #endif
  102. #endif
  103.  
  104. #ifdef  UNIX
  105. #define         TABLES_PATH     "tables"  /* to find data files */
  106. /* name of environment variable holding path of table files */
  107. #define         MPEGTABENV      "MPEGTABLES"
  108. #define         PATH_SEPARATOR  "/"        /* how to build paths */
  109. #endif  /* UNIX */
  110.  
  111. #ifdef  MACINTOSH
  112. #define      TABLES_PATH ":tables:"  /* where to find data files */
  113. #endif  /* MACINTOSH */
  114.  
  115. /* 
  116.  * Don't define FAR to far unless you're willing to clean up the 
  117.  * prototypes
  118.  */
  119. #define FAR /*far*/
  120.  
  121. #ifdef __STDC__
  122. #ifndef PROTO_ARGS
  123. #define PROTO_ARGS 
  124. #endif
  125. #endif
  126.  
  127. #ifdef CONVEX
  128. #define SEEK_SET        0
  129. #define SEEK_CUR        1
  130. #define SEEK_END        2
  131. #endif
  132.  
  133. /* MS_DOS and VMS do not define TABLES_PATH, so OpenTableFile will default
  134.    to finding the data files in the default directory */
  135.  
  136. /***********************************************************************
  137. *
  138. *  Global Include Files
  139. *
  140. ***********************************************************************/
  141.  
  142. #include        <stdio.h>
  143. #include        <string.h>
  144. #include        <math.h>
  145. #include "ieeefloat.h"
  146. #include "portableio.h"
  147.  
  148. #ifdef  UNIX
  149. #include        <unistd.h>
  150. #endif  /* UNIX */
  151.  
  152. #ifdef SOLARIS
  153. # include    <stdlib.h>
  154. # include    <fcntl.h>
  155. # include    <sys/file.h>
  156. # include    <multimedia/libaudio.h>
  157. # include    <prof.h>
  158. #endif
  159.  
  160. #ifdef LINUX
  161.     #include <sys/types.h>
  162.     #include <sys/stat.h>
  163.     #include <fcntl.h>
  164.     #include <sys/ioctl.h>
  165.     #include <sys/soundcard.h>
  166. #endif
  167.  
  168. #ifdef HPUX
  169. #include<sys/audio.h>
  170. #include<sys/ioctl.h>
  171. #include<sys/fcntl.h>
  172. #endif
  173.  
  174. #ifdef __sgi
  175. #include    <stdlib.h>
  176. #endif
  177.  
  178. #ifdef  MACINTOSH
  179. #include        <stdlib.h>
  180. #include        <console.h>
  181. #endif  /* MACINTOSH */
  182.  
  183. #ifdef  MS_DOS
  184. #include        <stdlib.h>
  185. #ifdef MSC60
  186. #include        <memory.h>
  187. #else
  188. #include        <alloc.h>
  189. #include        <mem.h>
  190. #endif  /* MSC60 */
  191. #endif  /* MS_DOS */
  192.  
  193. /***********************************************************************
  194. *
  195. *  Global Definitions
  196. *
  197. ***********************************************************************/
  198.  
  199. /* General Definitions */
  200.  
  201. #ifdef  MS_DOS
  202. #define         FLOAT                   double
  203. #else
  204. #define         FLOAT                   float
  205. #endif
  206.  
  207. #ifndef FALSE
  208. # define    FALSE                   0
  209. #endif
  210. #ifndef TRUE
  211. # define    TRUE                    1
  212. #endif
  213. #define         NULL_CHAR               '\0'
  214.  
  215. #define         MAX_U_32_NUM            0xFFFFFFFF
  216. #ifndef PI
  217. #define         PI                      3.14159265358979
  218. #endif
  219.  
  220. //#define    PI4            PI/4
  221. //#define    PI64            PI/64
  222. #define     PI4            0.78539816339744
  223. #define     PI12            0.261799388
  224. #define     PI36            0.087266463
  225. #define     PI64            0.049087385
  226. #define     LN_TO_LOG10        0.2302585093
  227.  
  228. #define         VOL_REF_NUM             0
  229. #define         MAC_WINDOW_SIZE         24
  230.  
  231. #define         MONO                    1
  232. #define         STEREO                  2
  233. #define         BITS_IN_A_BYTE          8
  234. #define         WORD                    16
  235. #define         MAX_NAME_SIZE           81
  236. #define         SBLIMIT                 32
  237. #define         SSLIMIT                 18
  238. #define         FFT_SIZE                1024
  239. #define         HAN_SIZE                512
  240. #define         SCALE_BLOCK             12
  241. #define         SCALE_RANGE             64
  242. #define         SCALE                   32767 //32768
  243. #define         CRC16_POLYNOMIAL        0x8005
  244.  
  245. /* MPEG Header Definitions - ID Bit Values */
  246. #define         MPEG_AUDIO_ID           1
  247. #define        MPEG_PHASE2_LSF        0    /* 1995-07-11 SHN */
  248.  
  249. /* MPEG Header Definitions - Mode Values */
  250.  
  251. #define         MPG_MD_STEREO           0
  252. #define         MPG_MD_JOINT_STEREO     1
  253. #define         MPG_MD_DUAL_CHANNEL     2
  254. #define         MPG_MD_MONO             3
  255.  
  256. /* Mode Extention */
  257.  
  258. #define         MPG_MD_LR_LR             0
  259. #define         MPG_MD_LR_I              1
  260. #define         MPG_MD_MS_LR             2
  261. #define         MPG_MD_MS_I              3
  262.  
  263. /* AIFF Definitions */
  264.  
  265. #define IFF_ID_FORM 0x464f524d /* "FORM" */
  266. #define IFF_ID_AIFF 0x41494646 /* "AIFF" */
  267. #define IFF_ID_COMM 0x434f4d4d /* "COMM" */
  268. #define IFF_ID_SSND 0x53534e44 /* "SSND" */
  269. #define IFF_ID_MPEG 0x4d504547 /* "MPEG" */
  270.  
  271. #define AIFF_FORM_HEADER_SIZE 12
  272. #define AIFF_SSND_HEADER_SIZE 16
  273.  
  274.  
  275. typedef struct  blockAlign_struct {
  276.     unsigned long   offset;
  277.     unsigned long   blockSize;
  278. } blockAlign;
  279.  
  280. typedef struct  IFF_AIFF_struct {
  281.     short           numChannels;
  282.     unsigned long   numSampleFrames;
  283.     short           sampleSize;
  284.     double          sampleRate;
  285.     unsigned long   sampleType;
  286.     blockAlign      blkAlgn;
  287. } IFF_AIFF;
  288.  
  289. enum byte_order { order_unknown, order_bigEndian, order_littleEndian };
  290. extern enum byte_order NativeByteOrder;
  291.  
  292. /* "bit_stream.h" Definitions */
  293.  
  294. #define         MINIMUM         4    /* Minimum size of the buffer in bytes */
  295. #define         MAX_LENGTH      32   /* Maximum length of word written or
  296.                                         read from bit stream */
  297. #define         READ_MODE       0
  298. #define         WRITE_MODE      1
  299. #define         ALIGNING        8
  300. #define         BINARY          0
  301. #define         ASCII           1
  302. #ifndef BS_FORMAT
  303. #define         BS_FORMAT       ASCII /* BINARY or ASCII = 2x bytes */
  304. #endif
  305. #define         BUFFER_SIZE     4096
  306.  
  307. #define         MIN(A, B)       ((A) < (B) ? (A) : (B))
  308. #define         MAX(A, B)       ((A) > (B) ? (A) : (B))
  309.  
  310. // Select float or double precision
  311. #ifdef FSINGLE
  312. # define    REAL        float
  313. #else
  314. # define    REAL        double
  315. #endif
  316.  
  317. /***********************************************************************
  318. *
  319. *  Global Type Definitions
  320. *
  321. ***********************************************************************/
  322. typedef struct {
  323.     char    encoded_file_name[MAX_NAME_SIZE];
  324.     char    decoded_file_name[MAX_NAME_SIZE];
  325.     int  need_aiff;
  326.     int  need_esps;
  327.     int  write_to_file;
  328.     int  topSb;
  329.     // Added Johan H
  330.     int  verbose;
  331.     int  forkoff;
  332. } Arguments_t;
  333.  
  334. /* Structure for Reading Layer II Allocation Tables from File */
  335.  
  336. typedef struct {
  337.     unsigned int    steps;
  338.     unsigned int    bits;
  339.     unsigned int    group;
  340.     unsigned int    quant;
  341. } sb_alloc, *alloc_ptr;
  342.  
  343. typedef sb_alloc        al_table[SBLIMIT][16];
  344.  
  345. /* Header Information Structure */
  346.  
  347. typedef struct {
  348.     int version;
  349.     int lay;
  350.     int error_protection;
  351.     int bitrate_index;
  352.     int sampling_frequency;
  353.     int padding;
  354.     int extension;
  355.     int mode;
  356.     int mode_ext;
  357.     int copyright;
  358.     int original;
  359.     int emphasis;
  360. } layer, *the_layer;
  361.  
  362. /* Parent Structure Interpreting some Frame Parameters in Header */
  363.  
  364. typedef struct {
  365.     layer       *header;        /* raw header information */
  366.     int         actual_mode;    /* when writing IS, may forget if 0 chs */
  367.     al_table    *alloc;         /* bit allocation table read in */
  368.     int         tab_num;        /* number of table as loaded */
  369.     int         stereo;         /* 1 for mono, 2 for stereo */
  370.     int         jsbound;        /* first band of joint stereo coding */
  371.     int         sblimit;        /* total number of sub bands */
  372. } frame_params;
  373.  
  374. /* Double and SANE Floating Point Type Definitions */
  375.  
  376. typedef struct  IEEE_DBL_struct {
  377.     unsigned long   hi;
  378.     unsigned long   lo;
  379. } IEEE_DBL;
  380.  
  381. typedef struct  SANE_EXT_struct {
  382.     unsigned long   l1;
  383.     unsigned long   l2;
  384.     unsigned short  s1;
  385. } SANE_EXT;
  386.  
  387.  
  388. /* "bit_stream.h" Type Definitions */
  389.  
  390. typedef struct  bit_stream_struc {
  391.     FILE        *pt;            /* pointer to bit stream device */
  392.     unsigned char *buf;         /* bit stream buffer */
  393.     int         buf_size;       /* size of buffer (in number of bytes) */
  394.     long        totbit;         /* bit counter of bit stream */
  395.     int         buf_byte_idx;   /* pointer to top byte in buffer */
  396.     int         buf_bit_idx;    /* pointer to top bit of top byte in buffer */
  397.     int         mode;           /* bit stream open in read or write mode */
  398.     int         eob;            /* end of buffer index */
  399.     int         eobs;           /* end of bit stream flag */
  400.     char        format;
  401.     
  402.     /* format of file in rd mode (BINARY/ASCII) */
  403. } Bit_stream_struc;
  404.  
  405. /* Layer III side information. */
  406. typedef struct {
  407.     unsigned part2_3_length;
  408.     unsigned big_values;
  409.     unsigned global_gain;
  410.     unsigned scalefac_compress;
  411.     unsigned window_switching_flag;
  412.     unsigned block_type;
  413.     unsigned mixed_block_flag;
  414.     unsigned table_select[3];
  415.     unsigned subblock_gain[3];
  416.     unsigned region0_count;
  417.     unsigned region1_count;
  418.     unsigned preflag;
  419.     unsigned scalefac_scale;
  420.     unsigned count1table_select;
  421. } my_gr_info ;
  422.  
  423. typedef struct {
  424.     unsigned main_data_begin;
  425.     unsigned private_bits;
  426.     struct {
  427.         unsigned scfsi[4];
  428.         struct gr_info_s {
  429.             unsigned part2_3_length;
  430.             unsigned big_values;
  431.             unsigned global_gain;
  432.             unsigned scalefac_compress;
  433.             unsigned window_switching_flag;
  434.             unsigned block_type;
  435.             unsigned mixed_block_flag;
  436.             unsigned table_select[3];
  437.             unsigned subblock_gain[3];
  438.             unsigned region0_count;
  439.             unsigned region1_count;
  440.             unsigned preflag;
  441.             unsigned scalefac_scale;
  442.             unsigned count1table_select;
  443.             } gr[2];
  444.         } ch[2];
  445.     } III_side_info_t;
  446.  
  447. /* Layer III scale factors. */
  448.  
  449. typedef struct {
  450.     int l[23];            /* [cb] */
  451.     int s[3][13];         /* [window][cb] */
  452.     } III_scalefac_t[2];  /* [ch] */
  453.  
  454. /***********************************************************************
  455. *
  456. *  Global Variable External Declarations
  457. *
  458. ***********************************************************************/
  459.  
  460. extern char     *mode_names[5];
  461. extern char     *layer_names[3];
  462. extern char    *version_names[2];
  463. extern double   s_freq[2][4];
  464. extern int      bitrate[2][3][15];
  465. extern REAL FAR multiple[64];
  466.  
  467. /***********************************************************************
  468. *
  469. *  Global Function Prototype Declarations
  470. *
  471. ***********************************************************************/
  472.  
  473. /* The following functions are in the file "common.c" */
  474.  
  475. #ifdef  PROTO_ARGS
  476. extern FILE           *OpenTableFile(char*);
  477. extern int            read_bit_alloc(int, al_table*);
  478. extern int            pick_table(frame_params*);
  479. extern int            js_bound(int, int);
  480. extern void           hdr_to_frps(frame_params*);
  481. extern void           WriteHdr(frame_params*, FILE*);
  482. extern void           WriteBitAlloc(unsigned int[2][SBLIMIT], frame_params*,
  483.                         FILE*);
  484. extern void           WriteScale(unsigned int[2][SBLIMIT],
  485.                         unsigned int[2][SBLIMIT], unsigned int[2][3][SBLIMIT],
  486.                         frame_params*, FILE*);
  487. extern void           WriteSamples(int, unsigned int FAR [SBLIMIT],
  488.                         unsigned int[SBLIMIT], frame_params*, FILE*);
  489. extern int            NumericQ(char*);
  490. extern int            BitrateIndex(int, int, int);
  491. extern int            SmpFrqIndex(long, int*);
  492. extern int            memcheck(char*, int, int);
  493. extern void           FAR *mem_alloc(unsigned long, char*);
  494. extern void           mem_free(void**);
  495. extern void           double_to_extended(double*, char[10]);
  496. extern void           extended_to_double(char[10], double*);
  497. extern int            aiff_read_headers(FILE*, IFF_AIFF*);
  498. extern int            aiff_seek_to_sound_data(FILE*);
  499. extern int            aiff_write_headers(FILE*, IFF_AIFF*);
  500. extern void          refill_buffer(Bit_stream_struc*);
  501. extern void          empty_buffer(Bit_stream_struc*, int);
  502. extern void          open_bit_stream_w(Bit_stream_struc*, char*, int);
  503. extern void          open_bit_stream_r(Bit_stream_struc*, char*, int);
  504. extern void           close_bit_stream_r(Bit_stream_struc*);
  505. extern void           close_bit_stream_w(Bit_stream_struc*);
  506. extern void           alloc_buffer(Bit_stream_struc*, int);
  507. extern void           desalloc_buffer(Bit_stream_struc*);
  508. extern void           back_track_buffer(Bit_stream_struc*, int);
  509. extern unsigned int   get1bit(Bit_stream_struc*);
  510. extern void           put1bit(Bit_stream_struc*, int);
  511. extern unsigned long  look_ahead(Bit_stream_struc*, int);
  512. extern unsigned long  getbits(Bit_stream_struc*, int);
  513. extern void           putbits(Bit_stream_struc*, unsigned int, int);
  514. extern void           byte_ali_putbits(Bit_stream_struc*, unsigned int, int);
  515. extern unsigned long  byte_ali_getbits(Bit_stream_struc*, int);
  516. extern unsigned long  sstell(Bit_stream_struc*);
  517. extern int            end_bs(Bit_stream_struc*);
  518. extern int            seek_sync(Bit_stream_struc*, long, int);
  519. extern void           I_CRC_calc(frame_params*, unsigned int[2][SBLIMIT],
  520.                         unsigned int*);
  521. extern void           II_CRC_calc(frame_params*, unsigned int[2][SBLIMIT],
  522.                         unsigned int[2][SBLIMIT], unsigned int*);
  523. extern void           update_CRC(unsigned int, unsigned int, unsigned int*);
  524. extern void           read_absthr(FLOAT*, int);
  525. extern unsigned int   hget1bit(); /* MI */
  526. extern unsigned long  hgetbits(int);
  527. extern unsigned long  hsstell();
  528. extern void           hputbuf(unsigned int,int);
  529. extern void           rewindNbytes( int );
  530. enum byte_order DetermineByteOrder();
  531. void SwapBytesInWords( short *loc, int words );
  532.  
  533.  
  534.  
  535. #ifdef  MACINTOSH
  536. extern void           set_mac_file_attr(char[MAX_NAME_SIZE], short, OsType,
  537.                         OsType);
  538. #endif
  539. #ifdef MS_DOS
  540. extern char           *new_ext(char *filename, char *extname); 
  541. #endif
  542.  
  543. #else
  544. extern FILE           *OpenTableFile();
  545. extern int            read_bit_alloc();
  546. extern int            pick_table();
  547. extern int            js_bound();
  548. extern void           hdr_to_frps();
  549. extern void           WriteHdr();
  550. extern void           WriteBitAlloc();
  551. extern void           WriteScale();
  552. extern void           WriteSamples();
  553. extern int            NumericQ();
  554. extern int            BitrateIndex();
  555. extern int            SmpFrqIndex();
  556. extern int            memcheck();
  557. extern void           FAR *mem_alloc();
  558. extern void           mem_free();
  559. extern void           double_to_extended();
  560. extern void           extended_to_double();
  561. extern int            aiff_read_headers();
  562. extern int            aiff_seek_to_sound_data();
  563. extern int            aiff_write_headers();
  564. extern void           refill_buffer();
  565. extern void           empty_buffer();
  566. extern void           open_bit_stream_w();
  567. extern void           open_bit_stream_r();
  568. extern void           close_bit_stream_r();
  569. extern void           close_bit_stream_w();
  570. extern void           alloc_buffer();
  571. extern void           desalloc_buffer();
  572. extern void           back_track_buffer();
  573. extern unsigned int   get1bit();
  574. extern void           put1bit();
  575. extern unsigned long  look_ahead();
  576. extern unsigned long  getbits();
  577. extern void           putbits();
  578. extern void           byte_ali_putbits();
  579. extern unsigned long  byte_ali_getbits();
  580. extern unsigned long  sstell();
  581. extern int            end_bs();
  582. extern int            seek_sync();
  583. extern void           I_CRC_calc();
  584. extern void           II_CRC_calc();
  585. extern void           update_CRC();
  586. extern void           read_absthr();
  587.  
  588. extern unsigned int   hget1bit();
  589. extern unsigned long  hgetbits();
  590. extern unsigned long  hsstell();
  591. extern void           hputbuf();
  592. extern void           rewindNbytes();
  593.  
  594. #ifdef MS_DOS
  595. extern char           *new_ext(); 
  596. #endif
  597. #endif
  598. #endif
  599.  
  600.