Launch with intent

In Chapter 7, 360-Degree Gallery, we introduced the use of Android intents to associate an app with a specific file type in order to launch our app as a viewer of those files. We'll do the same for OBJ files here.

An intent is a message that any app can send to the Android system that declares its intent to use another app for a certain purpose. The intent object contains a number of members to describe what type of action needs to be done, and, if any, the data on which it needs to be done. For the image gallery, we associated the intent filter with an image mime type. For this project, we'll associate an intent filter with a filename extension.

In your AndroidManifest.xml file, add an intent filter to the activity block. This ...

Get Cardboard VR Projects for Android now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.