title: How to print a qr code with brushes in PHP with GD?
body: <p>I have a problem with drawing circles instead of cubes for displaying the qr code.</p>
  
  <p>Here is my code for drawing cubes, I draw only one pixel after that I resize the image to the size I need it. </p>
  
  <pre><code>    ImageSetPixel($myImageRessource,$x,$y,$myColor);
  </code></pre>
  
  <p>After a little research I found a solution for drawing cirles with brushes</p>
  
  <pre><code>            $brush = imagecreatetruecolor(5,5);
              imagefilledellipse($brush,1,1,3,3,$myColor2);
              imagesetbrush($myImageRessource,$brush);
              ImageSetPixel($myImageRessource,$x,$y,$myColor);
  </code></pre>
  
  <p>Using brushes this way should draw a circle instead of a cube but it doesn't. </p>
  
  <p>This is what it should look like</p>
  
  <p><img src="https://i.stack.imgur.com/sck5Z.png" alt="This is what it should look like"></p>
  
  <p>This is what I got</p>
  
  <p><img src="https://i.stack.imgur.com/rQUQ3.jpg" alt="This is what I got"></p>
  
  <p>I don't see what wrong with this code.
  Can somebody give me an advice please. </p>