Terrain Generation
Summary
This project dynamically generates terrain using GPU-accelerated compute shaders.
Dynamic Terrain Generation ProjectThe key functionality of this project is implemented in the following function:
123456789101112131415void Tutorial::run_terrain_generation(std::vector<BlockCoord> &blocks) { // Use a hash map to handle evicted blocks in case of collisions for (auto &block : blocks) { // ---- First Pipeline: Generate Density and Normal Maps ---- vk ...
Materials
Summary
In this assignment, the .s72 loader is upgraded to handle material parameters, texture maps, and lighting environments, with an emphasis on efficiently uploading textures to the GPU. The drawing code is then updated to support multiple shaders and binding sets, ensuring smooth integration of the new features. Additionally, shader code for tangent-space normal maps is implemented to bring realistic surface details to life.
(function(){var player = new DPlayer({"container":document.get ...
Scene Viewer
Summary
In my approach to the scene graph assignment, I structured the code by creating a hierarchical system where each node represents an object in the scene, and each node contains a mesh and transformation data such as position, scale, and rotation. The camera is attached to one of these nodes, and its transformations are calculated accordingly. I implemented frustum culling to optimize rendering, rejecting meshes whose bounding boxes fall outside the camera’s frustum. What’s cool about this ...
Vulkan Tutorial
Using nakluV to take through the essentials of Vulkan starting with fragment shaders and working through command submission, resource creation, and support code.
Render Passes and Command Buffers
Pipelines and ShadersWrite shader programs in a C-like language called GLSL (OpenGL Shader Language).
Adding Time: Push Constants(function(){var player = new DPlayer({"container":document.getElementById("dplayer4"),"theme":"#FADFA3","loop":true,"video":{"url":"/2024/08/30/Vulkan-Tutorial/1.4.mp4"} ...
VSC Intellisense Setting
Set up Intellisense correctly for easy use in VS Code.
Check if Intellisense is enabledextensions -> Edit in settings.json
Ensure that “C_Cpp.intelliSenseEngine” is not set to “disable”
Animation
This assignment inplements an animation system, including skeletal animation, linear-blend skinning, and a particle simulation.
SkeletonImplements Forward Kinematics and Inverse Kinematics
Particle Systems(function(){var player = new DPlayer({"container":document.getElementById("dplayer0"),"theme":"#FADFA3","loop":true,"video":{"url":"/2024/08/12/Animation/animation.mp4"}});window.dplayers||(window.dplayers=[]);window.dplayers.push(player);})()
Path-Tracing
To enhance Scotty3D’s path-tracing renderer, the first part involves implementing efficient ray-scene geometry queries, followed by simulating light bounces to achieve higher-quality images.
Camera rays
BVHBounding volume hierarchy can accelerates ray-scene intersection.
Direct LightingArea Light Sampling Off
Area Light Sampling On
Environment Lighting
Mesh-Editing
Scotty3D stores and manipulates meshes using a halfedge mesh structure – a local connectivity description which allows for fast local topology changes and has clear storage locations for data associated with vertices, edges, faces, and face-corners (/edge-sides).
Local OperationsFlip Edge/ Split Edge/ Collapse Edge/ Extrude Face/ Dissolve Vertex/ Collapse Face
The most challenging operation is Collapse Edge, with bugs often going unnoticed until the global operation ...
Rasterization
Rasterization Pipeline breaks the process of converting 3D triangles into 2D pixels into several highly-parallel stages, allowing for a variety of efficient hardware implementations. This assignment implements parts of a simplified rasterization pipeline in software without a GPU.
Rasterization Pipeline
starts with an array of Vertices
transforms these vertices via Program::shade_vertex to produce ShadedVertices
assembles these vertices into primitives of type primitive_type
clips the primitive ...
Malloc Lab
This project involved developing a dynamic memory allocator as part of the malloc lab, which required implementing the malloc, free, realloc, and calloc functions. The primary goal was to create an allocator that is both correct and efficient while maximizing throughput and utilization.
AbstractThis project involved developing a dynamic memory allocator as part of the malloc lab, which required implementing the malloc, free, realloc, and calloc functions. The development process included conver ...
