Fix flickering of images in md2d

[#57495138]