Skip to content
This repository was archived by the owner on Nov 8, 2019. It is now read-only.

Commit 233e7fe

Browse files
committed
GVR Android SDK v1.130.0
1 parent 3bd22d7 commit 233e7fe

Some content is hidden

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

49 files changed

+98
-770
lines changed

NOTICE

Lines changed: 0 additions & 706 deletions
Large diffs are not rendered by default.

apks/controller_emulator.apk

-63.3 KB
Binary file not shown.

build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,13 @@ task clean(type: Delete) {
3333
// The dependencies for NDK builds live inside the .aar files so they need to
3434
// be extracted before NDK targets can build.
3535
task extractAudioSo(type: Copy) {
36-
from zipTree("${project.rootDir}/libraries/sdk-audio-1.120.0.aar")
36+
from zipTree("${project.rootDir}/libraries/sdk-audio-1.130.0.aar")
3737
into "${project.rootDir}/libraries/"
3838
include "jni/**/libgvr_audio.so"
3939
}
4040

4141
task extractGvrSo(type: Copy) {
42-
from zipTree("${project.rootDir}/libraries/sdk-base-1.120.0.aar")
42+
from zipTree("${project.rootDir}/libraries/sdk-base-1.130.0.aar")
4343
into "${project.rootDir}/libraries/"
4444
include "jni/**/libgvr.so"
4545
}

gradle/wrapper/gradle-wrapper.jar

-4 Bytes
Binary file not shown.

libraries/headers/vr/gvr/capi/include/gvr.h

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -707,10 +707,17 @@ gvr_swap_chain* gvr_swap_chain_create(gvr_context* gvr,
707707
const gvr_buffer_spec** buffers,
708708
int32_t count);
709709

710-
/// Destroys the swap chain and nulls the pointer.
710+
/// Destroys the swap chain and nulls the pointer that is passed in. This
711+
/// should be called after rendering is finished to free all the buffers that
712+
/// have been allocated in the swap chain.
713+
///
714+
/// @param swap_chain The swap chain to destroy.
711715
void gvr_swap_chain_destroy(gvr_swap_chain** swap_chain);
712716

713717
/// Gets the number of buffers in each frame of the swap chain.
718+
///
719+
/// @param swap_chain The swap chain to query.
720+
/// @return The number of buffers in the swap chain.
714721
int32_t gvr_swap_chain_get_buffer_count(const gvr_swap_chain* swap_chain);
715722

716723
/// Retrieves the size of the specified pixel buffer. Note that if the buffer
@@ -800,6 +807,10 @@ AHardwareBuffer* gvr_frame_get_hardware_buffer(const gvr_frame* frame,
800807
/// Submits the frame for distortion and display on the screen. The passed
801808
/// pointer is nulled to prevent reuse.
802809
///
810+
/// Note: On Cardboard devices, this function makes OpenGL commands in the
811+
/// current thread's GL context; this can affect various GL state such as
812+
/// texture bindings, depth testing, backface culling, and blending.
813+
///
803814
/// @param frame The frame to submit.
804815
/// @param list Buffer view configuration to be used for this frame.
805816
/// @param head_space_from_start_space Transform from start space (space with
@@ -1457,7 +1468,7 @@ class GvrApi {
14571468
if (!context) {
14581469
return nullptr;
14591470
}
1460-
return std::unique_ptr<GvrApi>(new GvrApi(context, true /* owned */));
1471+
return std::unique_ptr<GvrApi>(new GvrApi(context, /*owned=*/true));
14611472
}
14621473
#else
14631474
/// Instantiates and returns a GvrApi instance that owns a gvr_context.
@@ -1468,7 +1479,7 @@ class GvrApi {
14681479
if (!context) {
14691480
return nullptr;
14701481
}
1471-
return std::unique_ptr<GvrApi>(new GvrApi(context, true /* owned */));
1482+
return std::unique_ptr<GvrApi>(new GvrApi(context, /*owned=*/true));
14721483
}
14731484
#endif // #ifdef __ANDROID__
14741485

@@ -1699,7 +1710,7 @@ class GvrApi {
16991710
/// @param context Pointer to a non-null, non-owned gvr_context instance.
17001711
/// @return unique_ptr to the created GvrApi instance. Never null.
17011712
static std::unique_ptr<GvrApi> WrapNonOwned(gvr_context* context) {
1702-
return std::unique_ptr<GvrApi>(new GvrApi(context, false /* owned */));
1713+
return std::unique_ptr<GvrApi>(new GvrApi(context, /*owned=*/false));
17031714
}
17041715
/// @}
17051716

libraries/headers/vr/gvr/capi/include/gvr_audio.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -355,7 +355,7 @@ extern "C" {
355355
/// position_x,
356356
/// position_y,
357357
/// position_z);
358-
/// gvr_audio_api->PlaySound(source_id, true /* looped playback */);
358+
/// gvr_audio_api->PlaySound(source_id, /*looped playback=*/true);
359359
///
360360

361361
/// @{

libraries/headers/vr/gvr/capi/include/gvr_types.h

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -378,10 +378,13 @@ typedef enum {
378378
GVR_CONTROLLER_BUTTON_APP = 3,
379379
GVR_CONTROLLER_BUTTON_VOLUME_UP = 4,
380380
GVR_CONTROLLER_BUTTON_VOLUME_DOWN = 5,
381+
GVR_CONTROLLER_BUTTON_RESERVED0 = 6,
382+
GVR_CONTROLLER_BUTTON_RESERVED1 = 7,
383+
GVR_CONTROLLER_BUTTON_RESERVED2 = 8,
381384

382-
/// Note: there are 5 buttons on the controller, but the state arrays have
385+
/// Note: there are 8 buttons on the controller, but the state arrays have
383386
/// this many elements due to the inclusion of a dummy "none" button.
384-
GVR_CONTROLLER_BUTTON_COUNT = 6,
387+
GVR_CONTROLLER_BUTTON_COUNT = 9,
385388
} gvr_controller_button;
386389

387390
/// Controller battery states.

libraries/headers/vr/gvr/capi/include/gvr_version.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,14 @@ extern "C" {
2323
/// A string representation of the current GVR build version. This is of
2424
/// the form "MAJOR.MINOR.PATCH". Note that this may differ from the runtime
2525
/// GVR version as reported by gvr_get_version_string().
26-
#define GVR_SDK_VERSION_STRING "1.120.0"
26+
#define GVR_SDK_VERSION_STRING "1.130.0"
2727

2828
/// Semantic components for the current GVR build version. Note that these
2929
/// values may differ from the runtime GVR version as reported by
3030
/// gvr_get_version().
3131
enum {
3232
GVR_SDK_MAJOR_VERSION = 1,
33-
GVR_SDK_MINOR_VERSION = 120,
33+
GVR_SDK_MINOR_VERSION = 130,
3434
GVR_SDK_PATCH_VERSION = 0,
3535
};
3636

libraries/sdk-audio-1.120.0.aar

-834 KB
Binary file not shown.

libraries/sdk-audio-1.130.0.aar

1.25 MB
Binary file not shown.

0 commit comments

Comments
 (0)