Age | Commit message (Collapse) | Author |
|
reporting missing headers & C files.
this is important so IDE's using CMake integration always get blender headers. - QtCreator & MSVC for eg, probably others too.
|
|
- 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.
|
|
drivers allow scripts to add functions directly.
- bpy.app.driver_namespace, read-only dictionary, edit in-place.
- reset on file load and new file.
- on errors the namespace used to be reset, this should not be needed.
simple example.
def driverFunc(val):
return val * val
bpy.app.driver_namespace['driverFunc'] = driverFunc
... now all drivers can access this function.
|
|
the same subclass as the vectors they were derived from.
|
|
caused by own recent commit. update uv operator template too.
|
|
This is an annoying but which isn't a problem for Python because they don't execute multiple scripts, one after another (there is one __main__ and everything else is a module).
So when the __main__ module in sys.modules is overwritten, it decref's the module and clears the dictionary with _PyModule_Clear(), even though the modules dictionary is still in use.
Strangely this problem only happens with Python3.1.1 and Python3.2x svn but not 3.1.2
This commit restores the namespace after _PyModule_Clear() sets all its values to None.
|
|
|
|
|
|
- Python calling operators didn't run WM_operator_properties_sanitize() so enum functions called from python were given a NULL context.
- PROP_ENUM_NO_CONTEXT and PROP_NEVER_NULL used the same value in the enum (possible conflict).
|
|
an extern into a define.
|
|
- python/mathutils api matrix.lerp(other, factor)
- new function mat3_to_rot_size(), like mat4_to_loc_rot_size but with no location.
|
|
- correct exception messages for mathutils constructors.
|
|
unsigned byte/short/int were being passes as signed values which would raise an overflow error if a range greater then the signed value was used.
|
|
reports (when using operator callbacks).
- when python operators fail to execute they were returning RUNNING_MODAL, now return CANCELLED
now when an operator fails it gives an error popup as well as a message in the terminal.
|
|
|
|
* Keyframing operators now use the reports system for displaying all its error messages.
- The benefit of this is that users no longer need to check the console for error messages if keyframing fails.
- Unfortunately, reports are not currently viewable in any space/view in Blender, so...
* Added a temporary operator (UI_OT_reports_to_textblock), which can be accessed in the UI from the button which appears in place of the icon when more than one report exists. This dumps the current list of reports to a textblock "Recent Reports", from which they can be viewed.
This isn't really nice, but at least we now have a way to view these again, which makes debugging some things a pain.
* Bugfix #24606 - when trying to add keyframes to F-Curves with F-Modifiers already which alter the curve significantly enough that the keyframes will have no effect, there are now warnings which aim to alleviate any confusion.
|
|
flagged as PROP_THICK_WRAP.
Also use const char in many other parts of blenders code.
Currently this gives warnings for setting operator id, label and description since these are an exception and allocated beforehand.
|
|
- move bpy_array.c to bpy_rna_array.c
- minor syntax changes
|
|
past end of array
was setting the vector array out of bounds with vec*=matrix, where the vector wasnt size 4.
|
|
|
|
generates bugs
was printing transposed, also nicer printing.
>>> from mathutils import Matrix
>>> Matrix()
Matrix((1.0, 0.0, 0.0, 0.0),
(0.0, 1.0, 0.0, 0.0),
(0.0, 0.0, 1.0, 0.0),
(0.0, 0.0, 0.0, 1.0))
was...
Matrix((1.000000, 0.000000, 0.000000, 0.000000), (0.000000, 1.000000, 0.000000, 0.000000), (0.000000, 0.000000, 1.000000, 0.000000), (0.000000, 0.000000, 0.000000, 1.000000))
|
|
- 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.
|
|
|
|
doenst need to swap in NULL chars to draw word wrapping.
|
|
being treated as None.
|
|
WM_operator_poll() could fail in cases WM_operator_name_call() would succeed because calling the operator would setup the context before calling poll.
this would result in python raising an invalid error or menu items being greyed out.
now python can also check with an operator context:
bpy.ops.object.editmode_toggle.poll('INVOKE_SCREEN')
|
|
from mathutils.geometry import PolyFill
I couldn't find a way for python's inittab to do this so just inserting mathutils.geometry into sys.modules manually.
|
|
to sys.modules directly, no functional change.
|
|
function into path_util.h since these are not fileops.
|
|
it becomes an error.
having the blend file as a part of the __file__ variable is not essential, this is fixed in python 3.2 so add an ifdef and don't use the blend file path for py older then 3.2.
|
|
mat4_to_loc_rot_size(), use this now for pchan_apply_mat4() to support negative scale, visual keying now uses compatible eulers.
also added access to this in python's mathutils.Matrix()
loc, quat, scale = matrix.decompose()
|
|
utility functions using mathutils types.
|
|
Simple python benchmark shows this to be about 3x faster in the case where an update isn't needed.
This also speeds up rna function argument parsing, since each arg in a function call did 2 string lookups on the context which were never needed.
|
|
by cmake devs.
globbing vs explicit is discussed here.
http://www.cmake.org/pipermail/cmake/2008-December/025694.html
Practical implications are:
- developers need to keep CMakeLists.txt files up to date.
- Users wont get strange linking errors if they build after a file is added, since CMake detects CMakeLists.txt is modified and automatically reconfigure.
|
|
duplicates.
|
|
|
|
|
|
disallow registering RNA with names longer then 31 chars.
|
|
* Added build_system SCons or CMake
* Write the new build info also to system-info.txt
|
|
|
|
|
|
Both stored the filename of the blend file, but G.sce stored the last opened file.
This will make blender act differently in some cases since a relative path to the last opened file will no longer resolve (which is correct IMHO since that file isnt open and the path might not even be valid anymore).
Tested linking with durian files and rendering to relative paths when no files is loaded however we may need to have some operators give an error if they are used on the default startup.blend.
|
|
- made interface, windowmanager, readfile build without unused warnings.
- re-arranged CMake's source/blender build order so less changed libs are build later, eg: IK, avi
|
|
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.
|
|
|
|
First commit to make some structure in doc/ directory.
- moved source/blender/python/doc -> doc/python_api
- moved source/gameengine/PyDoc/*.rst -> doc/python_api/rst
- modified accordingly sphinx_doc_gen.py and sphinx_doc_gen.sh
(later on I'll try alternative/ scripts by neXyon as promised :)
- source/gameengine/PyDoc/ is still there because contains epydoc stuff for the bge, will ask more and look into it later
|
|
files (with fix).
from Sergej Reich (sergof)
Made some corrections to the patch as well as using bpy.app.tempdir with tempfile python module.
|
|
- bpy.app.debug can now be set, removed bpy.data.debug (since this is not blendfile data)
- added bpy.app.tempdir, this is needed because the userpref temp dir isn't always set, $TEMP may be used instead and scripts need temp dir access.
|
|
change).
|
|
converting the argv
- report errors when files dont load when given from the command line but not running in background mode.
|