Skip to content

Commit

Permalink
Support dithering in benchmark mode.
Browse files Browse the repository at this point in the history
  • Loading branch information
wolfpld committed May 30, 2014
1 parent 24390cb commit a830b2b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Application.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,14 @@ int main( int argc, char** argv )
auto tasks = new std::future<void>[NumTasks];
for( int i=0; i<NumTasks; i++ )
{
tasks[i] = std::async( [&bmp]()
tasks[i] = std::async( [&bmp, &dither]()
{
auto block = std::make_shared<BlockBitmap>( bmp, Channels::RGB );
auto bd = std::make_shared<BlockData>( bmp->Size(), false );
if( dither )
{
block->Dither();
}
bd->Process( block->Data(), bmp->Size().x * bmp->Size().y / 16, 0, 0, Channels::RGB );
} );
}
Expand Down

0 comments on commit a830b2b

Please sign in to comment.