Campbell Barton
36b6fb5cd6
Cleanup: warnings building with Python 3.8
2019-10-16 14:44:36 +11:00
Campbell Barton
a6a0a09197
Cleanup: spelling
2019-09-30 17:07:05 +10:00
Jacques Lucke
4987f28ed2
Fix T70177: Crash when calling to_track_quat() without arguments
2019-09-23 09:46:31 +02:00
Campbell Barton
2790740813
Cleanup: spelling
2019-08-17 00:57:05 +10:00
Campbell Barton
2425401a59
Cleanup: spelling
2019-08-04 12:51:44 +10:00
Campbell Barton
b5b0804c5a
Cleanup: use _ex suffix instead of _ext
...
Convention is to use ex, not ext for extended
versions of a functions.
2019-08-01 18:39:21 +10:00
Campbell Barton
e927ce8acb
Cleanup: avoid line breaks from trailing comments
2019-07-10 14:41:19 +10:00
Campbell Barton
b2e3f23bec
Cleanup: remove redundant cast
2019-07-04 21:14:12 +10:00
Campbell Barton
778542fd8f
Cleanup: comments (long lines) in python
2019-04-29 20:01:10 +10:00
Campbell Barton
e12c08e8d1
ClangFormat: apply to source, most of intern
...
Apply clang format as proposed in T53211.
For details on usage and instructions for migrating branches
without conflicts, see:
https://wiki.blender.org/wiki/Tools/ClangFormat
2019-04-17 06:21:24 +02:00
Campbell Barton
25ec4b437f
Cleanup: style, use braces for the Python API
2019-03-30 07:14:28 +11:00
Campbell Barton
de13d0a80c
doxygen: add newline after \file
...
While \file doesn't need an argument, it can't have another doxy
command after it.
2019-02-18 08:22:12 +11:00
Campbell Barton
eef4077f18
Cleanup: remove redundant doxygen \file argument
...
Move \ingroup onto same line to be more compact and
make it clear the file is in the group.
2019-02-06 15:45:22 +11:00
Campbell Barton
744f633986
Cleanup: trailing commas
...
Needed for clan-format not to wrap onto one line.
2019-02-03 14:59:11 +11:00
Campbell Barton
65ec7ec524
Cleanup: remove redundant, invalid info from headers
...
BF-admins agree to remove header information that isn't useful,
to reduce noise.
- BEGIN/END license blocks
Developers should add non license comments as separate comment blocks.
No need for separator text.
- Contributors
This is often invalid, outdated or misleading
especially when splitting files.
It's more useful to git-blame to find out who has developed the code.
See P901 for script to perform these edits.
2019-02-02 01:36:28 +11:00
Campbell Barton
8a61ea7296
Cleanup: add trailing commas
...
Prevents clang-format merging into a single line.
2019-01-19 13:58:35 +11:00
Campbell Barton
f35e9f047a
Merge branch 'master' into blender2.8
2018-09-19 12:14:36 +10:00
Campbell Barton
bb3ec3ebaf
BLI_utildefines: rename pointer conversion macros
...
Terms get/set don't make much sense when casting values.
Name macros so the conversion is obvious,
use common prefix for easier completion.
- GET_INT_FROM_POINTER -> POINTER_AS_INT
- SET_INT_IN_POINTER -> POINTER_FROM_INT
- GET_UINT_FROM_POINTER -> POINTER_AS_UINT
- SET_UINT_IN_POINTER -> POINTER_FROM_UINT
2018-09-19 12:12:21 +10:00
Campbell Barton
0ddf3e110e
Cleanup: comment blocks
2018-09-02 18:51:31 +10:00
Campbell Barton
ae57383648
Cleanup: comment blocks
2018-09-02 18:28:27 +10:00
Campbell Barton
7eaf00bfb0
Cleanup: style
2018-08-22 10:10:12 +10:00
Andrew Hale
aa5a96430e
Python: Add support for @ infix operator matrix multiplication
...
This differential revision implements the code for T56276
Reviewers: campbellbarton
Reviewed By: campbellbarton
Differential Revision: https://developer.blender.org/D3587
2018-08-10 15:18:00 +02:00
Campbell Barton
fe8d8aa27e
Fix Vector.project crash w/ >4 length vectors
2018-07-27 17:41:20 +10:00
Campbell Barton
a69f985f40
PyAPI: move deep-copy args check to py_capi_utils
2018-06-26 09:31:57 +02:00
Campbell Barton
0c82a6fec8
Cleanup: unused define
2017-09-22 07:23:03 +10:00
Campbell Barton
30d8829780
Docs: mathutils docstrings
2017-09-09 11:02:26 +10:00
Campbell Barton
90eb93791f
Cleanup: mathutils vector comments
...
Use doxy markup & correct outdated info.
2017-09-09 10:50:40 +10:00
Campbell Barton
3930e46e37
Correct last commit
2017-09-09 10:15:16 +10:00
Campbell Barton
002cc6aef3
Cleanup: Simplify SWIZZLE macro
...
- Use indices instead of character args.
- Use numbered macros instead of variadic args.
Parsing using rtags used over 11gb of memory. While this should be
resolved upstream (report as #1053 ), the extra complexity didn't give
any real advantage.
2017-09-09 10:10:05 +10:00
Campbell Barton
46cf33bf01
PyAPI: Make use of PyC_LongAs... API
...
Avoids setting exceptions inline,
also use Matrix_ParseAny for bmesh.ops.
Some inline exceptions are kept because they show useful details.
2017-08-20 15:49:10 +10:00
Campbell Barton
81f4bc1665
Cleanup: reduce Vector_getseters size using macros
2016-07-31 20:43:52 +10:00
Campbell Barton
4e500101a7
Cleanup: quiet -Wcomma, cast to void where needed
2016-03-05 09:16:12 +11:00
Campbell Barton
de356415ae
Correct comments & some explanation from last commit
2016-01-21 11:03:37 +11:00
Campbell Barton
a1164ce271
Remove errors for unsupported math operations
2016-01-21 10:30:17 +11:00
Campbell Barton
e5e73ccc90
Math Lib: rename fill_*, to copy_*
...
matching convention for fixed length api, eg: copy_v3_fl
2015-05-05 17:08:29 +10:00
Campbell Barton
f682129d62
PyAPI: clarify fallback docstring
2015-03-06 19:02:57 +11:00
Campbell Barton
c439d14a9a
missed this second last commit
2015-02-15 14:11:05 +11:00
Campbell Barton
fa2f7c69ac
mathutils: Implement __hash__() functions
...
- all mathutils types
- only works on frozen data (so vectors can be used in sets/dict keys)
- uses same method as CPython, (matches hashing a tuple)
D1104 by @juicyfruit with own modifications
2015-02-15 14:02:08 +11:00
Campbell Barton
a9d979c8ef
mathutils: add freeze() method, is_frozen attr
...
This allows you to make any mathutils object immutable.
2015-02-15 14:01:59 +11:00
Campbell Barton
ce85aef0d9
mathutils: remove redundant read callback
2015-02-15 13:46:47 +11:00
Campbell Barton
4feb77cf03
mathutils: avoid extra alloc for Vector.lerp
2015-02-15 13:46:47 +11:00
Sybren A. Stüvel
baa8b63111
Documentation: updated mathutils documentation
...
Added descriptions of the constructors, and improved the module-level
documentation.
2015-02-01 18:16:12 +01:00
Campbell Barton
79ba5e52dd
Revert "mathutils: let Vector.normalize() return the original length."
...
Please discuss changes to core mathutils functions first.
Changes like this should be considered and applied to all areas of the API (or not at all).
Missed quaternion, matrix normalize for eg.
2015-01-30 02:12:07 +11:00
Sybren A. Stüvel
6912fe132f
mathutils: let Vector.normalize() return the original length.
...
The length has to be calculated for normalization anyway, and it is already
returned by normalize_vn(vec, size).
2015-01-29 15:29:01 +01:00
Campbell Barton
8106a6b75d
mathutils: refactor instantiation
...
remove 'type' argument, very few mathutils objects are wrapped,
add new function for creating wrapped objects.
also fixes unlikely memory leak if the data-array can't be allocated.
2015-01-04 17:43:57 +11:00
Tamito Kajiyama
8d3bfef538
Extended mathutils.Vector.orthogonal() to accept a 2D vector.
...
Reviewer: Campbell Barton
Differential revision: https://developer.blender.org/D668
2014-07-23 23:10:03 +09:00
Campbell Barton
dc847607b6
Change Vector.slerp to accept nonunit vectors
2014-04-18 20:49:39 +10:00
Campbell Barton
55f83e36cc
Py API: Vector.slerp(). also added interp_v3_v3v3_slerp(_safe) functions
2014-03-31 13:28:37 +11:00
Campbell Barton
6aa75d3b2c
Fix for error in normalize_vn_vn(), add len_squared_vn
2014-03-31 11:19:32 +11:00
Campbell Barton
a47137a2db
Python API: add Vector.orthogonal() method
2014-03-18 00:39:46 +11:00