HighresScreenshot00000.png

GAIA

Technical Designer

( Work In Progress )

DESCRIPTION

Gaia Is an unreal engine editor tool that takes in a patterned image texture as an input and procedurally creates a landscape , forest, road, grass, and water bodies. 

Development Details

Team Size: 1

Genre: Unreal Engine Tool

Engine: Unreal Engine 4

Develop Time: 12 Weeks

Expected Shipping Date: May 2021

* Disclaimer : This is a work in progress which is constantly changing every day.

 
Gaia.gif

DEMO

The tool takes in a Image as in input and Scatter objects align the landscape according to the given pattern.

 

WHAT PROBLEM IS THIS TOOL SOLVING?

Design Goals

Most game engines have a landscape and foliage tool. But it takes an extremely long time to paint the foliage, player path, Trees etc if the scene is large and once done it takes longer to make iterate and make changes/revisions. If a designer wants to quickly prototype his large-scale scene in an open world, he must spend a substantial amount of time to import the heightmaps, paint of the grass and trees manually add in the water terrains etc. Using this tool, he can simply draw his intended layout of where everything needs to be at what density or use an existing image in photoshop import it into unreal and the tool automatically places all the necessary appropriate assets for you in that set pattern.
By using this tool, a designer can save a substantial amount of time in designing the level and can perform multiple iteration, changes when compared to the regular workflow which usually yields in better quality levels.

 

TECHNICAL SYSTEMS AND IMPLEMENTATIONS

 
Gaia_AUtoMAterial.gif

Auto Texturing Landscape Material

One of the first tasks that I did was to create an auto landscape material. This material automatically appible texture to landscape faces based on its current slope height.

 

MATERIAL MATH

There are the following functions that were used in the auto landscape material.

 
Dot Contrast.png

THE DOT CONTRAST

This function takes in the height and the contrast as parameters and blend in two colors in a natural way. The height and the contrast multiplier  are exposed to the designer for more control over the material look.

World ALign.png

WORLD ALIGN TEXTURING

Similarly the first visit to Anor Londo was grandiose and I wanted to recapture that moment in our game. The main way to final area (Initially planned as boss area ) was design in that retrospect.

HightmapNormalBasedBlend.jpg

HEIGHTMAP BASED BLEND

The used the heightmap of the landscape terra nand an input creates a normal map extract the red channel and inver it to get the only the slopes and us this to lerp texture on the slope on the walls.

AllCFunctions.jpg

CUSTOM C++ FUNCTIONS

Low Level C++ Code 

As I needed to access every pixel information from a given image texture I had to write to custom c++ code since Unreal didn't provide those feature from blueprint. 


 

THE PIXEL FUNCTIONS

Getting a 1D Pixel Array From an Image Texture

For this c++ function I take in the image texture as an input, make sure that it has all 4 channels i.e. Red,Green,Blue and Alpha and return the height of the image,width of the image and a 1D array of all the pixels in the image.

 

Getting the size of a Texture

Since now I could access the c++ classes I used it whenever possible to get any values with ease.

 

Getting a  Pixel value from a 1D Pixel Array

After generating the pixel array if I pass in the index of the row and column to this function then I can get the RGBA values of the pixels.

 

DYNAMIC VARIABLE ACCESS

The Post Edit Change Function

I expose many parameters to the designer. But though the use of the posteditchangeproperty I was able to give more conveyance and control to what all variable were accessible to him

 
PostEditChangeProeprty.gif

Dynamic Variable Access Example in Blueprint

 

UE4 BLUEPRINT CODE

Custom Event to Scatter Objects Per Channel

 

Take in every pixel from a texture send the color for each of the pixel for further processing.

 

Transform Pixel Space  points into Landscape Space points i.e the points scatter intensity vary depending on the landscape size.