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

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

?? epr_msph.c

?? Insar圖像處理軟件
?? C
?? 第 1 頁 / 共 2 頁
字號:
/* * $Id: epr_msph.c,v 1.1.1.1 2003/03/05 17:36:43 hartmut Exp $ * * Copyright (C) 2002 by Brockmann Consult (info@brockmann-consult.de) * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the * Free Software Foundation. This program is distributed in the hope it will * be useful, but WITHOUT ANY WARRANTY; without even the implied warranty * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * See the GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA. */#include <assert.h>#include <errno.h>#include <stdio.h>#include <stdlib.h>#include <string.h>#include "epr_api.h"#include "epr_core.h"#include "epr_string.h"#include "epr_ptrarray.h"#include "epr_swap.h"#include "epr_field.h"#include "epr_record.h"#include "epr_param.h"#include "epr_dsd.h"#include "epr_msph.h"#include "epr_band.h"#include "epr_bitmask.h"/** * Reads the full main product header (MPH) of the ENVISAT product file * by the given product identifier. * * @param product_id the product identifier, must not be <code>NULL</code> * @return a record representing the MPH of the specified product file *         or <code>NULL</code> if an error occured. */EPR_SRecord* epr_read_mph(EPR_SProductId* product_id){    EPR_SRecord* record = NULL;    char* code_block;    int numread;    epr_clear_err();    code_block = epr_create_string(EPR_MPH_SIZE);    if (code_block == NULL)    {        epr_set_err(e_err_out_of_memory,                     "epr_read_mph: out of memory");        return NULL;    }    rewind(product_id->istream);    numread = fread(code_block, 1, EPR_MPH_SIZE, product_id->istream);    if (numread != EPR_MPH_SIZE)    {        epr_set_err(e_err_file_read_error,             "epr_read_mph: wrong reading MPH from product data file");        return NULL;    }    record = epr_parse_header("mph", code_block);    if (record == NULL)    {        epr_set_err(e_err_invalid_record,             "epr_read_mph: can not recognize the correct MPH from product data file");    } else {        epr_add_ptr_array_elem(product_id->record_info_cache, record->info);    }    epr_free_string(code_block);    return record;}/** * Reads the full specific product header (SPH) of the ENVISAT product file * by the given product identifier. * * @param product_id the product identifier, must not be <code>NULL</code> * @return a record representing the MPH of the specified product file *         or <code>NULL</code> if an error occured. */EPR_SRecord* epr_read_sph(EPR_SProductId* product_id){    EPR_SRecord* sph_record = NULL;    const EPR_SField* field;    char* code_block;    int numread;    ulong sph_length = 0;    ulong sph_without_dsd_length = 0;    ulong dsd_number = 0;    epr_clear_err();    if (product_id->mph_record == NULL) {        product_id->mph_record = epr_read_mph(product_id);        if (product_id->mph_record == NULL) {            epr_set_err(e_err_file_read_error, "epr_read_sph: wrong MPH");            return NULL;        }    }    field = epr_get_field(product_id->mph_record, "SPH_SIZE");    sph_length = ((ulong*) field->elems)[0];    if (sph_length == 0) {        epr_set_err(e_err_invalid_value,             "epr_read_sph: wrong MPH: SPH_SIZE must be > 0");        return NULL;    }    field = epr_get_field(product_id->mph_record, "NUM_DSD");    dsd_number = ((ulong*) field->elems)[0];    if (dsd_number == 0) {        epr_set_err(e_err_invalid_value,             "epr_read_sph: wrong MPH: NUM_DSD must be > 0");        return NULL;    }    epr_api.epr_head_size = sph_length + EPR_MPH_SIZE;    if (fseek(product_id->istream, EPR_MPH_SIZE, SEEK_SET) != 0) {        epr_set_err(e_err_file_access_denied,                     "epr_read_sph: file seek failed");        return NULL;    }    sph_without_dsd_length = sph_length - dsd_number * EPR_DSD_SIZE;    code_block = epr_create_string(sph_without_dsd_length);    numread = fread(code_block, 1, sph_without_dsd_length, product_id->istream);    if ((uint)numread != sph_without_dsd_length) {        epr_set_err(e_err_file_read_error,             "epr_read_sph: wrong reading SPH from product data file");        return NULL;    }       sph_record = epr_parse_header("sph", code_block);    if (sph_record == NULL) {        epr_set_err(e_err_invalid_record,             "epr_read_sph: can not recognize the correct SPH from product data file");    } else {        epr_add_ptr_array_elem(product_id->record_info_cache, sph_record->info);    }    epr_free_string(code_block);    return sph_record;}void epr_store_header(const char* header_name, const char* ascii_source) {    FILE* os;    char fname[1024];    sprintf(fname, "%s.txt", header_name);    os=fopen(fname, "w");    fprintf(os,"%s", ascii_source);    fclose(os);}/** * Parses the header ASCII information. *  * @param header_name name of the header ascii information; * @param ascii_source the header ascii information was read; * @param record the identifier of header ascii information. */EPR_SRecord* epr_parse_header(const char* header_name, const char* ascii_source){    EPR_SRecordInfo* record_info;    EPR_SPtrArray* field_infos = NULL;    EPR_SFieldInfo* field_info;    EPR_SPtrArray* header_values = NULL;    EPR_SRecord* record = NULL;    EPR_EDataTypeId tp;    char * code_block;    char seps[] = EPR_HEADER_SEPARATOR_ARRAY;    char * token_name;    char * token_value;    char * token_unit;    char * h_name;          int pos = 0;    int pos_ascii = 0;    uint num_bytes = 0;    uint num_elems = 0;            epr_clear_err();    /* uncomment for debugging purpose */    /* epr_store_header(header_name, ascii_source); */    header_values = epr_create_ptr_array(16);    field_infos = epr_create_ptr_array(16);    h_name = epr_clone_string(header_name);        while ((code_block = epr_str_tok(ascii_source, "\n", &pos_ascii)) != NULL) {        /*if EMPTY code_block*/            if ((strlen(code_block) > 0) && (code_block[0] == ' ')) {            /* epr_log(e_log_info, "code_block is empty"); */            if (code_block != NULL) {                epr_free_string(code_block);                code_block = NULL;            }            continue;        }        /*if '=' separator*/        pos = 0;        token_name = epr_str_tok(code_block, seps, &pos);        if (pos == 1) {            epr_set_err(e_err_invalid_keyword_name,                         "epr_parse_header: invalid ascii header: keyword is empty");            epr_free_string(token_name);            if (code_block != NULL) {                epr_free_string(code_block);                code_block = NULL;            }            continue;        }         if (pos == (int)strlen(code_block) + 1) {            epr_set_err(e_err_invalid_keyword_name,                         "epr_parse_header: invalid ascii header: keyword not found");            epr_free_string(token_name);            if (code_block != NULL) {                epr_free_string(code_block);                code_block = NULL;            }            continue;        }        /*if STRING value*/        if (code_block[pos] == '\"') {            pos ++;			/* 			  Note that strings always are considered as one single element,			  so we get the total number of characters from tot_size.			  Addidionally we reserve an extra character for the trailing zero (terminator),			*/            token_value = epr_strip_string_r(epr_str_tok(code_block, "\"", &pos));            token_unit = NULL;            tp = e_tid_string;            num_bytes = (uint)strlen(token_value);            num_elems = 1;            epr_add_ptr_array_elem(header_values, token_value);        } else {            token_value = epr_str_tok(code_block, seps, &pos);            if (token_value == NULL) {                epr_set_err(e_err_invalid_value,                             "epr_parse_header: invalid ascii header: value not found");                token_value = epr_clone_string("");                token_unit = NULL;                tp = e_tid_uchar;                num_bytes = 0;                num_elems = 1;                epr_add_ptr_array_elem(header_values, token_value);            } else {                /*if FLOAT-DOUBLE value*/                if (strchr(token_value, '.') != NULL                     || strchr(token_value, 'e') != NULL                     || strchr(token_value, 'E') != NULL)                {                    epr_parse_double_token(header_values, token_value, &num_elems, &num_bytes, &tp);                    token_unit = epr_str_tok(code_block, seps, &pos);                    epr_free_string(token_value);                    token_value = NULL;                /*if INTEGER_LONG value*/                } else if ((strlen(token_value) > 1)) {                    epr_parse_long_token(header_values, token_value, &num_elems, &num_bytes, &tp);

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
91日韩在线专区| 久久先锋影音av| 精品国产免费久久| 一区二区三区精品| 国内精品国产三级国产a久久 | 色综合久久66| 日韩午夜激情视频| 亚洲乱码国产乱码精品精98午夜| 久久福利资源站| 欧美最新大片在线看| 日本一区二区高清| 狠狠色狠狠色综合| 欧美高清精品3d| 亚洲欧美另类小说视频| 国产盗摄视频一区二区三区| 91精品国产全国免费观看| 亚洲日本在线视频观看| 国产99精品视频| 久久综合国产精品| 日本aⅴ精品一区二区三区 | 欧美人动与zoxxxx乱| 国产精品护士白丝一区av| 国内精品久久久久影院薰衣草| 欧美酷刑日本凌虐凌虐| 一区二区三区视频在线观看| 懂色av一区二区三区蜜臀| 日韩欧美一区二区视频| 日韩精品欧美成人高清一区二区| 色婷婷av一区| 亚洲精品中文在线影院| 99国产精品久久久久久久久久| 中文字幕国产精品一区二区| 国产91精品精华液一区二区三区 | 青青草91视频| 91精品国产手机| 免费日韩伦理电影| 宅男在线国产精品| 日韩精品电影在线| 欧美情侣在线播放| 日本美女一区二区三区| 欧美一级电影网站| 久久99深爱久久99精品| 26uuu久久天堂性欧美| 国产综合色视频| 国产日本欧美一区二区| 成人性色生活片| 亚洲日韩欧美一区二区在线| 欧美性猛片aaaaaaa做受| 午夜亚洲福利老司机| 日韩欧美国产综合| 国产一区二区三区在线看麻豆| 久久久久久久综合日本| caoporm超碰国产精品| 亚洲欧洲综合另类| 91精品国产色综合久久不卡蜜臀 | 色吊一区二区三区| 亚洲国产精品精华液网站| 91精品国产综合久久久久| 精品一区二区三区在线观看| 中文av一区特黄| 欧美色图12p| 久久99久久99精品免视看婷婷 | 综合欧美一区二区三区| 色综合中文综合网| 欧美视频精品在线| 美女视频黄免费的久久| 国产欧美1区2区3区| 在线观看中文字幕不卡| 毛片基地黄久久久久久天堂| 欧美国产禁国产网站cc| 欧美四级电影网| 国产精品1区2区3区| 亚洲综合在线视频| 精品噜噜噜噜久久久久久久久试看| 粉嫩欧美一区二区三区高清影视| 伊人色综合久久天天| 精品处破学生在线二十三| 一本到不卡精品视频在线观看| 久久99精品国产麻豆婷婷洗澡| 亚洲精品你懂的| 欧美精品一区二区三区视频| 99vv1com这只有精品| 极品少妇xxxx精品少妇| 亚洲已满18点击进入久久| 久久精品亚洲精品国产欧美kt∨| 欧洲精品在线观看| 国产成都精品91一区二区三| 石原莉奈在线亚洲二区| ㊣最新国产の精品bt伙计久久| 日韩精品中文字幕一区| 91国模大尺度私拍在线视频| 国产揄拍国内精品对白| 亚洲福利视频导航| 亚洲天堂久久久久久久| 欧美v亚洲v综合ⅴ国产v| 欧美又粗又大又爽| 北条麻妃国产九九精品视频| 国产一区美女在线| 日本在线不卡一区| 一区二区三区在线观看视频 | 国产一区久久久| 欧美96一区二区免费视频| 亚洲主播在线播放| 亚洲欧美日韩电影| 国产欧美日产一区| 精品对白一区国产伦| 欧美一区二区三区四区五区| 欧美日韩黄色一区二区| 91黄色激情网站| 色狠狠桃花综合| 色先锋久久av资源部| 99久久夜色精品国产网站| 成人免费视频国产在线观看| 国产成人在线视频网站| 国产乱子伦视频一区二区三区| 精品一二三四区| 极品少妇一区二区| 国产一区二三区| 国产成人在线视频网址| 国产精品一区二区不卡| 国产凹凸在线观看一区二区| 粉嫩绯色av一区二区在线观看| 懂色av一区二区夜夜嗨| www.欧美日韩国产在线| 91丝袜美女网| 欧美三级欧美一级| 91精品一区二区三区在线观看| 8x8x8国产精品| 日韩亚洲欧美一区二区三区| 欧美电影免费观看高清完整版| 日韩精品一区二区三区老鸭窝| 欧美成人三级在线| 国产亚洲一区二区在线观看| 国产清纯白嫩初高生在线观看91| 中文久久乱码一区二区| 亚洲精品国产成人久久av盗摄 | 久久久久一区二区三区四区| 国产欧美日韩一区二区三区在线观看| 久久久久国产免费免费| 亚洲国产电影在线观看| 亚洲另类春色校园小说| 亚洲五码中文字幕| 久久成人羞羞网站| 波多野结衣视频一区| 在线观看日韩国产| 欧美成人午夜电影| 国产精品久久久久久久久免费丝袜 | 亚洲欧洲韩国日本视频| 亚洲一卡二卡三卡四卡| 免费观看一级欧美片| 国产一区久久久| 色婷婷狠狠综合| 精品国产乱码91久久久久久网站| 国产精品网站在线观看| 亚洲午夜一区二区三区| 国产在线一区二区综合免费视频| 91在线免费播放| 欧美成人一级视频| 亚洲女女做受ⅹxx高潮| 琪琪一区二区三区| 91麻豆国产自产在线观看| 日韩一区二区三区电影在线观看| 国产精品国产自产拍高清av| 日韩精品免费专区| www.视频一区| 久久综合视频网| 亚洲国产精品欧美一二99| 国产精品一二二区| 欧美色欧美亚洲另类二区| 久久精品夜色噜噜亚洲a∨| 亚洲成人先锋电影| 99re这里只有精品首页| 精品国产乱码久久久久久久久| 亚洲午夜在线观看视频在线| 成人午夜又粗又硬又大| 欧美一区二区在线视频| 亚洲少妇30p| 国产精品18久久久| 日韩免费高清av| 爽好多水快深点欧美视频| 91麻豆swag| 国产精品国模大尺度视频| 国产米奇在线777精品观看| 在线不卡免费欧美| 一区二区三区欧美亚洲| 成人国产精品视频| 久久九九全国免费| 久久97超碰色| 欧美一区二区三区在线观看| 亚洲大片在线观看| 在线观看欧美日本| 亚洲精品久久嫩草网站秘色| 成人av一区二区三区| 中文字幕av一区 二区| 国产精品中文字幕欧美| 精品国产91乱码一区二区三区| 奇米精品一区二区三区在线观看 | 色综合久久久久网| 亚洲欧美另类久久久精品2019 | 久久疯狂做爰流白浆xx|