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

? 歡迎來(lái)到蟲(chóng)蟲(chóng)下載站! | ?? 資源下載 ?? 資源專(zhuān)輯 ?? 關(guān)于我們
? 蟲(chóng)蟲(chóng)下載站

?? gethdr.c

?? MPEG2編解碼的源代碼.zip
?? C
?? 第 1 頁(yè) / 共 2 頁(yè)
字號(hào):
/* gethdr.c, header decoding                                                *//* Copyright (C) 1996, MPEG Software Simulation Group. All Rights Reserved. *//* * Disclaimer of Warranty * * These software programs are available to the user without any license fee or * royalty on an "as is" basis.  The MPEG Software Simulation Group disclaims * any and all warranties, whether express, implied, or statuary, including any * implied warranties or merchantability or of fitness for a particular * purpose.  In no event shall the copyright-holder be liable for any * incidental, punitive, or consequential damages of any kind whatsoever * arising from the use of these programs. * * This disclaimer of warranty extends to the user of these programs and user's * customers, employees, agents, transferees, successors, and assigns. * * The MPEG Software Simulation Group does not represent or warrant that the * programs furnished hereunder are free of infringement of any third-party * patents. * * Commercial implementations of MPEG-1 and MPEG-2 video, including shareware, * are subject to royalty fees to patent holders.  Many of these patents are * general enough such that they are unavoidable regardless of implementation * design. * */#include <stdio.h>#include "config.h"#include "global.h"/* private prototypes */static void sequence_header _ANSI_ARGS_((void));static void group_of_pictures_header _ANSI_ARGS_((void));static void picture_header _ANSI_ARGS_((void));static void extension_and_user_data _ANSI_ARGS_((void));static void sequence_extension _ANSI_ARGS_((void));static void sequence_display_extension _ANSI_ARGS_((void));static void quant_matrix_extension _ANSI_ARGS_((void));static void sequence_scalable_extension _ANSI_ARGS_((void));static void picture_display_extension _ANSI_ARGS_((void));static void picture_coding_extension _ANSI_ARGS_((void));static void picture_spatial_scalable_extension _ANSI_ARGS_((void));static void picture_temporal_scalable_extension _ANSI_ARGS_((void));static int  extra_bit_information _ANSI_ARGS_((void));static void copyright_extension _ANSI_ARGS_((void));static void user_data _ANSI_ARGS_((void));static void user_data _ANSI_ARGS_((void));/* introduced in September 1995 to assist spatial scalable decoding */static void Update_Temporal_Reference_Tacking_Data _ANSI_ARGS_((void));/* private variables */static int Temporal_Reference_Base = 0;static int True_Framenum_max  = -1;static int Temporal_Reference_GOP_Reset = 0;#define RESERVED    -1 static double frame_rate_Table[16] ={  0.0,  ((23.0*1000.0)/1001.0),  24.0,  25.0,  ((30.0*1000.0)/1001.0),  30.0,  50.0,  ((60.0*1000.0)/1001.0),  60.0,   RESERVED,  RESERVED,  RESERVED,  RESERVED,  RESERVED,  RESERVED,  RESERVED};/* * decode headers from one input stream * until an End of Sequence or picture start code * is found */int Get_Hdr(){  unsigned int code;  for (;;)  {    /* look for next_start_code */    next_start_code();    code = Get_Bits32();      switch (code)    {    case SEQUENCE_HEADER_CODE:      sequence_header();      break;    case GROUP_START_CODE:      group_of_pictures_header();      break;    case PICTURE_START_CODE:      picture_header();      return 1;      break;    case SEQUENCE_END_CODE:      return 0;      break;    default:      if (!Quiet_Flag)        fprintf(stderr,"Unexpected next_start_code %08x (ignored)\n",code);      break;    }  }}/* align to start of next next_start_code */void next_start_code(){  /* byte align */  Flush_Buffer(ld->Incnt&7);  while (Show_Bits(24)!=0x01L)    Flush_Buffer(8);}/* decode sequence header */static void sequence_header(){  int i;  int pos;  pos = ld->Bitcnt;  horizontal_size             = Get_Bits(12);  vertical_size               = Get_Bits(12);  aspect_ratio_information    = Get_Bits(4);  frame_rate_code             = Get_Bits(4);  bit_rate_value              = Get_Bits(18);  marker_bit("sequence_header()");  vbv_buffer_size             = Get_Bits(10);  constrained_parameters_flag = Get_Bits(1);  if((ld->load_intra_quantizer_matrix = Get_Bits(1)))  {    for (i=0; i<64; i++)      ld->intra_quantizer_matrix[scan[ZIG_ZAG][i]] = Get_Bits(8);  }  else  {    for (i=0; i<64; i++)      ld->intra_quantizer_matrix[i] = default_intra_quantizer_matrix[i];  }  if((ld->load_non_intra_quantizer_matrix = Get_Bits(1)))  {    for (i=0; i<64; i++)      ld->non_intra_quantizer_matrix[scan[ZIG_ZAG][i]] = Get_Bits(8);  }  else  {    for (i=0; i<64; i++)      ld->non_intra_quantizer_matrix[i] = 16;  }  /* copy luminance to chrominance matrices */  for (i=0; i<64; i++)  {    ld->chroma_intra_quantizer_matrix[i] =      ld->intra_quantizer_matrix[i];    ld->chroma_non_intra_quantizer_matrix[i] =      ld->non_intra_quantizer_matrix[i];  }#ifdef VERBOSE  if (Verbose_Flag > NO_LAYER)  {    printf("sequence header (byte %d)\n",(pos>>3)-4);    if (Verbose_Flag > SEQUENCE_LAYER)    {      printf("  horizontal_size=%d\n",horizontal_size);      printf("  vertical_size=%d\n",vertical_size);      printf("  aspect_ratio_information=%d\n",aspect_ratio_information);      printf("  frame_rate_code=%d",frame_rate_code);      printf("  bit_rate_value=%d\n",bit_rate_value);      printf("  vbv_buffer_size=%d\n",vbv_buffer_size);      printf("  constrained_parameters_flag=%d\n",constrained_parameters_flag);      printf("  load_intra_quantizer_matrix=%d\n",ld->load_intra_quantizer_matrix);      printf("  load_non_intra_quantizer_matrix=%d\n",ld->load_non_intra_quantizer_matrix);    }  }#endif /* VERBOSE */#ifdef VERIFY  verify_sequence_header++;#endif /* VERIFY */  extension_and_user_data();}/* decode group of pictures header *//* ISO/IEC 13818-2 section 6.2.2.6 */static void group_of_pictures_header(){  int pos;  if (ld == &base)  {    Temporal_Reference_Base = True_Framenum_max + 1; 	/* *CH* */    Temporal_Reference_GOP_Reset = 1;  }  pos = ld->Bitcnt;  drop_flag   = Get_Bits(1);  hour        = Get_Bits(5);  minute      = Get_Bits(6);  marker_bit("group_of_pictures_header()");  sec         = Get_Bits(6);  frame       = Get_Bits(6);  closed_gop  = Get_Bits(1);  broken_link = Get_Bits(1);#ifdef VERBOSE  if (Verbose_Flag > NO_LAYER)  {    printf("group of pictures (byte %d)\n",(pos>>3)-4);    if (Verbose_Flag > SEQUENCE_LAYER)    {      printf("  drop_flag=%d\n",drop_flag);      printf("  timecode %d:%02d:%02d:%02d\n",hour,minute,sec,frame);      printf("  closed_gop=%d\n",closed_gop);      printf("  broken_link=%d\n",broken_link);    }  }#endif /* VERBOSE */#ifdef VERIFY  verify_group_of_pictures_header++;#endif /* VERIFY */  extension_and_user_data();}/* decode picture header *//* ISO/IEC 13818-2 section 6.2.3 */static void picture_header(){  int pos;  int Extra_Information_Byte_Count;  /* unless later overwritten by picture_spatial_scalable_extension() */  ld->pict_scal = 0;     pos = ld->Bitcnt;  temporal_reference  = Get_Bits(10);  picture_coding_type = Get_Bits(3);  vbv_delay           = Get_Bits(16);  if (picture_coding_type==P_TYPE || picture_coding_type==B_TYPE)  {    full_pel_forward_vector = Get_Bits(1);    forward_f_code = Get_Bits(3);  }  if (picture_coding_type==B_TYPE)  {    full_pel_backward_vector = Get_Bits(1);    backward_f_code = Get_Bits(3);  }#ifdef VERBOSE  if (Verbose_Flag>NO_LAYER)  {    printf("picture header (byte %d)\n",(pos>>3)-4);    if (Verbose_Flag>SEQUENCE_LAYER)    {      printf("  temporal_reference=%d\n",temporal_reference);      printf("  picture_coding_type=%d\n",picture_coding_type);      printf("  vbv_delay=%d\n",vbv_delay);      if (picture_coding_type==P_TYPE || picture_coding_type==B_TYPE)      {        printf("  full_pel_forward_vector=%d\n",full_pel_forward_vector);        printf("  forward_f_code =%d\n",forward_f_code);      }      if (picture_coding_type==B_TYPE)      {        printf("  full_pel_backward_vector=%d\n",full_pel_backward_vector);        printf("  backward_f_code =%d\n",backward_f_code);      }    }  }#endif /* VERBOSE */#ifdef VERIFY  verify_picture_header++;#endif /* VERIFY */  Extra_Information_Byte_Count =     extra_bit_information();    extension_and_user_data();  /* update tracking information used to assist spatial scalability */  Update_Temporal_Reference_Tacking_Data();}/* decode slice header *//* ISO/IEC 13818-2 section 6.2.4 */int slice_header(){  int slice_vertical_position_extension;  int quantizer_scale_code;  int pos;  int slice_picture_id_enable = 0;  int slice_picture_id = 0;  int extra_information_slice = 0;  pos = ld->Bitcnt;  slice_vertical_position_extension =    (ld->MPEG2_Flag && vertical_size>2800) ? Get_Bits(3) : 0;  if (ld->scalable_mode==SC_DP)    ld->priority_breakpoint = Get_Bits(7);  quantizer_scale_code = Get_Bits(5);  ld->quantizer_scale =    ld->MPEG2_Flag ? (ld->q_scale_type ? Non_Linear_quantizer_scale[quantizer_scale_code] : quantizer_scale_code<<1) : quantizer_scale_code;  /* slice_id introduced in March 1995 as part of the video corridendum     (after the IS was drafted in November 1994) */  if (Get_Bits(1))  {    ld->intra_slice = Get_Bits(1);    slice_picture_id_enable = Get_Bits(1);	slice_picture_id = Get_Bits(6);    extra_information_slice = extra_bit_information();  }  else    ld->intra_slice = 0;#ifdef VERBOSE  if (Verbose_Flag>PICTURE_LAYER)  {    printf("slice header (byte %d)\n",(pos>>3)-4);    if (Verbose_Flag>SLICE_LAYER)    {      if (ld->MPEG2_Flag && vertical_size>2800)        printf("  slice_vertical_position_extension=%d\n",slice_vertical_position_extension);        if (ld->scalable_mode==SC_DP)        printf("  priority_breakpoint=%d\n",ld->priority_breakpoint);      printf("  quantizer_scale_code=%d\n",quantizer_scale_code);      printf("  slice_picture_id_enable = %d\n", slice_picture_id_enable);      if(slice_picture_id_enable)        printf("  slice_picture_id = %d\n", slice_picture_id);    }  }#endif /* VERBOSE */#ifdef VERIFY  verify_slice_header++;#endif /* VERIFY */  return slice_vertical_position_extension;}/* decode extension and user data *//* ISO/IEC 13818-2 section 6.2.2.2 */static void extension_and_user_data(){  int code,ext_ID;  next_start_code();  while ((code = Show_Bits(32))==EXTENSION_START_CODE || code==USER_DATA_START_CODE)  {    if (code==EXTENSION_START_CODE)    {      Flush_Buffer32();      ext_ID = Get_Bits(4);      switch (ext_ID)      {      case SEQUENCE_EXTENSION_ID:        sequence_extension();        break;      case SEQUENCE_DISPLAY_EXTENSION_ID:        sequence_display_extension();        break;      case QUANT_MATRIX_EXTENSION_ID:        quant_matrix_extension();        break;      case SEQUENCE_SCALABLE_EXTENSION_ID:        sequence_scalable_extension();        break;      case PICTURE_DISPLAY_EXTENSION_ID:        picture_display_extension();        break;      case PICTURE_CODING_EXTENSION_ID:        picture_coding_extension();        break;      case PICTURE_SPATIAL_SCALABLE_EXTENSION_ID:        picture_spatial_scalable_extension();        break;      case PICTURE_TEMPORAL_SCALABLE_EXTENSION_ID:        picture_temporal_scalable_extension();        break;      case COPYRIGHT_EXTENSION_ID:        copyright_extension();        break;     default:        fprintf(stderr,"reserved extension start code ID %d\n",ext_ID);        break;      }      next_start_code();    }    else    {#ifdef VERBOSE      if (Verbose_Flag>NO_LAYER)        printf("user data\n");#endif /* VERBOSE */      Flush_Buffer32();      user_data();    }  }}/* decode sequence extension *//* ISO/IEC 13818-2 section 6.2.2.3 */static void sequence_extension(){  int horizontal_size_extension;  int vertical_size_extension;  int bit_rate_extension;  int vbv_buffer_size_extension;  int pos;  /* derive bit position for trace */#ifdef VERBOSE  pos = ld->Bitcnt;#endif  ld->MPEG2_Flag = 1;  ld->scalable_mode = SC_NONE; /* unless overwritten by sequence_scalable_extension() */  layer_id = 0;                /* unless overwritten by sequence_scalable_extension() */    profile_and_level_indication = Get_Bits(8);  progressive_sequence         = Get_Bits(1);  chroma_format                = Get_Bits(2);  horizontal_size_extension    = Get_Bits(2);  vertical_size_extension      = Get_Bits(2);  bit_rate_extension           = Get_Bits(12);  marker_bit("sequence_extension");  vbv_buffer_size_extension    = Get_Bits(8);  low_delay                    = Get_Bits(1);  frame_rate_extension_n       = Get_Bits(2);  frame_rate_extension_d       = Get_Bits(5);  frame_rate = frame_rate_Table[frame_rate_code] *    ((frame_rate_extension_n+1)/(frame_rate_extension_d+1));  /* special case for 422 profile & level must be made */  if((profile_and_level_indication>>7) & 1)  {  /* escape bit of profile_and_level_indication set */      /* 4:2:2 Profile @ Main Level */    if((profile_and_level_indication&15)==5)    {      profile = PROFILE_422;      level   = MAIN_LEVEL;      }  }  else  {    profile = profile_and_level_indication >> 4;  /* Profile is upper nibble */    level   = profile_and_level_indication & 0xF;  /* Level is lower nibble */  }     horizontal_size = (horizontal_size_extension<<12) | (horizontal_size&0x0fff);  vertical_size = (vertical_size_extension<<12) | (vertical_size&0x0fff);  /* ISO/IEC 13818-2 does not define bit_rate_value to be composed of   * both the original bit_rate_value parsed in sequence_header() and   * the optional bit_rate_extension in sequence_extension_header().    * However, we use it for bitstream verification purposes.    */  bit_rate_value += (bit_rate_extension << 18);  bit_rate = ((double) bit_rate_value) * 400.0;  vbv_buffer_size += (vbv_buffer_size_extension << 10);#ifdef VERBOSE  if (Verbose_Flag>NO_LAYER)  {    printf("sequence extension (byte %d)\n",(pos>>3)-4);    if (Verbose_Flag>SEQUENCE_LAYER)    {      printf("  profile_and_level_indication=%d\n",profile_and_level_indication);      if (profile_and_level_indication<128)      {        printf("    profile=%d, level=%d\n",profile,level);      }      printf("  progressive_sequence=%d\n",progressive_sequence);      printf("  chroma_format=%d\n",chroma_format);      printf("  horizontal_size_extension=%d\n",horizontal_size_extension);      printf("  vertical_size_extension=%d\n",vertical_size_extension);      printf("  bit_rate_extension=%d\n",bit_rate_extension);      printf("  vbv_buffer_size_extension=%d\n",vbv_buffer_size_extension);

?? 快捷鍵說(shuō)明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国内不卡的二区三区中文字幕 | 色综合天天综合网国产成人综合天| 欧美中文一区二区三区| 国产亚洲欧美色| 秋霞午夜av一区二区三区| 91玉足脚交白嫩脚丫在线播放| 久久综合久久综合久久| 午夜日韩在线电影| 色猫猫国产区一区二在线视频| 国产日韩精品一区二区三区 | 亚洲国产欧美日韩另类综合 | 日韩电影在线观看一区| 91在线小视频| 国产欧美va欧美不卡在线| 麻豆精品在线观看| 欧美日韩大陆一区二区| 亚洲精品第一国产综合野| 粉嫩在线一区二区三区视频| 精品国产电影一区二区| 日韩精品成人一区二区在线| 在线观看精品一区| 亚洲人成网站精品片在线观看| 成人一区二区三区视频在线观看| 精品播放一区二区| 蜜臀91精品一区二区三区 | 国产黄人亚洲片| 精品久久久久久久久久久久久久久 | 亚洲一区二区偷拍精品| 91免费视频网址| 国产精品久久久爽爽爽麻豆色哟哟| 国产精品资源站在线| 精品国产亚洲在线| 热久久久久久久| 日韩一区和二区| 免费观看久久久4p| 欧美一级免费观看| 免费成人深夜小野草| 日韩一区二区麻豆国产| 日本va欧美va瓶| 精品久久国产字幕高潮| 国产一区二区中文字幕| 久久久精品日韩欧美| 国产精品18久久久久久久久| 国产欧美中文在线| 成人中文字幕电影| 综合分类小说区另类春色亚洲小说欧美| 成人av集中营| 亚洲精品国产无天堂网2021| 在线一区二区视频| 偷窥少妇高潮呻吟av久久免费| 91精品免费在线| 男女性色大片免费观看一区二区| 欧美α欧美αv大片| 精品一区二区国语对白| 26uuu亚洲综合色欧美| 国产一区二区三区在线观看免费| 久久综合久久综合久久综合| 国产不卡高清在线观看视频| 国产精品成人在线观看| 91黄色激情网站| 婷婷国产在线综合| 欧美成人精品二区三区99精品| 国产最新精品精品你懂的| 中文文精品字幕一区二区| 91日韩在线专区| 视频一区欧美精品| 欧美va天堂va视频va在线| 成人午夜又粗又硬又大| 亚洲日本在线看| 欧美日韩成人高清| 麻豆91精品视频| 欧美国产日韩在线观看| 在线免费精品视频| 男人操女人的视频在线观看欧美| 久久精品一区四区| 91理论电影在线观看| 日本视频在线一区| 欧美激情一区二区| 欧美三级电影精品| 国产麻豆成人传媒免费观看| 亚洲美女免费在线| 日韩一区二区三区电影在线观看| 国产99久久久国产精品免费看 | 久久综合给合久久狠狠狠97色69| 国产成人精品www牛牛影视| 一区二区不卡在线播放| 日韩欧美激情在线| 97精品久久久久中文字幕| 日韩国产在线观看一区| 国产欧美日韩在线看| 欧美日韩中文国产| 高清国产一区二区三区| 亚洲成人手机在线| 国产日韩在线不卡| 欧美日韩你懂得| 国产不卡高清在线观看视频| 亚洲福利电影网| 欧美国产精品久久| 欧美二区在线观看| 9色porny自拍视频一区二区| 日本vs亚洲vs韩国一区三区二区| 国产精品国模大尺度视频| 制服丝袜国产精品| 91蝌蚪国产九色| 国产原创一区二区三区| 亚洲国产精品久久艾草纯爱| 国产日本一区二区| 日韩一区二区三区精品视频| 色婷婷久久综合| 国产综合成人久久大片91| 亚洲成av人片观看| 亚洲日本va午夜在线影院| 精品盗摄一区二区三区| 欧美日精品一区视频| www.亚洲在线| 国产一区在线观看麻豆| 五月综合激情网| 日韩毛片高清在线播放| 国产亚洲精品福利| 日韩一级二级三级| 欧美日韩三级视频| 一本色道a无线码一区v| 国产91丝袜在线播放| 久久国产精品99久久久久久老狼| 亚洲一区二区三区四区五区黄| 中文字幕制服丝袜成人av| 久久婷婷国产综合精品青草| 欧美夫妻性生活| 欧美日韩一区三区| 色伊人久久综合中文字幕| 成人动漫一区二区三区| 国产久卡久卡久卡久卡视频精品| 日韩高清在线不卡| 亚洲国产一区在线观看| 自拍偷拍亚洲激情| 国产精品国产三级国产有无不卡| 精品国产伦一区二区三区观看体验 | 成人国产亚洲欧美成人综合网| 韩国女主播一区| 捆绑紧缚一区二区三区视频| 免费观看91视频大全| 日韩精品欧美成人高清一区二区| 亚洲最大成人网4388xx| 亚洲天堂成人网| 国产精品夫妻自拍| 国产精品久久网站| 国产精品色噜噜| 中文字幕国产一区| 欧美国产日韩精品免费观看| 久久精品日韩一区二区三区| www成人在线观看| 精品国产一区a| www国产成人免费观看视频 深夜成人网| 日韩三级伦理片妻子的秘密按摩| 欧美一区二区三区日韩视频| 欧美丰满美乳xxx高潮www| 欧美挠脚心视频网站| 欧美剧情电影在线观看完整版免费励志电影 | 韩国av一区二区三区四区| 老司机精品视频一区二区三区| 久久激情五月婷婷| 精油按摩中文字幕久久| 精品一二线国产| 国产激情一区二区三区四区| 懂色av噜噜一区二区三区av| 国产91露脸合集magnet| 成人国产亚洲欧美成人综合网| av电影天堂一区二区在线 | 老司机精品视频一区二区三区| 精品在线观看视频| 国产一区二区三区不卡在线观看| 国产成人啪午夜精品网站男同| 成人午夜视频在线观看| 91小视频免费观看| 精品视频999| 日韩欧美在线不卡| 久久综合久久综合亚洲| 国产精品三级在线观看| 亚洲欧美一区二区不卡| 亚洲成人av中文| 另类小说视频一区二区| 国产真实乱子伦精品视频| 成人中文字幕在线| 欧美性猛片aaaaaaa做受| 91精品在线一区二区| 26uuu成人网一区二区三区| 国产精品热久久久久夜色精品三区| 亚洲免费观看在线视频| 日韩经典中文字幕一区| 国产一区二区三区免费观看| 99精品偷自拍| 日韩午夜激情电影| 欧美国产一区在线| 亚洲一区二区三区自拍| 蜜臀av性久久久久蜜臀aⅴ流畅| 国产成人精品免费视频网站| 在线观看网站黄不卡| 精品福利一二区| 亚洲免费视频中文字幕| 久久精品久久精品|