Unverified Commit 7518a146 authored by Yegor's avatar Yegor Committed by GitHub

Do not call Picture.toImage on web during shader warm-up (#60379)

parent 76946829
......@@ -91,7 +91,10 @@ abstract class ShaderWarmUp {
final ui.Picture picture = recorder.endRecording();
final TimelineTask shaderWarmUpTask = TimelineTask();
shaderWarmUpTask.start('Warm-up shader');
await picture.toImage(size.width.ceil(), size.height.ceil());
// Picture.toImage is not yet implemented on the web.
if (!kIsWeb) {
await picture.toImage(size.width.ceil(), size.height.ceil());
}
shaderWarmUpTask.finish();
}
}
......
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