[svn] / branches / dev-api-4 / xvidcore / vfw / src / codec.c Repository:
ViewVC logotype

Diff of /branches/dev-api-4/xvidcore/vfw/src/codec.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1061, Tue Jun 10 10:07:03 2003 UTC revision 1193, Tue Oct 28 23:42:09 2003 UTC
# Line 208  Line 208 
208    
209          if (lpbiOutput == NULL)          if (lpbiOutput == NULL)
210          {          {
211                  return sizeof(BITMAPV4HEADER);                  return sizeof(BITMAPINFOHEADER);
212          }          }
213    
214          memcpy(outhdr, inhdr, sizeof(BITMAPINFOHEADER));          memcpy(outhdr, inhdr, sizeof(BITMAPINFOHEADER));
# Line 486  Line 486 
486      for (i=0; i<config->num_zones && config->zones[i].frame <= framenum; i++) ;      for (i=0; i<config->num_zones && config->zones[i].frame <= framenum; i++) ;
487      i--;      i--;
488    
489        frame->type = config->zones[i].type;
490    
491      if (config->zones[i].greyscale) {      if (config->zones[i].greyscale) {
492          frame->vop_flags |= XVID_VOP_GREYSCALE;          frame->vop_flags |= XVID_VOP_GREYSCALE;
493      }      }
# Line 540  Line 542 
542                  frame.motion |= XVID_ME_QUARTERPELREFINE16 | XVID_ME_QUARTERPELREFINE8;                  frame.motion |= XVID_ME_QUARTERPELREFINE16 | XVID_ME_QUARTERPELREFINE8;
543          }          }
544    
545          if ((profiles[codec->config.profile].flags & PROFILE_GMC) && codec->config.gmc)          if ((profiles[codec->config.profile].flags & PROFILE_GMC) && codec->config.gmc) {
546                  frame.vol_flags |= XVID_VOL_GMC;                  frame.vol_flags |= XVID_VOL_GMC;
547                    frame.motion |= XVID_ME_GME_REFINE;
548            }
549    
550          if ((profiles[codec->config.profile].flags & PROFILE_INTERLACE) && codec->config.interlacing)          if ((profiles[codec->config.profile].flags & PROFILE_INTERLACE) && codec->config.interlacing)
551                  frame.vol_flags |= XVID_VOL_INTERLACING;                  frame.vol_flags |= XVID_VOL_INTERLACING;
# Line 562  Line 566 
566                  frame.vop_flags |= XVID_VOP_INTER4V;                  frame.vop_flags |= XVID_VOP_INTER4V;
567    
568          if (codec->config.chromame)          if (codec->config.chromame)
569                  frame.vop_flags |= XVID_ME_CHROMA16 + XVID_ME_CHROMA8;                  frame.motion |= XVID_ME_CHROMA_PVOP + XVID_ME_CHROMA_BVOP;
570    
571            if (codec->config.cartoon_mode) {
572                    frame.vop_flags |= XVID_VOP_CARTOON;
573    #if 0 /* Seems to cause crashes with P4 cpus */
574                    frame.motion |= XVID_ME_DETECT_STATIC_MOTION;
575    #endif
576            }
577    
578          frame.motion |= pmvfast_presets[codec->config.motion_search];          frame.motion |= pmvfast_presets[codec->config.motion_search];
579    
580          switch (codec->config.vhq_mode)          switch (codec->config.vhq_mode)
581          {          {
582          case VHQ_MODE_DECISION :          case VHQ_MODE_DECISION :
583                  frame.vop_flags |= XVID_VOP_MODEDECISION_BITS;                  frame.vop_flags |= XVID_VOP_MODEDECISION_RD;
584                  break;                  break;
585    
586          case VHQ_LIMITED_SEARCH :          case VHQ_LIMITED_SEARCH :
587                  frame.vop_flags |= XVID_VOP_MODEDECISION_BITS;                  frame.vop_flags |= XVID_VOP_MODEDECISION_RD;
588                  frame.motion |= XVID_ME_HALFPELREFINE16_BITS;                  frame.motion |= XVID_ME_HALFPELREFINE16_RD;
589                  frame.motion |= XVID_ME_QUARTERPELREFINE16_BITS;                  frame.motion |= XVID_ME_QUARTERPELREFINE16_RD;
590                  break;                  break;
591    
592          case VHQ_MEDIUM_SEARCH :          case VHQ_MEDIUM_SEARCH :
593                  frame.vop_flags |= XVID_VOP_MODEDECISION_BITS;                  frame.vop_flags |= XVID_VOP_MODEDECISION_RD;
594                  frame.motion |= XVID_ME_HALFPELREFINE16_BITS;                  frame.motion |= XVID_ME_HALFPELREFINE16_RD;
595                  frame.motion |= XVID_ME_HALFPELREFINE8_BITS;                  frame.motion |= XVID_ME_HALFPELREFINE8_RD;
596                  frame.motion |= XVID_ME_QUARTERPELREFINE16_BITS;                  frame.motion |= XVID_ME_QUARTERPELREFINE16_RD;
597                  frame.motion |= XVID_ME_QUARTERPELREFINE8_BITS;                  frame.motion |= XVID_ME_QUARTERPELREFINE8_RD;
598                  frame.motion |= XVID_ME_CHECKPREDICTION_BITS;                  frame.motion |= XVID_ME_CHECKPREDICTION_RD;
599                  break;                  break;
600    
601          case VHQ_WIDE_SEARCH :          case VHQ_WIDE_SEARCH :
602                  frame.vop_flags |= XVID_VOP_MODEDECISION_BITS;                  frame.vop_flags |= XVID_VOP_MODEDECISION_RD;
603                  frame.motion |= XVID_ME_HALFPELREFINE16_BITS;                  frame.motion |= XVID_ME_HALFPELREFINE16_RD;
604                  frame.motion |= XVID_ME_HALFPELREFINE8_BITS;                  frame.motion |= XVID_ME_HALFPELREFINE8_RD;
605                  frame.motion |= XVID_ME_QUARTERPELREFINE16_BITS;                  frame.motion |= XVID_ME_QUARTERPELREFINE16_RD;
606                  frame.motion |= XVID_ME_QUARTERPELREFINE8_BITS;                  frame.motion |= XVID_ME_QUARTERPELREFINE8_RD;
607                  frame.motion |= XVID_ME_CHECKPREDICTION_BITS;                  frame.motion |= XVID_ME_CHECKPREDICTION_RD;
608                  frame.motion |= XVID_ME_EXTSEARCH_BITS;                  frame.motion |= XVID_ME_EXTSEARCH_RD;
609                  break;                  break;
610    
611          default :          default :

Legend:
Removed from v.1061  
changed lines
  Added in v.1193

No admin address has been configured
ViewVC Help
Powered by ViewVC 1.0.4