Displaying an Image with OpenGL
?
?

Keyboard Navigation

Global Keys

[, < / ], > Jump to previous / next episode
W, K, P / S, J, N Jump to previous / next marker
t / T Toggle theatre / SUPERtheatre mode
z Toggle filter mode V Revert filter to original state

Menu toggling

q Quotes r References f Filter c Credits

In-Menu Movement

a
w
s
d
h j k l


Quotes and References Menus

Enter Jump to timecode

Quotes, References and Credits Menus

o Open URL (in new tab)

Filter Menu

x, Space Toggle category and focus next
X, ShiftSpace Toggle category and focus previous
v Invert topics / media as per focus

Credits Menu

Enter Open URL (in new tab)
1:13win32_handmade.cpp: Disable PFD_DOUBLEBUFFER
1:13win32_handmade.cpp: Disable PFD_DOUBLEBUFFER
1:13win32_handmade.cpp: Disable PFD_DOUBLEBUFFER
2:04Give it a shot and see our pink window
2:04Give it a shot and see our pink window
2:04Give it a shot and see our pink window
2:33Recap our current situation
2:33Recap our current situation
2:33Recap our current situation
5:07Blackboard: Ways of drawing quads
5:07Blackboard: Ways of drawing quads
5:07Blackboard: Ways of drawing quads
6:47Blackboard: Using two triangles to draw our quadrilateral textures
6:47Blackboard: Using two triangles to draw our quadrilateral textures
6:47Blackboard: Using two triangles to draw our quadrilateral textures
7:52win32_handmade.cpp: Explain glVertex nomenclature
7:52win32_handmade.cpp: Explain glVertex nomenclature
7:52win32_handmade.cpp: Explain glVertex nomenclature
11:08Blackboard: Covering the screen with triangles
11:08Blackboard: Covering the screen with triangles
11:08Blackboard: Covering the screen with triangles
12:03win32_handmade.cpp: Construct our first OpenGL primitive, a triangle
12:03win32_handmade.cpp: Construct our first OpenGL primitive, a triangle
12:03win32_handmade.cpp: Construct our first OpenGL primitive, a triangle
13:00Run the game and "see" our triangle
13:00Run the game and "see" our triangle
13:00Run the game and "see" our triangle
14:03Blackboard: Fixed function vs programmable pipelines
14:03Blackboard: Fixed function vs programmable pipelines
14:03Blackboard: Fixed function vs programmable pipelines
16:49Blackboard: Matrix multiplication
16:49Blackboard: Matrix multiplication
16:49Blackboard: Matrix multiplication
20:06Blackboard: Homogeneous coordinates and affine transforms
20:06Blackboard: Homogeneous coordinates and affine transforms
20:06Blackboard: Homogeneous coordinates and affine transforms
24:35Blackboard: Model View and Projection matrices
24:35Blackboard: Model View and Projection matrices
24:35Blackboard: Model View and Projection matrices
26:52win32_handmade.cpp: Use glLoadIdentity to set the MODELVIEW and PROJECTION matrices to the identity matrix
26:52win32_handmade.cpp: Use glLoadIdentity to set the MODELVIEW and PROJECTION matrices to the identity matrix
26:52win32_handmade.cpp: Use glLoadIdentity to set the MODELVIEW and PROJECTION matrices to the identity matrix
28:59Run the game and see the same thing we started with
28:59Run the game and see the same thing we started with
28:59Run the game and see the same thing we started with
29:04Blackboard: How OpenGL does Clipping
29:04Blackboard: How OpenGL does Clipping
29:04Blackboard: How OpenGL does Clipping
35:04win32_handmade.cpp: Pass glVertex2i the unit cube and then 0.9f
35:04win32_handmade.cpp: Pass glVertex2i the unit cube and then 0.9f
35:04win32_handmade.cpp: Pass glVertex2i the unit cube and then 0.9f
36:11Run the game and see the smaller rectangle
36:11Run the game and see the smaller rectangle
36:11Run the game and see the smaller rectangle
36:47Blackboard: Moving from Clip space to Screen space
36:47Blackboard: Moving from Clip space to Screen space
36:47Blackboard: Moving from Clip space to Screen space
39:47Blackboard: Drawing a texture
39:47Blackboard: Drawing a texture
39:47Blackboard: Drawing a texture
40:34win32_handmade.cpp: Do glColor3f before the two trianges
40:34win32_handmade.cpp: Do glColor3f before the two trianges
40:34win32_handmade.cpp: Do glColor3f before the two trianges
42:00Blackboard: Establishing our u,v texture coordinates
42:00Blackboard: Establishing our u,v texture coordinates
42:00Blackboard: Establishing our u,v texture coordinates
42:25win32_handmade.cpp: Set our texture coordinates
42:25win32_handmade.cpp: Set our texture coordinates
42:25win32_handmade.cpp: Set our texture coordinates
44:17win32_handmade.cpp: Use glTexImage2D to submit a texture to the graphics card
44:17win32_handmade.cpp: Use glTexImage2D to submit a texture to the graphics card
44:17win32_handmade.cpp: Use glTexImage2D to submit a texture to the graphics card
57:38win32_handmade.cpp: Use glTexEnvi and glTexParameteri
57:38win32_handmade.cpp: Use glTexEnvi and glTexParameteri
57:38win32_handmade.cpp: Use glTexEnvi and glTexParameteri
1:00:16Note that we aren't yet specifying the stride
1:00:16Note that we aren't yet specifying the stride
1:00:16Note that we aren't yet specifying the stride
1:01:14win32_handmade.cpp: Explain these parameters
1:01:14win32_handmade.cpp: Explain these parameters
1:01:14win32_handmade.cpp: Explain these parameters
1:04:34Run the game and see that we actually are there yet
1:04:34Run the game and see that we actually are there yet
1:04:34Run the game and see that we actually are there yet
1:04:49"It's all a lie"α
1:04:49"It's all a lie"α
1:04:49"It's all a lie"α
1:06:17Q&A
🗩
1:06:17Q&A
🗩
1:06:17Q&A
🗩
1:06:56ratchetfreak You used static instead of local_persist for Init
🗪
1:06:56ratchetfreak You used static instead of local_persist for Init
🗪
1:06:56ratchetfreak You used static instead of local_persist for Init
🗪
1:07:04win32_handmade.cpp: Introduce global_variable GLuint BlitTextureHandle
1:07:04win32_handmade.cpp: Introduce global_variable GLuint BlitTextureHandle
1:07:04win32_handmade.cpp: Introduce global_variable GLuint BlitTextureHandle
1:08:32nxsy Can we verify the vsync somehow?
🗪
1:08:32nxsy Can we verify the vsync somehow?
🗪
1:08:32nxsy Can we verify the vsync somehow?
🗪
1:09:00SoysauceTheKid Are there any stretching issues when going from u,v coordinates to screen coordinates? If so, how would you fix it?
🗪
1:09:00SoysauceTheKid Are there any stretching issues when going from u,v coordinates to screen coordinates? If so, how would you fix it?
🗪
1:09:00SoysauceTheKid Are there any stretching issues when going from u,v coordinates to screen coordinates? If so, how would you fix it?
🗪
1:09:53macielda The texture name you are binding is always zero after the first iteration
🗪
1:09:53macielda The texture name you are binding is always zero after the first iteration
🗪
1:09:53macielda The texture name you are binding is always zero after the first iteration
🗪
1:10:18insofaras I think in old OpenGL you don't even need glGenTextures, you can just pick your own arbitrary ints
🗪
1:10:18insofaras I think in old OpenGL you don't even need glGenTextures, you can just pick your own arbitrary ints
🗪
1:10:18insofaras I think in old OpenGL you don't even need glGenTextures, you can just pick your own arbitrary ints
🗪
1:10:31win32_handmade.cpp: Set GlobalBlitTextureHandle = 1; rather than using glGenTextures
1:10:31win32_handmade.cpp: Set GlobalBlitTextureHandle = 1; rather than using glGenTextures
1:10:31win32_handmade.cpp: Set GlobalBlitTextureHandle = 1; rather than using glGenTextures
1:12:51robrobby Would Texture Filtering (->GL_NEAREST) even occur when image and texture size is the same as it is now?
🗪
1:12:51robrobby Would Texture Filtering (->GL_NEAREST) even occur when image and texture size is the same as it is now?
🗪
1:12:51robrobby Would Texture Filtering (->GL_NEAREST) even occur when image and texture size is the same as it is now?
🗪
1:13:39garryjohanson In your professional career what GPU library have you preferred, such as OpenGL, DirectX, GLSL, etc.? Which one do you currently use and why?
🗪
1:13:39garryjohanson In your professional career what GPU library have you preferred, such as OpenGL, DirectX, GLSL, etc.? Which one do you currently use and why?
🗪
1:13:39garryjohanson In your professional career what GPU library have you preferred, such as OpenGL, DirectX, GLSL, etc.? Which one do you currently use and why?
🗪
1:14:03ChronalDragon Later on, after we upgrade to more modern OpenGL, will the game render into a framebuffer and then onto the same triangles, or will you just have it render directly to the main window buffer?
🗪
1:14:03ChronalDragon Later on, after we upgrade to more modern OpenGL, will the game render into a framebuffer and then onto the same triangles, or will you just have it render directly to the main window buffer?
🗪
1:14:03ChronalDragon Later on, after we upgrade to more modern OpenGL, will the game render into a framebuffer and then onto the same triangles, or will you just have it render directly to the main window buffer?
🗪
1:15:25macielda Before you removed the Init variable and inline initialization of the texture you were always passing 0 as the name, by the way
🗪
1:15:25macielda Before you removed the Init variable and inline initialization of the texture you were always passing 0 as the name, by the way
🗪
1:15:25macielda Before you removed the Init variable and inline initialization of the texture you were always passing 0 as the name, by the way
🗪
1:15:56macielda So there is no way to blit directly to the back buffer anymore?
🗪
1:15:56macielda So there is no way to blit directly to the back buffer anymore?
🗪
1:15:56macielda So there is no way to blit directly to the back buffer anymore?
🗪
1:17:29robrobby Is there a difference in speed now we use OpenGL to move the buffer to the GPU?
🗪
1:17:29robrobby Is there a difference in speed now we use OpenGL to move the buffer to the GPU?
🗪
1:17:29robrobby Is there a difference in speed now we use OpenGL to move the buffer to the GPU?
🗪
1:19:41garryjohanson Is there a way you know of to optimize PCI transfers between CPU and GPU using OpenGL?
🗪
1:19:41garryjohanson Is there a way you know of to optimize PCI transfers between CPU and GPU using OpenGL?
🗪
1:19:41garryjohanson Is there a way you know of to optimize PCI transfers between CPU and GPU using OpenGL?
🗪
1:22:39sssmcgrath I dunno if this is applicable to the last question, I literally just got here, but glTexSubImage2D could be faster than glTexImage2D
🗪
1:22:39sssmcgrath I dunno if this is applicable to the last question, I literally just got here, but glTexSubImage2D could be faster than glTexImage2D
🗪
1:22:39sssmcgrath I dunno if this is applicable to the last question, I literally just got here, but glTexSubImage2D could be faster than glTexImage2D
🗪
1:23:03Blackboard: glTexImage2D vs glTexSubImage2D
1:23:03Blackboard: glTexImage2D vs glTexSubImage2D
1:23:03Blackboard: glTexImage2D vs glTexSubImage2D
1:29:26quartertron At what point in that chain of gl commands does the card actually get involved? Command dependent? Driver dependent?
🗪
1:29:26quartertron At what point in that chain of gl commands does the card actually get involved? Command dependent? Driver dependent?
🗪
1:29:26quartertron At what point in that chain of gl commands does the card actually get involved? Command dependent? Driver dependent?
🗪
1:30:02Wrap it up
🗩
1:30:02Wrap it up
🗩
1:30:02Wrap it up
🗩