Skip to content

Latest commit

 

History

History

CubemapRefractions

README.md

Refraction with Cubemaps

Code Name: CubemapRefractions

Description

In this example, the cubemap refraction calculation is tested assuming the sphere presented is made of glass. Only entry refraction is assumed for the sphere; exit refraction is not taken into account.

Output

Controls

Input Action
Mouse Move Rotataing the orbit camera
Mouse Scroll Zooming the orbit camera
Esc Close the window

Application Parameters

Settings

Parameter / Key Type Usage in Code Description Default Value
AppSettings.ClearColor VkClearColorValue AppSettings::ClearColor Background color of the screen
AppSettings.MouseSensitivity float AppSettings::MouseSensitivity Mouse sensitivity value
AppSettings.CameraZoomSpeed float AppSettings::CameraZoomSpeed Zoom speed of the camera

Learning Objectives

  • Implementing refractions with using static cubemaps

Shader Status

Shader Type Status Notes
GLSL ✅
HLSL ✅
Slang ❌ Will be implemented.

Theoretical Background

None

Extensions Used

Instance

Window system-dependent extensions:

  • VK_KHR_surface
  • VK_KHR_win32_surface (Windows)

Device

  • VK_KHR_swapchain