Skip to content

Commit

Permalink
ARCore Android SDK v1.37.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Joseph Dibble committed May 10, 2023
1 parent 429ee46 commit 0192b44
Show file tree
Hide file tree
Showing 456 changed files with 285,970 additions and 3,434 deletions.
828 changes: 826 additions & 2 deletions LICENSE

Large diffs are not rendered by default.

1,730 changes: 1,598 additions & 132 deletions libraries/include/arcore_c_api.h

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion samples/augmented_faces_java/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ android {

dependencies {
// ARCore (Google Play Services for AR) library.
implementation 'com.google.ar:core:1.36.0'
implementation 'com.google.ar:core:1.37.0'

// Obj - a simple Wavefront OBJ file loader
// https://github.com/javagl/Obj
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
/*
* Copyright 2023 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.google.ar.core.examples.java.common.helpers;

import android.content.Context;
import android.content.SharedPreferences;

/**
* A class providing persistent EIS preference across instances using {@code
* android.content.SharedPreferences}.
*/
public class EisSettings {
public static final String SHARED_PREFERENCE_ID = "SHARED_PREFERENCE_EIS_OPTIONS";
public static final String SHARED_PREFERENCE_EIS_ENABLED = "eis_enabled";
private boolean eisEnabled = false;
private SharedPreferences sharedPreferences;

/** Creates shared preference entry for EIS setting. */
public void onCreate(Context context) {
sharedPreferences = context.getSharedPreferences(SHARED_PREFERENCE_ID, Context.MODE_PRIVATE);
eisEnabled = sharedPreferences.getBoolean(SHARED_PREFERENCE_EIS_ENABLED, false);
}

/** Returns saved EIS state. */
public boolean isEisEnabled() {
return eisEnabled;
}

/** Sets and saves the EIS using {@code android.content.SharedPreferences} */
public void setEisEnabled(boolean enable) {
if (enable == eisEnabled) {
return;
}

eisEnabled = enable;
SharedPreferences.Editor editor = sharedPreferences.edit();
editor.putBoolean(SHARED_PREFERENCE_EIS_ENABLED, eisEnabled);
editor.apply();
}
}
Binary file modified samples/augmented_faces_java/gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
Loading

0 comments on commit 0192b44

Please sign in to comment.