Saturday 28 March 2020

Final Major Project - Weeks 9-12



Organic Modeling & Foliage

From week 9 I started to work on modeling the tree that has fallen into the cabin. I'm sure that my method for creating the tree was long winded, but I find working in ZBrush allows me to create better organic shapes. 




I tried not going too into detail with sculpting the tree, I added a few suggestive marks of a birch tree just to better visualize what the end result may look like. Since this mesh takes up the space of more than 4 meters, it is unreasonable to bake down. However I can use a mixture of tilling textures to get a similar look on a lower poly mesh. 


This is the initial stage of the re-topping process. Like I said before this might have been quite a long winded process, but since I don't have access to speed-tree I thought this would lead to good results. 
Additionally I can break off some of the mesh to create fallen/broken branches.


Here is the full re-topped version of the tree. Something that I want to point out is why I did a stump for the tree.  I want to show where the tree originally was, if this can be seen from a window. Or if I expand the range of accessibility to outside, then there should be a stump. 

Planning Foliage



When I was planning out how I should approach the foliage I originally thought that I should have everything contained on one texture sheet. However after giving it some thought I realized that it would be better to separate the different species of plant, onto their own separate uv's. This is so that I can better manage texel density and easily edit/change the textures.

Since I had been working on the tree in ZBrush, I thought that I should do the same for the foliage. Being able to sculpt allows me to add details that would be much more difficult in 3dsmax. However the only draw back to ZBrush is that I can get lost in adding details, its sometimes difficult to stop sculpting. 


The process for creating my foliage starts with masking the shape/silhouette on a plane. I will often try to get the majority of the proportions correct at this point, as it would save time for later. 



From there I cut out the shape and use zmodeler to qmesh the plane and make it into a 3d object instead fo a plane. I also add support loops to the edges to control the smoothing process.


Most of the time is spent in the dynamesh stage, where I will often tweak the silhouettes and add or take away from the mesh. Something that I found difficult with sculpting foliage in general, is that they are not perfectly symmetrical. There is an offset between the two sides, as if the veins are one after another. To speed up the process I would often sculpt symmetrically and then mask one side and move it to offset. 


There will be an additional layer of detail, this will often try to break up some of the repetitive shapes and add the smaller details of veins and the cell like structure.


Once I have finalized the details, I then move onto creating variations. Here I use the transpose tool or move brush to offset the model. In this particular case there are some variations on how the dockleaf sort of folds/ripples. It's also important to look at references. I also keep one model completely flat, since I can distort the low poly model if I feel like I want more variations. 


Before I move onto the texturing process, I wanted to touch on a quick method of creating hair/flowers. Using the tool fibermesh in zbrush allows you to control hair strands that populate a selected mesh. Using the masking tool controls where the fibers appear as well. 


I export the high-poly models into my 3dsmax scene and then arrange the models to how they will fit to the texture sheet. When I arranged the models for the dock leaves I realized I could fit an extra leaf.



Some advice I have to improve the quality of the bake, is to place a high-poly plane below the foliage models. This is to stop any sort of bleeding edges. I found that without this, the area's around the leaves would be inset.


Here is what the leaves look like in Substance Painter. As you can see the texturing process is left quite simple. There isn't much of a need to go too in-depth with the textures. As the more detail you add might make the leaves easy to spot that they repeat in the scene. 

Also you might see that the stems of these dock leaves look fairly strange. This is because I used the metal channel to paint a subsurface mask. Since there is no metal on foliage, I re-purposed that channel for other uses. As long as I do the same for all of my foliage, there will be no issues with this. 


I then export the textures from Substance Painter and import them into Substance Designer. I use Designer to organize the textures and add more details to the textures. For the base colour I add a opacity mask, and then for the RGBA texture I add a different opacity mask, one that has holes and bite marks that insects would make. This will help break up the repetitiveness of the model.  


For other textures such as the stinging nettles I create and add a stem to the texture. I find that adding tiling details such as the stem, is much easier in Designer as I can control the details and know that it will always tile.


After finishing the textures in Substance Designer it is then to the final stage of creating the low poly models. First is cutting out leaves. I find that working in passes, of adding more loops when they are needed works best.


After cutting out the leaves it is then distorting/warping the model to look more like the real life version. I used primarily the Bend and FFD modifiers to get the curves that I want.


The final stage is composing the separate leaves into a bundle. Again looking at references really helps, as it helps composing the models to look correct. 


Looking back at the process I know there are somethings that I can do to improve the process. But everything so far has just been a lot of discoveries and self learning. It does take a while to create the textures, but it definitely speeds up towards the end. I also know that I could probably add more polys to the low poly models to get more detail. I can always go back and do so.

Repeat this process three times and this is essentially what I've been spending my time on from weeks 10 to 12.  

So far I have created ferns, nettles and dock leaves. I still need to create Ivy and Grass.


Below is my material set up for the foliage. The set-up is fairly simple mainly compromising of controls for subsurface colour, and roughness. 


From week 13 I'll be working on texturing the scene as much as I can, whilst also working on the last two remaining foliage. I hope to speed up development, which will be difficult as I'm forced to work from home. Not being able to access the university's computer labs has definitely affected my productivity. But I will try to do my best in these uncertain times. 



Sunday 15 March 2020

Final Major Project - Weeks 6 to 8


Before I go into what I have been doing I want to touch on how I am approaching the format of this blog. As I am behind schedule when writing this, I am having to write multiple weeks worth of information. So to catch up I am going to talk more broadly on specific things that are note worthy rather than going on a week by week basis. 

Creating the Master Material 
(or what it is currently)

Following on from the last blog entry I wanted to touch on my Master Material that I have been working on for a while now, however I felt as though it would add even more content to the already long post. 

With this section I wanted to talk about what I've done so far and the reasons for why I have certain parameters in the graph. The purpose for this master material is to be used as a base for all or most of my models in the scene. And since there are still things I need to create in the future, I might add more features to this material to accommodate them. Basically this material will probably change quite frequently for future needs.


I've colour coded all the major parts of the material. Purple parts are nodes that affect the UV's. I've seperated them into three different sections as they have three different purposes. 

- One of them is to make the texture world aligned, meaning that the texture is projected onto all axi's of the model. Instead of using the unwraped uv's of the model, the textures are projected in world space.

- Another is to affect the tiling, offset and rotation for all of the textures. 

- And the last is to affect only the Colour texture and RGBA texture, as some assets will only require a unique normal texture map and can have tiling textures for the colour and roughness. 



The white center is filled with TextureParamaters for Colour, RGBA and Normals. I labeled this section "Standard Material" as this is where any textures I have created will be imput into the material. It's standard as there is barely any changes/manipulation to the texture, for most unique assets this is all thats needed. 


The orange part at the top of the graph is a sort of a smart material I've been working on for the house walls. I will go into more detail further down but very briefly this is an additional layer of detail to add more wood details. 


The red section of the graph is the vertex painting nodes. So far in the project I haven't needed to vertex paint two different textures yet, but I know that I will in the future so I have started to prepare for that. I will also eventually add additional nodes to paint in the blue and green channels, when they are needed. 


The last thing I want to mention in this section is that I am using Lerps as switches instead of Static Switch nodes. The reason being that Static Switch nodes creates extra instances of the material. When a static switch is used it references the material as two new materials, instead of referencing the whole material as one. This can negatively affect the load/run time as it creates more shaders unnecessarily. 

Lerps circumvents this issue, as it allows you to switch between two different states without creating extra unnecessary instances. The only difference is that you will need a static parameter that is named correctly since you will need to use values of 0 to 1 instead of ticking a box for false or true.



Creating the log walls



As can be seen in my previous blog post, you can notice that the walls in the environment have gone through multiple stages. From blockout to rough model to something more like the final version.

Russian izba walls have a peculiar design to them, as they are usually whole logs that are then carved and planed to become a flat wall. However there is still a cylinder shape towards the ends of the logs. Which can be seen below.



To re-create these walls I had to consider how I should texture these walls. Since they are a couple meters long, they are too large to be baked, however I still want to give each log a somewhat unique look. And I think I've come up with a good result. 



Firstly is the modeling, I created a few long cylinders and then removed faces and strip modeled where the cylinder is carved into a plane. Since the model is somewhat simple I decided to use vertex weighting the normals of the model to get the nice beveled edge. This allows me to not need a normal texture sheet just for the edges. 




Next is unwrapping the uv's. I used a texture with three horizontal gradients to define the center and edges of the log. With the center being white and the edges being black our grey. I have three gradients as this will help give three different variations of wood grain. In addition to unwrapping the wood logs to these gradients, I have given the logs three different material Id's. This will help to add more variation as I can apply different instance materials that will have varying attributes. 


The next step is the wood textures. I wanted to keep these textures quite simple as I will be combining multiple layers within Ue4 instead of Substance Designer. Recently with my work I've been trying to push more parts of production into Ue4 rather than Designer. Taking my knowledge of Designer nodes and using it in Ue4 to create more interesting materials that use factors such as world space to change or warp the texture. Such as this warped lined texture below. This will be added onto the wood material within Ue4. Also I should mention that since these are greyscale images they can be used in a RGBA texture to be efficient.




Taking the wood material and all these additional textures into Ue4 will get a result like so. 




Going into more depth with the creating the wood. Below you can see a section of the graph circled in blue. All these nodes basically means that I am distorting a gradient mask with a perlin noise texture that is world aligned. So that the distortion will be different depending on the location of the texture in the world. You might also notice that I re-created the 3 horizontal gradient bar texture (that I showed higher up in this post) within unreal. The reason as to why is because I can have more control over the mask in unreal if I have all the inputs as parameters in the material. Such as how large the gradient masks are, how strong or soft the transition is etc.



Below is how I created the ring formations on the wood, when I was creating this material I named it as TigerPattern for simplicity, and this will be how I refer to it from now. 

The reason why I have separated this section of the material as its own thing instead of having it as a simple tiling texture on the Substance Designer material, is because I ran into problems of the texture being noticeably tiling. I could get different colour variations of wood using instances, but the TigerPatterns will still be the same. So this is how I solved that issue, by separating it out.



There are two things that I want to point out. 
First is how I was able to modify the texture to have a wood grain. I plugged the green channel from the normal texture of the tiling wood grain into the UV's of the TigerPattern Texture, which then gives the distorted wood look shown below.





Second is the colour, to have more control on how the wood looks. I used a three vector parameter for the controlling the colour, since this is throwing more noise onto a wood texture having one colour for the pattern is sufficient. As later down the line I will be throwing decals and vertex painting different versions of the material as well. 



Next I combine the two parts of the world gradient mask and tiger pattern.



Here I add more colour to the wood by using a similar gradient to the one I created. This allows me to give a strip of different colour in the center. 



Below is what it looks like when adding the colour onto the material.


Using the same masks that I created I used them to control and affect the roughness. I know that I can use a scalar parameter instead of a three vector parameter to control the roughness, but I only used the three vector to visualize what the roughness may look like in the instance.



 With everything that I've shown you, here is how it looks in action. I may go back through this material again and simplify a lot of the nodes. But it works for now. 



Applying Critique
Recently our university had the opportunity to have people from both Dambuster Studios and Ubisoft Leamington visit us. I was able to get some critique from the wonderful Environment artists, that I have been slowly adding to this project. One of the larger things pointed out to me was that the walls looked quite stylized. 
The reason for this was the silhouette/shape of the wood logs were thick, and the walls had large gaps between the logs. Which can be seen below



Going back to my model I realized that I needed to flatten both the tops and bottoms of the logs so that it sits more flush. After some more research into log cabins/houses, most logs will be flattened on the top and bottom to get rid of holes. After all the walls are made, there would be an extra material such as dried grass or hay stuffed into the gap to fill in any holes.
I also made more size variation between the logs, as it would be nearly impossible to find logs of the same circumference for all the walls. To add an extra step of realism I should add some warping to the logs as most logs will not be perfectly straight.


There was some additional critiques but these are details that will be added later down in the line of production such as decals.

Production

Since I've been working on the walls and floor, I feel as though its time to start paying attention to everything that is inside of the building. Below are two images of a coat hanger. Something that I tend to think a lot about is how dense should an object be? 
-What needs to be thought about is how close will the camera get to this object? 

-Does it appear once or is it going to be duplicated? Does the object have curves or cylindrical? 

-Will the object be uniquely textured or use tiling textures? 

All these can determine how dense a mesh might be. With the coat hanger being created from many curvy shapes, it has to have a decent amount of edge loops to not have a jarring transition. However this means that I should reduce as many edges or faces wherever possible to slightly cut its budget down. 


 

However I seem to have a problem with parts of the model, the vertex normals of the model appear to have a strange shading. on the some what flat part of the model. This could be fixed with either beveling the edge and using weighted vertex normals or baking a normal map. Since the model is already dense, I opted for using a normal map. 



Here is what it looks like in the engine.



With the table I wanted to get a very simple table cloth, so I took the table model into Marvelous Designer and simulated a rectangle of cloth on top of the table. It gave a nice result, but the problem I had was creating the low poly.



 I tried using both ZRemesher in Zbrush and ProOptimise in 3dsMax to get a simple low poly. But the result I got with both of these were terrible. With both of these tools, their goal is to reduce the amount of all the polys. Which ends up with the edges of the cloth becoming distorted. With the low poly I wanted the edges to maintain its shape and then reduce the polys in the flat center of the cloth. I'm sure that there is some tool or knowledge that could help me, but since I didn't know them I thought I might as well quickly re-top manually. Simulating the fabric was quick but re topping is where I spent most of the time.


Additionally I worked onto some of the assets already in the scene such as bowls, shelves, and this window below. Since the geometry is fairly simple I used weighted vertex normals to get a nice edge. I also modeled the window with the ability to be opened. I just need to come back and set up a parent child rig to the window and add some extra details such as a lock on the window. 


Ubisoft Art Test

I have been applying to a bunch of companies whilst working on this FMP, and on week 7 I had the privileged to work on an art test for Ubisoft. I can't go into the details of what I created or what the art test entails, but I want to mention this as it shifted my priority of the FMP to this art test. I started from Tuesday the 18th and finished Tuesday the 25th. I worked as hard as I could during this time, and after submitting the art test I decided to take two days off as a way to celebrate and relax. 
After working on the art test I have been able to self reflect on my skills, and see how I could push myself to improve. It feels similar to the frog in the well proverb. I feel excited to see how I might improve in the coming months. 

I resumed working on my FMP on week 9.