Announcing Oculus Debugger: VSCode for UE4 & Native Developers

Oculus Developer Blog
|
Posted by Marko Novakovic, Software Engineer
|
February 22, 2021
|
Share
Native SDK
Unreal

We’re excited to launch Oculus Debugger, a VSCode extension that provides support for debugging native C/C++ code applications running on Quest and Quest 2. Improved tools for debugging Unreal Engine and native applications has been one of the top requests we’ve heard from developers. Oculus Debugger provides a customized experience that seamlessly integrates with Unreal Engine and C++ projects, providing powerful debugging tools that help developers identify, diagnose and resolve issues in their code. You can download and install the extension today, available in the Visual Studio Marketplace (Oculus Debugger).

“Oculus Debugger has been a game changer for us. It's great to have something that's simpler and easier to deploy than other solutions. We were able to integrate it into an auto-generated VSCode workspace and roll it out to our programmers with very little setup on their end. Overall speed/latency of stepping and inspecting is much better than other tools and we were able to track down some previously elusive bugs with Oculus Debugger.”

-Matt Pettineo, Lead Engineer, Ready At Dawn

Features

We designed Oculus Debugger to be used for most common native debugging needs and environments:

  • Supports debugging native C/C++ (ELF) binaries.

  • Supports debugging Oculus applications shipped via APK files.

  • Works on both Quest and Quest 2.

  • Works on Windows and Mac operating systems.

  • Has integration with Unreal Engine, which produces a VS Code workspace file with build and launch configurations.

  • Uses LLDB debugger which is downloaded from our servers so no additional setup is required.

  • Has support for setting breakpoints/watch variables, stepping over lines of code, stepping into executed functions, views of running threads and their stacktraces.

To see the above features in action, this is an example that shows a list of running threads and corresponding stack traces in the extension UI:



The currently executed source line is highlighted in the editor and you can pause, step in and out and continue the execution:

In addition, you can see and inspect the variables and add them to watchlist:



Installation

The first step is to install Visual Studio Code, so if you don’t have it already installed you can download it here. After you install and start it, open the Extensions tab (View->Extensions) and search for “Oculus Debugger”, then click on the Install button. To debug your Oculus project you would need to create a debug configuration file, which you can read more about in the documentation.



UE4 Integration

Starting with Oculus's GitHub version of UE4.26 released this week, the GenerateProjectFiles.bat UE script can be used to generate a workspace that contains configurations to build and debug all code projects in your local UE folder. More info can be found in the user guide.

Next Steps

We’re excited to publicly launch Oculus Debugger today to make Quest development easier for our UE4 and Native developers. We look forward to hearing your feedback so we can improve the product over time.