Skip to content

keechang-choi/Vulkan-Game-Engine-Tutorial

Repository files navigation

Vulkan-Game-Engine-Tutorial

practice repo for Vulkan game engine lecture and Vulkan tutorial
all the base codes and materials from

Summary

  • ~Lec08

    • covered:
      • env setup
      • window, glfw, glm, RAII
      • pipeline, shader, glsl
      • device, validatioin layer,
      • pipeline stage configuration, pipeline layout, render pass
      • frame buffer, v-sync, swap chain
      • command buffer, recording
      • vertex buffer, binding, attribute
      • interpolation
      • swap chain recreation, dynamic viewport and scissors
    • vulkan-tut-08-01
  • Lec09

    • covered:
      • push constants
      • shader alignment requirement
    • vulkan-tut-09-01
  • Lec10

  • Lec11

    • covered:
      • refactoring -> rederer/ render system
      • reder pass compatibility
      • break one-to-one correspondence between swap chain image and command buffer.
    • bonus: gravity simulation vulkan-tut-11-01
  • Lec12

    • covered:

      • homogeneous coordinates
      • Euler angle
      • 3d rendering
    • intrinsic rotation, extrinsic rotation

      intrinsic rotation, extrinsic rotation

      https://math.stackexchange.com/questions/1137745/proof-of-the-extrinsic-to-intrinsic-rotation-transform

      4개의 basis와 변환. rotation mat들은 모두 similar.

      $$ \begin{align} P_0 = S_{world_0}^{-1} \\ P_0: xyz \rightarrow x_0y_0z_0 \\ P_1: x_0y_0z_0 \rightarrow x_1y_1z_1 \\ P_2: x_1y_1z_1 \rightarrow x_2y_2z_2 \end{align} $$

      intrinsic xyz 순서로 alpha, beta, gamma 회전을 한다는것은 다음 mat연산

      $$ R = Z''(\gamma) P_2 Y'(\beta) P_1 X(\alpha) $$

      $$ \begin{align} X: A_{x_{0} y_{0} z_{0}} \rightarrow A_{x_{0} y_{0} z_{0}} \\ Y' P_1: A_{x_{0} y_{0} z_{0}} \rightarrow A_{x_{1} y_{1} z_{1}} \\ Z'' P_2: A_{x_{1} y_{1} z_{1}} \rightarrow A_{x_{2} y_{2} z_{2}} \end{align} $$

      Claim) : extrinsic으로 볼 수도 있다. (회전 축 순서는 반대방향)

      $$ \begin{align} S_{world_2}Z''(\gamma) P_2 Y'(\beta) P_1 X(\alpha) S_{world_0}^{-1} = X^{*}(\alpha) Y^{*}(\beta) Z^{*}(\gamma) \\ where \; S_{world_2} = (P_0 P_1 P_2)^{-1} \; and \; S_{world_0}^{-1} = P_0 \\ X^{*}: A_{xyz} \rightarrow A_{xyz} \\ Y^{*}: A_{xyz} \rightarrow A_{xyz} \\ Z^{*}: A_{xyz} \rightarrow A_{xyz} \end{align} $$

      Pf)

      $$ \begin{align} Y^{*} = S_{world_1} Y' S_{world_1}^{-1} = (P_1 P_0)^{-1} Y'(P_1 P_0) \\ Z^{*} = (P_2 P_1 P_0)^{-1} Z''(P_2 P_1 P_0) \\ \Rightarrow X^{*} Y^{*} Z^{*} = S_{world_2} Z''P_2 Y' P_1 X P_0 = \\ P_0^{-1}(P_1^{-1} P_2^{-1} Z''P_2 Y' P_1 X ) P_0 \end{align} $$

  • Lec13

    • covered:
      • projection
        • orthographic
        • perspective
      • homogeneous coordinates
    • tut13
  • Lec14

    • covered:
      • cameara transformation
      • Viewing transformation (model - camera - perspective - orthographic - viewport)
  • Lec15

    • covered:
      • game loop and time
      • camera controller
  • Lec16

    • covered:
      • index buffer
      • staging buffer
  • Lec17

    • covered:
      • wavefront .obj format
      • tiny obj loader
      • .obj format using index buffer (vertex hash)
    • image
  • Lec18

    • covered:
      • lighting model. lambertian
      • directional light, diffuse, ambient
      • smooth shading, flat shading
      • surface normal transform
    • vulkan-tut-18
  • Lec19

    • covered:
      • uniform buffer, alignment
      • refactoring buffer abstraction, descriptor set intro
      • refactoring frame info
  • Lec20

    • covered:
      • Descriptors, descriptor set, descriptor set layout, descriptor pool
      • update projection view model matrix to use uniform buffer.
  • Lec21

    • covered:
      • Point light, attenuation
      • floor object
    • image
  • Lec22

    • covered:
      • per fragment lighting.
      • ECS refactoring - game objects controlled by a map with key of ID.
    • image
  • Lec23

    • covered:
      • build system refactoring with cmake
  • Lec24

    • covered:
      • billboard - screen aligned
      • point light render system
    • vulkan-tutorial24-2
  • Lec25

    • covered:
      • multiple point light
        • multiple light calculation in shader
        • multiple light source rendering
    • vulkan-tut-25
  • Lec26

    • covered:
      • specular lighting
      • Blinn-Phong model, inverse view matrix and half angle vector
    • image
  • Lec27

    • covered:
      • alpha blending
      • sorting semi-transparents object in rendering
    • vulkan-tut27
  • Tutorial Texture mapping

    • covered:
      • image, imageView, texture sampler
      • texture resource descriptor set per object
    • vulkan-tutorial-texture-2
  • Tutorial Depth buffering

    • covered:
      • depth image, render pass update
    • image
  • Tutorial Loading models

    • covered:
      • textured model loading, vertex deduplication
    • refacotoring: point light rotation system
    • image
  • Tutorial Generating mipmaps

    • covered:
      • using mipmap, image blit command and transition, sampler mipmap update
    • vulkan-study-mipmap
    • image
    • image
  • Tutorial Multi-Sampling-Anti-Aliasing

    • covered:
      • MSAA sample count, render target update, sample shading
    • x1 w/o MSAA MSAAx4
      image image
  • Tutorial Compute Shader

    • covered:

      • compute pipeline, compute shader, SSBO(shader storage buffer object)
    • recap:

      • descriptor sets, submitting commands buffers to queue and synchronization, depth test and alpha blending
    • vulkan-tut-compute-particles-2-opt

    • vulkan-tut-compute-particles-9

About

Youtube lecture practice

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published