Skip to content

Commit

Permalink
ARCore iOS SDK v1.36.0
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremyvc committed Mar 2, 2023
1 parent f892f4b commit 03978f8
Show file tree
Hide file tree
Showing 29 changed files with 12,586 additions and 94 deletions.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
18 changes: 18 additions & 0 deletions AugmentedFaces/Sources/dummy.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
* Copyright 2022 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.
*/

// Swift Package Manager requires that every target has a header file.
#pragma mark To the linter: this is an Objective-C header file.
18 changes: 18 additions & 0 deletions AugmentedFaces/dummy.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
* 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.
*/

// Trigger auto-linking if ARCore is never imported in the app.
@import ARCore;
27 changes: 27 additions & 0 deletions Base/Sources/ARCore/ARCore.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
/*
* Copyright 2022 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.
*/
#if __has_include(<ARCoreAugmentedFaces/ARCoreAugmentedFaces.h>)
#import <ARCoreAugmentedFaces/ARCoreAugmentedFaces.h>
#endif
#if __has_include(<ARCoreCloudAnchors/ARCoreCloudAnchors.h>)
#import <ARCoreCloudAnchors/ARCoreCloudAnchors.h>
#endif
#if __has_include(<ARCoreGeospatial/ARCoreGeospatial.h>)
#import <ARCoreGeospatial/ARCoreGeospatial.h>
#endif
#if __has_include(<ARCoreGARSession/ARCoreGARSession.h>)
#import <ARCoreGARSession/ARCoreGARSession.h>
#endif
4 changes: 4 additions & 0 deletions Base/Sources/ARCore/module.modulemap
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
module ARCore {
export *
header "ARCore.h"
}
18 changes: 18 additions & 0 deletions Base/Sources/dummy.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
* Copyright 2022 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.
*/

// Swift Package Manager requires that every target has a header file.
#pragma mark To the linter: this is an Objective-C header file.
18 changes: 18 additions & 0 deletions Base/dummy.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
* 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.
*/

// Trigger auto-linking if ARCore is never imported in the app.
@import ARCore;
18 changes: 18 additions & 0 deletions CloudAnchors/Sources/dummy.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
* Copyright 2022 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.
*/

// Swift Package Manager requires that every target has a header file.
#pragma mark To the linter: this is an Objective-C header file.
18 changes: 18 additions & 0 deletions CloudAnchors/dummy.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
* 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.
*/

// Trigger auto-linking if ARCore is never imported in the app.
@import ARCore;
2 changes: 1 addition & 1 deletion Examples/AugmentedFacesExample/Podfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
target 'AugmentedFacesExample'
use_frameworks!
platform :ios, '11.0'
pod 'ARCore/AugmentedFaces', '~> 1.35.0'
pod 'ARCore/AugmentedFaces', '~> 1.36.0'
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.3;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
Expand Down Expand Up @@ -283,7 +283,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.3;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
VALIDATE_PRODUCT = YES;
Expand All @@ -299,7 +299,7 @@
DEVELOPMENT_TEAM = EQHXZ8M8AV;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = CloudAnchorExample/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.3;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
OTHER_LDFLAGS = (
"$(inherited)",
Expand All @@ -321,7 +321,7 @@
DEVELOPMENT_TEAM = EQHXZ8M8AV;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = CloudAnchorExample/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.3;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
OTHER_LDFLAGS = (
"$(inherited)",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -496,20 +496,14 @@ - (void)renderer:(id<SCNSceneRenderer>)renderer
if ([anchor isKindOfClass:[ARPlaneAnchor class]]) {
ARPlaneAnchor *planeAnchor = (ARPlaneAnchor *)anchor;

CGFloat width = planeAnchor.extent.x;
CGFloat height = planeAnchor.extent.z;
SCNPlane *plane = [SCNPlane planeWithWidth:width height:height];

plane.materials.firstObject.diffuse.contents =
[UIColor colorWithRed:0.0f green:0.0f blue:1.0f alpha:0.7f];

SCNNode *planeNode = [SCNNode nodeWithGeometry:plane];

CGFloat x = planeAnchor.center.x;
CGFloat y = planeAnchor.center.y;
CGFloat z = planeAnchor.center.z;
planeNode.position = SCNVector3Make(x, y, z);
planeNode.eulerAngles = SCNVector3Make(-M_PI / 2, 0, 0);
ARSCNPlaneGeometry *planeGeometry =
[ARSCNPlaneGeometry planeGeometryWithDevice:_sceneView.device];
[planeGeometry updateFromPlaneGeometry:planeAnchor.geometry];
planeGeometry.materials.firstObject.diffuse.contents = [UIColor colorWithRed:0.0f
green:0.0f
blue:1.0f
alpha:0.7f];
SCNNode *planeNode = [SCNNode nodeWithGeometry:planeGeometry];

[node addChildNode:planeNode];
}
Expand All @@ -522,17 +516,7 @@ - (void)renderer:(id<SCNSceneRenderer>)renderer
ARPlaneAnchor *planeAnchor = (ARPlaneAnchor *)anchor;

SCNNode *planeNode = node.childNodes.firstObject;
SCNPlane *plane = (SCNPlane *)planeNode.geometry;

CGFloat width = planeAnchor.extent.x;
CGFloat height = planeAnchor.extent.z;
plane.width = width;
plane.height = height;

CGFloat x = planeAnchor.center.x;
CGFloat y = planeAnchor.center.y;
CGFloat z = planeAnchor.center.z;
planeNode.position = SCNVector3Make(x, y, z);
[(ARSCNPlaneGeometry *)planeNode.geometry updateFromPlaneGeometry:planeAnchor.geometry];
}
}

Expand Down
2 changes: 1 addition & 1 deletion Examples/CloudAnchorExample/Podfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
target 'CloudAnchorExample'
use_frameworks!
platform :ios, '11.0'
pod 'ARCore/CloudAnchors', '~> 1.35.0'
pod 'ARCore/CloudAnchors', '~> 1.36.0'
pod 'Firebase/Database', '~> 8.0'
39 changes: 9 additions & 30 deletions Examples/GeospatialExample/GeospatialExample/ViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -875,22 +875,14 @@ - (void)renderer:(id<SCNSceneRenderer>)renderer
if ([anchor isKindOfClass:[ARPlaneAnchor class]]) {
ARPlaneAnchor *planeAnchor = (ARPlaneAnchor *)anchor;

CGFloat width = planeAnchor.extent.x;
CGFloat height = planeAnchor.extent.z;
SCNPlane *plane = [SCNPlane planeWithWidth:width height:height];

plane.materials.firstObject.diffuse.contents = [UIColor colorWithRed:0.0f
green:0.0f
blue:1.0f
alpha:0.7f];

SCNNode *planeNode = [SCNNode nodeWithGeometry:plane];

CGFloat x = planeAnchor.center.x;
CGFloat y = planeAnchor.center.y;
CGFloat z = planeAnchor.center.z;
planeNode.position = SCNVector3Make(x, y, z);
planeNode.eulerAngles = SCNVector3Make(-M_PI / 2, 0, 0);
ARSCNPlaneGeometry *planeGeometry =
[ARSCNPlaneGeometry planeGeometryWithDevice:self.scnView.device];
[planeGeometry updateFromPlaneGeometry:planeAnchor.geometry];
planeGeometry.materials.firstObject.diffuse.contents = [UIColor colorWithRed:0.0f
green:0.0f
blue:1.0f
alpha:0.7f];
SCNNode *planeNode = [SCNNode nodeWithGeometry:planeGeometry];

[node addChildNode:planeNode];
}
Expand All @@ -903,20 +895,7 @@ - (void)renderer:(id<SCNSceneRenderer>)renderer
ARPlaneAnchor *planeAnchor = (ARPlaneAnchor *)anchor;

SCNNode *planeNode = node.childNodes.firstObject;
NSAssert([planeNode.geometry isKindOfClass:[SCNPlane class]],
@"planeNode's child is not an SCNPlane--did something go wrong in "
@"renderer:didAddNode:forAnchor:?");
SCNPlane *plane = (SCNPlane *)planeNode.geometry;

CGFloat width = planeAnchor.extent.x;
CGFloat height = planeAnchor.extent.z;
plane.width = width;
plane.height = height;

CGFloat x = planeAnchor.center.x;
CGFloat y = planeAnchor.center.y;
CGFloat z = planeAnchor.center.z;
planeNode.position = SCNVector3Make(x, y, z);
[(ARSCNPlaneGeometry *)planeNode.geometry updateFromPlaneGeometry:planeAnchor.geometry];
}
}

Expand Down
2 changes: 1 addition & 1 deletion Examples/GeospatialExample/Podfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
target 'GeospatialExample'
use_frameworks!
platform :ios, '11.0'
pod 'ARCore/Geospatial', '~> 1.35.0'
pod 'ARCore/Geospatial', '~> 1.36.0'
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@
DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO;
INFOPLIST_FILE = PersistentCloudAnchorExample/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.3;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand All @@ -370,7 +370,7 @@
DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO;
INFOPLIST_FILE = PersistentCloudAnchorExample/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.3;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -277,22 +277,14 @@ - (void)renderer:(id<SCNSceneRenderer>)renderer
if ([anchor isKindOfClass:[ARPlaneAnchor class]]) {
ARPlaneAnchor *planeAnchor = (ARPlaneAnchor *)anchor;

CGFloat width = planeAnchor.extent.x;
CGFloat height = planeAnchor.extent.z;
SCNPlane *plane = [SCNPlane planeWithWidth:width height:height];

plane.materials.firstObject.diffuse.contents = [UIColor colorWithRed:kPlaneColor[0]
green:kPlaneColor[1]
blue:kPlaneColor[2]
alpha:kPlaneColor[3]];

SCNNode *planeNode = [SCNNode nodeWithGeometry:plane];

CGFloat x = planeAnchor.center.x;
CGFloat y = planeAnchor.center.y;
CGFloat z = planeAnchor.center.z;
planeNode.position = SCNVector3Make(x, y, z);
planeNode.eulerAngles = SCNVector3Make(-M_PI / 2, 0, 0);
ARSCNPlaneGeometry *planeGeometry =
[ARSCNPlaneGeometry planeGeometryWithDevice:_sceneView.device];
[planeGeometry updateFromPlaneGeometry:planeAnchor.geometry];
planeGeometry.materials.firstObject.diffuse.contents = [UIColor colorWithRed:kPlaneColor[0]
green:kPlaneColor[1]
blue:kPlaneColor[2]
alpha:kPlaneColor[3]];
SCNNode *planeNode = [SCNNode nodeWithGeometry:planeGeometry];

[node addChildNode:planeNode];
}
Expand All @@ -310,17 +302,7 @@ - (void)renderer:(id<SCNSceneRenderer>)renderer
ARPlaneAnchor *planeAnchor = (ARPlaneAnchor *)anchor;

SCNNode *planeNode = node.childNodes.firstObject;
SCNPlane *plane = (SCNPlane *)planeNode.geometry;

CGFloat width = planeAnchor.extent.x;
CGFloat height = planeAnchor.extent.z;
plane.width = width;
plane.height = height;

CGFloat x = planeAnchor.center.x;
CGFloat y = planeAnchor.center.y;
CGFloat z = planeAnchor.center.z;
planeNode.position = SCNVector3Make(x, y, z);
[(ARSCNPlaneGeometry *)planeNode.geometry updateFromPlaneGeometry:planeAnchor.geometry];
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion Examples/PersistentCloudAnchorExample/Podfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
target 'PersistentCloudAnchorExample'
use_frameworks!
platform :ios, '11.0'
pod 'ARCore/CloudAnchors', '~> 1.35.0'
pod 'ARCore/CloudAnchors', '~> 1.36.0'
Binary file added GARSession/Resources/ARCoreResources/Resources
Binary file not shown.
18 changes: 18 additions & 0 deletions GARSession/Sources/dummy.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
* Copyright 2022 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.
*/

// Swift Package Manager requires that every target has a header file.
#pragma mark To the linter: this is an Objective-C header file.
Loading

0 comments on commit 03978f8

Please sign in to comment.