Bug 59380 - Incorrect GKPath.FromPoints (Vector3[], float, cyclical) implementation
Summary: Incorrect GKPath.FromPoints (Vector3[], float, cyclical) implementation
Status: RESOLVED FIXED
Alias: None
Product: iOS
Classification: Xamarin
Component: Xamarin.iOS.dll ()
Version: master
Hardware: PC Mac OS
: --- normal
Target Milestone: Future Cycle (TBD)
Assignee: Alex Soto [MSFT]
URL:
Depends on:
Blocks:
 
Reported: 2017-09-11 08:33 UTC by Rolf Bjarne Kvinge [MSFT]
Modified: 2017-09-11 19:30 UTC (History)
1 user (show)

Tags:
Is this bug a regression?: No
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Rolf Bjarne Kvinge [MSFT] 2017-09-11 08:33:38 UTC
See: https://github.com/xamarin/xamarin-macios/blob/96067ef1c1ff84280f5aac7011fa3c8d60a0b7ad/src/GameplayKit/GKPath.cs#L54

The native signature is:

> - (instancetype)initWithFloat3Points:(vector_float3 *)points count:(size_t)count radius:(float)radius cyclical:(BOOL)cyclical NS_AVAILABLE(10_12, 10_0)

that's an array of vector_float3.

vector_float3 is 16 bytes, which means the binding is incorrect, because Vector3 is 12 bytes, and our code does not that difference into account.
Comment 1 Rolf Bjarne Kvinge [MSFT] 2017-09-11 08:36:36 UTC
@Alex, git blame blames you 🙂
Comment 2 Alex Soto [MSFT] 2017-09-11 15:47:52 UTC
I'll take the blame :)

PR: https://github.com/xamarin/xamarin-macios/pull/2644
Comment 3 Alex Soto [MSFT] 2017-09-11 19:30:03 UTC
Fixed in xamarin-macios/xcode9 @ fdf67c6645702ff04f2dccd692c9caf1fdd726b8