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

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

?? avc_e00parse.c

?? 支持各種柵格圖像和矢量圖像讀取的庫
?? C
?? 第 1 頁 / 共 5 頁
字號:
/********************************************************************** * $Id: avc_e00parse.c,v 1.18 2006/06/27 18:06:34 dmorissette Exp $ * * Name:     avc_e00parse.c * Project:  Arc/Info vector coverage (AVC)  E00->BIN conversion library * Language: ANSI C * Purpose:  Functions to parse ASCII E00 lines and fill binary structures. * Author:   Daniel Morissette, dmorissette@dmsolutions.ca * ********************************************************************** * Copyright (c) 1999-2005, Daniel Morissette * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), * to deal in the Software without restriction, including without limitation * the rights to use, copy, modify, merge, publish, distribute, sublicense, * and/or sell copies of the Software, and to permit persons to whom the * Software is furnished to do so, subject to the following conditions: *  * The above copyright notice and this permission notice shall be included * in all copies or substantial portions of the Software. *  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER  * DEALINGS IN THE SOFTWARE. ********************************************************************** * * $Log: avc_e00parse.c,v $ * Revision 1.18  2006/06/27 18:06:34  dmorissette * Applied patch for EOP processing from James F. (bug 1497) * * Revision 1.17  2006/06/19 14:35:47  dmorissette * New patch from James F. for E00 read support in OGR (bug 1497) * * Revision 1.16  2006/06/16 11:48:11  daniel * New functions to read E00 files directly as opposed to translating to * binary coverage. Used in the implementation of E00 read support in OGR. * Contributed by James E. Flemer. (bug 1497) * * Revision 1.15  2006/03/02 22:46:26  daniel * Accept empty subclass names for TX6/TX7 sections (bug 1261) * * Revision 1.14  2005/06/03 03:49:58  daniel * Update email address, website url, and copyright dates * * Revision 1.13  2002/08/27 15:43:02  daniel * Small typo in type 40 fix (forgot to commit to CVS on 2002-08-05) * * Revision 1.12  2002/08/05 20:20:17  daniel * Fixed parsing type 40 fields to properly detect negative exp. (bug 1272) * * Revision 1.11  2001/11/25 21:15:23  daniel * Added hack (AVC_MAP_TYPE40_TO_DOUBLE) to map type 40 fields bigger than 8 * digits to double precision as we generate E00 output (bug599) * * Revision 1.10  2001/11/25 19:45:32  daniel * Fixed reading of type 40 when not in exponent format (bug599) * * Revision 1.9  2001/07/12 20:59:34  daniel * Properly handle PAL entries with 0 arcs * * Revision 1.8  2000/09/22 19:45:20  daniel * Switch to MIT-style license * * Revision 1.7  2000/03/16 03:48:00  daniel * Accept 0-length text strings in TX6/TX7 objects * * Revision 1.6  2000/02/03 07:21:40  daniel * TXT/TX6 with string longer than 80 chars: split string in 80 chars chunks * * Revision 1.5  1999/12/05 03:40:13  daniel * Fixed signed/unsigned mismatch compile warning * * Revision 1.4  1999/11/23 05:27:58  daniel * Added AVCE00Str2Int() to extract integer values in E00 lines * * Revision 1.3  1999/08/23 18:20:49  daniel * Fixed support for attribute fields type 40 * * Revision 1.2  1999/05/17 16:20:48  daniel * Added RXP + TXT/TX6/TX7 write support + some simple problems fixed * * Revision 1.1  1999/05/11 02:34:46  daniel * Initial revision * **********************************************************************/#include "avc.h"#include <ctype.h>      /* toupper() *//********************************************************************** *                          AVCE00Str2Int() * * Convert a portion of a string to an integer value. * The difference between this function and atoi() is that this version * takes only the specified number of characters... so it can handle the  * case of 2 numbers that are part of the same string but are not separated  * by a space. **********************************************************************/int    AVCE00Str2Int(const char *pszStr, int numChars){    int nValue = 0;    if (pszStr && numChars >= (int)strlen(pszStr))        return atoi(pszStr);    else if (pszStr)    {        char cNextDigit;        char *pszTmp;        /* Get rid of const */        pszTmp = (char*)pszStr;        cNextDigit = pszTmp[numChars];        pszTmp[numChars] = '\0';        nValue = atoi(pszTmp);        pszTmp[numChars] = cNextDigit;    }    return nValue;}/********************************************************************** *                          AVCE00ParseInfoAlloc() * * Allocate and initialize a new AVCE00ParseInfo structure. * * AVCE00ParseStartSection() will have to be called at least once * to specify the type of objects to parse. * * The structure will eventually have to be freed with AVCE00ParseInfoFree(). **********************************************************************/AVCE00ParseInfo  *AVCE00ParseInfoAlloc(){    AVCE00ParseInfo       *psInfo;    psInfo = (AVCE00ParseInfo*)CPLCalloc(1,sizeof(AVCE00ParseInfo));    psInfo->eFileType = AVCFileUnknown;    psInfo->eSuperSectionType = AVCFileUnknown;    /* Allocate output buffer.       * 2k should be enough... the biggest thing we'll need to store     * in it will be 1 complete INFO table record.     */    psInfo->nBufSize = 2048;    psInfo->pszBuf = (char *)CPLMalloc(psInfo->nBufSize*sizeof(char));    /* Set a default precision, but this value will be set on a section     * by section basis inside AVCE00ParseStartSection()     */    psInfo->nPrecision = AVC_SINGLE_PREC;    return psInfo;}/********************************************************************** *                         _AVCE00ParseDestroyCurObject() * * Release mem. associated with the psInfo->cur.* object we are * currently using. **********************************************************************/void    _AVCE00ParseDestroyCurObject(AVCE00ParseInfo  *psInfo){    if (psInfo->eFileType == AVCFileUnknown)        return;    if (psInfo->eFileType == AVCFileARC)    {        CPLFree(psInfo->cur.psArc->pasVertices);        CPLFree(psInfo->cur.psArc);    }    else if (psInfo->eFileType == AVCFilePAL ||             psInfo->eFileType == AVCFileRPL )    {        CPLFree(psInfo->cur.psPal->pasArcs);        CPLFree(psInfo->cur.psPal);    }    else if (psInfo->eFileType == AVCFileCNT)    {        CPLFree(psInfo->cur.psCnt->panLabelIds);        CPLFree(psInfo->cur.psCnt);    }    else if (psInfo->eFileType == AVCFileLAB)    {        CPLFree(psInfo->cur.psLab);    }    else if (psInfo->eFileType == AVCFileTOL)    {        CPLFree(psInfo->cur.psTol);    }    else if (psInfo->eFileType == AVCFilePRJ)    {        CSLDestroy(psInfo->cur.papszPrj);    }    else if (psInfo->eFileType == AVCFileTXT ||              psInfo->eFileType == AVCFileTX6)    {        CPLFree(psInfo->cur.psTxt->pasVertices);        CPLFree(psInfo->cur.psTxt->pszText);        CPLFree(psInfo->cur.psTxt);    }    else if (psInfo->eFileType == AVCFileRXP)    {        CPLFree(psInfo->cur.psRxp);    }    else if (psInfo->eFileType == AVCFileTABLE)    {        _AVCDestroyTableFields(psInfo->hdr.psTableDef, psInfo->cur.pasFields);        _AVCDestroyTableDef(psInfo->hdr.psTableDef);        psInfo->bTableHdrComplete = FALSE;    }    else    {        CPLError(CE_Failure, CPLE_NotSupported,                 "_AVCE00ParseDestroyCurObject(): Unsupported file type!");    }    psInfo->eFileType = AVCFileUnknown;    psInfo->cur.psArc = NULL;}/********************************************************************** *                          AVCE00ParseInfoFree() * * Free any memory associated with a AVCE00ParseInfo structure. **********************************************************************/void    AVCE00ParseInfoFree(AVCE00ParseInfo  *psInfo){    if (psInfo)    {        CPLFree(psInfo->pszSectionHdrLine);        psInfo->pszSectionHdrLine = NULL;        CPLFree(psInfo->pszBuf);        _AVCE00ParseDestroyCurObject(psInfo);    }    CPLFree(psInfo);}/********************************************************************** *                          AVCE00ParseReset() * * Reset the fields in a AVCE00ParseInfo structure so that further calls * to the API will be ready to process a new object. **********************************************************************/void    AVCE00ParseReset(AVCE00ParseInfo  *psInfo){    psInfo->iCurItem = psInfo->numItems = 0;    psInfo->bForceEndOfSection = FALSE;}/********************************************************************** *                          AVCE00ParseSuperSectionHeader() * * Check if pszLine is a valid "supersection" header line, if it is one  * then store the supersection type in the ParseInfo structure. * * What I call a "supersection" is a section that contains several * files, such as the TX6/TX7, RPL, RXP, ... and also the IFO (TABLEs). * * The ParseInfo structure won't be ready to read objects until * a call to AVCE00ParseSectionHeader() (see below) succesfully * recognizes the beginning of a subsection of this type. * * Returns the new supersection type, or AVCFileUnknown if the line is * not recognized. **********************************************************************/AVCFileType  AVCE00ParseSuperSectionHeader(AVCE00ParseInfo  *psInfo,                                           const char *pszLine){    /*-----------------------------------------------------------------     * If we're already inside a supersection or a section, then     * return AVCFileUnknown right away.     *----------------------------------------------------------------*/    if (psInfo == NULL ||        psInfo->eSuperSectionType != AVCFileUnknown ||        psInfo->eFileType != AVCFileUnknown )    {        return AVCFileUnknown;    }    /*-----------------------------------------------------------------     * Check if pszLine is a valid supersection header line.     *----------------------------------------------------------------*/    if (EQUALN(pszLine, "RPL  ", 5))        psInfo->eSuperSectionType = AVCFileRPL;    else if (EQUALN(pszLine, "TX6  ", 5) || EQUALN(pszLine, "TX7  ", 5))        psInfo->eSuperSectionType = AVCFileTX6;    else if (EQUALN(pszLine, "RXP  ", 5))        psInfo->eSuperSectionType = AVCFileRXP;    else if (EQUALN(pszLine, "IFO  ", 5))        psInfo->eSuperSectionType = AVCFileTABLE;    else        return AVCFileUnknown;    /*-----------------------------------------------------------------     * Record the start of the supersection (for faster seeking)     *----------------------------------------------------------------*/    psInfo->nStartLineNum = psInfo->nCurLineNum;    /*-----------------------------------------------------------------     * OK, we have a valid new section header. Set the precision and      * get ready to read objects from it.     *----------------------------------------------------------------*/    if (atoi(pszLine+4) == 2)        psInfo->nPrecision = AVC_SINGLE_PREC;    else if (atoi(pszLine+4) == 3)        psInfo->nPrecision = AVC_DOUBLE_PREC;    else    {        CPLError(CE_Failure, CPLE_AppDefined,                  "Parse Error: Invalid section header line (\"%s\")!",                  pszLine);        psInfo->eSuperSectionType = AVCFileUnknown;        /* psInfo->nStartLineNum = -1; */    }    return psInfo->eSuperSectionType;}/********************************************************************** *                          AVCE00ParseSuperSectionEnd() * * Check if pszLine marks the end of a supersection, and if it is the * case, then reset the supersection flag in the ParseInfo. *  * Supersections always end with the line "JABBERWOCKY", except for * the IFO section. **********************************************************************/GBool  AVCE00ParseSuperSectionEnd(AVCE00ParseInfo  *psInfo,                                  const char *pszLine ){    if (psInfo->eFileType == AVCFileUnknown &&        psInfo->eSuperSectionType != AVCFileUnknown &&        (EQUALN(pszLine, "JABBERWOCKY", 11) ||         (psInfo->eSuperSectionType == AVCFileTABLE &&           EQUALN(pszLine, "EOI", 3) )  ) )    {

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩成人av影视| 国产一区二区不卡老阿姨| 精品国产91洋老外米糕| 成人免费视频国产在线观看| 香港成人在线视频| 专区另类欧美日韩| 日韩精品最新网址| 欧美日韩一区二区三区高清| 丁香婷婷综合激情五月色| 视频一区欧美日韩| 樱桃视频在线观看一区| 日本一区二区三区国色天香 | 91精品国产综合久久久久久久| 国产成人精品三级麻豆| 日精品一区二区| 亚洲美女视频在线观看| 国产欧美va欧美不卡在线| 日韩精品中文字幕在线不卡尤物| 欧美视频在线播放| 色婷婷精品大在线视频| 成人精品视频一区二区三区尤物| 黄色精品一二区| 日本中文一区二区三区| 亚洲精品国产品国语在线app| 中文在线一区二区| 2021国产精品久久精品| 日韩欧美高清一区| 日韩一区二区高清| 日韩视频免费观看高清完整版在线观看| 一本久久a久久精品亚洲| 91香蕉国产在线观看软件| 丰满亚洲少妇av| 粉嫩蜜臀av国产精品网站| 国产一区二区三区蝌蚪| 精久久久久久久久久久| 久久精品国产一区二区三| 日本不卡1234视频| 美腿丝袜亚洲色图| 日本免费在线视频不卡一不卡二| 亚洲国产综合人成综合网站| 亚洲精品高清视频在线观看| 亚洲综合色成人| 亚洲国产精品久久艾草纯爱| 一区二区三区免费在线观看| 亚洲国产成人av网| 免费在线观看成人| 久久精品免费看| 国产美女娇喘av呻吟久久 | 在线中文字幕不卡| 欧美性猛片xxxx免费看久爱| 欧美亚洲国产怡红院影院| 欧美午夜精品免费| 91麻豆精品国产综合久久久久久| 91精品国产91久久综合桃花| 欧美xxx久久| 国产欧美一区二区三区鸳鸯浴| 欧美激情中文字幕| 亚洲区小说区图片区qvod| 亚洲国产一区二区a毛片| 日韩国产成人精品| 国产一区二区三区在线观看免费视频| 国产主播一区二区| 91美女视频网站| 欧美日韩综合在线| 欧美大黄免费观看| 欧美国产欧美综合| 亚洲综合免费观看高清完整版 | 成人亚洲精品久久久久软件| 99久久久精品| 欧美日韩精品三区| 精品国产亚洲一区二区三区在线观看| 国产日韩欧美精品电影三级在线| 一区精品在线播放| 丝袜美腿亚洲综合| 国产不卡视频一区二区三区| 欧美艳星brazzers| 亚洲精品在线一区二区| 国产精品美女久久福利网站| 亚洲va国产va欧美va观看| 国产曰批免费观看久久久| 色综合久久天天| 精品国产伦一区二区三区观看方式| 中文字幕在线播放不卡一区| 日韩激情在线观看| 白白色亚洲国产精品| 日韩一区国产二区欧美三区| 综合自拍亚洲综合图不卡区| 免费在线观看视频一区| 91在线看国产| 日韩精品一区二区在线| 亚洲欧美区自拍先锋| 九色综合狠狠综合久久| 在线免费不卡视频| 国产校园另类小说区| 日韩福利视频导航| 91视频国产资源| 2024国产精品视频| 亚洲成a人片综合在线| 国产91对白在线观看九色| 欧美一区二区在线免费播放| 亚洲日本中文字幕区| 激情综合一区二区三区| 欧美在线一二三| 亚洲国产成人在线| 国产在线乱码一区二区三区| 欧美色老头old∨ideo| 国产精品视频免费| 极品少妇xxxx精品少妇| 欧美电影在哪看比较好| 亚洲黄色免费网站| 成人av综合在线| 国产日韩影视精品| 精品无码三级在线观看视频| 538prom精品视频线放| 亚洲素人一区二区| 国产成人免费视| 精品国产精品一区二区夜夜嗨 | 国产成人亚洲精品青草天美| 欧美一级高清片在线观看| 亚洲一区二区偷拍精品| eeuss鲁一区二区三区| 久久免费电影网| 国产真实乱对白精彩久久| 在线成人午夜影院| 丝袜美腿亚洲综合| 91麻豆精品久久久久蜜臀 | 制服视频三区第一页精品| 亚洲午夜久久久久| 欧美在线啊v一区| 亚洲三级视频在线观看| 波多野结衣中文字幕一区二区三区| 国产色爱av资源综合区| 国产呦精品一区二区三区网站| 欧美一级高清片在线观看| 免费美女久久99| 日韩欧美一区在线| 另类综合日韩欧美亚洲| 精品国产免费一区二区三区香蕉| 久久99久久久欧美国产| 欧美精品一区二区蜜臀亚洲| 久久99久久精品欧美| 欧美成人精品3d动漫h| 国模大尺度一区二区三区| 久久久久久久免费视频了| 国产麻豆成人精品| 国产欧美一区二区精品性色超碰| 国产成人精品免费一区二区| 国产女人aaa级久久久级 | 亚洲美女淫视频| 欧洲色大大久久| 午夜亚洲福利老司机| 91精品国产91久久久久久最新毛片| 蜜臀精品久久久久久蜜臀| 欧美精品一区二区三区蜜桃视频| 国产剧情一区二区| 国产精品国产三级国产普通话99 | 国产清纯在线一区二区www| 国产suv精品一区二区883| 国产精品久久久久久亚洲伦| 91在线免费播放| 图片区小说区区亚洲影院| 欧美videossexotv100| 国产成人亚洲综合a∨婷婷| 亚洲欧美日韩精品久久久久| 精品视频999| 国产专区综合网| 亚洲美女免费视频| 9191精品国产综合久久久久久| 久久精品国产久精国产| 欧美国产精品一区| 在线国产电影不卡| 美女在线观看视频一区二区| 中文字幕av一区二区三区高| 欧美色图一区二区三区| 久久精品国产亚洲高清剧情介绍| 欧美激情资源网| 欧美理论在线播放| 国产高清亚洲一区| 亚洲va中文字幕| 亚洲国产精品成人综合| 精品视频色一区| 岛国av在线一区| 亚洲aⅴ怡春院| 国产女人18水真多18精品一级做| 欧美在线观看视频在线| 国产美女精品人人做人人爽 | 蜜桃精品在线观看| 国产精品国产a级| 日韩三级电影网址| 99久久婷婷国产综合精品| 麻豆国产精品一区二区三区| 亚洲欧美一区二区三区久本道91| 日韩欧美国产三级电影视频| 色诱视频网站一区| 国产成人综合亚洲网站| 日韩高清一级片| 亚洲人成网站影音先锋播放| 国产拍欧美日韩视频二区| 日韩丝袜情趣美女图片| 欧美性猛交xxxxxxxx|