Commit graph

88 commits

Author SHA1 Message Date
the_fiddler
d7a85401da Deprecated Mult in favor of Multiply.
Modified operator * to use Multiply internally (reduces code duplication).
2009-11-03 12:11:51 +00:00
the_fiddler
9ce7437cbd Fixed Vector3.Transform signature to return a Vector3, not a Vector4. It was previously impossible to transform a Vector3 structure without intermediate conversions to Vector4. 2009-11-03 11:45:20 +00:00
the_fiddler
3d6d476d16 Modified Transform(ref Vector4, ref Matrix4, out Vector4) overload to work correctly when the ref and out parameters point to the same Vector4.
Modified Transform(Vector4, Matrix4): Vector4 to call the reference overload internally. Faster and reduces code duplication.
2009-11-03 11:41:36 +00:00
the_fiddler
1a9fc63a57 * Matrix4d.cs: M44 should be 1.0 to conform with GL.Ortho(). Fixes issue [#1307]: "GL.Ortho behaves other than combination of OpenTK.Matrix4d.CreateOrthographic and GL.MultMatrix". 2009-11-02 13:25:41 +00:00
the_fiddler
2f522e790b Improved interoperation with System.Drawing with new addition, subtraction and implicit conversion operators, as well as additional method overloads.
Only expose fields through public properties to allow for parameter validation.
2009-11-02 07:20:59 +00:00
the_fiddler
2340e87eda Added experimental OpenTK.Point/Size/Rectangle alternatives to System.Drawing, to make OpenTK usable without referencing System.Drawing (disabled by default, #define EXPERIMENTAL to test). Modified a number of using directives and namespace qualifiers to accommodate this change. 2009-11-01 12:44:38 +00:00
the_fiddler
a98c1f9ae2 Corrected documentation on the M42 property. Fixes issue [#1227]: "Matrix4.M42 documentation". 2009-10-14 18:30:12 +00:00
the_fiddler
72cb52941e Added missing CreatePerspectiveFieldOfView and CreatePerspectiveOffCenter methods (fixes issue [#1226]: "Matrix4d.CreatePerspectiveFieldOfView").
Replaced several instances of float values by double equivalents.
2009-10-13 21:33:59 +00:00
the_fiddler
99aab2fa2e Replaced calls to obsolete methods.
Fixed parameters in double versions of BaryCentric() (should be double instead of float).
2009-10-06 09:51:13 +00:00
the_fiddler
f2c91d4a7c Obsoleted Scale() instance method (reason: redundant. Mult()/Multiply() instance/static methods can be used to achieve the same effect). 2009-10-06 09:45:09 +00:00
the_fiddler
201b06931e Added vector overloads to Multiply and Divide methods.
Renamed Sub to Subtract, Mult to Multiply and Div to Divide (reason: conform with the class library design guidelines).
Obsoleted instance Add, Sub, Mult and Div methods in favor of static ones (reason: reduce API bloat, they are completely redudant).
Improved documentation for new methods.
2009-10-06 09:42:21 +00:00
the_fiddler
21bde35e61 Fixed formatting. 2009-10-06 08:57:48 +00:00
the_fiddler
fb95f10458 Implemented Quaternion scaling by scalars. Fixes issue [#1131]: "[Math] add Quaternion scaling (easy)". 2009-09-05 16:17:47 +00:00
the_fiddler
376a1fca65 Fixed XML documentation warnings. 2009-09-04 23:11:20 +00:00
the_fiddler
685b646efa Fixed a large number of documentation warnings. 2009-09-04 21:44:39 +00:00
the_fiddler
48008d1e6a Removed this property to maintain parity with the Matrix4 structure. 2009-09-04 21:37:53 +00:00
the_fiddler
6b03992812 Added missing XML documentation and fixed invalid XML doc references.
Removed deprecated methods from IGraphicsContext.
2009-09-04 21:25:29 +00:00
the_fiddler
6c5d3a90c3 Added missing Matrix4./Matrix4d.CreateRotation[XYZ] methods.
Added missing Matrix4d.CreateFromAxisAngle method.
Fixed Matrix4d constructor to take double parameters instead of float.
2009-09-04 13:02:23 +00:00
the_fiddler
1beceffa2a Added mathematical constants used by XNA (Pi, E, logarithms).
Removed unused code.
2009-08-14 14:15:30 +00:00
the_fiddler
87b2fe1a9d Obsoleted OpenTK.Functions in favor of OpenTK.MathHelper (reason: XNA compatibility).
Added Matrix4.LookAt overload that does not use Vector3 parameters.
2009-08-14 12:37:18 +00:00
the_fiddler
16a05a1cf9 Merged fix for bug [#1060]: "Wrong XML Comment on the W property in Vector4[d]". 2009-08-01 14:24:47 +00:00
the_fiddler
787d56f7cd Added NextPowerOfTwo float and double overloads. 2009-07-19 20:58:35 +00:00
the_fiddler
55de62cd02 Replaced tabs with spaces. 2009-07-17 08:27:25 +00:00
the_fiddler
170568c57d Fixed XML docs and remove unnecessary CLSCompliance attributes. 2009-06-28 10:52:58 +00:00
the_fiddler
1bdc6b6634 Added missing XML docs. 2009-06-28 10:49:10 +00:00
the_fiddler
c43407e77e Added several missing XML comments. 2009-06-28 10:33:32 +00:00
the_fiddler
a28616db87 Added CreateFromAxisAngle method. 2009-06-26 21:45:26 +00:00
the_fiddler
79686aa4dd Obsoleted Frustum and Perspective methods in favor of CreatePerspectiveOffCenter and CreatePerspectiveFieldOfView, respectively. 2009-06-25 22:47:01 +00:00
the_fiddler
a7363b54e6 Removed OpenTK.Math namespace. Math functions now go directly into the OpenTK namespace. 2009-06-25 11:42:05 +00:00
the_fiddler
74c45c479e Optimized Matrix4/Matrix4d.Mult by unrolling and inlining the multiplications. 2009-06-19 13:44:33 +00:00
the_fiddler
8604913954 Optimized Matrix4.Mult by unrolling the multiplications. 2009-06-19 13:41:32 +00:00
the_fiddler
70f735d2a6 Fixed Matrix4.CreateOrthographicOffCenter (M44 should be 1). 2009-06-08 22:46:18 +00:00
the_fiddler
bf89289ad9 Added static readonly Vector[234]d?.One properties. 2009-06-04 16:51:45 +00:00
the_fiddler
402230b61c Fixed a large amount of documentation warnings.
Marked several APIs as obsolete.
2009-06-04 11:22:20 +00:00
the_fiddler
584fa7c761 Added M11-M44 properties to Matrix4 and Matrix4d.
Implemented CreateOrthographic and CreateOrthographicOffCenter static methods. Fixes issue [#676]: "Add Matrix4.Ortho method" (http://www.opentk.com/node/676).
Implemented CreateTranslation methods. Obsoleted Translation() in favor of the new methods.
2009-05-29 16:44:12 +00:00
the_fiddler
dd84fddf19 Added new matrix constructors that take 16 distinct matrix elements. 2009-04-12 16:34:35 +00:00
the_fiddler
9265747541 Fixed all known build warnings, apart from missing xml comments. 2009-03-25 21:53:12 +00:00
the_fiddler
39710404ee Fixed two instances where the obsolete XYZ attribute was being used. 2009-02-22 12:09:23 +00:00
the_fiddler
144d5dd450 Hopefully fixed all remaining encoding problems. 2009-02-22 11:26:17 +00:00
the_fiddler
a22019d890 Normalize line endings and set the mime-type=text/plain and eol-style=native properties on all files. 2009-02-22 10:43:35 +00:00
the_fiddler
98edd251ba Fixed infinite recursion in Quaternion constructor (http://www.opentk.com/node/663). 2009-02-15 16:22:49 +00:00
the_fiddler
b40ccdc726 Marked the swizzle properties with the XmlIgnoreAttribute. 2009-02-13 20:40:57 +00:00
the_fiddler
a594d261ff Changed the public fields to properties.
Renamed XYZ property to Xyz, in accordance to the guidelines for class libraries.
Added the SerializableAttribute.
2009-02-13 20:40:19 +00:00
the_fiddler
527fb19364 Implemented IEquatable interface.
Fixed ToAxisAngle implementation at 0-degree angles.
Added ToAxisAngle overload that returns a Vector4 struct.
2009-02-13 19:53:46 +00:00
the_fiddler
92d79bb47b Added Xy and Xyz swizzle operators. 2009-02-13 19:51:35 +00:00
chrisbrandtner
493e52e05b Added explicit operators for converting single-precision Vector234 <-> double-precision Vector234d. 2009-02-13 13:26:39 +00:00
the_fiddler
4e82e450be Added (Vector3, float) and (Vector3d, double) constructors. 2009-01-29 00:41:09 +00:00
chrisbrandtner
0ab939a744 Added ref/out overloads to all static Vector*.Transform* methods. 2009-01-25 15:06:42 +00:00
chrisbrandtner
5a3cd34953 Removed cast to float from Vector3d.CalculateAngle (unnecessary precision loss as double is returned).
Overloaded static Vector3 and Vector3d CalculateAngle methods.
2009-01-24 16:15:04 +00:00
chrisbrandtner
46f25f27a4 Overloaded instance methods Add, Sub, Scale to pass-vector-by-value and set CLS compliance flags.
Overloaded static method BaryCentric to pass-by-reference.
2009-01-24 14:54:52 +00:00