Drawing Debug Volumes

?

?

W, K, P / S, J, N Jump to previous / next marker

t / T Toggle theatre / SUPERtheatre mode

V Revert filter to original state Y Select link (requires manual Ctrl-c)

X, ShiftSpace Toggle category and focus previous

v Invert topics / media as per focus

# Keyboard Navigation

## Global Keys

[, < / ], > Jump to previous / next episodeW, K, P / S, J, N Jump to previous / next marker

t / T Toggle theatre / SUPERtheatre mode

V Revert filter to original state Y Select link (requires manual Ctrl-c)

## Menu toggling

q Quotes r References f Filter y Link c Credits## In-Menu Movement

a

w

s

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 nextX, ShiftSpace Toggle category and focus previous

v Invert topics / media as per focus

## Filter and Link Menus

z Toggle filter / linking mode## Credits Menu

Enter Open URL (in new tab)⏫

Previous: 'Adding Distance-based Fog'

⏫

0:02Recap and set the stage for the day

0:02Recap and set the stage for the day

0:02Recap and set the stage for the day

3:06Consider approaching alpha fade and upgrading our understanding of the camera

3:06Consider approaching alpha fade and upgrading our understanding of the camera

3:06Consider approaching alpha fade and upgrading our understanding of the camera

5:48Run the game to assess our current situation

5:48Run the game to assess our current situation

5:48Run the game to assess our current situation

8:44Determine to fix the camera code

8:44Determine to fix the camera code

8:44Determine to fix the camera code

9:41handmade_world_mode.cpp and handmade_render_group.cpp: Make PlayWorld() generate fewer rooms and SetCameraTransform() disable the fog in debug mode

9:41handmade_world_mode.cpp and handmade_render_group.cpp: Make PlayWorld() generate fewer rooms and SetCameraTransform() disable the fog in debug mode

12:39Run the game to see that the fog is disabled, and consider how to define the extents of a room

12:39Run the game to see that the fog is disabled, and consider how to define the extents of a room

12:39Run the game to see that the fog is disabled, and consider how to define the extents of a room

16:10Determine to extend the debug rectangles into the third dimension as per Miblo's request

16:10Determine to extend the debug rectangles into the third dimension as per Miblo's request

16:10Determine to extend the debug rectangles into the third dimension as per Miblo's request

17:39Blackboard: Drawing rectangles on sheets

17:39Blackboard: Drawing rectangles on sheets

17:39Blackboard: Drawing rectangles on sheets

18:29handmade_render_group.cpp: Introduce PushVolumeOutline() based on PushCube()

18:29handmade_render_group.cpp: Introduce PushVolumeOutline() based on PushCube()

18:29handmade_render_group.cpp: Introduce PushVolumeOutline() based on PushCube()

22:06Blackboard: Cube edges, faces and vertices

22:06Blackboard: Cube edges, faces and vertices

22:06Blackboard: Cube edges, faces and vertices

23:09handmade_render_group.cpp: Enable PushVolumeOutline() to set the cube vertices

23:09handmade_render_group.cpp: Enable PushVolumeOutline() to set the cube vertices

23:09handmade_render_group.cpp: Enable PushVolumeOutline() to set the cube vertices

25:16Blackboard: Defining cube vertices and edges

25:16Blackboard: Defining cube vertices and edges

25:16Blackboard: Defining cube vertices and edges

28:14handmade_render_group.cpp: Enable PushVolumeOutline() to call PushLineSegment() for each edge

28:14handmade_render_group.cpp: Enable PushVolumeOutline() to call PushLineSegment() for each edge

28:14handmade_render_group.cpp: Enable PushVolumeOutline() to call PushLineSegment() for each edge

31:18Blackboard: Cube edges

31:18Blackboard: Cube edges

31:18Blackboard: Cube edges

36:03handmade_render_group.cpp: Introduce PushLineSegment()

36:03handmade_render_group.cpp: Introduce PushLineSegment()

36:03handmade_render_group.cpp: Introduce PushLineSegment()

41:36Blackboard: Computing thickness for our line segment, an end user-facing approach being to use a distance field in a shader, but using the cross product in a debug scenario

41:36Blackboard: Computing thickness for our line segment, an end user-facing approach being to use a distance field in a shader, but using the cross product in a debug scenario

45:03Blackboard: Differential Geometry (gradient, divergence and curl) and Geometric Algebra (dot and cross product)

45:03Blackboard: Differential Geometry (gradient, divergence and curl) and Geometric Algebra (dot and cross product)

51:00Blackboard: Inner / dot product

51:00Blackboard: Inner / dot product

51:00Blackboard: Inner / dot product

53:04Blackboard: Cross product

53:04Blackboard: Cross product

53:04Blackboard: Cross product

1:00:07Blackboard: Solving for the cross product vectors that go in the same direction

1:00:07Blackboard: Solving for the cross product vectors that go in the same direction

1:00:07Blackboard: Solving for the cross product vectors that go in the same direction

1:06:15Hunt for a computer algebra system to solve our equation

1:06:15Hunt for a computer algebra system to solve our equation

1:06:15Hunt for a computer algebra system to solve our equation

1:13:31Consult the documentation for YACAS

^{1}1:13:31Consult the documentation for YACAS

^{1}1:13:31Consult the documentation for YACAS

^{1}1:15:20Try to plug our equations into YACAS

1:15:20Try to plug our equations into YACAS

1:15:20Try to plug our equations into YACAS

1:17:00Blackboard: Computing the angle between two vectors

1:17:00Blackboard: Computing the angle between two vectors

1:17:00Blackboard: Computing the angle between two vectors

1:19:41Try to prescribe the angle between the vectors

1:19:41Try to prescribe the angle between the vectors

1:19:41Try to prescribe the angle between the vectors

1:20:35View the supposed solution to our equations

1:20:35View the supposed solution to our equations

1:20:35View the supposed solution to our equations

1:22:22Continue the hunt for a computer algebra system

1:22:22Continue the hunt for a computer algebra system

1:22:22Continue the hunt for a computer algebra system

1:25:12Consult the documentation for Maxima

1:25:12Consult the documentation for Maxima

1:25:12Consult the documentation for Maxima

1:27:36Try to plug our equations into Maxima

1:27:36Try to plug our equations into Maxima

1:27:36Try to plug our equations into Maxima

1:29:18View the non-solution

1:29:18View the non-solution

1:29:18View the non-solution

1:30:09Prescribe that the sine must be 1 and view this solution

1:30:09Prescribe that the sine must be 1 and view this solution

1:30:09Prescribe that the sine must be 1 and view this solution

1:30:36Reflect on our foray into computer algebra systems

1:30:36Reflect on our foray into computer algebra systems

1:30:36Reflect on our foray into computer algebra systems

1:32:50Cross product

^{2}1:32:50Cross product

^{2}1:32:50Cross product

^{2}1:35:43handmade_math.h: Introduce Cross()

1:35:43handmade_math.h: Introduce Cross()

1:35:43handmade_math.h: Introduce Cross()

1:39:17Blackboard: How the cross product helps us to produce thickness

1:39:17Blackboard: How the cross product helps us to produce thickness

1:39:17Blackboard: How the cross product helps us to produce thickness

1:41:31handmade_render_group.cpp: Enable PushLineSegment() to compute the normalised perpendicular using Cross() and NOZ()

1:41:31handmade_render_group.cpp: Enable PushLineSegment() to compute the normalised perpendicular using Cross() and NOZ()

1:44:58handmade_render_group.cpp: Enable PushVolumeOutline() to pass the C and Thickness to PushLineSegment()

1:44:58handmade_render_group.cpp: Enable PushVolumeOutline() to pass the C and Thickness to PushLineSegment()

1:46:55handmade_world_mode.cpp: Enable PlayWorld() to call PushVolumeOutline()

1:46:55handmade_world_mode.cpp: Enable PlayWorld() to call PushVolumeOutline()

1:46:55handmade_world_mode.cpp: Enable PlayWorld() to call PushVolumeOutline()

1:47:55Run the game to see our 3D debug cube

1:47:55Run the game to see our 3D debug cube

1:47:55Run the game to see our 3D debug cube

1:48:47handmade_render_group.cpp: Sanity check PushLineSegment()

1:48:47handmade_render_group.cpp: Sanity check PushLineSegment()

1:48:47handmade_render_group.cpp: Sanity check PushLineSegment()

1:49:39Blackboard: Pre-projecting down to the screen

1:49:39Blackboard: Pre-projecting down to the screen

1:49:39Blackboard: Pre-projecting down to the screen

1:50:57handmade_render_group.cpp: Temporarily make PushLineSegment() keep the Line in line with the camera's Z axis

1:50:57handmade_render_group.cpp: Temporarily make PushLineSegment() keep the Line in line with the camera's Z axis

1:51:39Run the game to see that debug cube

1:51:39Run the game to see that debug cube

1:51:39Run the game to see that debug cube

1:52:06handmade_math.h: Sanity check Cross() and consider what is happening

1:52:06handmade_math.h: Sanity check Cross() and consider what is happening

1:52:06handmade_math.h: Sanity check Cross() and consider what is happening

1:53:49handmade_render_group.cpp: Temporarily make PushVolumeOutline() only draw one segment, and run the game to see how that looks

1:53:49handmade_render_group.cpp: Temporarily make PushVolumeOutline() only draw one segment, and run the game to see how that looks

1:56:33handmade_world_mode.cpp: Reduce the thickness and run the game to see the problem when the line is head-on

1:56:33handmade_world_mode.cpp: Reduce the thickness and run the game to see the problem when the line is head-on

1:57:34handmade_render_group.cpp: Enable PushLineSegment() to compensate for the LinePerpLength

1:57:34handmade_render_group.cpp: Enable PushLineSegment() to compensate for the LinePerpLength

1:57:34handmade_render_group.cpp: Enable PushLineSegment() to compensate for the LinePerpLength

1:59:31Blackboard: On losing our length as the angle between the edges reduces to 0

1:59:31Blackboard: On losing our length as the angle between the edges reduces to 0

1:59:31Blackboard: On losing our length as the angle between the edges reduces to 0

2:00:21handmade_render_group.cpp: Continue to enable PushLineSegment() to compensate for the LinePerpLength

2:00:21handmade_render_group.cpp: Continue to enable PushLineSegment() to compensate for the LinePerpLength

2:02:24Run the game to see our current problematic behaviour

2:02:24Run the game to see our current problematic behaviour

2:02:24Run the game to see our current problematic behaviour

2:03:43Blackboard: Computing the perpendicular to the CameraZ

2:03:43Blackboard: Computing the perpendicular to the CameraZ

2:03:43Blackboard: Computing the perpendicular to the CameraZ

2:05:09Q&A

🗩

2:05:09Q&A

🗩

2:05:09Q&A

🗩

2:10:47handmade_entity.cpp: Make UpdateAndRenderEntities() draw collision volumes

2:10:47handmade_entity.cpp: Make UpdateAndRenderEntities() draw collision volumes

2:10:47handmade_entity.cpp: Make UpdateAndRenderEntities() draw collision volumes

2:12:06Run the game to see what that does

2:12:06Run the game to see what that does

2:12:06Run the game to see what that does

2:12:37handmade_render_group.cpp: Make PushVolumeOutline() take the ObjectTransform into account

2:12:37handmade_render_group.cpp: Make PushVolumeOutline() take the ObjectTransform into account

2:12:37handmade_render_group.cpp: Make PushVolumeOutline() take the ObjectTransform into account

2:13:32Run the game to see the collision volumes

2:13:32Run the game to see the collision volumes

2:13:32Run the game to see the collision volumes

2:15:10handmade_render_group.cpp: Enable SetCameraTransform() to set the DebugXForm in both modes, and run the game to see the collision volumes in the game mode

2:15:10handmade_render_group.cpp: Enable SetCameraTransform() to set the DebugXForm in both modes, and run the game to see the collision volumes in the game mode

2:20:50Blackboard: Struct, as a representations of data in memory

2:20:50Blackboard: Struct, as a representations of data in memory

2:20:50Blackboard: Struct, as a representations of data in memory

2:24:12Blackboard: Union, as a combination of structs

2:24:12Blackboard: Union, as a combination of structs

2:24:12Blackboard: Union, as a combination of structs

2:26:21Blackboard: Discriminated union, as a union containing a type field

2:26:21Blackboard: Discriminated union, as a union containing a type field

2:26:21Blackboard: Discriminated union, as a union containing a type field

2:30:03Blackboard: Inheritance in C++

2:30:03Blackboard: Inheritance in C++

2:30:03Blackboard: Inheritance in C++

2:33:11Blackboard: A "single dispatch" example in which a discriminated union and inheritance work equally well

2:33:11Blackboard: A "single dispatch" example in which a discriminated union and inheritance work equally well

2:38:54Blackboard: The tractability of Single vs Double Dispatch

2:38:54Blackboard: The tractability of Single vs Double Dispatch

2:38:54Blackboard: The tractability of Single vs Double Dispatch

2:40:00Blackboard: A "double dispatch" example in which a discriminated union excels

2:40:00Blackboard: A "double dispatch" example in which a discriminated union excels

2:40:00Blackboard: A "double dispatch" example in which a discriminated union excels

2:46:06Blackboard: Generating a sparse matrix containing the cases you care about

2:46:06Blackboard: Generating a sparse matrix containing the cases you care about

2:46:06Blackboard: Generating a sparse matrix containing the cases you care about

2:49:34Blackboard: Discriminated unions shine in enabling the ability to write code which looks at the way in which types are set among more than one object

2:49:34Blackboard: Discriminated unions shine in enabling the ability to write code which looks at the way in which types are set among more than one object

2:55:09Recommend researching category theory, with a call for Pseudonym73

2:55:09Recommend researching category theory, with a call for Pseudonym73

2:55:09Recommend researching category theory, with a call for Pseudonym73

3:00:32Wind down here

🗩

3:00:32Wind down here

🗩

3:00:32Wind down here

🗩

⏬

Next: 'Improving Collision Volumes and the Camera'

⏬