Fixed a big regression where the "omp" tag was not correct. Also, restructured the encoder to be much faster, and changed "omp master" to "omp single".

This commit is contained in:
Jonathan Thomas
2012-08-28 15:53:18 -05:00
parent c564a15ced
commit 0f3758bc29
4 changed files with 108 additions and 77 deletions

View File

@@ -319,7 +319,7 @@ Frame* FFmpegReader::ReadStream(int requested_frame)
//omp_set_num_threads(1);
#pragma omp parallel
{
#pragma omp master
#pragma omp single
{
// Loop through the stream until the correct frame is found
while (true)
@@ -407,11 +407,7 @@ Frame* FFmpegReader::ReadStream(int requested_frame)
} // end while
} // end omp master
// Be sure all threads are finished
#pragma omp barrier
} // end omp single
} // end omp parallel