tmpWidth and tmpHeight are unused.