gdal-1.11.0/frmts/pcraster/libcsf/rattrblk.c
void CsfReadAttrBlock(
	MAP *m,              /* map handle */
	CSF_FADDR pos,           /* file position of block to be read */
	ATTR_CNTRL_BLOCK *b) /* write-only. attribute control block read */
{
	int i;
	fseek(m->fp, (long)pos, SEEK_SET);
	for(i=0; i < NR_ATTR_IN_BLOCK; i++)
	{
	 m->read((void *)&(b->attrs[i].attrId), sizeof(UINT2),(size_t)1,m->fp);
	 m->read((void *)&(b->attrs[i].attrOffset), sizeof(CSF_FADDR),(size_t)1,m->fp);
	 m->read((void *)&(b->attrs[i].attrSize), sizeof(UINT4),(size_t)1,m->fp);
	}
	m->read((void *)&(b->next), sizeof(CSF_FADDR),(size_t)1,m->fp);
}
/* read attribute control block (LIBRARY_INTERNAL)
 */
read attribute control block (LIBRARY_INTERNAL)
read attribute control block ( LIBRARY_INTERNAL )
void CsfReadAttrBlock(
	MAP *m,              
	CSF_FADDR pos,           
	ATTR_CNTRL_BLOCK *b) 
{
	int i;
	fseek(m->fp, (long)pos, SEEK_SET);
	for(i=0; i < NR_ATTR_IN_BLOCK; i++)
	{
	 m->read((void *)&(b->attrs[i].attrId), sizeof(UINT2),(size_t)1,m->fp);
	 m->read((void *)&(b->attrs[i].attrOffset), sizeof(CSF_FADDR),(size_t)1,m->fp);
	 m->read((void *)&(b->attrs[i].attrSize), sizeof(UINT4),(size_t)1,m->fp);
	}
	m->read((void *)&(b->next), sizeof(CSF_FADDR),(size_t)1,m->fp);
}
void CsfReadAttrBlock ( MAP * m , CSF_FADDR pos , ATTR_CNTRL_BLOCK * b ) { int i ; fseek ( m -> fp , ( long ) pos , SEEK_SET ) ; for ( i = 0 ; i < NR_ATTR_IN_BLOCK ; i ++ ) { m -> read ( ( void * ) & ( b -> attrs [ i ] . attrId ) , sizeof ( UINT2 ) , ( size_t ) 1 , m -> fp ) ; m -> read ( ( void * ) & ( b -> attrs [ i ] . attrOffset ) , sizeof ( CSF_FADDR ) , ( size_t ) 1 , m -> fp ) ; m -> read ( ( void * ) & ( b -> attrs [ i ] . attrSize ) , sizeof ( UINT4 ) , ( size_t ) 1 , m -> fp ) ; } m -> read ( ( void * ) & ( b -> next ) , sizeof ( CSF_FADDR ) , ( size_t ) 1 , m -> fp ) ; }
read attribute control block (LIBRARY_INTERNAL)
read attribute control block ( LIBRARY_INTERNAL )
/* map handle */ /* file position of block to be read */ /* write-only. attribute control block read */