Only use avs2yuv for '.avs' files + update details when the process completes.

This commit is contained in:
LoRd_MuldeR 2012-01-31 15:51:13 +01:00
parent c1d867228e
commit a78ae8f7cd

View File

@ -151,7 +151,7 @@ void EncodeThread::encode(void)
unsigned int frames = 0; unsigned int frames = 0;
//Detect source info //Detect source info
bool usePipe = true; //m_x64 && (QFileInfo(m_sourceFileName).suffix().compare("avs", Qt::CaseInsensitive) == 0); bool usePipe = (QFileInfo(m_sourceFileName).suffix().compare("avs", Qt::CaseInsensitive) == 0);
if(usePipe) if(usePipe)
{ {
log(tr("\n--- AVS INFO ---\n")); log(tr("\n--- AVS INFO ---\n"));
@ -344,7 +344,22 @@ bool EncodeThread::runEncodingPass(bool x64, bool usePipe, unsigned int frames,
return false; return false;
} }
setStatus((pass == 2) ? JobStatus_Running_Pass2 : ((pass == 1) ? JobStatus_Running_Pass1 : JobStatus_Running)); switch(pass)
{
case 1:
setStatus(JobStatus_Running_Pass1);
setDetails(tr("First pass completed. Preparing for second pass..."));
break;
case 2:
setStatus(JobStatus_Running_Pass2);
setDetails(tr("Second pass completed successfully."));
break;
default:
setStatus(JobStatus_Running);
setDetails(tr("Encode completed successfully."));
break;
}
setProgress(100); setProgress(100);
processEncode.close(); processEncode.close();
processAvisynth.close(); processAvisynth.close();