Commit Graph

1546 Commits

Author SHA1 Message Date
Sergej Reich
09b124fbd3 rigidbody: Add option to create chanis for the connect operator
Connects objects based on distance.

Based on a patch by Brandon Hechinger (jaggz), thanks!
2013-02-21 19:04:39 +00:00
Sergej Reich
9c08d1c649 rigidbody: code cleanup
Use bpy.data.objects.new() instead of the object.add() operator.
2013-02-21 19:04:36 +00:00
Sergej Reich
822a06920b rigidbody: Move "Enabled" checkbox out of rigid body panel header
Rename it to "Dynamic" to make it more obvious that it switches between
static and dynamic state.
Also don't show it for passive rigid bodies since it's redundant in that
case.
2013-02-21 19:04:34 +00:00
Howard Trickey
0a6e8a41b9 Enable new bevel tool code in bevel modifier.
Now modifier takes a segments parameter.
Bevel edge weights will multiply the overall amount.
For vertex-only, you can give a vertex group name,
and the weights in that will multiply the overall amount.
2013-02-21 17:29:35 +00:00
Campbell Barton
6869ea8e7e code cleanup: no need to use list(range()), just use range() 2013-02-21 17:12:08 +00:00
Thomas Dinges
442d16b468 Fix for [#34308] only half width of material list row is used for material name.
* Issue was caused in r54393.
2013-02-18 23:41:28 +00:00
Bastien Montagne
d7058f12e5 Make list_id mandatory when using default UI_UL_list class for a template_list. 2013-02-18 14:03:26 +00:00
Bastien Montagne
5c5b753779 Fix [#34300] Slider for list of particle systems (keyed particles) is not doing anything. Navigating a list of more than 5 elements requires keyboard.
Systematically adding some custom id to template_list using default UI_UL_list class, this one is commoly used more than once in an area, yielding collision issues if they do not have a custom id...
2013-02-18 13:30:40 +00:00
Sergej Reich
85b6bbe6cd ribidbody: Fix setting "Bake to Keyframes" start frame above 2
Simulation needs to run from the beginning to work properly.
2013-02-17 18:13:22 +00:00
Bastien Montagne
c524b47912 Another huge bunch of UI translation fixes, mostly reported by Leon Cheung, Sv.Lockal, Gabriel Gazzán and Satoshi Yamasaki, thanks! 2013-02-17 13:56:49 +00:00
Monique Dewanchand
9cd01c6a5c Added option for group node buffering in the compositor.
Justa cluster did not have enough memory to handle all Mango 4k scenes.
Option is default disabled and can be enabled in the performance panel.

 - At Mind -
2013-02-16 20:21:41 +00:00
Bastien Montagne
313df262e3 Fix [#34253] UIList resize, resizes wrong list I/II
When using default UI_UL_list, one should always spully a custom ID, else collision inside an area are quite likely...
2013-02-15 08:32:25 +00:00
Bastien Montagne
43f4f807d9 Fix physics' name not translated in main physics panel (reported on bf-translations ML).
This also revealed another bug, as you could not explicitely set default context to text_ctxt UI func parameter (None is not accpeted by RNA string props), so I had to change default context from py POV to "*" instead of None.

Anyway, that physics UI translation remains weak, as the trick used here (helper func) prevents message extractor script to directly find them. Currently it works because specified labels are also defined elsewhere, but it would be nice to have some kind of "translation markers" in py code too (similar to our N_/CTX_N_ C macros, unfortunately python does not have preprocessing ;) )...
2013-02-13 11:52:01 +00:00
Bastien Montagne
027a426c4d Add translation of stats/info string. 2013-02-12 07:32:17 +00:00
Bastien Montagne
d0f4a2396b Actually, UI scripts should not use directly pgettext, but rather the iface or tooltip variants. Added those to bpy.app.translations, and used pgettext_iface.
(Did not add those when I created that module, because I did not thought we would actually need them in usual UI code, but turned out I was wrong).

Also made some optimizations in those py gettext funcs, when i18n is disabled at build time, no need to do pyobject -> cstring -> pyobject conversions!.
2013-02-10 10:29:38 +00:00
Campbell Barton
3b8a0f3d67 use import rather then assignment for loading '_' into scripts. 2013-02-10 09:56:05 +00:00
Bastien Montagne
c0fa16f2c9 Another fix for r54414 (cleaner to "import" pgettext once at top of files, also now using usual '_' shortcut). 2013-02-10 09:09:26 +00:00
Campbell Barton
5d4df1a999 pep8 cleanup 2013-02-10 08:54:10 +00:00
Campbell Barton
63af7068ad revert removal of ternary operators from r54414 2013-02-10 08:26:48 +00:00
Bastien Montagne
82c86af7f7 Bunch of fixes for py ui messages (all those using 'formating' were not translated previously, now they use bpy.app.translations.pgettext). Also pleas avoid complex py statements in 'text' values (like 'text="foo" if cond else "bar"'), thes make message extraction script fails!
And another "final point in UI message" removal!
2013-02-09 18:26:40 +00:00
Campbell Barton
d26c063121 disable translations for some python buttons. 2013-02-08 16:41:02 +00:00
Bastien Montagne
23aa0c9067 Fix uilists showing data names translated (reported on bf-translations ML by Satoshi Yamasaki aka yamyam, thanks!). 2013-02-08 16:01:21 +00:00
Ton Roosendaal
a3bd7de8a3 Added warning below MultiSample User Preference option for Linux systems.
(All 8 reports in tracker for selection failures were linux...)
2013-02-08 13:15:30 +00:00
Ton Roosendaal
1dfb6404b7 Release todo: added userpref for Mac users having "Natural Scroll" set.
As per discussion and analysis of all trackpad usage, we now
follow this convention:

- Blender follows system setting for trackpad direction preference.

- If you set your system to "natural" scroll, we need to invert a couple
  of cases in Blender we do "natural" already. Like:

   - view rotate (the inversed option just never feels ok)
   - scroll active items in list or pulldown menu (up/down is absolute)
   - ALT+scroll values in buttons (up/down is absolute)

The new User Preference setting "Trackpad Natural" handles this.

For 2.66 we only have trackpad handling for OS X... so this isn't
affecting trackpad usage in Windows and Linux, which stick to be mapped
to Scroll Wheel still.

(Note: viewrotate now is "natural" always, changing how it worked in the
past weeks).
2013-02-08 12:12:57 +00:00
Campbell Barton
08326778c5 use sys.platform for checking the OS. 2013-02-08 11:23:22 +00:00
Campbell Barton
4b8fe80e6e code cleanup: use exist_ok keyword arg to os.makedirs() rather then checking if the dir exists first. 2013-02-07 04:02:24 +00:00
Sergej Reich
b64858cade rigidbody: Use ARROWS empty draw type when creating constraints
Since we don't have constraint visualization yet, it's useful to see
where the individual axes point.
2013-02-05 21:51:20 +00:00
Campbell Barton
26ee2a1f79 patch [#33886] Combine Dissolve Menu with Delete Menu 2013-01-30 05:19:27 +00:00
Brecht Van Lommel
df53f46065 Fix #34031: in the keymap editor, Timer and Text Input types did not show field
to edit the operator name.
2013-01-29 17:30:30 +00:00
Joshua Leung
cf9e619889 Skeleton Sketching bugfixes/tweaks
* Disabling Skeleton Sketching now refreshes the view properly, so that strokes
don't linger on even after being disabled
* Added the delete operator to the panel
2013-01-29 03:04:24 +00:00
Joshua Leung
d6b166d1a1 Bugfix [#34012] Skeleton Sketching settings unclear
Although the bug report here wasn't exactly clear about what exactly was wrong,
it soon became apparent that the UI stuff here was in need of some love.

Changes:
* Ported over missing tooltips from 2.49 (i.e. most of them)
* Fixed a few incorrect tooltips (mostly the subdivision length settings)
* Made the autonaming and number/side settings slightly clearer - number/side
are used to replace placeholders in the names of template bones (&N and &S
respectively) when autonaming is disabled. When it is enabled, these values are
determined automatically.
2013-01-29 02:00:33 +00:00
Pablo Vazquez
56f82655ed Window menu: Make Screencast (should be Save?, to match screenshot?) option.
Thought of setting the operator context before so it wouldnt invoke the confirmation dialog, but better leave it by default to confirm since it might be clicked by mistake and start dumping video/image-sequence and can get annoying.
2013-01-29 01:43:03 +00:00
Pablo Vazquez
12a4a84ee5 Info Editor: Adding Save Screenshot option to the Window menu, was only available through search or shortcut (CTRL+F3) 2013-01-28 23:06:27 +00:00
Bastien Montagne
6fdaa9c99a Fix [#34023] r54146 breaks name-display of default "UI_UL_list"
draw_item *is* optional (it then uses default C function), even though there is not much sense to register a class without it, except for our default UI_UL_list!
2013-01-28 18:46:04 +00:00
Campbell Barton
2bae448ed5 fix [#34018] Delete Edge Loop undo works not als expected. 2013-01-28 12:42:38 +00:00
Campbell Barton
1c2d5eeeef fix for rigid body assuming active object would be selected, also don't check length of selected objects in poll function (getting and throwing away object selection array on every redraw is no good). 2013-01-28 12:24:25 +00:00
Lukas Toenne
0bf264f7ef Fix for errors caused by fixing RNA function register flags. Default UIList class now has a dummy draw_item callback. Panel draw_header is now optional (most panel classes don't define it). 2013-01-28 12:18:00 +00:00
Campbell Barton
8445a56b48 use more conventional names in rigid body script. 2013-01-28 12:15:50 +00:00
Sergej Reich
753890d0e8 rigidbody: Don't show dialog for "Connect" operator
Use redo last panel to change settings now.
This is more in line with how the rest of blender operates.

Also fix tootip
2013-01-28 11:56:01 +00:00
Joshua Leung
67c2cd916d Made the tooltip for rigid body constraint "Connect" operator clearer
Previously it wasn't clear what it was supposed to be doing, or what was
required for it to work.
TODO: figure out why the operator redo settings panel won't work. The workflow
here is still a bit clunky.
2013-01-28 02:48:19 +00:00
Dalai Felinto
0976a780eb BGE UI: removing "use_occlusion_culling" from the ui
(and marking rna as deprecated)

I talked with Benoit Bolsee and Mitchell Stokes and they both agreed that
the feature should be removed.

In case someone was actually using it the rna is still available. But next
release we remove both the rna, the DNA and the flag in the code.

I did a simple benchmark with tons of cubes, and the DBVT culling (use_occlusion_culling=True)
always perform better than when it's off. Even when no occluder objects are in the scene.
2013-01-27 19:57:47 +00:00
Bastien Montagne
a2e55171fe Bunch of fixes for UI messages.
Also generate rigid body constraint types in py bullet code from RNA enum values (simpler than having to sync the code when something is changed here!).

Side note: RNA API about icons still needs to expose icons for enum values, and conversion funcs between icon_name and icon_value!
2013-01-27 18:14:24 +00:00
Ton Roosendaal
2545e832e2 Pack UI:
Oops! So there was an Unpack button, hidden in the Nkey properties of Image window.
This was drawn next to greyed-out buttons, didn't notice it well.

I also now found the unpack() menu in editors/util, and there's an Image unpack op.
Also the RNA api has an unpack!

Will remove the generic unpack op, and add a sound and vfont unpack instead.
2013-01-27 17:20:08 +00:00
Sergej Reich
204ec89bff rigidbody: Improve add/remove operators
Now all add/remove operators for rigid body objects and constraints
automatically add objects to the appropriate groups and create groups if they
don't exist yet.

This makes handling rigid bodies easier but doesn't take away functionality.
If users want to handle groups manually they just need to create them before
adding any objects.

The previous behaviour was confusing and was even considered to be a bug since
clicking on rigid body in the physics tab seemed to do nothing.
2013-01-25 06:26:38 +00:00
Campbell Barton
296f91c4cc add 'deform - integrate' option to mesh-cache,
This means the deformation on the input to the modifier can be re-applied ontop of the mesh cache.

In practice this is most useful for using corrective shape-keys with mesh-cache.
2013-01-24 04:02:30 +00:00
Ton Roosendaal
17b1c19054 UI todo:
Added "Panel Title" style to Theme settings.
Allows to make these nice larger or draw differently.

Also tried to put hinting in Style, but this needs to be a per-font
setting. uiFont data is still not being saved (also not allowing
to set own font files for UI). That's a todo for 267 then.
2013-01-23 16:01:35 +00:00
Sergej Reich
90a97a4710 rigidbody: Fix constraint buttons only showing for mesh objects
Was silly indentation mistake.
2013-01-23 13:45:52 +00:00
Ton Roosendaal
3e6892e18f File Menu, "Save startup file" no asks for save-over confirm.
Being a destructive action (and there are no versions saved as backup) it's an
OK convention to prevent accidents.
2013-01-23 12:08:23 +00:00
Thomas Dinges
be21034ae4 UI / Layout scripts:
* Code cleanup for new Rigid Body panels. 
* Removed some unneeded split() calls.
* Remove redundant check for "ob.rigid_body_constraint" in the draw() function of the "Rigid Body Constraint" panel. The check is already made in the poll.
2013-01-23 11:40:35 +00:00
Campbell Barton
45fb9f9f09 scene panel for rigid body - remove operator isnt greyed out when rigidbody is disabled 2013-01-23 08:07:39 +00:00