title: glPolygonMode different behavior when rendering a texture?
body: <p>I have a quad which I store using an EBO (it has some positional and texture coord attributes:</p>
  <p><a href="https://i.stack.imgur.com/PXDOr.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/PXDOr.png" alt="enter image description here" /></a></p>
  <p>I can draw it using polygons like this</p>
  <pre><code>glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
  </code></pre>
  <p><a href="https://i.stack.imgur.com/HwKcF.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/HwKcF.png" alt="enter image description here" /></a></p>
  <p>Now if I remove that line and just switch to a shader using textures, I have a sprite being drawn.</p>
  <p><a href="https://i.stack.imgur.com/pdvNN.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/pdvNN.png" alt="enter image description here" /></a></p>
  <p>Now if I turn on the glPolygonMode with GL_LINE again, I get this</p>
  <p><a href="https://i.stack.imgur.com/bWcPU.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/bWcPU.png" alt="enter image description here" /></a></p>
  <p>The expected behavior: I expected to see a wireframe exactly like image #2, but I'm instead seeing something quite different. Is this normal? What could be causing this?</p>
  <p>The only thing I did that was different was just change shaders.</p>