Index: NewOpenGLGame.vcxproj
===================================================================
--- NewOpenGLGame.vcxproj	(revision 6877ef354ff33fcdc2172e9c02a4a0e016a4df57)
+++ NewOpenGLGame.vcxproj	(revision 9f9f9a7cc841cfce67bdaef5b74e8948bf835d81)
@@ -168,4 +168,8 @@
     <None Include="texture.vert" />
   </ItemGroup>
+  <ItemGroup>
+    <Image Include="laser.png" />
+    <Image Include="test.png" />
+  </ItemGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
   <ImportGroup Label="ExtensionTargets">
Index: TODO.txt
===================================================================
--- TODO.txt	(revision 6877ef354ff33fcdc2172e9c02a4a0e016a4df57)
+++ TODO.txt	(revision 9f9f9a7cc841cfce67bdaef5b74e8948bf835d81)
@@ -30,7 +30,10 @@
 ==================
 -Figure out why rendering doesn't work on the Windows laptop
--Investigate switching to SFML, i.e. create a simple demo of SFML with OpenGL and ImGui
 -Implement lasers
 
 MAJOR TASKS DONE
 ==================
+-Investigate switching to SFML, i.e. create a simple demo of SFML with OpenGL and ImGui
+  -The SFML graphics module requires the compatibility profile, which on OSX is only available for OpenGL < 3.0
+  -I don't think ImGui would work with SFML
+  -When the time comes, maybe just try using the networking and audio components of SFML
Index: laser.frag
===================================================================
--- laser.frag	(revision 6877ef354ff33fcdc2172e9c02a4a0e016a4df57)
+++ laser.frag	(revision 9f9f9a7cc841cfce67bdaef5b74e8948bf835d81)
@@ -1,9 +1,15 @@
 #version 410
 
-in vec3 position_eye, color;
+uniform sampler2D basic_texture;
+uniform vec3 laser_color;
+
+in vec2 texture_coordinates;
+in vec3 position_eye;
 
 out vec4 frag_color;
 
 void main() {
-  frag_color = vec4(color, 1.0f);
+  vec4 texel = texture(basic_texture, texture_coordinates);
+
+  frag_color = vec4(texel.r * laser_color.r, texel.g * laser_color.g, texel.b * laser_color.b, texel.a);
 }
Index: laser.vert
===================================================================
--- laser.vert	(revision 6877ef354ff33fcdc2172e9c02a4a0e016a4df57)
+++ laser.vert	(revision 9f9f9a7cc841cfce67bdaef5b74e8948bf835d81)
@@ -4,11 +4,12 @@
 
 layout(location = 0) in vec3 vertex_position;
-layout(location = 1) in vec3 vertex_color;
+layout(location = 1) in vec2 vt;
 
-out vec3 position_eye, color;
+out vec2 texture_coordinates;
+out vec3 position_eye;
 
 void main() {
   position_eye = vec3(view * vec4(vertex_position, 1.0));
-  color = vertex_color;
+  texture_coordinates = vt;
 
   gl_Position = proj * vec4(position_eye, 1.0);
Index: new-game.cpp
===================================================================
--- new-game.cpp	(revision 6877ef354ff33fcdc2172e9c02a4a0e016a4df57)
+++ new-game.cpp	(revision 9f9f9a7cc841cfce67bdaef5b74e8948bf835d81)
@@ -40,7 +40,10 @@
  *    -The textures should be grayscale and have transparency
  *    -The laser shader should take an input color to blend with the texture to give the lasers color
+ *    -DONE
  * -The lasers should be SceneObjects and drawn like all other objects
  *    -DONE
  * -Make lasers shoot from the ends of the ship's wings when the user presses a button and disappear after a second or so
+ *
+ * NOTE: Asteroid movement currently depends on framerate, fix this in a generic/reusable way
  */
 
@@ -233,5 +236,5 @@
 #endif
 
-   glfwWindowHint(GLFW_SAMPLES, 4);
+   glfwWindowHint(GLFW_SAMPLES, 16);
 
    GLFWwindow* window = NULL;
@@ -304,4 +307,6 @@
    printf("OpenGL version supported %s\n", version);
 
+   glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
+
    glEnable(GL_DEPTH_TEST);
    glDepthFunc(GL_LESS);
@@ -311,4 +316,5 @@
    // glFrontFace(GL_CW);
 
+   /*
    int x, y;
    unsigned char* texImage = loadImage("test.png", &x, &y);
@@ -320,8 +326,29 @@
    }
 
-   GLuint tex = 0;
-   glGenTextures(1, &tex);
+   GLuint testTex = 0;
+   glGenTextures(1, &testTex);
    glActiveTexture(GL_TEXTURE0);
-   glBindTexture(GL_TEXTURE_2D, tex);
+   glBindTexture(GL_TEXTURE_2D, testTex);
+   glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, x, y, 0, GL_RGBA, GL_UNSIGNED_BYTE, texImage);
+
+   glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
+   glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
+   glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
+   glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
+   */
+
+   int x, y;
+   unsigned char* texImage = loadImage("laser.png", &x, &y);
+   if (texImage) {
+      cout << "Laser texture loaded successfully!" << endl;
+      cout << x << endl;
+      cout << y << endl;
+      printf("first 4 bytes are: %i %i %i %i\n", texImage[0], texImage[1], texImage[2], texImage[3]);
+   }
+
+   GLuint laserTex = 0;
+   glGenTextures(1, &laserTex);
+   glActiveTexture(GL_TEXTURE0);
+   glBindTexture(GL_TEXTURE_2D, laserTex);
    glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, x, y, 0, GL_RGBA, GL_UNSIGNED_BYTE, texImage);
 
@@ -948,4 +975,5 @@
    GLuint laser_view_mat_loc = glGetUniformLocation(laser_sp, "view");
    GLuint laser_proj_mat_loc = glGetUniformLocation(laser_sp, "proj");
+   GLuint laser_color_loc = glGetUniformLocation(laser_sp, "laser_color");
 
    glUseProgram(color_sp);
@@ -963,7 +991,9 @@
    glBindBufferRange(GL_UNIFORM_BUFFER, ub_binding_point, ubo, 0, GL_MAX_UNIFORM_BLOCK_SIZE);
 
+
    glUseProgram(laser_sp);
    glUniformMatrix4fv(laser_view_mat_loc, 1, GL_FALSE, value_ptr(view_mat));
    glUniformMatrix4fv(laser_proj_mat_loc, 1, GL_FALSE, value_ptr(proj_mat));
+   glUniform3f(laser_color_loc, 0.2f, 1.0f, 0.2f);
 
    bool cam_moved = false;
@@ -1533,22 +1563,22 @@
 
    obj.points = {
-      start.x + width / 2, start.y, start.z - width,
-      start.x - width / 2, start.y, start.z - width,
+      start.x + width / 2, start.y, start.z - width / 2,
+      start.x - width / 2, start.y, start.z - width / 2,
       start.x - width / 2, start.y, start.z,
-      start.x + width / 2, start.y, start.z - width,
+      start.x + width / 2, start.y, start.z - width / 2,
       start.x - width / 2, start.y, start.z,
       start.x + width / 2, start.y, start.z,
-      end.x + width / 2,   end.y,   end.z + width,
-      end.x - width / 2,   end.y,   end.z + width,
-      start.x - width / 2, start.y, start.z - width,
-      end.x + width / 2,   end.y,   end.z + width,
-      start.x - width / 2, start.y, start.z - width,
-      start.x + width / 2, start.y, start.z - width,
+      end.x + width / 2,   end.y,   end.z + width / 2,
+      end.x - width / 2,   end.y,   end.z + width / 2,
+      start.x - width / 2, start.y, start.z - width / 2,
+      end.x + width / 2,   end.y,   end.z + width / 2,
+      start.x - width / 2, start.y, start.z - width / 2,
+      start.x + width / 2, start.y, start.z - width / 2,
       end.x + width / 2,   end.y,   end.z,
       end.x - width / 2,   end.y,   end.z,
-      end.x - width / 2,   end.y,   end.z + width,
+      end.x - width / 2,   end.y,   end.z + width / 2,
       end.x + width / 2,   end.y,   end.z,
-      end.x - width / 2,   end.y,   end.z + width,
-      end.x + width / 2,   end.y,   end.z + width,
+      end.x - width / 2,   end.y,   end.z + width / 2,
+      end.x + width / 2,   end.y,   end.z + width / 2,
    };
 
@@ -1575,4 +1605,25 @@
    };
 
+   obj.texcoords = {
+      1.0f, 0.5f,
+      0.0f, 0.5f,
+      0.0f, 0.0f,
+      1.0f, 0.5f,
+      0.0f, 0.0f,
+      1.0f, 0.0f,
+      1.0f, 0.51f,
+      0.0f, 0.51f,
+      0.0f, 0.49f,
+      1.0f, 0.51f,
+      0.0f, 0.49f,
+      1.0f, 0.49f,
+      1.0f, 1.0f,
+      0.0f, 1.0f,
+      0.0f, 0.5f,
+      1.0f, 1.0f,
+      0.0f, 0.5f,
+      1.0f, 0.5f,
+   };
+
    obj.num_points = obj.points.size() / 3;
 
@@ -1752,8 +1803,10 @@
       glBindBuffer(GL_ARRAY_BUFFER, selected_colors_vbo);
       glBufferSubData(GL_ARRAY_BUFFER, obj.vertex_vbo_offset * sizeof(GLfloat) * 3, obj.selected_colors.size() * sizeof(GLfloat), &obj.selected_colors[0]);
-
-      glBindBuffer(GL_ARRAY_BUFFER, texcoords_vbo);
-      glBufferSubData(GL_ARRAY_BUFFER, obj.vertex_vbo_offset * sizeof(GLfloat) * 2, obj.texcoords.size() * sizeof(GLfloat), &obj.texcoords[0]);
-
+   }
+
+   glBindBuffer(GL_ARRAY_BUFFER, texcoords_vbo);
+   glBufferSubData(GL_ARRAY_BUFFER, obj.vertex_vbo_offset * sizeof(GLfloat) * 2, obj.texcoords.size() * sizeof(GLfloat), &obj.texcoords[0]);
+
+   if (obj.type != TYPE_LASER) {
       glBindBuffer(GL_ARRAY_BUFFER, normals_vbo);
       glBufferSubData(GL_ARRAY_BUFFER, obj.vertex_vbo_offset * sizeof(GLfloat) * 3, obj.normals.size() * sizeof(GLfloat), &obj.normals[0]);
@@ -1809,8 +1862,12 @@
    glDrawArrays(GL_TRIANGLES, shaderBufferInfo[texture_sp].vbo_base, shaderBufferInfo[texture_sp].vbo_offset);
 
+   glEnable(GL_BLEND);
+
    glUseProgram(laser_sp);
-   glBindVertexArray(color_vao);
+   glBindVertexArray(texture_vao);
 
    glDrawArrays(GL_TRIANGLES, shaderBufferInfo[laser_sp].vbo_base, shaderBufferInfo[laser_sp].vbo_offset);
+
+   glDisable(GL_BLEND);
 }
 
