Commit Graph

2415 Commits

Author SHA1 Message Date
Campbell Barton
fccceaa87f - pyrna support for (value in array), currently only 1 dimensional arrays.
- use python malloc's in bpy_array.c
- automatically blending bone locations is disabled if the target bone has locked location
- neck had incorrect roll
2009-12-08 09:40:30 +00:00
Matt Ebb
81a69bb00f Various changes to screen-related code, aiming to fix a few problems and usability issues with 'temp' screen layouts.
Now, temp screens are hidden from being accessed directly, with a new 'Back to Previous' button appearing in place of the screen menu when (for example) fullscreen render image areas are present. Window type menus also get disabled here too, to prevent things from getting too mixed up.
2009-12-08 07:12:06 +00:00
Campbell Barton
f4fa39a551 white space commit (spaces -> tabs and clearing whitespace) 2009-12-08 07:11:43 +00:00
Joshua Leung
53f94f92a1 Animation Editors: Fixes for RNA/Python Bastardisation
Still not happy about the tight/regular-spacing imposed by the layout engine automation, but will tweak later.
2009-12-08 06:32:30 +00:00
Martin Poirier
4ea3e14ebf Wrong argument type for zoom operator. 2009-12-08 01:56:01 +00:00
Andrea Weikert
d653b0c961 Few small things:
1. MSVC 9 projectfiles update (graph_header.c, action_header.c and nla_header.c removed)

2. Fix for opening the filebrowser when saving file for the first time (untitled.blend) from file menu

3. Add CROSS effect sequence type back to menu. (Durian fix)
Note: Removed SEQ_EFFECT from rna, since this no actual sequence type, but rather used to check for the effect bit.
2009-12-08 00:57:14 +00:00
Elia Sarti
b71749305a Pythonazed DopeSheet and NLA editors headers UI. 2009-12-07 21:51:44 +00:00
Campbell Barton
ce49719a0c use the SUM driver type to avoid adding all values on each bone.
also avoids hitting the 255 string limit if you want to add 100's of values. eg.
>>> b05/max(0.001, [globals().update({"LOCALS":locals(), "ADD":float.__add__, "reduce":__import__("functools").reduce}), 0.0][1], max((, [LOCALS["b%.2d" % (i+1)] for i in range(5)])))

Since this more simple expression reaches the limit fairly quick...
>>> b05/max(0.001,b01+b02+b03+b04+b05)
2009-12-07 20:49:12 +00:00
Brecht Van Lommel
4a23c3f9e1 Particles: child editing bugfixes
* Make partial update work again for faster editing.
* Draw parents over children again, nicer for editing.
* Fix crash with remove tools & showing child particles.
* Fix children not disappearing always when setting to None.
* Fix wrong normal for last point in child path.
* Fix a python error in the hair dynamics panel.
2009-12-07 17:55:58 +00:00
Campbell Barton
f8f7f57557 - bone.basename now only gets the name before the first '.', since names like finger.01.L are common
- updated delta not to remove a bone
- spine and neck rigs interpolation bones are now axis aligned to the control bone
- palm tag is expected on the pointer finger rather then the wrist
- operate on bone children first working up the chain (not essential but more pradictable)
2009-12-07 17:21:30 +00:00
Campbell Barton
926201acf8 - string copy without .py wasnt terminating the string
- console import autocomplete wasnt including modules defined in C like BGL, Mathutils
2009-12-07 14:09:53 +00:00
Elia Sarti
73fbc0f02d pep8 compliance cleanups. 2009-12-07 12:11:28 +00:00
Elia Sarti
c1c5acae14 Porting of Graph Editor's UI to python, just header done for now.
Brecht, I added a Layout template function, template_dopesheet_filter -> uiTemplateDopeSheetFilter, this creates the group of buttons for filtering ID type (and some other options) for animation editors (Graph, NLA and Dopesheet). I hope this is all right, if not, we can move this maybe to a .py file as a function for reuse.
2009-12-07 11:50:05 +00:00
Campbell Barton
764c4c94fa use sets rather then tuples for enum/flags so you can use bitfield operators 2009-12-07 02:20:55 +00:00
Campbell Barton
750764f411 rna flag PROP_ENUM_FLAG which makes rna props a tuple of enums when converted into a PyObject
only used by wm.invoke_props_popup() currently
2009-12-07 00:16:57 +00:00
Campbell Barton
062cf438ce remove nasty hack which made StructRNA class instaces have no __dict__,
use __slots__, it seems all the parent classes need to have slots as well for this to work.
all python defined srna classes are checked for this too
2009-12-05 23:41:45 +00:00
Campbell Barton
5ebe54f470 pep8 edits and fix some warnings 2009-12-05 22:03:07 +00:00
Campbell Barton
651336d5df fixes for automatic tests and some errors in last commit 2009-12-05 20:45:51 +00:00
Martin Poirier
bcd1ab54cd Support for the C Macro system in Python.
Basic definition works like a python operator but you derive from "bpy.types.Macro" instead.
Operators are added to the macro after it has been added with "bpy.ops.add_macro" through the class method "define" which takes an operator id and returns an OperatorMacroType (new RNA type) for which properties can then be defined to be passed to the operator when run.

Example: http://blenderartists.org/~theeth/bf/macro.py

Using this system, it should be easy to add an operator to the console that converts selected lines into a macro or even a more generic record macro system.
2009-12-05 19:27:26 +00:00
Campbell Barton
65edb7341f split up metarig hierarchy evaluation and modifying the metarig into 2 steps,
original bone names cant be changed anymore but this means the bones can be re-parented without confusing scripts that run after the rig is modified.
support for defining a bone to have multiple types and  automatically blending between 2 generated rigs
2009-12-05 19:26:28 +00:00
Martin Poirier
c7c1fda642 Changes to netrender baking operator.
Force step of 1 for full baking.
2009-12-04 19:13:22 +00:00
Guillermo S. Romero
648122b1a2 String fix and a bunch of PEP8 issues I had collected in the meanwhile. 2009-12-04 17:54:48 +00:00
Campbell Barton
19c0a169b8 touches for demo'ing 2009-12-04 16:35:31 +00:00
Matt Ebb
a358b6386d * Fix for incorrect disabling after baking cloth sim
* Fix for time cursor getting 'stuck' after baking point caches
2009-12-04 04:28:50 +00:00
Campbell Barton
a9b9993414 rna function
editbone.align(vector), to align the bones z axis to a localspace direction.

finished leg rig pose mode data
2009-12-04 02:32:34 +00:00
Martin Poirier
d3d11ede44 Fix for cache path.
Operator for background baking (no support in netrender itself yet).
2009-12-04 01:28:00 +00:00
Matt Ebb
688c4aa1de Fix for [#19478] Shortkeys for switch to Quad view mode is not working
changed default quad view shortcut to Ctrl Alt Q
2009-12-04 00:49:02 +00:00
Campbell Barton
ab1290d62e leg rig type & metarig example, still need to add IK's
fixed some small bugs too.
2009-12-03 22:44:11 +00:00
Martin Poirier
18b465b749 Finish renaming job in Set Center operator to use Origin instead of Center.
Also replace ObData by Geometry and Object Geometry after talk with Matt.
2009-12-03 21:56:04 +00:00
Campbell Barton
3b0e182f71 - property decorators for setting attributes didnt work, hack to prevent every instance of an BPyStructRNA to have its own dictionary, set the tp_dictoffset to 0. attempted to use __slots__ but this doesnt work for some reason.
- made bone.length writable
2009-12-03 21:53:01 +00:00
William Reynish
18fb6d5e43 Added Toggle Full Screen and Duplicate Area to the menus of all the main spaces in Blender 2009-12-03 16:28:50 +00:00
Campbell Barton
685d418f3a - curve geometry curve panel wasnt displaying with no active spline
- graph export didnt work for constraints with no subtarget
- utility functions for duplicating a set of bones and blending between 2 sets
2009-12-03 14:20:35 +00:00
Joshua Leung
f146d96c3b Bugfix #20219: Timeline navigation
Added missing "View All" (HomeKey) operator for TimeLine
2009-12-03 09:56:31 +00:00
Matt Ebb
bd8e929044 Fix for [#20226] 3DView header: hiding menu texts and layer button's issue.
Also: big purge of old 3d view header menus and old unused code
2009-12-03 09:49:21 +00:00
Martin Poirier
63fc267929 [#20213] Align to Transform Orientation crashes Blender
Align needs to be call with region context.

Also added checks to prevent this from crashing if not called properly.
2009-12-02 19:59:57 +00:00
Campbell Barton
7706261e79 change bone storage class so __slots__ can be used for looping over attributes without getting functions 2009-12-02 19:13:54 +00:00
Campbell Barton
e2450e4dd9 multiple script paths broke text template menu 2009-12-02 16:11:10 +00:00
Campbell Barton
ce36cdac04 - bpy.data.add_armature()
- rigify testnig function, creates all example metarigs, processes and generates graphs for before and after.
2009-12-02 15:37:07 +00:00
Damien Plisson
a219c93cb0 Quicktime(Carbon/win32) : add operator to raise the "compression settings" quicktime standard dialog 2009-12-02 14:39:49 +00:00
Campbell Barton
2bf618368a - include example input rigs for each autorig type, running metarig_template() in each submodule generates the armature and pose bone ID properties.
- rigify.write_meta_rig() exports rigs as python scripts
2009-12-02 11:55:47 +00:00
Brecht Van Lommel
927b976a88 AAO Indirect Diffuse
Don't use passes anymore for indirect lighting, people were using this
probably thinking it would do bounces, but that's not the intention of
this feature, it is to reduce problems with light bleeding. I want to
remove this option for AO as well, but will leave it in for now until
there is a better alternative.

Added bounces option for indirect, could be implemented much better,
but perhaps useful for testing now. Existing files need to set this to
1 to get the same results again.
2009-12-02 11:54:48 +00:00
Campbell Barton
8c5d021d19 rename armature RNA props
armature_matrix --> matrix_local
armature_head --> head_local
armature_tail --> tail_local
2009-12-02 10:32:39 +00:00
Matt Ebb
b89138564e Changes to Color Management
After testing and feedback, I've decided to slightly modify the way color 
management works internally. While the previous method worked well for 
rendering, was a smaller transition and had some advantages over this
new method, it was a bit more ambiguous, and was making things difficult 
for other areas such as compositing.

This implementation now considers all color data (with only a couple of 
exceptions such as brush colors) to be stored in linear RGB color space, 
rather than sRGB as previously. This brings it in line with Nuke, which also 
operates this way, quite successfully. Color swatches, pickers, color ramp 
display are now gamma corrected to display gamma so you can see what 
you're doing, but the numbers themselves are considered linear. This 
makes understanding blending modes more clear (a 0.5 value on overlay 
will not change the result now) as well as making color swatches act more 
predictably in the compositor, however bringing over color values from 
applications like photoshop or gimp, that operate in a gamma space, 
will give identical results.

This commit will convert over existing files saved by earlier 2.5 versions to 
work generally the same, though there may be some slight differences with 
things like textures. Now that we're set on changing other areas of shading, 
this won't be too disruptive overall.

I've made a diagram explaining the pipeline here:
http://mke3.net/blender/devel/2.5/25_linear_workflow_pipeline.png

and some docs here:
http://www.blender.org/development/release-logs/blender-250/color-management/
2009-12-02 07:56:34 +00:00
Martin Poirier
fa2ec6af38 Restore new snap align icon that was lost in previous changes. 2009-12-02 04:07:40 +00:00
Campbell Barton
50c8c28c60 - finished spine rig generator, (drivers, constraints)
- bug with args passed for class slots being modified in place.
- sort graphviz bones & drivers (useful for diffing 2 armatures)
2009-12-02 02:56:22 +00:00
Martin Poirier
fd69360fd2 remove icon_only option for snap target option in header to make the button wider. Now it's a bit too wide, but at least it can be read. 2009-12-02 01:38:54 +00:00
Campbell Barton
c27f3adadc - rig spine type WIP, editmode done, still needs pose constraints and drivers.
- bone.translate(vec) utility function
2009-12-01 22:45:56 +00:00
Campbell Barton
6372c63ae9 select pattern for bones 2009-12-01 14:48:36 +00:00
Campbell Barton
48398c978e more small fixes 2009-12-01 12:43:06 +00:00
Campbell Barton
2afc967a2f small fixes, also option for fake parent so hierarchy is always from the parent down 2009-12-01 12:25:59 +00:00