#include <stdio.h>#include <stdlib.h>#include <string.h>#include "tdef.h"#include "xalloc.h"#include "uti.h"#include "cabdef0.h"#include "cabctrl.h"

Ir al código fuente de este archivo.
Definiciones | |
| #define | SIZE(sf) ((UINT4)sizeof(cgs->sf)) |
| #define | TSIZE(tf) |
| #define | FREE(tf) |
| #define | READCGS32(sf) { INT32 i32; xfread(&i32,sizeof(i32),1,fp); endian_fromlittle32(&i32); cgs->sf=i32; } |
| #define | FREADCGS(sf) cgs->sf = xlee_sfloat(fp) |
| #define | TREADCGS(tf) { pCHAR1 pch=cgs->tf.txt; UINT2 l=cgs->tf.ltxt; retval|=lee_cvariable_txt(fp,&pch,&l); cgs->tf.txt=pch; cgs->tf.ltxt=l; } |
| #define | WRITECGS32(sf) { INT32 i32=cgs->sf; endian_tolittle32(&i32); xfwrite(&i32,sizeof(i32),1,fp); } |
| #define | FWRITECGS(sf) xescribe_sfloat(fp,cgs->sf) |
| #define | TWRITECGS(tf) { pCHAR1 pch=cgs->tf.txt; UINT2 l=cgs->tf.ltxt; escribe_cvariable_txt( fp,pch,l); } |
| #define | WRITEM32(sf) { INT32 i32=cgs->sf; endian_tolittle32(&i32); xfwrite(&i32,sizeof(i32),1,fp); } |
| #define | FWRITEM(sf) xescribe_sfloat(fp,cgs->sf) |
| #define | TWRITEM(tf) { pCHAR1 pch=cgs->tf.txt; UINT2 l=cgs->tf.ltxt; escribe_cvariable_txt( fp,pch,l); } |
| #define | oREAD32(sf) { INT32 i32; xfread(&i32,sizeof(i32),1,fp); endian_fromlittle32(&i32); cgs->sf=i32; } |
| #define | oFREAD(sf) cgs->sf = xlee_sfloat(fp) |
| #define | oTREAD(tf, n) |
| #define | M(f) (cgs->marc.f) |
| #define | oWRITE32(sf) { INT32 i=cgs->sf; endian_tolittle32(&i); xfwrite(&i,sizeof(i),1,fp); } |
| #define | oFWRITE(sf) xescribe_sfloat(fp,cgs->sf) |
| #define | oTWRITE(tf, n) |
| #define | M(f) (cgs->marc.f) |
Funciones | |
| FLOAT4 | xlee_sfloat (FILE *f) |
| void | xescribe_sfloat (FILE *f, FLOAT4 sf) |
| void | salta_cab (FILE *fp) |
| UINT4 | get_cmask (FILE *fp) |
| int | vete_cab (FILE *fp, UINT4 cabmask) |
| void | xvete_cab (FILE *fp, UINT4 cabmask) |
| void | lee_cfich (FILE *fp, struct cfich *cf_ptr) |
| void | escribe_cfich (FILE *fp, struct cfich *cf_ptr) |
| void | anade_cmask (FILE *fp, UINT4 cabmask) |
| void | escribe_long (FILE *fp, UINT4 l) |
| void | escribe_long_actual (FILE *fp, UINT4 cabmask) |
| long | lee_long_actual (FILE *fp, UINT4 cabmask) |
| UINT4 | prepara_cvariable (pVOID *cvptr, UINT4 nb, UINT4 fnb, BOOL is_txt) |
| int | lee_cvariable_txt (FILE *fp, pCHAR1 *cvptr, UINT2 *nelem) |
| int | lee_cvariable_marcas (FILE *fp, pUINT4 *cvptr, UINT4 *nelem) |
| void | escribe_cvariable_txt (FILE *fp, pCHAR1 cvptr, UINT2 nelem) |
| void | escribe_cvariable_marcas (FILE *fp, pUINT4 cvptr, UINT4 nelem) |
| UINT4 | long_cgsenal (struct cgsenal *cgs) |
| void | free_cgsenal (struct cgsenal *cgs) |
| int | lee_cgsenal (FILE *fp, struct cgsenal *cgs) |
| void | escribe_cgsenal (FILE *fp, struct cgsenal *cgs) |
| void | escribe_cgsenal_marc (FILE *fp, struct cgsenal *cgs) |
| void | limpia_texto (pCHAR1 p, UINT2 *l) |
| void | lee_csenal_vieja (FILE *fp, struct cgsenal *cgs) |
| void | escribe_csenal_vieja (FILE *fp, struct cgsenal *cgs) |
| void | lee_cgp_parcor (FILE *fp, struct cgp_parcor *cgp_pc_ptr) |
| void | escribe_cgp_parcor (FILE *fp, struct cgp_parcor *cgp_pc_ptr) |
| void | lee_cgp_lpc (FILE *fp, struct cgp_lpc *cgp_lpc_ptr) |
| void | escribe_cgp_lpc (FILE *fp, struct cgp_lpc *cgp_lpc_ptr) |
| #define SIZE | ( | sf | ) | ((UINT4)sizeof(cgs->sf)) |
| #define TSIZE | ( | tf | ) |
Valor:
(UINT4)(sizeof(cgs->tf.ltxt)+ \ ((UINT4)(cgs->tf.ltxt))*sizeof(*(cgs->tf.txt)))
| #define FREE | ( | tf | ) |
Valor:
if (cgs->tf.txt!=NULL) \ xfree((void *)cgs->tf.txt); \ cgs->tf.ltxt=0
| #define READCGS32 | ( | sf | ) | { INT32 i32; xfread(&i32,sizeof(i32),1,fp); endian_fromlittle32(&i32); cgs->sf=i32; } |
| #define FREADCGS | ( | sf | ) | cgs->sf = xlee_sfloat(fp) |
| #define TREADCGS | ( | tf | ) | { pCHAR1 pch=cgs->tf.txt; UINT2 l=cgs->tf.ltxt; retval|=lee_cvariable_txt(fp,&pch,&l); cgs->tf.txt=pch; cgs->tf.ltxt=l; } |
| #define WRITECGS32 | ( | sf | ) | { INT32 i32=cgs->sf; endian_tolittle32(&i32); xfwrite(&i32,sizeof(i32),1,fp); } |
| #define FWRITECGS | ( | sf | ) | xescribe_sfloat(fp,cgs->sf) |
| #define TWRITECGS | ( | tf | ) | { pCHAR1 pch=cgs->tf.txt; UINT2 l=cgs->tf.ltxt; escribe_cvariable_txt( fp,pch,l); } |
| #define WRITEM32 | ( | sf | ) | { INT32 i32=cgs->sf; endian_tolittle32(&i32); xfwrite(&i32,sizeof(i32),1,fp); } |
| #define FWRITEM | ( | sf | ) | xescribe_sfloat(fp,cgs->sf) |
| #define TWRITEM | ( | tf | ) | { pCHAR1 pch=cgs->tf.txt; UINT2 l=cgs->tf.ltxt; escribe_cvariable_txt( fp,pch,l); } |
| #define oREAD32 | ( | sf | ) | { INT32 i32; xfread(&i32,sizeof(i32),1,fp); endian_fromlittle32(&i32); cgs->sf=i32; } |
| #define oFREAD | ( | sf | ) | cgs->sf = xlee_sfloat(fp) |
| #define oTREAD | ( | tf, | |||
| n | ) |
Valor:
{ \
pCHAR1 pch=cgs->tf.txt; \
UINT2 l=cgs->tf.ltxt; \
l= (UINT2)prepara_cvariable( (pVOID *)&pch,l,n,TRUE); \
xfread(pch,1,l,fp); \
xfseek(fp,l,SEEK_CUR); \
limpia_texto(pch,&l); \
cgs->tf.txt=pch; \
cgs->tf.ltxt=l; }
| #define M | ( | f | ) | (cgs->marc.f) |
| #define oFWRITE | ( | sf | ) | xescribe_sfloat(fp,cgs->sf) |
| #define oTWRITE | ( | tf, | |||
| n | ) |
| #define M | ( | f | ) | (cgs->marc.f) |
| void lee_cfich | ( | FILE * | fp, | |
| struct cfich * | cf_ptr | |||
| ) |
| void escribe_cfich | ( | FILE * | fp, | |
| struct cfich * | cf_ptr | |||
| ) |
| void escribe_long_actual | ( | FILE * | fp, | |
| UINT4 | cabmask | |||
| ) |
| UINT4 prepara_cvariable | ( | pVOID * | cvptr, | |
| UINT4 | nb, | |||
| UINT4 | fnb, | |||
| BOOL | is_txt | |||
| ) |
| int lee_cvariable_txt | ( | FILE * | fp, | |
| pCHAR1 * | cvptr, | |||
| UINT2 * | nelem | |||
| ) |
| int lee_cvariable_marcas | ( | FILE * | fp, | |
| pUINT4 * | cvptr, | |||
| UINT4 * | nelem | |||
| ) |
| void escribe_cvariable_txt | ( | FILE * | fp, | |
| pCHAR1 | cvptr, | |||
| UINT2 | nelem | |||
| ) |
| void escribe_cvariable_marcas | ( | FILE * | fp, | |
| pUINT4 | cvptr, | |||
| UINT4 | nelem | |||
| ) |
| int lee_cgsenal | ( | FILE * | fp, | |
| struct cgsenal * | cgs | |||
| ) |
| void escribe_cgsenal | ( | FILE * | fp, | |
| struct cgsenal * | cgs | |||
| ) |
| void escribe_cgsenal_marc | ( | FILE * | fp, | |
| struct cgsenal * | cgs | |||
| ) |
| void lee_csenal_vieja | ( | FILE * | fp, | |
| struct cgsenal * | cgs | |||
| ) |
| void escribe_csenal_vieja | ( | FILE * | fp, | |
| struct cgsenal * | cgs | |||
| ) |
| void lee_cgp_parcor | ( | FILE * | fp, | |
| struct cgp_parcor * | cgp_pc_ptr | |||
| ) |
| void escribe_cgp_parcor | ( | FILE * | fp, | |
| struct cgp_parcor * | cgp_pc_ptr | |||
| ) |
| void lee_cgp_lpc | ( | FILE * | fp, | |
| struct cgp_lpc * | cgp_lpc_ptr | |||
| ) |
| void escribe_cgp_lpc | ( | FILE * | fp, | |
| struct cgp_lpc * | cgp_lpc_ptr | |||
| ) |
1.5.6