Skip to content

Commit 8d888a7

Browse files
author
Mark Fine
committed
ARCore Android SDK v1.45.0
1 parent 80036a5 commit 8d888a7

File tree

250 files changed

+7345
-4506
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

250 files changed

+7345
-4506
lines changed

libraries/include/arcore_c_api.h

Lines changed: 38 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1331,6 +1331,15 @@ AR_DEFINE_ENUM(ArFocusMode){/// Focus is fixed.
13311331
/// Auto-focus is enabled.
13321332
AR_FOCUS_MODE_AUTO = 1};
13331333

1334+
/// @ingroup ArConfig
1335+
/// Selects the desired behavior of the camera flash subsystem. See the <a
1336+
/// href="https://developers.google.com/ar/develop/camera/flash/c">documentation
1337+
/// page</a> for more information on using the device's flash.
1338+
AR_DEFINE_ENUM(ArFlashMode){/// Flash is off.
1339+
AR_FLASH_MODE_OFF = 0,
1340+
/// Flash is on.
1341+
AR_FLASH_MODE_TORCH = 2};
1342+
13341343
/// @ingroup ArConfig
13351344
/// Describes the behavior of the Electronic Image Stabilization (EIS) API. When
13361345
/// enabled, EIS smoothes the camera feed and helps correct video shakes in the
@@ -2504,6 +2513,33 @@ void ArConfig_getFocusMode(const ArSession *session,
25042513
ArConfig *config,
25052514
ArFocusMode *focus_mode);
25062515

2516+
/// @ingroup ArConfig
2517+
/// Gets the current camera flash mode set on this config object.
2518+
///
2519+
/// @param[in] session The ARCore session.
2520+
/// @param[in] config The configuration object.
2521+
/// @param[inout] out_flash_mode The current camera flash mode.
2522+
void ArConfig_getFlashMode(const ArSession *session,
2523+
const ArConfig *config,
2524+
ArFlashMode *out_flash_mode);
2525+
2526+
/// @ingroup ArConfig
2527+
/// Sets the camera flash mode.
2528+
///
2529+
/// See @c ::ArFlashMode for available options. The default flash
2530+
/// mode is @c #AR_FLASH_MODE_OFF. Note, on devices where camera flash hardware
2531+
/// is not supported, calling this function will do nothing.
2532+
/// See the <a
2533+
/// href="https://developers.google.com/ar/develop/camera/flash/c">documentation
2534+
/// page</a> for more information on how to query device flash capability.
2535+
///
2536+
/// @param[in] session The ARCore session.
2537+
/// @param[in] config The configuration object.
2538+
/// @param[in] flash_mode The desired camera flash mode.
2539+
void ArConfig_setFlashMode(const ArSession *session,
2540+
ArConfig *config,
2541+
ArFlashMode flash_mode);
2542+
25072543
/// @ingroup ArConfig
25082544
/// Gets the camera image stabilization mode set on this config
25092545
/// object.
@@ -7675,7 +7711,7 @@ typedef struct ArImageMetadata_const_entry {
76757711
/// The tag identifying the entry.
76767712
uint32_t tag;
76777713
/// The data type of this metadata entry. Determines which data pointer in the
7678-
/// @c union below is valid.
7714+
/// @c union below is valid. See @c ACAMERA_TYPE_* enum values in the NDK.
76797715
uint8_t type;
76807716
/// Count of elements (NOT count of bytes) in this metadata entry.
76817717
uint32_t count;
@@ -7728,7 +7764,7 @@ void ArImageMetadata_getAllKeys(const ArSession *session,
77287764
/// Get a metadata entry for the provided @c ::ArImageMetadata and tag.
77297765
///
77307766
/// The returned @p out_metadata_entry remains valid until the provided @p
7731-
/// image_metadata is released via @c ::ArFrame_acquireImageMetadata.
7767+
/// image_metadata is released via @c ::ArImageMetadata_release.
77327768
///
77337769
/// @param[in] session The ARCore session.
77347770
/// @param[in] image_metadata @c ::ArImageMetadata struct obtained from

samples/augmented_faces_java/app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ android {
4141

4242
dependencies {
4343
// ARCore (Google Play Services for AR) library.
44-
implementation 'com.google.ar:core:1.44.0'
44+
implementation 'com.google.ar:core:1.45.0'
4545

4646
// Obj - a simple Wavefront OBJ file loader
4747
// https://github.com/javagl/Obj

samples/augmented_faces_java/app/src/main/java/com/google/ar/core/examples/java/common/helpers/SnackbarHelper.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,11 @@ public void setMaxLines(int lines) {
9292
maxLines = lines;
9393
}
9494

95+
/** Returns whether the snackbar is currently being shown with an indefinite duration. */
96+
public boolean isDurationIndefinite() {
97+
return isShowing() && messageSnackbar.getDuration() == Snackbar.LENGTH_INDEFINITE;
98+
}
99+
95100
/**
96101
* Sets the view that will be used to find a suitable parent view to hold the Snackbar view.
97102
*

samples/augmented_image_c/app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,8 @@ android {
6868

6969
dependencies {
7070
// ARCore (Google Play Services for AR) library.
71-
implementation 'com.google.ar:core:1.44.0'
72-
natives 'com.google.ar:core:1.44.0'
71+
implementation 'com.google.ar:core:1.45.0'
72+
natives 'com.google.ar:core:1.45.0'
7373

7474
implementation 'androidx.appcompat:appcompat:1.1.0'
7575
implementation 'com.google.android.material:material:1.1.0'

samples/augmented_image_java/app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ android {
4141

4242
dependencies {
4343
// ARCore (Google Play Services for AR) library.
44-
implementation 'com.google.ar:core:1.44.0'
44+
implementation 'com.google.ar:core:1.45.0'
4545

4646
// Obj - a simple Wavefront OBJ file loader
4747
// https://github.com/javagl/Obj

samples/augmented_image_java/app/src/main/java/com/google/ar/core/examples/java/common/helpers/SnackbarHelper.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,11 @@ public void setMaxLines(int lines) {
9292
maxLines = lines;
9393
}
9494

95+
/** Returns whether the snackbar is currently being shown with an indefinite duration. */
96+
public boolean isDurationIndefinite() {
97+
return isShowing() && messageSnackbar.getDuration() == Snackbar.LENGTH_INDEFINITE;
98+
}
99+
95100
/**
96101
* Sets the view that will be used to find a suitable parent view to hold the Snackbar view.
97102
*

samples/cloud_anchor_java/app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ android {
4141

4242
dependencies {
4343
// ARCore (Google Play Services for AR) library.
44-
implementation 'com.google.ar:core:1.44.0'
44+
implementation 'com.google.ar:core:1.45.0'
4545

4646
// Obj - a simple Wavefront OBJ file loader
4747
// https://github.com/javagl/Obj

samples/cloud_anchor_java/app/src/main/java/com/google/ar/core/examples/java/common/helpers/SnackbarHelper.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,11 @@ public void setMaxLines(int lines) {
9292
maxLines = lines;
9393
}
9494

95+
/** Returns whether the snackbar is currently being shown with an indefinite duration. */
96+
public boolean isDurationIndefinite() {
97+
return isShowing() && messageSnackbar.getDuration() == Snackbar.LENGTH_INDEFINITE;
98+
}
99+
95100
/**
96101
* Sets the view that will be used to find a suitable parent view to hold the Snackbar view.
97102
*

samples/computervision_c/app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,8 @@ android {
6868

6969
dependencies {
7070
// ARCore (Google Play Services for AR) library.
71-
implementation 'com.google.ar:core:1.44.0'
72-
natives 'com.google.ar:core:1.44.0'
71+
implementation 'com.google.ar:core:1.45.0'
72+
natives 'com.google.ar:core:1.45.0'
7373

7474
implementation 'androidx.appcompat:appcompat:1.1.0'
7575
implementation 'com.google.android.material:material:1.1.0'

samples/computervision_java/app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ android {
4141

4242
dependencies {
4343
// ARCore (Google Play Services for AR) library.
44-
implementation 'com.google.ar:core:1.44.0'
44+
implementation 'com.google.ar:core:1.45.0'
4545

4646
// Obj - a simple Wavefront OBJ file loader
4747
// https://github.com/javagl/Obj

0 commit comments

Comments
 (0)