[Toolkit.Graphics] Fix calculation for mipmap counts