title: Drawing the shape of an image
body: <p>In Java swing, is there any way to draw only the shape of an image, instead of the image itself? And if so, how can I do it?</p>
  
  <p>I added a picture to show you what I mean:
  <a href="https://i.stack.imgur.com/UMvGH.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/UMvGH.jpg" alt="Click here"></a>.</p>
  
  <p>My image would consist of a one-colored shape and a transparent background. My intention is to be able to change the images color.</p>