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

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

?? ldecod.c

?? Mobile IP VCEG的信道模擬程序
?? C
?? 第 1 頁 / 共 3 頁
字號:
/*!
 *	\file
 *			Ldecod.c	
 *	\brief
 *			TML decoder project main()
 *	\author
 *			Main contributors (see contributors.h for copyright, address and affiliation details)
 *
 *			Inge Lille-Lang鴜       <inge.lille-langoy@telenor.com>
 *			Rickard Sjoberg         <rickard.sjoberg@era.ericsson.se>
 *			Stephan Wenger		    <stewe@cs.tu-berlin.de>
 *			Jani Lainema		    <jani.lainema@nokia.com>
 *			Sebastian Purreiter		<sebastian.purreiter@mch.siemens.de>
 *			Byeong-Moon Jeon		<jeonbm@lge.com>
 *      Gabi Blaettermann               <blaetter@hhi.de>
 *
 *	\note	tags are used for document system "doxygen"
 *			available at http://www.stack.nl/~dimitri/doxygen/index.html
 *
 *		
 * 
 * 	\note
 *		-Limitations:
 *			Using different NAL's the assignment of partition-id to containing
 *			syntax elements may got lost, if this information is not transmitted.
 *			The same has to be stated for the partitionlength if partitions are
 *			merged by the NAL. \par
 *		
 *			The presented solution in Q15-K-16 solves both of this problems as the
 *			departitioner parses the bitstream before decoding. Due to syntax element 
 *			dependencies both, partition bounds and partitionlength information can
 *			be parsed by the departitioner. \par
 *		
 *		-Handling partition information in external file:
 *			As the TML is still a work in progress, it makes sense to handle this 
 *			information for simplification in an external file, here called partition 
 *			information file, which can be found by the extension .dp extending the 
 *			original encoded H.26L bitstream. In this file partition-ids followed by its
 *			partitionlength is written. Instead of parsing the bitstream we get the 
 *			partition information now out of this file. 
 *			This information is assumed to be never sent over transmission channels 
 *			(simulation scenarios) as it's information we allways get using a 
 *			"real" departitioner before decoding \par
 *
 *		-Extension of Interim File Format:
 *			Therefore a convention has to be made within the interim file format.
 *			The underlying NAL has to take care of fulfilling these conventions.
 *			All partitions have to be bytealigned to be readable by the decoder, 
 *			So if the NAL-encoder merges partitions, >>this is only possible to use the 
 *			VLC	structure of the H.26L bitstream<<, this bitaligned structure has to be 
 *			broken up by the NAL-decoder. In this case the NAL-decoder is responsable to 
 *			read the partitionlength information from the partition information file.
 *			Partitionlosses are signaled with a partition of zero length containing no
 *			syntax elements.
 *
 *	
 */

#include "contributors.h"

#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <time.h>
#include <sys/timeb.h>

#include "global.h"
#include "elements.h"
#include "bitsbuf.h"

#define TML			"6"
#define VERSION		"6.50"
#define LOGFILE		"log.dec"
#define DATADECFILE	"data.dec"
#define TRACEFILE	"trace_dec.txt"

/*! 
 *	\fn		main()
 *	\brief	main function for TML decoder
 */

int main(int argc, char **argv)
{
    struct inp_par    *inp;         /* input parameters from input configuration file   */
	struct snr_par    *snr;         /* statistics                                       */
	struct img_par    *img;         /* image parameters                                 */

    /* allocate memory for the structures */
	inp =  (struct inp_par *)calloc(1, sizeof(struct inp_par));
	snr =  (struct snr_par *)calloc(1, sizeof(struct snr_par));
	img =  (struct img_par *)calloc(1, sizeof(struct img_par));

	/* Read Configuration File */
    if (argc != 2)
	{
		fprintf(stdout,"Usage: %s <config.dat> \n",argv[0]);
		fprintf(stdout,"\t<config.dat> defines decoder parameters\n");
		exit(-1);
	}
    
    /* Initializes Configuration Parameters with configuration file */
	init_conf(inp, argv[1]);
	
    /* Allocate Slice data struct */
	malloc_slice(inp,img);

	init(img);
	img->number=0;

	/* B pictures */
	Bframe_ctr=0;

    /* time for total decoding session */
    tot_time = 0;
   
    while (decode_one_frame(img, inp, snr) != EOS);
    
    // B PICTURE : save the last P picture
	write_prev_Pframe(img, p_out);

    report(inp, img, snr);

    free_slice(inp,img);
    free_mem4global_buffers(inp, img);

	CloseBitstreamFile();

    fclose(p_out);
    fclose(p_ref);
#if TRACE
    fclose(p_trace);
#endif
	return 0;
}


/*!
 *	\fn		init()
 *	\brief	Initilize some arrays
 */
void init(struct img_par *img)	/*!< image parameters */
{
	int i;
	/* initilize quad matrix used in snr routine */

	for (i=0; i <  256; i++)
	{
		img->quad[i]=i*i; /* fix from TML 1, truncation removed */
	}
}

/************************************************************************
*
*  Name :       init_conf(struct inp_par *inp, char *config_filename)
*
*  Description: Read input from configuration file
*
*  Input      : Name of configuration filename
*
*  Output     : none
*
************************************************************************/

void init_conf(struct inp_par *inp,
               char *config_filename)
{
	FILE *fd;
    int NAL_mode;
    //char string[255];

    /* read the decoder configuration file */
	if((fd=fopen(config_filename,"r")) == NULL)           
	{
		fprintf(stdout,"Error: Control file %s not found\n",config_filename);
		exit(0);
	}

	fscanf(fd,"%s",inp->infile);                /* H.26L compressed input bitsream */ 
	fscanf(fd,"%*[^\n]");

	fscanf(fd,"%s",inp->outfile);               /* YUV 4:2:2 input format */
	fscanf(fd,"%*[^\n]");

	fscanf(fd,"%s",inp->reffile);               /* reference file */
	fscanf(fd,"%*[^\n]");

    /* Symbol mode */
	fscanf(fd,"%d,",&inp->symbol_mode);        /* 0: UVLC 1: CABAC */
	fscanf(fd,"%*[^\n]");
	if (inp->symbol_mode != UVLC && inp->symbol_mode != CABAC)
	{
		sprintf(errortext, "Unsupported symbol mode=%d, use UVLC=0 or CABAC=1\n",inp->symbol_mode);
		error(errortext);
	}

	/* Frame buffer size */
	fscanf(fd,"%d,",&inp->buf_cycle);
	fscanf(fd,"%*[^\n]");
	if (inp->buf_cycle < 1)
	{
		sprintf(errortext, "Frame Buffer Size is %d. It has to be at least 1\n",inp->buf_cycle);
		error(errortext);
	}

	fscanf(fd,"%d",&(NAL_mode));                /* NAL mode */
    fscanf(fd,"%*[^\n]");

    switch(NAL_mode)
	{
	case 0:
		inp->of_mode = PAR_OF_26L;
		/* Note: Data Partitioning in 26L File Format not yet supported */
		inp->partition_mode = PAR_DP_1;
		break;
	default:
		printf("NAL mode %i is not supported\n", NAL_mode);
		exit(1);
	}


#if TRACE
	sprintf(string,"%s",TRACEFILE);
	if ((p_trace=fopen(string,"w"))==0)             /* append new statistic at the end */
	{
		printf("Error open file %s!\n",string);
		exit(0);
	}
#endif
    	
    
//    if ((p_in=fopen(inp->infile,"rb"))==0)
//	{
//		fprintf(stdout,"Input file %s does not exist \n",inp->infile);
//		exit(0);
//	}
	
	if (OpenBitstreamFile (inp->infile) < 0) {
			printf ("Cannot open bitstream file '%s'\n", inp->infile);
			exit (-1);
	}
	if ((p_out=fopen(inp->outfile,"wb"))==0)
	{
		fprintf(stdout,"Error open file %s  \n",inp->outfile);
		exit(0);
	}

    fprintf(stdout,"--------------------------------------------------------------------------\n");
	fprintf(stdout," Decoder config file                    : %s \n",config_filename);
	fprintf(stdout,"--------------------------------------------------------------------------\n");
	fprintf(stdout," Input H.26L bitstream                  : %s \n",inp->infile);
	fprintf(stdout," Output decoded YUV 4:2:0               : %s \n",inp->outfile);
	fprintf(stdout," Output status file                     : %s \n",LOGFILE);
	if ((p_ref=fopen(inp->reffile,"rb"))==0)
	{
		fprintf(stdout," Input reference file                   : %s does not exist \n",inp->reffile);
		fprintf(stdout,"                                          SNR values are not available\n");
	}
	else
		fprintf(stdout," Input reference file                   : %s \n",inp->reffile);
	fprintf(stdout,"--------------------------------------------------------------------------\n");


	fprintf(stdout,"Frame   TR    QP  SnrY    SnrU    SnrV   Time(ms)\n");
}
/************************************************************************
*
*  Name :       void report()
*
*  Description: Reports the gathered information to appropriate outputs
*
*  Input      : struct inp_par *inp, 
*				struct img_par *img, 
*				struct snr_par *stat
*
*  Output     : None
*
************************************************************************/
void report(struct inp_par *inp, struct img_par *img, struct snr_par *snr)
{
    char string[255];
    FILE *p_log;

#ifndef WIN32
    time_t	now;
    struct tm	*l_time;
#else
    char timebuf[128];
#endif

	fprintf(stdout,"-------------------- Average SNR all frames ------------------------------\n");
	fprintf(stdout," SNR Y(dB)           : %5.2f\n",snr->snr_ya);
	fprintf(stdout," SNR U(dB)           : %5.2f\n",snr->snr_ua);
	fprintf(stdout," SNR V(dB)           : %5.2f\n",snr->snr_va);
	fprintf(stdout," Total decoding time : %.3f sec \n",tot_time*0.001); 
	fprintf(stdout,"--------------------------------------------------------------------------\n");
	fprintf(stdout," Exit TML %s decoder, ver %s \n",TML,VERSION);

	/* write to log file */

	sprintf(string, "%s", LOGFILE);
	if (fopen(string,"r")==0)                    /* check if file exist */
	{
		if ((p_log=fopen(string,"a"))==0)
		{
			fprintf(stdout,"Error open file %s for appending\n",string);
			exit(0);
		}
		else                                              /* Create header to new file */
		{
			fprintf(p_log," ------------------------------------------------------------------------------------------\n");
			fprintf(p_log,"|  Decoder statistics. This file is made first time, later runs are appended               |\n");
			fprintf(p_log," ------------------------------------------------------------------------------------------ \n");
			fprintf(p_log,"| Date  | Time  |    Sequence        |#Img|Format|SNRY 1|SNRU 1|SNRV 1|SNRY N|SNRU N|SNRV N|\n");

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
中文字幕在线观看不卡视频| 欧美—级在线免费片| 26uuu久久天堂性欧美| 一区在线播放视频| 免费成人av资源网| 色婷婷久久综合| 久久综合色天天久久综合图片| 一区二区视频在线| 岛国av在线一区| 欧美大片日本大片免费观看| 亚洲另类春色校园小说| 国产精品白丝jk白祙喷水网站| 在线电影院国产精品| 亚洲少妇30p| 国产v综合v亚洲欧| 久久久影视传媒| 久久精品国产亚洲一区二区三区| 在线观看亚洲一区| 亚洲视频图片小说| av在线一区二区| 国产精品免费看片| 国产精品一区二区久久精品爱涩| 精品88久久久久88久久久| 亚洲在线观看免费视频| 色呦呦国产精品| 亚洲三级电影全部在线观看高清| 成人自拍视频在线| 国产亚洲1区2区3区| 国产剧情一区在线| 精品欧美乱码久久久久久1区2区 | 91搞黄在线观看| 亚洲视频一区二区在线观看| 波多野结衣欧美| 日韩毛片视频在线看| 99re这里只有精品视频首页| 中文字幕中文字幕在线一区 | 欧美无人高清视频在线观看| 亚洲免费成人av| 欧美艳星brazzers| 亚洲福中文字幕伊人影院| 在线观看欧美精品| 午夜成人免费电影| 日韩欧美国产不卡| 国产美女精品在线| 成人欧美一区二区三区1314| 不卡一区中文字幕| 亚洲一区二区三区在线看| 在线播放视频一区| 精品一区二区三区在线播放视频 | 亚洲精品高清在线| 欧美午夜不卡视频| 日本欧美久久久久免费播放网| 日韩亚洲欧美一区| 国产精品自拍毛片| 亚洲免费在线电影| 91精品国产福利| 国产精品综合视频| 一区二区在线看| 91精品国产综合久久小美女| 国产美女主播视频一区| 亚洲欧美视频在线观看视频| 欧美精品粉嫩高潮一区二区| 久久99久久久久久久久久久| 亚洲国产高清不卡| 欧美日韩国产一区二区三区地区| 极品美女销魂一区二区三区| 自拍偷拍亚洲综合| 69精品人人人人| 国产99精品国产| 亚洲午夜久久久久久久久久久| 日韩一区二区三区精品视频| 9l国产精品久久久久麻豆| 亚洲成人自拍网| 中文成人av在线| 91精品欧美久久久久久动漫| 成a人片亚洲日本久久| 日日骚欧美日韩| 国产精品传媒视频| 精品久久免费看| 91猫先生在线| 韩国成人在线视频| 亚洲福利电影网| 国产精品三级av| 欧美一区二区性放荡片| 91丨国产丨九色丨pron| 狠狠色丁香久久婷婷综| 亚洲123区在线观看| 国产精品久久久久久久久免费桃花 | 另类调教123区| 亚洲黄色小视频| 国产精品国产三级国产aⅴ中文| 337p亚洲精品色噜噜| 91蜜桃网址入口| 国产精品羞羞答答xxdd| 久久成人综合网| 亚洲高清在线视频| 国产精品久久久久国产精品日日| 精品久久五月天| 欧美精品九九99久久| 欧美午夜片在线观看| 99视频精品全部免费在线| 国内久久婷婷综合| 久久国产三级精品| 麻豆91在线看| 美日韩黄色大片| 蜜臀a∨国产成人精品| 日韩中文字幕一区二区三区| 亚洲成av人片一区二区| 亚洲激情六月丁香| 最近日韩中文字幕| 亚洲欧美日韩国产成人精品影院 | 日韩理论片在线| 中文字幕久久午夜不卡| 国产欧美一区二区精品性色超碰 | 欧美日产国产精品| 欧美日韩精品一区二区天天拍小说 | 亚洲欧洲av在线| 色哟哟一区二区在线观看| 日本中文字幕一区二区有限公司| 精品国产露脸精彩对白 | 欧美三片在线视频观看| 激情久久五月天| 国内精品久久久久影院色| 毛片不卡一区二区| 日韩成人伦理电影在线观看| 轻轻草成人在线| 国内精品伊人久久久久影院对白| 精品一区二区三区在线观看 | 91精品久久久久久久91蜜桃 | 亚洲国产高清不卡| 成人免费一区二区三区视频 | 久久精品视频免费观看| 欧美激情综合五月色丁香小说| 国产精品久久看| 亚洲精品国产成人久久av盗摄 | 在线电影院国产精品| 欧美一区二区在线不卡| 久久综合久久综合久久综合| 欧美激情中文字幕一区二区| 亚洲狼人国产精品| 首页综合国产亚洲丝袜| 久久99精品久久久| 成人精品gif动图一区| 色悠悠亚洲一区二区| 欧美一区二区三区系列电影| 久久日韩粉嫩一区二区三区 | 色综合久久天天综合网| 在线播放一区二区三区| 国产亚洲污的网站| √…a在线天堂一区| 香蕉成人啪国产精品视频综合网| 美女脱光内衣内裤视频久久网站| 国产一区不卡视频| 在线视频国内一区二区| 欧美大片日本大片免费观看| 亚洲嫩草精品久久| 精油按摩中文字幕久久| 91丨九色丨蝌蚪丨老版| 日韩欧美一级片| 国产女人水真多18毛片18精品视频| 一区二区日韩电影| 久久国产精品72免费观看| 一本大道久久a久久综合婷婷| 精品少妇一区二区三区在线播放| 国产精品久久久久久久久免费桃花 | 亚洲特级片在线| 久久国产精品色婷婷| 91黄色免费网站| 久久免费美女视频| 性做久久久久久免费观看欧美| 成人一二三区视频| 日韩一区二区电影在线| 一区二区三区精品在线观看| 国产高清在线观看免费不卡| 91精品国产综合久久蜜臀| 亚洲欧美日韩综合aⅴ视频| 精品无码三级在线观看视频| 欧美视频一区二| 亚洲天天做日日做天天谢日日欢 | 日韩成人一区二区| 99久久99久久精品国产片果冻| 精品国产乱码久久久久久闺蜜| 亚洲bdsm女犯bdsm网站| 色综合久久久久综合体桃花网| 国产夜色精品一区二区av| 美女在线视频一区| 7777精品伊人久久久大香线蕉经典版下载 | a4yy欧美一区二区三区| 国产日韩欧美电影| 国产在线不卡一卡二卡三卡四卡| 在线成人高清不卡| 亚洲一级二级三级在线免费观看| 99国产精品久久久久| 国产欧美日韩久久| 国产乱子伦一区二区三区国色天香| 欧美一区三区二区| 日韩av中文字幕一区二区三区| 欧美日韩亚洲另类| 亚洲国产精品人人做人人爽| 在线观看亚洲精品|