Commit 65ac94db authored by Romain Vimont's avatar Romain Vimont Committed by Luca Barbato

Consume tile contexts to avoid a clone()

Replace par_iter() by into_par_iter() so that the tile contexts may be
consumed.
parent 57112d49
......@@ -2114,10 +2114,10 @@ fn encode_tile_group<T: Pixel>(fi: &FrameInvariants<T>, fs: &mut FrameState<T>)
.tile_iter_mut(fs, &mut blocks)
.zip(cdfs.iter_mut())
.collect::<Vec<_>>()
.par_iter_mut()
.map(|(ref mut ctx, cdf)| {
.into_par_iter()
.map(|(mut ctx, cdf)| {
let raw = encode_tile(fi, &mut ctx.ts, cdf, &mut ctx.tb);
(raw, ctx.ts.rdo.clone())
(raw, ctx.ts.rdo)
})
.unzip();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment