-
-
Notifications
You must be signed in to change notification settings - Fork 957
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
System.Numerics conversions #1161
Conversation
Thanks, not sure if you're done but you might want to cover matrix as well. Will have to verify whether they are row major or column major though. |
Of course, there are other conversions i will add too that can be useful |
Can you also do the conversions the other way from Stride vectors into System.Numerics? |
Didn't think of it but will do, shouldn't be much of a trouble! |
Are you sure that stride and dotnet's matrix have the same memory layout ? (more info #291) |
OOH, i shouldn't have assumed it, will correct this ! |
Thanks ! |
As we've discussed on Discord, this PR breaks UWP, iOS and Android build. Someone will have to take a look at this and provide a fix before we can merge this back in |
PR Details
Adds implicit conversions between System.Numerics and Stride.Maths vectors
Some casts use
Unsafe.As
for better performance, haven't done any tests though.Motivation and Context
A lot nugets use System.Numerics, it would be nice to be able to cast implicitely between Sys Nums and Stride Maths
Types of changes
Checklist