g2.drawImage(bufImg,null,(int)(-(size/2)*ds),
                                    (int)(-(size/2)*ds));

Figure 6