Development of University of Science and Technology of Hanoi interactive virtual world using Unreal Engine
Tags: octograd2020, devgrad2020, showdev, unrealengine
Published: 2020-05-21 22:04:15

[Comment]: # (All of this is placeholder text. Use this format or any other format of your choosing to best describe your project and experience.)

[Note]: # (If you used the GitHub Student Developer Pack on your project, add the "#githubsdp" tag above. We’d also love to know which services you used and how you used it!)

![Demo](https://media.giphy.com/media/cl1vuFIgcCHPPZCDlE/giphy.gif)


## Introduction

### Context and Motivation

Today's virtual worlds are purpose-built for entertainment, social, educational, training and various other purposes. It is being more better than the real world. So the virtual reality has take over everything. For instance the illustrations showed in a game are more better than the reality we live in. It provides the gamer a whole new experience by taking over his imaginations it’s as if we are playing the real game with all those real gaming characters in the real life. Virtual world is bringing out all our imaginations so that we can experience it in reality. Similarly for the automobile industry we can take a virtual ride of the desired vehicle we want to buy which provides a whole new dimension to the world of buying things. 

Moreovers, virtual world has been adopted in education for teaching and learning situations. Students are able to interact with each other and within a three dimensional environment. Students can also be taken on virtual field trips, for example, to museums, taking tours of the solar system and going back in time to different eras. In this internship, I’ll mainly focus on entertainment-based virtual world as it’s closer to real world we are living, bring a pleasant for us, especially with 3D environment.

In this work, I will focus on creating 3D models from scratch and also  build a demo of 3D virtual world of my University in Vietnam using Unreal Engine, whereas a player can walk through, and interact with some objects. This application can be used for celebrating 10 years of USTH, marketing, and also 
for remote students/parents have a virtual trips before applying to our university or any USTH student who is studying abroad.

## How I built it
### Work flow
Having three months internship at USTH ICT lab, my work will be divided into four main steps as the figure above to successfully build and create both University 3D models and virtual world.

![Workflow](https://dev-to-uploads.s3.amazonaws.com/i/tvft6335cmpog9t2rgoh.png)

**Input Data**
- **Collect a dataset** of *2D images* of my University: 
    - This work is the first step and is one of the important task.
    - Data will be 2D images, videos.
    - We will use a simple camera from a smartphone to perform this task. After taking pictures with different view and also furnitures of USTH, these photos will be classified to specific folder ( e.g: Room 5/Lab ICT). This approach has two drawbacks howerver, it is time-consuming and easy to make mistakes.

**Modelling**


**Conduct** fully 3D models from collected 2D images which will be a 3D model foundations for other reaseacher or developer to create others world of USTH. To create a fully 3D models from scratch ( 2D images, videos, floor plan), this task will be breaked down into four steps as the figures below. 

![3D modelling steps](https://dev-to-uploads.s3.amazonaws.com/i/pdk07b599tl4imppwdfe.png)

#### Ground Prep / Floor plan
First of all we need to create a Floor Plans. Thus the university provided me a 2D legacy floor plan images, but it is captured from
a cemera intead of a digital floorplan, so i will need to transfer it into a digital version as the picture below.

![Floor Plan Legacy](https://dev-to-uploads.s3.amazonaws.com/i/n40r26k179b092p7ptqr.jpg)

![Digital version](https://dev-to-uploads.s3.amazonaws.com/i/749uhrmmhec58anwbu4b.jpg)

#### Structure and Interior Walls
To structure and interior walls is quite simple thus we already have the digital floor plans version, Now by using *offset* tool, it will allow you to draw a offset of a perimeter, so in this case i can dictate how thick our walls is. And as the default parameter in Architecture field, i will set it equal to six inches.

![Structure walls](https://dev-to-uploads.s3.amazonaws.com/i/349m2gecwuxn2qb0ec1e.png)

#### Furnitures

Finally in order to make the 3D model complete, we import sketchup textures, create custom materials and also add furniture objects. These furnitures can be found in the 3D warehouse store which comes with SketchUp when installed. Sometime I also need to create some special models in my University thus it cannot be found in the store. 

![Example 1](https://dev-to-uploads.s3.amazonaws.com/i/yqozmj0gr64tuniv8n85.png)
![Example 2](https://dev-to-uploads.s3.amazonaws.com/i/9gu7177vn695t0uwadlr.png)
![Example 3](https://dev-to-uploads.s3.amazonaws.com/i/f7sn17o5ytu5qx0nno1r.png)

I also built some special furniture that only has in Vietnam like this:

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/pgluzn8v7j90lx526kys.png)

### The final work: Unreal Engine and Creating my University 3D virtual world

We start making our 3D virtual world by adding player, light, interact, and some technique like *level streaming*...

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/jdqizil0gm5qhbdrk87f.png)

## Result
This application will be built to run on Window, MacOS and Linux thus we are focusing on marketing, and for students and USTH's lecturers. 

![Real](https://dev-to-uploads.s3.amazonaws.com/i/hm4meahg64qkbg9d6l64.JPG)

![Unreal](https://dev-to-uploads.s3.amazonaws.com/i/w924r2fxis41mcswgup4.png)

![real](https://dev-to-uploads.s3.amazonaws.com/i/kefg3t56tjw02b8ylmrm.JPG)
![unReal](https://dev-to-uploads.s3.amazonaws.com/i/tizy8muorh8b8q99r5bd.png)

![Real](https://dev-to-uploads.s3.amazonaws.com/i/ebqbzuap8zuosr71cge7.JPG)
![Unreal](https://dev-to-uploads.s3.amazonaws.com/i/3xu8z077zesf4dadp1ui.PNG)


## Demo Gif

![Demo](https://media.giphy.com/media/cl1vuFIgcCHPPZCDlE/giphy.gif)

## Download
There is more laboratory room in my university that wasnt included in this post but
You can download my application for discorvering my university in Hanoi [here!!!](https://drive.google.com/drive/folders/1AOLKdLRUaUZaHy3KVtGqAHmkXWelK9j4?usp=sharing)

## Link to Code

[Note]: # (Our markdown editor supports pretty embeds. If you're sharing a GitHub repo, try this syntax: `{% github link_to_your_repo %}`)

You can read my thesis and project at {% github https://github.com/huyhoang8398/internship %}

## Additional Thoughts / Feelings / Stories

After 3 years studying Computer Science at University of Science and Technology of Hanoi, this is my biggest project about software engineering and also my proudest project for my university 10-year anniversary
[Final Note]: # (CONGRATULATIONS!!! You are amazing!)