Salmon Steak
Realtime Material and Shader in UE4
Project Overview
I completed the "Salmon Steak" project as part of my coursework for the GAME 722 - Real-Time Materials and Shaders course at Savannah College of Art and Design (SCAD). Using Maya, Substance Designer, Substance Painter, and Unreal Engine 4.27, I created both raw and cooked versions of organic materials. Through this project, I was able to refine my skills in organic material design and real-time rendering with industry-standard software. It also challenged me to approach the project creatively and think critically about how to achieve the most realistic and engaging results
Responsible for all aspects except music: model, material, texture, shade, lighting, and rendering
please click at the button to see complete process
Final Video
Content
Introduction
As someone who has always been interested in food, I decided to combine this passion with my skills in CGI by undertaking a project that explored the intersection of these two fields. Specifically, I wanted to study subsurface scattering, a technique used to create realistic-looking food textures, by researching steak recipes and taking photos of them myself.
To create the desired mood and tone for the project, I conducted extensive research online, looking at different sources for inspiration and guidance. I analyzed the lighting, colors, and overall aesthetic of various food photography, and used this knowledge to inform my approach to the project.
Through this project, I was able to not only deepen my understanding of subsurface scattering, but also to explore my interest in food and food photography in a new and exciting way. The combination of technical skill and creative expression required for this project was challenging, but ultimately rewarding, and I look forward to continuing to push the boundaries of what is possible at this intersection of CGI and food.
Inspiration and Reference
As someone who has always been interested in food, I decided to combine this passion with my skills in CGI by undertaking a project that explored the intersection of these two fields. Specifically, I wanted to study subsurface scattering, a technique used to create realistic-looking food textures, by researching steak recipes and taking photos of them myself.
To create the desired mood and tone for the project, I conducted extensive research online, looking at different sources for inspiration and guidance. I analyzed the lighting, colors, and overall aesthetic of various food photography, and used this knowledge to inform my approach to the project.
Through this project, I was able to not only deepen my understanding of subsurface scattering, but also to explore my interest in food and food photography in a new and exciting way. The combination of technical skill and creative expression required for this project was challenging, but ultimately rewarding, and I look forward to continuing to push the boundaries of what is possible at this intersection of CGI and food.
Lighting and Material Reference
Model and UV Mapping
Using Autodesk Maya, I created a 3D model using basic shapes like spheres, cylinders, ovals, and cubes. Starting with low polygon shapes, I added bevels to the corners and increased the number of divisions to create a detailed and realistic model.
To ensure that my textures were as high-quality as possible, I needed to create a close-up rendering of my project. Unfortunately, Unreal Engine version 4.27 did not support multiple UV Mapping, so I had to find another solution. To do this, I used a UV checker in 4K resolution and adjusted the repeat UV attribute in the place2dTexture node in Maya hypershade. By increasing the resolution from 1024x1024 to 4096x4096, I was able to test how close I could make the most detailed aspects of my project.
This approach allowed me to test the texture resolution in a controlled and precise way, ensuring that my final rendering would be as realistic and detailed as possible. While it required some additional effort and experimentation, I believe that the results were well worth it, giving my project a level of texture and detail that truly brings it to life.
For the tomato model, I combined green and red parts to become one object but separate materials.
When I separate material in Maya, UE will follow the material element the same as in Maya. So, this is a good way to make an object has more details.
Texture and Material
I begin my material work in Substance Designer, where I create a strip and use several nodes such as the Cartesian to Polar node, Warp node, and Creased node to create the salmon material. you can see all detail in this breakdown document.
Substance Painter is a powerful tool for creating textures in 3D. With the ability to see all around the object, painting textures in 3D is often easier than in 2D. In this chapter, I will guide you through the process of creating a salmon texture. Choosing the right material type is essential, and by making a small adjustment to the default settings, we can achieve a great result. I use PBR-Metal-Rough for the material type then enable SSS and choose "Skin"
Unreal Engine material real-time rendering is different from CPU or GPU-based traditional rendering. I start with creating basic material in a content browser
The last couple of image is tomato texture breakdown in Substance Painter. the first image is a raw texture version and the second image is a cooked texture version
Raw version
1. Red color
2. Dark red color
3. Transition color
4. Top color
Cooked version
1. Red color
2. Dark red color
3. Transition color
4. Top color
Texture Exporting (Substance Painter)
To ensure fast calculations in Unreal Engine, it's important to optimize texture maps. One example is the ORM Map (Occlusion, Roughness, and Metallic), which combines three values in different RGB colors. In order to calculate subsurface intensity in Unreal Engine material, the Subsurface attribute requires an alpha channel. Additionally, in the "Unreal Engine 4 SSS", scattering is an alpha of the Basecolor Map.
For this project, I used the output template shown in the following images to ensure optimal results.
Unreal Engine: Shader
In this part, I will explain more about shaders and material connections in Unreal Engine. Because subsurface scattering is a complex effect that is related to material and light, I use both subsurface scattering systems: sss and sss profile.
Subsurface Scattering
Let's create the Material and change the shading model to "Subsurface". please click here to see the Subsurface Scattering document.
Subsurface Scattering Profile
For the subsurface profile, I create that node from right-click > Material & Textures > Subsurface Profile. And then adjust the SSS profile attribute: scatter radius, subsurface color, and falloff color.
I create a material instance from Salmon SSS material because it is easy to replace it. You can see the example of the material instance and the cooked texture version in the following image.
Basic Material Connection
There are two images of the SSS and SSS Profile material connection
1. Connect the input of the base color with a 3-vector color before multiplying with Base Color Map.
2. Connect ORM (Ambient Occlusion, Roughness, Metalness) separately
- R channel, connect with ambient occlusion input
| - G channel, connect with roughness input
- B channel, connect with metalness input
3. Before connecting the roughness map, I create 3 PointLevel for adjusting the image.
4. Create a VectorNormalWS and multiply it with the Height Map before connecting to the World Displacement.
5. Connect Normal Map with FlatternNormal Map and then connect with material node
6. Create vector 3 color node and multiply SSS
Sequencer
In this part, I use the master sequence instead of the level sequence. The master sequence is contained many "level sequence" and is easy to animate objects, camera attributes, or any attributes. The master sequence is easy for editing, I create 6 shots and move the camera each by each. Click here to see more detail about the master sequence.
Lighting
Inspired by the elegant world of fine dining food photography, I incorporated the subtle beauty of soft, low-key lighting in my work, using a carefully selected combination of 1 skylight and 2 medium-sized area lights to create a truly captivating atmosphere.
Rendering
In this project, I use raytracing because I need to study more about real-time rendering. Ray tracing in UE4.27 offers several benefits over traditional rasterization techniques, including more accurate and realistic lighting and shadows, as well as better reflections and refractions. By tracing the path of individual rays of light, UE4.27 can simulate the way that light interacts with objects in the scene, resulting in more natural and realistic lighting effects.
Ray Tracing
First, select Direct X 12 and enable Ray Tracing in Project Setting. please click here to see more information about ray tracing
Movie Render Que
For the best quality, I enable the Movie Render Que to capture the sequence in the Edit > Plugins. Movie Render Queue is a tool for controlling the quality, format, etc. Please click here to see more information about Movie Render Que.
Post Processing
In the post-processing node, I enable the bloom attribute. this effect enhances the image, making a soft light and glow. It is like a glow node in Nuke, but it processes in real-time. Please click here to see more information about the post-processing node.
Conclusion
Real-Time Shading and material in Unreal Engine are really new for me. It's out of my comfort zone. I created a bunch of works with traditional rendering in both CPU and GPU-based rendering. however, real-time stuff is a new trend recently. In my opinion, it would be a great opportunity if I know this process. I can expand my existing skills and study in-depth. When I was working on the shader, I was very impressed with the pace. When I enable the ray tracing, the shadow is softer and the sample quality is much better than before. I will study more in lighting and material in Unreal Engine and will use it in my MA Project.
In addition, I have edited the transition and juicy look for the sliced lemon from the professor and professional artist's advice. I think Unreal Engine can solve problems and go back and forth very easily. so, this is the before and after image.
Finally, Thank you, Professor Manuel Prada, Ariyawat Meechoui, and Gen Li for helping and giving me useful suggestions. I hope this article will help you guys who have a passion for building visual imagery, lighting, and rendering can find a solution. if you need more information please contact me at thitaphon.piraban@gmail.com
All Projects
Anya Taylor-JoyGrooming
Red PandaGrooming
Cozy CabinRealtime Rendering
Salmon SteakRealtime Rendering
BonnevilleLook Development
CoffeeLook Development