193 |
|
|
194 |
if (lpbiOutput == NULL) |
if (lpbiOutput == NULL) |
195 |
{ |
{ |
196 |
return sizeof(BITMAPV4HEADER); |
return sizeof(BITMAPINFOHEADER); |
197 |
} |
} |
198 |
|
|
199 |
memcpy(outhdr, inhdr, sizeof(BITMAPINFOHEADER)); |
memcpy(outhdr, inhdr, sizeof(BITMAPINFOHEADER)); |
388 |
|
|
389 |
frame.general |= XVID_HQACPRED; |
frame.general |= XVID_HQACPRED; |
390 |
|
|
391 |
|
frame.bframe_threshold = 255; |
392 |
|
|
393 |
if (codec->config.motion_search > 4) |
if (codec->config.motion_search > 4) |
394 |
frame.general |= XVID_INTER4V; |
frame.general |= XVID_INTER4V; |
395 |
|
|
413 |
if (codec->config.reduced_resolution) |
if (codec->config.reduced_resolution) |
414 |
frame.general |= XVID_REDUCED; |
frame.general |= XVID_REDUCED; |
415 |
|
|
416 |
|
if (codec->config.chroma_opt) |
417 |
|
frame.general |= XVID_CHROMAOPT; |
418 |
// added by koepi for credits greyscale |
// added by koepi for credits greyscale |
419 |
|
|
420 |
check_greyscale_mode(&codec->config, &frame, codec->framenum); |
check_greyscale_mode(&codec->config, &frame, codec->framenum); |
584 |
} |
} |
585 |
|
|
586 |
frame.bquant = 0; |
frame.bquant = 0; |
587 |
|
frame.bframe_threshold = 0; |
588 |
|
|
589 |
// OutputDebugString(" "); |
// OutputDebugString(" "); |
590 |
switch (xvid_encore(codec->ehandle, XVID_ENC_ENCODE, &frame, &stats)) |
switch (xvid_encore(codec->ehandle, XVID_ENC_ENCODE, &frame, &stats)) |
608 |
{ |
{ |
609 |
*icc->lpdwFlags = 0; |
*icc->lpdwFlags = 0; |
610 |
} |
} |
611 |
|
if (frame.length == 0) { frame.length = 1; *((unsigned char*)frame.bitstream) = 0x7f; } |
612 |
|
|
613 |
outhdr->biSizeImage = frame.length; |
outhdr->biSizeImage = frame.length; |
614 |
|
|