Skip to content

Commit 93eff89

Browse files
authored
Closes #2911 Remove unsupported platforms (#2976)
* Remove unsupported platforms * third party hash update * VRB update
1 parent e1f3240 commit 93eff89

27 files changed

+8
-20418
lines changed

README.md

+1-16
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ git clone [email protected]:MozillaReality/FirefoxReality-android-third-party.git t
4242
This repo is only available to Mozilla employees. If you have access to the relevant SDK but not this repo, you can manually place them here:
4343

4444
- `third_party/ovr_mobile/` for Oculus (should contain a `VrApi` folder)
45-
- `third_party/svr/` for Snapdragon (should contain a `libs` folder, among other things)
4645
- `third_party/wavesdk/` for Vive (should contain a `build` folder, among other things)
4746

4847
The [repo in `third_party`](https://github.com/MozillaReality/FirefoxReality-android-third-party) can be updated like so:
@@ -62,32 +61,18 @@ git submodule update --init --recursive
6261
You can build for different devices:
6362

6463
- **`oculusvr`**: Samsung Gear VR & Oculus Go
65-
- **`svr`**: Qualcomm & ODG glasses
6664
- **`wavevr`**: VIVE Focus
67-
- **`googlevr`**: Google Daydream
6865

6966
For testing on a non-VR device:
7067

7168
- **`noapi`**: Runs on standard Android phones without a headset
7269

73-
Building for Oculus Mobile, SVR, and WaveVR requires access to their respective SDKs which are not included in this repo.
74-
75-
*If you want to build FirefoxReality for Google Daydream (`googlevr`), you need to run:*
76-
77-
```bash
78-
cd gvr-android-sdk && ./gradlew :extractNdk
79-
```
70+
Building for Oculus Mobile, and WaveVR requires access to their respective SDKs which are not included in this repo.
8071

8172
The command line version of `gradlew` requires [JDK 8 from Oracle](http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html). If you see an error that Gradle doesn't understand your Java version, check which version of you're using by running `java -showversion` or `java -version`. You're probably using JDK 9 or 10, which won't work.
8273

83-
If you get an error extracting the NDK, you might need to copy the `local.properties file` from the top-level project directory into the `gvr-android-sdk` directory. If this file doesn't exist at the top-level directory either, open the top-level directory in Android Studio, and it should be created.
84-
8574
*Open the project with [Android Studio](https://developer.android.com/studio/index.html)* then build and run it. Depending on what you already have installed in Android Studio, the build may fail and then may prompt you to install dependencies. Just keep doing as it suggests. To select the device to build for, go to `Tool Windows > Build Variants` and select a build variant corresponding to your device.
8675

87-
If you run the APK on an Android device outside of Daydream or Gear VR, it will run in flat mode. To run in VR, put the device into a headset, and run the app from the VR launcher.
88-
89-
Unfortunately, for mobile-clip-in VR viewers, the APK isn't yet published in the Google Play Store because of [known performance issues and bugs](https://github.com/MozillaReality/FirefoxReality/issues/598). The APK currently available is for only standalone Daydream headsets.
90-
9176
*If you want to build FirefoxReality for WaveVR SDK:*
9277

9378
Download the [VIVE Wave SDK](https://developer.vive.com/resources/knowledgebase/wave-sdk/) from the [VIVE Developer Resources](https://vivedeveloper.com/), and unzip it. Then, from the top-level project directory, run:

app/.gitignore

-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
/build
2-
/googlevr*
3-
/googlevrFlat*
42
/oculusvr*
53
/noapi*
64
/svr*

app/CMakeLists.txt

-23
Original file line numberDiff line numberDiff line change
@@ -54,13 +54,6 @@ target_sources(
5454
src/wavevr/cpp/native-lib.cpp
5555
src/wavevr/cpp/DeviceDelegateWaveVR.cpp
5656
)
57-
elseif(GOOGLEVR)
58-
target_sources(
59-
native-lib
60-
PUBLIC
61-
src/googlevr/cpp/native-lib.cpp
62-
src/googlevr/cpp/DeviceDelegateGoogleVR.cpp
63-
)
6457
elseif(PICOVR)
6558
target_sources(
6659
native-lib
@@ -110,14 +103,6 @@ add_custom_command(TARGET native-lib POST_BUILD
110103
)
111104
endif()
112105

113-
if(SNAPDRAGONVR)
114-
target_sources(
115-
native-lib
116-
PUBLIC
117-
src/svr/cpp/DeviceDelegateSVR.cpp
118-
)
119-
endif()
120-
121106
# Searches for a specified prebuilt library and stores the path as a
122107
# variable. Because CMake includes system libraries in the search path by
123108
# default, you only need to specify the name of the public NDK library
@@ -140,14 +125,6 @@ add_library(ovrplatform-lib SHARED IMPORTED)
140125
set_target_properties(ovrplatform-lib PROPERTIES IMPORTED_LOCATION
141126
${CMAKE_SOURCE_DIR}/../third_party/OVRPlatformSDK/Android/libs/${ANDROID_ABI}/libovrplatformloader.so )
142127

143-
add_library(googlevr-lib SHARED IMPORTED)
144-
set_target_properties(googlevr-lib PROPERTIES IMPORTED_LOCATION
145-
${CMAKE_SOURCE_DIR}/../gvr-android-sdk/libraries/jni/${ANDROID_ABI}/libgvr.so)
146-
147-
add_library(svr-lib SHARED IMPORTED)
148-
set_target_properties(svr-lib PROPERTIES IMPORTED_LOCATION
149-
${CMAKE_SOURCE_DIR}/../third_party/svr/libs/${ANDROID_ABI}/libsvrapi.so )
150-
151128
add_library(wavevr-lib SHARED IMPORTED)
152129
set_target_properties(wavevr-lib PROPERTIES IMPORTED_LOCATION
153130
${CMAKE_SOURCE_DIR}/../third_party/wavesdk/build/wvr_client/jni/${ANDROID_ABI}/libwvr_api.so )

app/build.gradle

-98
Original file line numberDiff line numberDiff line change
@@ -110,25 +110,10 @@ android {
110110
disable "ExtraTranslation"
111111
}
112112

113-
packagingOptions {
114-
pickFirst '/lib/*/libgvr.so'
115-
}
116-
117113
flavorDimensions "platform", "abi"
118114

119115
productFlavors {
120116
// Supported platforms
121-
googlevr {
122-
dimension "platform"
123-
externalNativeBuild {
124-
cmake {
125-
cppFlags " -I" + file("${project.rootDir}/gvr-android-sdk/libraries/headers").absolutePath +
126-
" -DVRBROWSER_GOOGLEVR"
127-
arguments "-DVR_SDK_LIB=googlevr-lib", "-DGOOGLEVR=ON"
128-
}
129-
}
130-
}
131-
132117
oculusvr {
133118
dimension "platform"
134119
externalNativeBuild {
@@ -171,18 +156,6 @@ android {
171156
manifestPlaceholders = [ headtrackingRequired:"false", permissionToRemove:"android.permission.CAMERA" ]
172157
}
173158

174-
svr {
175-
dimension "platform"
176-
externalNativeBuild {
177-
cmake {
178-
cppFlags " -I" + file("${project.rootDir}/third_party/svr/public").absolutePath +
179-
" -I" + file("${project.rootDir}/app/src/svr/cpp").absolutePath +
180-
" -DSNAPDRAGONVR"
181-
arguments "-DVR_SDK_LIB=svr-lib", "-DSNAPDRAGONVR=ON"
182-
}
183-
}
184-
}
185-
186159
wavevr {
187160
minSdkVersion build_versions.min_sdk_wave
188161
dimension "platform"
@@ -229,13 +202,6 @@ android {
229202
}
230203

231204
// Supported ABIs
232-
arm {
233-
dimension "abi"
234-
ndk {
235-
abiFilters "armeabi-v7a"
236-
}
237-
}
238-
239205
arm64 {
240206
dimension "abi"
241207
ndk {
@@ -253,38 +219,18 @@ android {
253219

254220
variantFilter { variant ->
255221
def needed = variant.name in [
256-
'googlevrArmDebug',
257-
'googlevrArmRelease',
258-
'googlevrArm64Debug',
259-
'googlevrArm64Release',
260-
'oculusvrArmDebug',
261-
'oculusvrArmRelease',
262222
'oculusvrArm64Debug',
263223
'oculusvrArm64Release',
264-
'oculusvrStoreArmDebug',
265-
'oculusvrStoreArmRelease',
266224
'oculusvrStoreArm64Debug',
267225
'oculusvrStoreArm64Release',
268-
'oculusvr3dofStoreArmDebug',
269-
'oculusvr3dofStoreArmRelease',
270226
'oculusvr3dofStoreArm64Debug',
271227
'oculusvr3dofStoreArm64Release',
272-
'svrArmDebug',
273-
'svrArmRelease',
274-
'svrArm64Debug',
275-
'svrArm64Release',
276228
'picovrArm64Debug',
277229
'picovrArm64Release',
278-
'wavevrArmDebug',
279-
'wavevrArmRelease',
280230
'wavevrArm64Debug',
281231
'wavevrArm64Release',
282-
'wavevrStoreArmDebug',
283-
'wavevrStoreArmRelease',
284232
'wavevrStoreArm64Debug',
285233
'wavevrStoreArm64Release',
286-
'noapiArmDebug',
287-
'noapiArmRelease',
288234
'noapiArm64Debug',
289235
'noapiArm64Release',
290236
'noapiX86_64Debug',
@@ -309,12 +255,6 @@ android {
309255

310256
}
311257

312-
googlevr {
313-
java.srcDirs = [
314-
'src/googlevr/java'
315-
]
316-
}
317-
318258
oculusvr {
319259
java.srcDirs = [
320260
'src/oculusvr/java'
@@ -339,11 +279,6 @@ android {
339279
]
340280
}
341281

342-
oculusvrArmRelease {
343-
manifest.srcFile getUseDebugSigningOnRelease() ? "src/oculusvrArmDebug/AndroidManifest.xml"
344-
: manifest.srcFile
345-
}
346-
347282
oculusvrArm64Debug {
348283
manifest.srcFile "src/oculusvrArmDebug/AndroidManifest.xml"
349284
}
@@ -353,49 +288,24 @@ android {
353288
: "src/oculusvrArmRelease/AndroidManifest.xml"
354289
}
355290

356-
oculusvrStoreArmDebug {
357-
manifest.srcFile "src/oculusvrArmDebug/AndroidManifest.xml"
358-
}
359-
360291
oculusvrStoreArm64Debug {
361292
manifest.srcFile "src/oculusvrArmDebug/AndroidManifest.xml"
362293
}
363294

364-
oculusvrStoreArmRelease {
365-
manifest.srcFile getUseDebugSigningOnRelease() ? "src/oculusvrArmDebug/AndroidManifest.xml"
366-
: "src/oculusvrArmRelease/AndroidManifest.xml"
367-
}
368-
369295
oculusvrStoreArm64Release {
370296
manifest.srcFile getUseDebugSigningOnRelease() ? "src/oculusvrArmDebug/AndroidManifest.xml"
371297
: "src/oculusvrArmRelease/AndroidManifest.xml"
372298
}
373299

374-
oculusvr3dofStoreArmDebug {
375-
manifest.srcFile "src/oculusvrArmDebug/AndroidManifest.xml"
376-
}
377-
378300
oculusvr3dofStoreArm64Debug {
379301
manifest.srcFile "src/oculusvrArmDebug/AndroidManifest.xml"
380302
}
381303

382-
oculusvr3dofStoreArmRelease {
383-
manifest.srcFile getUseDebugSigningOnRelease() ? "src/oculusvrArmDebug/AndroidManifest.xml"
384-
: "src/oculusvrArmRelease/AndroidManifest.xml"
385-
}
386-
387304
oculusvr3dofStoreArm64Release {
388305
manifest.srcFile getUseDebugSigningOnRelease() ? "src/oculusvrArmDebug/AndroidManifest.xml"
389306
: "src/oculusvrArmRelease/AndroidManifest.xml"
390307
}
391308

392-
svr {
393-
java.srcDirs = [
394-
'src/svr/java'
395-
]
396-
jniLibs.srcDirs = ["${project.rootDir}/third_party/svr/libs"]
397-
}
398-
399309
wavevr {
400310
java.srcDirs = [
401311
'src/wavevr/java'
@@ -456,7 +366,6 @@ dependencies {
456366
implementation deps.openwnn
457367

458368
// Common
459-
// implementation deps.google_vr.sdk_audio
460369
implementation deps.lifecycle.runtime
461370
implementation deps.lifecycle.extensions
462371
implementation deps.support.cardview
@@ -515,20 +424,13 @@ dependencies {
515424
testImplementation deps.telemetry.glean_unittests
516425
testImplementation deps.work.testing
517426

518-
// Daydream
519-
googlevrImplementation deps.google_vr.sdk_base
520-
521-
// ODG
522-
svrImplementation fileTree(dir: "${project.rootDir}/third_party/svr/", include: ['*.jar'])
523-
524427
// Pico
525428
picovrImplementation fileTree(dir: "${project.rootDir}/third_party/picovr/", include: ['*.jar'])
526429
}
527430

528431
if (findProject(':servo')) {
529432
dependencies {
530433
oculusvrImplementation project(':servo')
531-
googlevrImplementation project(':servo')
532434
}
533435
}
534436

app/metrics.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ distribution:
1111
lifetime: application
1212
description: >
1313
The distribution channel name of this application. We use this field to recognize Firefox Reality
14-
is distributed to which channels, such as wavevr, oculusvr, googlevr, etc.
14+
is distributed to which channels, such as wavevr, oculusvr, etc.
1515
send_in_pings:
1616
- baseline
1717
- events

app/src/common/shared/org/mozilla/vrbrowser/VRBrowserActivity.java

-12
Original file line numberDiff line numberDiff line change
@@ -707,18 +707,6 @@ public boolean dispatchKeyEvent(KeyEvent event) {
707707
}
708708
return result || super.dispatchKeyEvent(event);
709709

710-
} else if (DeviceType.isGoogleVR()) {
711-
boolean result;
712-
switch (keyCode) {
713-
case KeyEvent.KEYCODE_VOLUME_UP:
714-
case KeyEvent.KEYCODE_VOLUME_DOWN:
715-
result = true;
716-
break;
717-
default:
718-
result = super.dispatchKeyEvent(event);
719-
break;
720-
}
721-
return result;
722710
}
723711
return super.dispatchKeyEvent(event);
724712
}

app/src/common/shared/org/mozilla/vrbrowser/utils/DeviceType.java

-4
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,6 @@ public static boolean isWaveBuild() {
3636
return BuildConfig.FLAVOR_platform.toLowerCase().contains("wavevr");
3737
}
3838

39-
public static boolean isGoogleVR() {
40-
return BuildConfig.FLAVOR_platform.toLowerCase().contains("googlevr");
41-
}
42-
4339
public static boolean isPicoVR() {
4440
return BuildConfig.FLAVOR_platform.toLowerCase().contains("picovr");
4541
}

app/src/googlevr/AndroidManifest.xml

-36
This file was deleted.

app/src/googlevr/assets/vr_controller_daydream.mtl

-14
This file was deleted.

0 commit comments

Comments
 (0)