top of page
jpUhaVYopi.gif

Mesh Generation

Solo - 2weeks

Bullet Holes and a Virtual 3D Scanner

This one of the personal projects I did during the spring of 2021. I started the project wanting to create wall that that you can shot trough and leave holes that you can see trough. My exploration with mesh generation ended with me trying to figure out how 3D scanning works.

Bullet Holes

Research
My first step doing this project was to try and find examples on how other people had solved this same problem. I watched a number of videos from GDC especially one from the developers of Rainbow Six Siege which is a game filled with wall destruction. They used full mesh destruction and since this was my first project working with mesh generation I felt like it was outside of my scope.

​

Concept

I decided to instead come up with a simple custom solution that fit my scope and allowed me to get a visually satisfying result. We had just had a shader course so I felt confident that I could write a shader where you could paint transparency on a texture. If I got that to work I only had to generate a loop of circles around the inside of the hole.

 

Texture Hole Painting

To make the Shader for the texture I followed a tutorial that taught you to make a simple canvas application and then I adapted that into paining transparency holes on a texture instead. I can also print holes of different shapes with this shader by using a hole texture.
 

Generating the Mesh
Generating the mesh takes part in 4 steps:

Step 1:

Draw out X amount of points in a circle around the center of each

hole where X is decided with a resolution variable and the distance from the center is controlled by a radius variable. 

​

Step 2:

remove all points that are overlapping another hole. and mark each point that has a removed  neighbour point as an endpoint, visualized as green points on the pictures.

​

Step 3:

Connect each all points so that you get a border of the bullet hole and connected bullet holes.


Step 4: 
Extrude that border into a mesh.


Potential Improvements

One potential Improvement I could Implement is to use a circle Intersection algorithm and draw a point at the intersection and connection this would be more reliable than my current method but would not get the semi rounded corners I currently get for free.

BulletHole.gif
jpUhaVYopi.gif

Painting transparency on a texture

image_2022-01-12_125502.png

Step 1

image_2022-01-12_125907.png

Step 2

image_2022-01-12_130137.png

Step 3

image_2022-01-12_130634.png

Step 4

​

Virtual 3D Scanner

bottom of page