We tried out the AR foundation sample project. To see how the system works.
We noticed an error in the code where he tries to parse the Device.systemVersion to a float in the ARKitimageTrackingSubsystem. This works great on iPads were the version exists of X.X like 12.3 or 11.1 but we have an iPad with version 12.1.3.
https://support.apple.com/en-us/HT209084
See the following line:
ARKitimageTrackingSubsystem : Line 124
This throws the following error:
FormatException
string is not a number in a valid format.
https://docs.microsoft.com/en-us/dotnet/api/system.single.parse?view=netframework-4.8#System_Single_Parse_System_String_System_Globalization_NumberStyles_
https://docs.microsoft.com/en-us/dotnet/api/system.formatexception?view=netframework-4.8
I second that - has something changed with the way Device.systemVersion is stored? I just manually assigned the value as float for a temp workaround.
Thanks for reporting. Looks like a bug; we'll get on it.
Can confirm the bug - had an iPhoneX running on 12.x and the samples application worked fine, updated to 12.3.1 this afternoon and suddenly the image and object tracking scenes do not work anymore (ground plane is fine).
Console output from Xcode:
FormatException: Input string was not in a correct format.
at System.Number.ParseSingle (System.String value, System.Globalization.NumberStyles options, System.Globalization.NumberFormatInfo numfmt) [0x00000] in <00000000000000000000000000000000>:0
at System.Single.Parse (System.String s, System.Globalization.NumberStyles style, System.Globalization.NumberFormatInfo info) [0x00000] in <00000000000000000000000000000000>:0
at System.Single.Parse (System.String s, System.IFormatProvider provider) [0x00000] in <00000000000000000000000000000000>:0
at UnityEngine.XR.ARKit.ARKitImageTrackingSubsystem.RegisterDescriptor () [0x00000] in <00000000000000000000000000000000>:0
Think the guy over at issue #131 are having the same problem.
@tdmowrer Is there any quick fix for this we can apply to the package ourselves? All of our iOS devices are on 12.x.x so we are unable to test out object-tracking based project.
Update your ARKit package to 2.1.0-preview.5 -- this contains the fix for this problem.
Thanks the issue seems to be resolved. 馃憤 Will close this issue.
Most helpful comment
Update your ARKit package to 2.1.0-preview.5 -- this contains the fix for this problem.