Граф коммитов

277 Коммитов

Автор SHA1 Сообщение Дата
Dean Ellis 69e2f36725 Removed NO_SYSDRAWING in favour of just MINUMAL
Reverted changes to GLControl.cs
Updated sln to not build OpenTK.GLControl in MINIMAL mode
2015-08-12 11:56:12 +01:00
Dean Ellis c7e86d467b Fixed MINIMAL and NO_SYSDRAWING compilation 2015-08-12 11:53:20 +01:00
Fraser Waters 9ad18583fe Remove NO_SYSDRAWING, replace with MINIMAL 2015-08-10 20:26:06 +01:00
thefiddler 788b039e32 Merge pull request #220 from Frassle/project
[Math] Vector3 Project and Unproject
2015-05-11 12:07:24 +02:00
Fraser Waters 75961e6895 [Math] Fix NaN issue in CalculateAngle
Clamp dot product between -1 and 1 so acos always has a valid input.
2015-02-21 10:55:39 +00:00
Fraser Waters 79fc848015 [Math] Vector3 Project and Unproject
Add methods to Vector3 to project to and from screen space.
2015-02-14 19:05:59 +00:00
Fraser Waters 1002d4e33a Add XML documentation to matrix Add methods.
Fixes warnings [#61] about missing documentation on public members.
2014-11-03 01:33:27 +01:00
Lasse Numminen 6c53ab6623 Added support for Euler angles in Quaternion and Quaterniond by adding proper vec3 and pitch-yaw-roll constructors, and also added similar static helper functions. I unit tested them locally and the results match to the calculator found from the bottom of this web page: http://www.euclideanspace.com/maths/geometry/rotations/conversions/eulerToQuaternion/index.htm 2014-10-12 21:37:26 +03:00
Robert Rouhani 7a4dfcf40d Changed Matrix4[d].CreateFromRotationMatrix to a new constructor. 2014-09-11 12:33:34 -04:00
Robert Rouhani ee56a3506d Added Matrix3[d].Add and Matrix4[d].CreateFromRotationMatrix 2014-09-09 13:21:11 -04:00
thefiddler 00b531fdef Fixed compilation warnings on Mono 3.4.0 2014-07-21 17:46:39 +02:00
thefiddler aa4e8ef9aa Merge pull request #128 from Frassle/half-fix
Fix a bug in single->half conversion.
2014-06-02 13:03:30 +02:00
Fraser Waters 5481aa7097 Fix a bug in single->half conversion.
The original C code had if(m & 0x00800000) which is true if the
expresssion does not evaluate to zero. This was inncorretly translated
to the C# code if((m & 0x00800000) == 1) which only evaluates true if
the expression evalaute to 1, which it never does. The correct test is
to test not equal to zero (!= 0).
2014-06-02 11:16:43 +01:00
thefiddler d292d44b90 [Math] Replaced tab characters with spaces 2014-03-31 18:20:08 +02:00
Phyyl 617131066a Added multiplication operator to all vectors 2014-03-17 16:59:09 -04:00
Jonas Boesch e2ecba7274 Updated Matrix4d.FromAxisAngle to mirror the Matrix4 version. 2014-02-04 14:03:59 +01:00
thefiddler 6856fe5e71 Merged remote-tracking branch 'l3m/matrix4d-quat-fix' into develop
Updated the Matrix4d CreateFromQuaternion methods to actually create
Matrix4d. They now mirror the Matrix4 CreateFromQuaternion methods,
just using doubles and the -d classes.

Previously, Matrix4d.CreateFromQuaterion actually created a Matrix4
from a single-precision Quaterion.
2014-02-03 11:11:36 +01:00
Stefanos A. 88c57db5b6 [Math] Added MathHelper.Clamp 2014-01-06 01:52:08 +01:00
Stefanos A f579d0fd81 Eliminated cls-compliance warnings in the math library 2013-12-15 22:02:08 +01:00
thefiddler 8dcb8601a2 Normalized line endings
Hopefully this is the first and last time we have to do this.
2013-10-11 01:58:54 +02:00
thefiddler c7e04c6097 Merge remote-tracking branch 'andy/master' 2013-09-26 01:28:58 +02:00
Neil White fc1a8e022b Fix for setting Matrix/Vector values by Index
Many Matrix*/Vector* implementations were throwing
IndexOutOfBoundsException when you tried to set their values via their
indexer due to a missing else statement.
2013-09-24 15:46:34 +01:00
Robert Rouhani 5c66266933 Added Quaterniond version of FromMatrix 2013-07-18 13:14:30 -07:00
Robert Rouhani d479e3768b Added Quaternion.FromMatrix
Added a Diagonal and Trace property to all matrices
Added missing doc comments in the matrix classes to reduce the number of compiler warnings
2013-07-18 12:58:43 -07:00
Tom Edwards b38c81a458 Added Matrix clearing methods
- Added ClearTranslation(), ClearScale(), ClearRotation() and
ClearProjection()
- Added ExtractProjection() to Matrix4
- Fixed ExtractScale() giving incorrect results if a Matrix4 contained
projection data
- Added setters to Matrix4d's Column properties
2013-04-11 22:23:43 +01:00
Tom Edwards ca7e2c9c4b Copied Matrix4 changes to other classes
* Removed  pointless LengthSquared check from ExtractRotation()
* Improved inline documentation
2013-03-20 12:44:12 +00:00
Tom Edwards 498b659d58 Changes suggested by Rob Rouhani
* Turned the new Matrix4 properties into methods
* Matrix4.Normalize() now behaves correctly. ExtractRotation() does its
own row normalisation.
2013-03-19 15:28:31 +00:00
Tom Edwards b20b21d228 A couple more maths functions 2013-02-23 18:26:34 +00:00
Tom Edwards 11114ca4ea Extra maths features
- Added TranslationPart, ScalePart and RotationPart properties to
Matrix4
- Added Normalized() to Vector2/3/4, Quaternion and Matrix
2013-02-18 18:46:26 +00:00
Andy Korth ebb56e9d77 minor notes in comments of Matrix classes 2013-01-31 09:58:49 -06:00
Robert Rouhani 920d683954 Merge branch 'master' of github.com:andykorth/opentk
Conflicts:
	Source/OpenTK/Math/Matrix3.cs
	Source/OpenTK/Math/Matrix3d.cs
2013-01-26 16:29:23 -05:00
Robert Rouhani 2f9ccbc3af Converted tabs to spaces. 2013-01-26 16:08:34 -05:00
Robert Rouhani 2cbff7261a Copied float matrix classes to their double equivalents. 2013-01-26 14:06:16 -05:00
Robert Rouhani 94c7ad4f58 Implemented Matrix3(d) constructor that takes upper-left 3x3 of a Matrix4(d) as discussed in the following issue: https://github.com/andykorth/opentk/issues/4 2013-01-26 12:57:19 -05:00
Tamme Schichler f455176d2b Added missing XML comments for Matrix3d 2013-01-24 01:53:40 +01:00
Tamme Schichler 56430c7751 Added missing XML comments for Matrix3d
Fixed a few small issues in XML comments for Matrix4d

--HG--
extra : rebase_source : 18595a2fc57dcf7ff0f61d699e092be036d65157
2013-01-24 01:28:53 +01:00
Tamme Schichler f0a9afacce Fixed a few warnings with XML comments 2013-01-24 01:26:33 +01:00
Robert Rouhani 31ba0a36b9 Matrix4x2 implementation and documenting the other matrix classes. 2013-01-20 16:38:25 -05:00
Robert Rouhani df78210bc5 Matrix3x2 implementation and partial Matrix4x2 implementation. 2013-01-20 00:46:47 -08:00
Robert Rouhani f10af59c14 Matrix2x3 and Matrix2x4 implementatinos 2013-01-19 23:58:30 -08:00
Robert Rouhani 5438f941dc More work on matrices.
Fixed some static fields in the math classes that weren't also readonly.
2013-01-19 15:06:51 -08:00
Robert Rouhani 84a03e965c Matrix2 implementation
Started on Matrix2x3 implementation
Minor changes to Matrix3 and Matrix4
2013-01-19 00:29:22 -08:00
Robert Rouhani 8b8ded3232 Added very basic implementations of all possible matrix sizes up to 4x4
Moved the indexers out of the Properties region and into their own Indexers region
2013-01-18 19:21:24 -08:00
Robert Rouhani e5adf4d862 Added Matrix4x3 and Matrix3x4 implementations from our game. 2013-01-18 15:32:09 -08:00
Robert Rouhani afefc93fc6 Fixed bug in Matrix4.LookAt. 2013-01-18 15:13:36 -08:00
Robert Rouhani 3a9dfc62ad Fixed extra endregion directive that prevented compilation.
Fixed some warnings about csproj files.
2013-01-16 22:11:18 -08:00
Robert Rouhani 1712057977 Removed swizzles that had duplicate components. 2013-01-16 19:21:54 -08:00
Robert Rouhani c0fcbb6961 Fixed spacing of #endregion directives from merging 2013-01-16 18:53:59 -08:00
Robert Rouhani bf1401e115 Fixed the issues caused by merging in our changes as patches from the old repo. 2013-01-16 18:08:03 -08:00
Robert Rouhani 59c652aaf8 Added all swizzle permutations up to the vector's dimension. 2013-01-16 18:01:07 -08:00