Strides in development (Virtual Reality)
Last week I was watching the CEO of Facebook talk to MKBHD about Virtual Reality, and it got me excited. So, after letting my VR headset catch dust for most of the time during the pandemic, I took it out and after playing with it for a while, I decided to build an application.
Researching (aka watching more YouTube videos) led me to two tools that I could use to build VR apps, UnrealEngine and UnityHub. Both of these engines involved coding in languages that I haven't used in a while. I remembered being dazed and confused a few months back when I looked at some code I had written half a decade ago using JQuery for a school project. But I didn't let that deter me from giving this a shot. And so, I began.
Here are the system specifications I worked with:
OS: Ubuntu 14.04 LTS
CPU: i5 2.3Ghz x4
Memory: 8 GiB
Disk: 250 GB
Graphics: Intel HD Graphics 520 (Skylake GT2)
VR headset: Oculus Quest
Day 1 - Attempt 1: UnrealEngine (Based on C++)
- Created Epic Games account.
- Created Git account.
- Linked Epic Games account to Git account.
- Downloaded the engine's source code, as the installer is only available for Windows and Mac.
- Built the engine.
The documentation suggested the build could take 10 minutes to 1 hour depending on the system specifications. After my system pushed forward for 7 hours with all 4 CPU cores running at 100% the build/installation was a success. And then ./UE4Editor ↩
"Error: Failed to load Vulkan Driver which is required to run the engine. The engine no longer fallbacks to OpenGL4 which has been deprecated."
I attempted to install the Vulkan Drivers, but couldn't proceed as my system's specifications were lower than minimum requirements.
AMD:
NVIDIA:
UnrealEngine execution: Failed
Failure is the fog through which we glimpse triumph. - Aldrich Killian
Day 2 - Attempt 2: UnityHub (Based on C# )
- Created a Unity Developer Network account
- Downloaded UnityHub installer
- Installed 2018.4.x with Android Build Support
- Downloaded and installed Android SDK & NDK Tools
- Created a new project
- Mapped Android tools in Unity
- Added Oculus Integration in Unity from the Asset Store
Next step was to connect the headset to my computer to sideload the application onto the headset. I enabled the developer mode for the headset using the Oculus app, but my computer wouldn't detect the headset when its developer mode is on. So, I tried using adbLink. That didn't work either. After more research, I found a way to sideload the application from a mobile device. The process for setting up Unity took 3 hours.
UnityHub execution: Success
Coming back to the project, I added a plane, a few materials, changed some colors. Then I proceeded to build the app which took almost 45 minutes to build the .apk file for a basic application. System limitations. I copied the .apk file over to my mobile device and then using a USB-C cable and Bugjaeger app, I sideloaded my VR app onto the headset. I put on the headset, navigated to the Library > Unknown Sources, found my app on there and started it. And then...
Someone in the initial days of my Bachelor's degree asked me what I do. I replied, "Engineering". "Do you know what an Engineer means?", he asked. I was curious. "A creator", he said.
Every time I build something I'm reminded of that conversation, it's the feeling when you create something and it works beautifully, be it Frankenstein's monster or Edison's light bulb or a piece of code.
So here's what happened ...I saw a dark void, that's all I saw. What I created didn't work, probably wasn't going to, it was less than a basic app, in an environment I didn't fully understand. But at that moment I knew more than what I knew a day ago.
Lessons learned:
- I need a system upgrade, obviously.
- UnityHub worked better than UnrealEngine in my case.
- Application build time isn't acceptable when you need to develop and test changes frequently, though these issues could get resolved after I upgrade.
- Reality is different than a training environment.
- Things don't work the way you expect them to every time.
- You have to work with what you've got or around it.
I hope my 12 hour journey sheds some light on the hardships that come before success and acts as a guide of do's and don'ts when starting off with VR development. And to put it in perspective, I did not fail, I almost succeeded, and... I'm not done yet.
Keep it up Well done
Keep going man!!