title: Textured Primitives in XNA with a first person camera
body: <p>So I have a XNA application set up. The camera is in first person mode, and the user can move around using the keyboard and reposition the camera target with the mouse. I have been able to load 3D models fine, and they appear on screen no problem. Whenever I try to draw any primitive (textured or not), it does not show up anywhere on the screen, no matter how I position the camera.</p>
  
  <p>In Initialize(), I have:</p>
  
  <pre><code>        quad = new Quad(Vector3.Zero, Vector3.UnitZ, Vector3.Up, 2, 2);
  
          quadVertexDecl = new VertexDeclaration(this.GraphicsDevice, VertexPositionNormalTexture.VertexElements);
  </code></pre>
  
  <p>In LoadContent(), I have:</p>
  
  <pre><code>        quadTexture = Content.Load&lt;Texture2D&gt;(@"Textures\brickWall");
  
          quadEffect = new BasicEffect(this.GraphicsDevice, null);
          quadEffect.AmbientLightColor = new Vector3(0.8f, 0.8f, 0.8f);
          quadEffect.LightingEnabled = true;
          quadEffect.World = Matrix.Identity;
          quadEffect.View = Matrix.CreateLookAt(cameraPosition, cameraTarget, Vector3.Up);
          quadEffect.Projection = this.Projection;
          quadEffect.TextureEnabled = true;
          quadEffect.Texture = quadTexture;
  </code></pre>
  
  <p>And in Draw() I have:</p>
  
  <pre><code>        this.GraphicsDevice.VertexDeclaration = quadVertexDecl;
          quadEffect.Begin();
  
          foreach (EffectPass pass in quadEffect.CurrentTechnique.Passes)
          {
              pass.Begin();
              GraphicsDevice.DrawUserIndexedPrimitives&lt;VertexPositionNormalTexture&gt;(
                       PrimitiveType.TriangleList,
                       quad.Vertices, 0, 4,
                       quad.Indexes, 0, 2);
  
              pass.End();
          }
  
          quadEffect.End();
  </code></pre>
  
  <p>I think I'm doing something wrong in the quadEffect properties, but I'm not quite sure what.</p>