summaryrefslogtreecommitdiff
path: root/core/math/quat.h
AgeCommit message (Collapse)Author
2020-09-04Ensure assignment operators return by reference to avoid unnecessary copies.Marcel Admiraal
2020-05-14Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocksRémi Verschelde
Which means that reduz' beloved style which we all became used to will now be changed automatically to remove the first empty line. This makes us lean closer to 1TBS (the one true brace style) instead of hybridating it with some Allman-inspired spacing. There's still the case of braces around single-statement blocks that needs to be addressed (but clang-format can't help with that, but clang-tidy may if we agree about it). Part of #33027.
2020-05-14Port member initialization from constructor to declaration (C++11)Rémi Verschelde
Using `clang-tidy`'s `modernize-use-default-member-init` check and manual review of the changes, and some extra manual changes that `clang-tidy` failed to do. Also went manually through all of `core` to find occurrences that `clang-tidy` couldn't handle, especially all initializations done in a constructor without using initializer lists.
2020-03-25Style: Harmonize header guards to style guide [Core]Rémi Verschelde
2020-01-24Add explanations for errors related to Vector/Quat normalizationHugo Locurcio
2020-01-01Update copyright statements to 2020Rémi Verschelde
Happy new year to the wonderful Godot community! We're starting a new decade with a well-established, non-profit, free and open source game engine, and tons of further improvements in the pipeline from hundreds of contributors. Godot will keep getting better, and we're looking forward to all the games that the community will keep developing and releasing with it.
2019-10-14Make is_equal_approx separate for structuresAaron Franke
This commit adds exposed behavior for C#
2019-08-12Remove redundant author doc commentsIAmActuallyCthulhu
2019-03-02Fix new GCC 9 warnings: -Wdeprecated-copy.marxin
2019-01-01Update copyright statements to 2019Rémi Verschelde
Happy new year to the wonderful Godot community!
2018-12-11Moved member variables to initializer listWilson E. Alvarez
2018-10-06Remove redundant "== false" codeAaron Franke
Some of this code has been re-organized. f
2018-09-12Make core/ includes absolute, remove subfolders from include pathRémi Verschelde
This allows more consistency in the manner we include core headers, where previously there would be a mix of absolute, relative and include path-dependent includes.
2018-05-27Fixed Basis -> Quat conversions, added a few safety checks.tagcup
Fixes #19027.
2018-05-12Add SLERP to Vector{2,3}, optimize Quat's Vector3 rotation.tagcup
Also even out Basis and Quat APIs a little.
2018-01-01Update copyright statements to 2018Rémi Verschelde
Happy new year to the wonderful Godot community!
2017-08-27Use HTTPS URL for Godot's website in the headersRémi Verschelde
2017-08-09Use YXZ convention for Euler angles.Ferenc Arn
As discussed in issues #1479 and #9782, choosing the up axis (which is Y in Godot) as the axis of the last (or first) rotation is helpful in practical use cases. This also aligns Godot's convention with Unity, helping with a smoother transition for people who are used to working with Unity (issue #9905). Internally, both XYZ and YXZ functions are kept, for potential future applications.
2017-04-24Merge pull request #8277 from tagcup/math_checksRémi Verschelde
Added various functions basic math classes. Also enabled math checks …
2017-04-08Add "Godot Engine contributors" copyright lineRémi Verschelde
2017-04-06Added various functions basic math classes. Also enabled math checks only ↵Ferenc Arn
for debug builds. Added set_scale, set_rotation_euler, set_rotation_axis_angle. Addresses #2565 directly. Added an euler angle constructor for Basis in GDScript and also exposed is_normalized for vectors and quaternions. Various other changes mostly cosmetic in nature.
2017-03-05A Whole New World (clang-format edition)Rémi Verschelde
I can show you the code Pretty, with proper whitespace Tell me, coder, now when did You last write readable code? I can open your eyes Make you see your bad indent Force you to respect the style The core devs agreed upon A whole new world A new fantastic code format A de facto standard With some sugar Enforced with clang-format A whole new world A dazzling style we all dreamed of And when we read it through It's crystal clear That now we're in a whole new world of code
2017-02-14Revert "Make nan==nan true for GDScript"Juan Linietsky
2017-02-14Make nan==nan true for GDScriptHein-Pieter van Braam
After discussing this with Reduz this seemed like the best way to fix #7354. This will make composite values that contain NaN in the same places as well as the same other values compare as the same. Additionally non-composite values now also compare equal if they are both NaN. This breaks IEEE specifications but this is probably what most users expect. There is a GDScript function check for NaN if the user needs this information. This fixes #7354 and probably also fixes #6947
2017-01-16Overloaded basic math funcs (double and float variants). Use real_t rather ↵Ferenc Arn
than float or double in generic functions (core/math) whenever possible. Also inlined some more math functions.
2017-01-10Merge pull request #7426 from m4nu3lf/bugfix/physicsJuan Linietsky
Fixed inertia tensor computation and center of mass
2017-01-09Fixed inertia tensor computation and center of massm4nu3lf
2017-01-03Use right handed coordinate system for rotation matrices and quaternions. ↵Ferenc Arn
Also fixes Euler angles (XYZ convention, which is used as default by Blender). Furthermore, functions which expect a rotation matrix will now give an error simply, rather than trying to orthonormalize such matrices. The documentation for such functions has be updated accordingly. This commit breaks code using 3D rotations, and is a part of the breaking changes in 2.1 -> 3.0 transition. The code affected within Godot code base is fixed in this commit.
2017-01-01Welcome in 2017, dear changelog reader!Rémi Verschelde
That year should bring the long-awaited OpenGL ES 3.0 compatible renderer with state-of-the-art rendering techniques tuned to work as low as middle end handheld devices - without compromising with the possibilities given for higher end desktop games of course. Great times ahead for the Godot community and the gamers that will play our games!
2016-03-09remove trailing whitespaceHubert Jarosz
2016-01-01Update copyright to 2016 in headersGeorge Marques
2015-11-11Implement Quat multiply operator, and xform methodFranklin Sobrinho
2015-04-18Updated copyright year in all headersJuan Linietsky
2014-09-153D Physics Rework, Other StuffJuan Linietsky
-=-=-=-=-=-=-=-=-=-=-=-=-=- 3D Physics: -Fixed "Bounce" parameter in 3D -Fixed bug affecting Area (sometims it would not detect properly) -Vehicle Body has seen heavy work -Added Query API for doing space queries in 3D. Needs some docs though. -Added JOINTS! Adapted Bullet Joints: and created easy gizmos for setting them up: -PinJoint -HingeJoint (with motor) -SliderJoint -ConeTwistJoint -Generic6DOFJoint -Added OBJECT PICKING! based on the new query API. Any physics object now (Area or Body) has the following signals and virtual functions: -input_event (mouse or multitouch input over the body) -mouse_enter (mouse entered the body area) -mouse_exit (mouse exited body area) For Area it needs to be activated manually, as it isn't by default (ray goes thru). Other: -Begun working on Windows 8 (RT) port. Compiles but does not work yet. -Added TheoraPlayer library for improved to-texture and portable video support. -Fixed a few bugs in the renderer, collada importer, collada exporter, etc.
2014-02-09GODOT IS OPEN SOURCEJuan Linietsky