cancel
Showing results for 
Search instead for 
Did you mean: 

SDK 0.4 - Distortion Params?

CitizenSnips
Honored Guest
Hi there. I'm a bit new to the Oculus SDK (and rendering in general). Currently my team is trying to utilize the Oculus to create a 3D augmented reality. However, I'm running into an issue where I can't locate where the SDK provides the distortion params for a lens warp. Every piece of example code I've seen draws from DX which I don't fully understand. Is there any way I can do a simple grab from the Oculus libs instead of including DX? I saw that in previous versions of the SDK you could grab directly from DistortionK, but now that seems to have been put to the wayside (a grep on the src directory shows DistortionK is private now). In case it's needed, I'm using VTK for rendering.
4 REPLIES 4

jherico
Adventurer
If you're using VTK with OpenGL, then you should be relying on the SDK to do the distortion. If that's impractical for some reason, you can do the distortion yourself, but rather than using distortion parameters, you fetch a distortion mesh from the SDK and use that to do the distortion.

The distortion parameters are all deep inside the SDK and not exposed directly through the 0.4.x C API.
Brad Davis - Developer for High Fidelity Co-author of Oculus Rift in Action

CitizenSnips
Honored Guest
Oh awesome, that's really good to know. Is there a guide anywhere that details exactly how SDK distortion is integrated, or perhaps a post that points to the necessary classes?

jherico
Adventurer
"CitizenSnips" wrote:
Oh awesome, that's really good to know. Is there a guide anywhere that details exactly how SDK distortion is integrated, or perhaps a post that points to the necessary classes?


Well, there's my book on using the Oculus Rift with OpenGL and C++. It doesn't specifically cover VTK, but it does detail how to integrate your application with the SDK, specifically covering distortion. The current early access version is somewhat out of date, with the chapters on distortion still working with the 0.2.x SDK, but the next version of the MEAP (Manning early access program) should have all the available chapters updated to the 0.4.x SDK, and should be available within a couple of weeks.

Additionally, all of the source code for the examples in the book is available on my GitHub repositories.
Brad Davis - Developer for High Fidelity Co-author of Oculus Rift in Action

CitizenSnips
Honored Guest
Alright, I'll have to see if I can pull from the budget for the book 😛 Looks like it would be worth it though. Until that's decided I'll definitely check out the code examples you provided. Thanks a ton
Still need help?

Did this answer your question? If it didn’t, use our search to find other topics or create your own and other members of the community will help out.

If you need an agent to help with your Meta device, please contact our store support team here.

Having trouble with a Facebook or Instagram account? The best place to go for help with those accounts is the Facebook Help Center or the Instagram Help Center. This community can't help with those accounts.

Check out some popular posts here:

Getting Help from the Meta Quest Community

Tips and Tricks: Charging your Meta Quest Headset

Tips and Tricks: Help with Pairing your Meta Quest

Trouble With Facebook/Instagram Accounts?