Difference between revisions of "3D Fundamentals Tutorial 2"

From Chilipedia
Jump to: navigation, search
(Video)
(Video)
Line 7: Line 7:
 
<div class="mw-collapsible mw-collapsed"><br />
 
<div class="mw-collapsible mw-collapsed"><br />
 
* Fix an error in <code>Mat2.h</code> (vector * Matrix multiplication) [https://youtu.be/HV1ZGyiY5C8?t=0m16s 0:16]
 
* Fix an error in <code>Mat2.h</code> (vector * Matrix multiplication) [https://youtu.be/HV1ZGyiY5C8?t=0m16s 0:16]
 
+
* Introducing 3D space [https://youtu.be/HV1ZGyiY5C8?t=1m57s 1:57]
 +
* Implementing the <code>Vec3</code> class [https://youtu.be/HV1ZGyiY5C8?t=3m19s 3:19]
 
<div class="mw-collapsible-content">
 
<div class="mw-collapsible-content">
* ...
+
:* Inherits from <code>Vec2</code> (z-component added)
 +
:* Overload all operators for 3D
 +
:* Advantage of inheritence here: enables passing <code>Vec3</code>s into functions that accept <code>Vecc2&</code> references
 
</div>
 
</div>
 +
* Calculating the length of a 3D vector (i.e., in R3) [https://youtu.be/HV1ZGyiY5C8?t=4m57s 4:57]
 +
* The <code>Mat3</code> 3D Matrix class [https://youtu.be/HV1ZGyiY5C8?t=5m57s 5:57]
 +
* Setting up the coordinate system [https://youtu.be/HV1ZGyiY5C8?t=7m37s 7:37]
 +
:*
 +
 +
 +
 +
* ...
 +
 
</div>
 
</div>
  

Revision as of 05:43, 24 April 2020

In this video we lay the groundwork needed to represent and transform positions and 3D space, we define the relationship between our 3D space and the screen coordinates, and we setup a data structure to hold our test cube geometry.

Video

The tutorial video is on YouTube here.


  • Fix an error in Mat2.h (vector * Matrix multiplication) 0:16
  • Introducing 3D space 1:57
  • Implementing the Vec3 class 3:19
  • Inherits from Vec2 (z-component added)
  • Overload all operators for 3D
  • Advantage of inheritence here: enables passing Vec3s into functions that accept Vecc2& references
  • Calculating the length of a 3D vector (i.e., in R3) 4:57
  • The Mat3 3D Matrix class 5:57
  • Setting up the coordinate system 7:37


  • ...

Downloads

The GitHub repository for the tutorial code is here.


See also