Age | Commit message (Collapse) | Author |
|
no functionality change.
|
|
python functions.
- use NULL rather then 0 where possible (makes code & function calls more readable IMHO).
- set static variables and functions (exposed some unused vars/funcs).
- use func(void) rather then func() for definitions.
|
|
matrix__apply_to_copy() and similar.
+ other minor internal changes.
|
|
each accept Euler/Quaternion/Matrix types.
eg:
Euler.rotate(Quaternion(axis, angle))
Vector.rotate(Euler((pi/2, 0, 0)))
matrix.resize_4x4() and euler.make_compatible() were still returning an instance of themselves, now return None.
|
|
return new values.
http://wiki.blender.org/index.php/Dev:2.5/Source/Python/Mathutils
This completes the changes proposed.
This will break scripts (fixing coming up next), for full list of changes see mathutils.c comments.
|
|
- fix for returning empty slices (was returning list rather then tuple).
- report invalid type when mathutils_array_parse_fast() fails.
|
|
http://wiki.blender.org/index.php/Dev:2.5/Source/Python/Mathutils#Coerce_Method_Arguments
|
|
- multiplying a 2D vector by a 3x3 or 4x4 matrix would use un-initialized memory, now throw an exception.
- use more variable length array BLI_math functions.
|
|
|
|
- rna array parsing was using PySequence_Size() in a loop, this can be slow to run so only call once.
- assigning a single value to a multi-dimensional array was missing type check.
- improve exception messages for rna array type errors.
- simplify vector slice assignment by using mathutils_array_parse(...)
|
|
|
|
python for backwards compatibility.
|
|
cases, raise more informative exceptions.
|
|
- move GS() define into DNA_ID.h
- add BLI_utildefines as an automatic include with makesrna generated files.
|
|
MAKE_ID, FILE_MAXDIR, moved the generic defines to BLI_utildefines.h.
no functional changes.
|
|
The main advantage with this is that its close to twice as fast to do 'vertex.co[:]' then 'tuple(vertex.co)', this is common for writing a vertex array.
the correct python behavior in this case is to return a copy of the original type, however euler and quats don't support different sizes so we cant do so easily.
|
|
'const char's,.
Only one functional change where Transform orientations passed "" to BIF_createTransformOrientation() which could then have the value written into.
|
|
|
|
|
|
- pep8 script was giving an error on non utf8 scons source files.
- use PyList_SET_ITEM macro when list type is ensured.
- all mathutils types use subtypes to create new types when available.
- use defines MAT3_UNITY, MAT4_UNITY to initialize unit matrices.
|
|
the same subclass as the vectors they were derived from.
|
|
|
|
|
|
- python/mathutils api matrix.lerp(other, factor)
- new function mat3_to_rot_size(), like mat4_to_loc_rot_size but with no location.
|
|
past end of array
was setting the vector array out of bounds with vec*=matrix, where the vector wasnt size 4.
|
|
|
|
- Reverse vector * matrix multiplication order. now this matches how numpy works.
- Disallow 'matrix * vec' and 'quat * vec', now it raises an error.
- Add missing in-place multiply 'vec *= quat'
Many scripts will need to be updated for this but at least it will error rather then failing silently.
|
|
|
|
warnings.
applied to python api and exotic.c, removed some args being passed down which were not needed.
keyword args for new mathutils types were being ignored when they should raise an error.
|
|
vec.rotate(axis, angle)
equivalent to...
vec[:] = vec * mathutils.Quaternion(axis, angle)
|
|
works like scons where using a subset of the targets name is enough.
make_quicky.py py
...expands into
make bf_python bf_python_ext blender/fast
arguments like -j4 are passed on.
|
|
- they now share the same code so it wont happen again.
- added id_data to properties so we can do...
matrix = C.object.matrix_world
obj = matrix.owner.id_data # get the original object back.
|
|
Rough summary of fixes/changes:
- Blender Py API: GameLogic -> bge.logic
- Blender Py API: Implemented missing KX_PYATTRIBUTE_TODOs and -DUMMYs.
- Fix for [#22924] KX_PolygonMaterial.diffuse does not return expected list[r,g,b]
- Py API: Renaming _owner attribute of mathutils classes to owner.
- Fix some minor errors in mathutils and blf.
- Enabling game engine autoplay again based on a patch by Dalai:
* The biggest 3D view in the open scene is used, if there is none, blender opens the file normally and raises an error.
* The 3D view are is made fullscreen.
* Quad view, header, properties and toolbox panel are all hidden to get the maximum view.
* If the game engine full screen setting is set, the game starts in fullscreen.
- Fix for ipo conversion on file transition in the game engine.
|
|
Changing " **type** " into "\n\n:type: " in Mathutils, to have like "type: float" in its own line.
|
|
quat * quat was returning the dot product (a float), rather then the cross product.
Use BLI_math's mul_qt_qtqt() function.
|
|
|
|
vec1.angle(vec2, fallback)
in my experiences most uses of this function required a try/except so better to allow a fallback value.
|
|
|
|
- add PySequenceMethods members (all NULL)
- spaces -> tabs
- cmake syntax warning from recent ghost commit
|
|
- mathutils.Color.hsv attribute. eg. material.diffuse_color.hsv = 0.2, 0.8, 0.4
- Vector/Euler/Quaternion/Color now only take a single seq arg.
- internal function for parsing arrays. (cleanup messy internal list/vector/tuple/seq parsing)
- didnt update rigify yet.
|
|
- docstring for Euler.rotate
- rotate_eul, use upper case in Py and C.
- use less verbose repr method.
|
|
|
|
- added new mathutils.Color() type, use with rna so we can do for eg:
material.diffuse_color.r = 1.0
# also has hsv access
material.diffuse_color.s = 0.6
- made Mathutils and Geometry module names lowercase.
|
|
- prefix mathutils api.
- 2 blf.c files (annoying for debugging)
- py api docs ignore keying sets as with operators.
|