亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? putattr.c

?? 支持各種柵格圖像和矢量圖像讀取的庫
?? C
字號:
#include "csf.h"#include "csfimpl.h"/* make block empty */static void InitBlock(	ATTR_CNTRL_BLOCK *b) /* write-only */{	int i; 	for (i = 0 ; i < NR_ATTR_IN_BLOCK; i++)	{		b->attrs[i].attrId   = END_OF_ATTRS;		b->attrs[i].attrSize   = 0;		b->attrs[i].attrOffset = 0;	}	b->next = 0;}/* replace an attribute (LIBRARY_INTERNAL) * */CSF_ATTR_ID CsfUpdateAttribute(	MAP *m,       		/* map handle */	CSF_ATTR_ID id,               /* attribute identification */	size_t itemSize,        /* size of each attribute element.	                         * 1 or sizeof(char) in case of a	                         * string 	                         */	size_t nitems,          /* number of attribute elements or	                         * strlen+1 in case of a variable character	                         * string field. Don't forget to pad a	                         * non-variable field with '\0'!	                         */	void *attr)       /* buffer containing attribute */{	PRECOND(CsfValidSize(itemSize));	if (CsfAttributeSize(m,id))		if (! MdelAttribute(m,id))			return 0;	return CsfPutAttribute(m,id,itemSize,nitems, attr);}/* write an attribute to a map (LIBRARY_INTERNAL) * MputAttribute writes exactly the number of bytes specified * by the size argument starting at the address of argument * attr. Which means that you can't simply pass a structure or an  * array of structures as argument attr, due to the alignment * of fields within a structure and internal swapping. You can * only pass an array of elementary types (UINT1, REAL4, etc.) * or character string. * If one wants to refresh an attribute, one should first * call MdelAttribute to delete the attribute and then use * MputAttribute to write the new value. * returns argument id or 0 in case of error. * * Merrno * ATTRDUPL * NOACCESS * WRITE_ERROR */CSF_ATTR_ID CsfPutAttribute(	MAP *m,       		/* map handle */	CSF_ATTR_ID id,               /* attribute identification */	size_t itemSize,        /* size of each attribute element.	                         * 1 or sizeof(char) in case of a	                         * string 	                         */	size_t nitems,          /* number of attribute elements or	                         * strlen+1 in case of a variable character	                         * string field. Don't forget to pad a	                         * non-variable field with '\0'!	                         */	void *attr)       /* buffer containing attribute */{	size_t size = nitems * itemSize;		PRECOND(CsfValidSize(itemSize));	PRECOND(size > 0);	if (CsfSeekAttrSpace(m,id,size) == 0)		goto error;	if (m->write(attr, itemSize, nitems, m->fp) != nitems) 	{		M_ERROR(WRITE_ERROR);		goto error;	}	return(id); 		/* succes */error:	return(0);	/* failure */} /* seek to space for attribute  (LIBRARY_INTERNAL) * CsfSeekAttrSpace seeks to the a point in the file where * the attribute must be stored and update the attribute control  * blocks accordingly. * Writing can still fail since there is no check if that space is really * avalaible on the device. After this call returns the file is already * seeked to the point the functions returns. * returns the file position or 0 in case of error. * * Merrno * ATTRDUPL * NOACCESS * WRITE_ERROR */CSF_FADDR CsfSeekAttrSpace( 	MAP *m,       		/* map handle */	CSF_ATTR_ID id,               /* attribute identification only for check if avalaible */	size_t size)            /* size to be seeked to */{	ATTR_CNTRL_BLOCK b;	CSF_FADDR currBlockPos, prevBlockPos=USED_UNINIT_ZERO, newPos, endBlock, resultPos=0;	int noPosFound;	int i;	if (MattributeAvail(m ,id))	{		M_ERROR(ATTRDUPL);		goto error;	}	if (! WRITE_ENABLE(m))	{		M_ERROR(NOACCESS);		goto error;	}	currBlockPos = m->main.attrTable;        noPosFound = 1;	while (noPosFound) 	{			if (currBlockPos == 0)		{			if (m->main.attrTable == 0)			{ /* FIRST BLOCK */				newPos =( (CSF_FADDR)(m->raster.nrRows)*					   (CSF_FADDR)(m->raster.nrCols)*					  (CSF_FADDR)(CELLSIZE(RgetCellRepr(m))))					  + ADDR_DATA;				m->main.attrTable = newPos;			}			else			{ /* NEW/NEXT BLOCK */				newPos = b.attrs[LAST_ATTR_IN_BLOCK].attrOffset 					+					b.attrs[LAST_ATTR_IN_BLOCK].attrSize;				b.next = newPos;				if (CsfWriteAttrBlock(m, prevBlockPos, &b))				{					M_ERROR(WRITE_ERROR);					resultPos = 0;				}			}			InitBlock(&b);			b.attrs[0].attrOffset =				newPos + SIZE_OF_ATTR_CNTRL_BLOCK;			currBlockPos = newPos;			noPosFound = 0;		}		else			CsfReadAttrBlock(m, currBlockPos, &b);		i = 0; /* this is also the right index if a new block			   is added ! */		while (noPosFound  && i < NR_ATTR_IN_BLOCK) 			switch (b.attrs[i].attrId)			{				case END_OF_ATTRS:					POSTCOND(i >= 1);					/* i >= 1 , no block otherwise */					b.attrs[i].attrOffset =						b.attrs[i-1].attrOffset  +						b.attrs[i-1].attrSize;					noPosFound = 0;                                        break;				case ATTR_NOT_USED:					if (i == NR_ATTR_IN_BLOCK)						endBlock = b.next;					else						endBlock = b.attrs[i+1].attrOffset;					if (( endBlock - b.attrs[i].attrOffset)						>= size)						/* this position can							hold the attr */						noPosFound = 0;                                        else                                            i++;                                        break;				 default:                                            i++;			} /* switch *//*		if (b.next == 0)                      ? When did I change this CW		       remember this block position since it may be have		       to rewritten */		prevBlockPos = currBlockPos;		if (noPosFound)			currBlockPos = b.next; 	} /* while */	b.attrs[i].attrSize = size;	b.attrs[i].attrId   = id;	resultPos = b.attrs[i].attrOffset;	if (CsfWriteAttrBlock(m, currBlockPos, &b))	{		M_ERROR(WRITE_ERROR);		resultPos = 0;	}	fseek(m->fp, (long)resultPos, SEEK_SET); /* fsetpos() is better */error:	return resultPos;} /* CsfSeekAttrSpace */

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲1区2区3区视频| 久久免费午夜影院| 极品美女销魂一区二区三区免费| 精品电影一区二区三区| 99riav久久精品riav| 国产精品久久久久毛片软件| 91麻豆精品91久久久久同性| 国产成a人无v码亚洲福利| 一区二区不卡在线播放| 99re在线精品| 国产精品一区二区不卡| 亚洲影院久久精品| 国产欧美日韩在线视频| 日韩一级片在线播放| 91麻豆国产在线观看| 九九九精品视频| 一区二区高清在线| 欧美国产日韩一二三区| 欧美一区二区性放荡片| 91首页免费视频| 国产乱人伦精品一区二区在线观看| 亚洲综合丁香婷婷六月香| 久久美女高清视频| 3d成人h动漫网站入口| 99久久婷婷国产精品综合| 久久9热精品视频| 国产精品国产a级| 久久网站最新地址| 7777精品伊人久久久大香线蕉的| 成熟亚洲日本毛茸茸凸凹| 久久九九久久九九| 欧美xxxxx裸体时装秀| 欧美日韩在线观看一区二区 | 欧美精品九九99久久| 99精品视频一区二区三区| 国内一区二区在线| 美女看a上一区| 亚洲成人先锋电影| 五月婷婷激情综合| 亚洲精品成a人| 国产精品午夜春色av| 久久综合九色综合欧美就去吻| 精品日韩在线一区| 日韩一卡二卡三卡| 成人高清免费观看| 91老师国产黑色丝袜在线| 国产成人免费视| 国产精品一级在线| 国产一区二区精品在线观看| 国产精品女主播av| 欧洲另类一二三四区| 国产成人免费视频一区| 亚洲色图欧美偷拍| 精品国精品国产| 欧美伊人久久大香线蕉综合69| 久久精品国产**网站演员| 亚洲国产成人午夜在线一区| 欧美午夜一区二区三区免费大片| 国产在线看一区| 另类小说色综合网站| 一区二区三区日韩在线观看| 久久久亚洲精品一区二区三区| 久久婷婷综合激情| wwwwxxxxx欧美| 久久精品欧美一区二区三区麻豆| 欧美日韩夫妻久久| 精品国产1区二区| 久久综合资源网| 久久九九全国免费| 国产亚洲欧美在线| 亚洲免费毛片网站| 亚洲18女电影在线观看| 日韩电影在线一区二区| 亚洲123区在线观看| 激情六月婷婷综合| 成人免费视频视频在线观看免费| 国产99久久久久久免费看农村| 蜜臀av性久久久久蜜臀aⅴ四虎 | 欧美视频在线不卡| 欧美欧美欧美欧美首页| 欧美精品777| 久久亚洲私人国产精品va媚药| 久久蜜桃av一区二区天堂| 国产精品你懂的| 亚洲一区二区三区影院| 国产一区二区不卡| av一区二区三区在线| 欧洲色大大久久| 日韩欧美一级在线播放| 亚洲色图在线看| 性感美女久久精品| 在线电影院国产精品| 日本精品一区二区三区高清 | 欧美日韩国产高清一区二区| 欧美大片在线观看一区二区| 国产精品美女www爽爽爽| 国产亚洲精品福利| 婷婷一区二区三区| 国产白丝精品91爽爽久久| av网站免费线看精品| 欧美中文字幕一二三区视频| 久久久不卡网国产精品一区| 亚洲午夜一二三区视频| 免费视频一区二区| 制服丝袜中文字幕亚洲| 午夜成人免费视频| 国产福利一区二区三区视频| 色综合久久天天| 久久久精品免费免费| 一级女性全黄久久生活片免费| 国产日本欧美一区二区| 亚洲电影你懂得| 色哟哟亚洲精品| 亚洲视频一区二区免费在线观看| 欧美日本韩国一区二区三区视频| 在线看国产一区| 久久这里只有精品视频网| 日韩中文字幕1| 91极品视觉盛宴| 亚洲色图视频免费播放| 国产一区二区免费看| 日韩精品一区二区三区在线| 亚洲成人免费视频| 在线免费一区三区| 亚洲欧美视频在线观看视频| 国产一区久久久| 日韩精品一区二区三区swag| 亚洲成人综合网站| 在线观看91视频| 亚洲综合色自拍一区| 色悠悠久久综合| 亚洲精品日日夜夜| 亚洲电影在线播放| 精品亚洲国内自在自线福利| 日韩一区二区在线看片| 日韩二区三区在线观看| 91精品国产一区二区人妖| 日韩精品久久久久久| 8x8x8国产精品| 日本中文字幕一区二区有限公司| 欧美精品aⅴ在线视频| 日韩综合小视频| 制服丝袜亚洲播放| 蜜臀久久99精品久久久久久9| 日韩欧美一区二区久久婷婷| 久久国产精品99精品国产| 久久亚洲影视婷婷| 粉嫩一区二区三区在线看| 中文字幕 久热精品 视频在线| 成熟亚洲日本毛茸茸凸凹| 中文字幕一区视频| 色久优优欧美色久优优| 亚洲电影中文字幕在线观看| 91精品蜜臀在线一区尤物| 另类小说一区二区三区| 久久久九九九九| 成人激情电影免费在线观看| 亚洲免费看黄网站| 91麻豆精品国产自产在线| 日本午夜一区二区| www国产精品av| 91香蕉视频黄| 日本va欧美va欧美va精品| 26uuu亚洲综合色欧美| 国产激情一区二区三区| 亚洲天堂精品视频| 欧美日韩一本到| 国产一区视频导航| 亚洲色图清纯唯美| 日韩一区二区在线观看视频 | 综合av第一页| 欧美中文一区二区三区| 裸体在线国模精品偷拍| 国产欧美在线观看一区| 91高清在线观看| 极品尤物av久久免费看| 中文字幕日韩av资源站| 337p亚洲精品色噜噜狠狠| 风间由美性色一区二区三区| 亚洲最大成人综合| 久久色在线观看| 欧美私模裸体表演在线观看| 国产专区综合网| 亚洲午夜三级在线| 国产人成亚洲第一网站在线播放| 欧美最新大片在线看 | 免费看精品久久片| 成人精品免费看| 国产精品狼人久久影院观看方式| 在线看国产一区| 国产精品乡下勾搭老头1| 亚洲一区免费在线观看| 国产亚洲成aⅴ人片在线观看 | 国产乱一区二区| 亚洲图片欧美一区| 国产精品国产自产拍在线| 69成人精品免费视频| 91香蕉视频黄| 国产成人精品影视| 三级欧美在线一区|