Calculate offset of trimmed spritesheets