[cvs] / vfw / src / codec.c Repository:
ViewVC logotype

Diff of /vfw/src/codec.c

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

revision 1.23.2.14, Wed Jan 15 14:41:30 2003 UTC revision 1.23.2.17, Wed Feb 12 13:26:25 2003 UTC
# Line 386  Line 386 
386          frame.general |= XVID_HALFPEL;          frame.general |= XVID_HALFPEL;
387  //      frame.general |= XVID_ME_EPZS;  //      frame.general |= XVID_ME_EPZS;
388    
389            frame.general |= XVID_HQACPRED;
390    
391          if (codec->config.motion_search > 4)          if (codec->config.motion_search > 4)
392                  frame.general |= XVID_INTER4V;                  frame.general |= XVID_INTER4V;
393    
# Line 404  Line 406 
406                  frame.general |= XVID_GMC;                  frame.general |= XVID_GMC;
407    
408          if (codec->config.chromame)          if (codec->config.chromame)
409                  frame.motion |= PMV_CHROMA16;                  frame.motion |= PMV_CHROMA16 + PMV_CHROMA8;
410    
411          if (codec->config.reduced_resolution)          if (codec->config.reduced_resolution)
412                  frame.general |= XVID_REDUCED;                  frame.general |= XVID_REDUCED;
# Line 457  Line 459 
459    
460          frame.motion |= pmvfast_presets[codec->config.motion_search];          frame.motion |= pmvfast_presets[codec->config.motion_search];
461    
462            switch (codec->config.vhq_mode)
463            {
464            case VHQ_MODE_DECISION :
465                    frame.general |= XVID_MODEDECISION_BITS;
466                    break;
467    
468            case VHQ_LIMITED_SEARCH :
469                    frame.general |= XVID_MODEDECISION_BITS;
470                    frame.motion |= HALFPELREFINE16_BITS;
471                    frame.motion |= QUARTERPELREFINE16_BITS;
472                    break;
473    
474            case VHQ_MEDIUM_SEARCH :
475                    frame.general |= XVID_MODEDECISION_BITS;
476                    frame.motion |= HALFPELREFINE16_BITS;
477                    frame.motion |= HALFPELREFINE8_BITS;
478                    frame.motion |= QUARTERPELREFINE16_BITS;
479                    frame.motion |= QUARTERPELREFINE8_BITS;
480                    frame.motion |= CHECKPREDICTION_BITS;
481                    break;
482    
483            case VHQ_WIDE_SEARCH :
484                    frame.general |= XVID_MODEDECISION_BITS;
485                    frame.motion |= HALFPELREFINE16_BITS;
486                    frame.motion |= HALFPELREFINE8_BITS;
487                    frame.motion |= QUARTERPELREFINE16_BITS;
488                    frame.motion |= QUARTERPELREFINE8_BITS;
489                    frame.motion |= CHECKPREDICTION_BITS;
490                    frame.motion |= EXTSEARCH_BITS;
491                    break;
492    
493            default :
494                    break;
495            }
496    
497          frame.image = icc->lpInput;          frame.image = icc->lpInput;
498          frame.stride = (((icc->lpbiInput->biWidth * icc->lpbiInput->biBitCount) + 31) & ~31) >> 3;          frame.stride = (((icc->lpbiInput->biWidth * icc->lpbiInput->biBitCount) + 31) & ~31) >> 3;
499    
# Line 661  Line 698 
698          }          }
699          /* --- yv12 --- */          /* --- yv12 --- */
700    
701          result = decompress_query(codec, lpbiInput, lpbiOutput);          result = decompress_query(codec, lpbiInput, NULL);
702          if (result != ICERR_OK)          if (result != ICERR_OK)
703          {          {
704                  return result;                  return result;
705          }          }
706    
         memcpy(outhdr, inhdr, sizeof(BITMAPINFOHEADER));  
707          outhdr->biSize = sizeof(BITMAPINFOHEADER);          outhdr->biSize = sizeof(BITMAPINFOHEADER);
708          outhdr->biCompression = FOURCC_YUY2;          outhdr->biWidth = inhdr->biWidth;
709            outhdr->biHeight = inhdr->biHeight;
710            outhdr->biPlanes = 1;
711            outhdr->biBitCount = 24;
712            outhdr->biCompression = BI_RGB; /* sonic foundry vegas video v3 only supports BI_RGB */
713          outhdr->biSizeImage = outhdr->biWidth * outhdr->biHeight * outhdr->biBitCount;          outhdr->biSizeImage = outhdr->biWidth * outhdr->biHeight * outhdr->biBitCount;
714          outhdr->biXPelsPerMeter = 0;          outhdr->biXPelsPerMeter = 0;
715          outhdr->biYPelsPerMeter = 0;          outhdr->biYPelsPerMeter = 0;

Legend:
Removed from v.1.23.2.14  
changed lines
  Added in v.1.23.2.17

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