title: How to fix the blurry image when I run my java swing project
body: <p>I currently studying the java swing builder as a new tech skills. I need to study how to import the image on my canvas. Yes it successfully imported and the image clearly define and not blurry.
  however when I run the project the image that I import to the project it goes blurry. I don't know why it happens. I research some functionality like get scaled but nothing happens it goes same output it get blurry.</p>
  <p>Image Dimension: 250x250</p>
  <p>Here is my code that I implement on my project:</p>
  <pre><code>private Image doctor_ppe = new ImageIcon(LoginScreen.class.getResource(&quot;/assets/large.png&quot;)).getImage().getScaledInstance(250, 250, Image.SCALE_SMOOTH);
  
  
  JLabel lblDds = new JLabel(&quot;&quot;);
      lblDds.setVerticalAlignment(SwingConstants.BOTTOM);
      lblDds.setHorizontalAlignment(SwingConstants.CENTER);
      lblDds.setIcon(new ImageIcon(doctor_ppe));
      lblDds.setBounds(59, 305, 236, 251);
      panel.add(lblDds);
  </code></pre>
  <p>Difference of not runnable project and runnable project:</p>
  <p><strong>Image not blurry:</strong></p>
  <p><a href="https://i.stack.imgur.com/OTF66.png" rel="noreferrer"><img src="https://i.stack.imgur.com/OTF66.png" alt="Not blurry image" /></a></p>
  <p><strong>Image Blurry After I run the project:</strong></p>
  <p><a href="https://i.stack.imgur.com/6PxzP.png" rel="noreferrer"><img src="https://i.stack.imgur.com/6PxzP.png" alt="Blurry Image after i run the project" /></a></p>
  <p>Hope someone experience this, hope will help on my problem
  thank you.</p>