Commit Graph

1327 Commits

Author SHA1 Message Date
4a33d7f210 Fix related on #31984: Multires Displacement Bake creates ripples for each subidived face
Skip applying subdivisions in cases when low resolution mesh is disabled
and baking happens from higher level to higher level/
2012-07-02 07:40:25 +00:00
1597ad9377 style cleanup 2012-07-01 09:54:44 +00:00
8b865c01cd style cleanup: comments 2012-06-30 22:49:33 +00:00
2d7efed014 mark modifier operators that only work in the UI as internal, otherwise this causes some confusion when they do nothing when accessed from the spacebar search menu. 2012-06-29 23:09:19 +00:00
15cb064e1b style cleanup 2012-06-25 07:24:48 +00:00
ac9344de75 Fixes for modifier data in multi-user meshes.
When removing a skin or multires modifier, it skips deletion of the
associated CustomData layer if the object has any other modifiers of
that type. This check has been extended to all objects that use the
object's data.

Similarly, deleting higher multires levels and multires subdivision
will not update the maximum level of any other multires modifiers on
objects that link to the same mesh.

Note that modifier_apply_obdata() doesn't need any changes as it
does not allow applying to multi-user data.

Object joining has also been modified to synchronize multires levels
objects that share a mesh. This is needed because joining can
subdivide or delete levels in order to match the maximum level of the
join-from object to the join-to object.

Fixes bug [#31880] instance multiresolution modifier error.
http://projects.blender.org/tracker/index.php?func=detail&aid=31880&group_id=9&atid=498

Reviewed by Sergey:
http://codereview.appspot.com/6332047/
2012-06-24 20:18:32 +00:00
091c716198 correction to own commit - thanks Anthony Edlin for pointing out the error. 2012-06-20 22:57:05 +00:00
72f7ab441d removing from group now shows menu to select group to remove. 2012-06-20 14:13:22 +00:00
bdfcc5c619 Fix #31825: 3D View Editor Header > Object > Game > Copy Properties affecting other commands.
Mark property to be copied/moved as SKIP_SAVE. That was giving the issues.
2012-06-18 14:44:16 +00:00
f5f25b81e8 style cleanup:
also fix for building ghost test and fix double free in one of the tests
2012-06-17 09:58:26 +00:00
f0c724219d Internal refactoring of tracking module, should be no functional changes
- Re-arrange functions in headers and implementation file to make them
  more grouped by entity they're operating with. Also order of functions
  in implementation file should match order of functions in header for
  easier navigation.

- Rename some functions to match conventions of naming public functions.
- Some code de-duplication, still some room for improvements tho.
- Split main 2D tracking functions into smaller steps to make it more clear.

Accidentally OpenMP was disabled in some of previous commits, re-enable it.
2012-06-15 11:03:23 +00:00
29e5f72395 Interface:
* Rename "Clear Game Property" to "Rename Game Properties", because the operator deletes all game properties from all selected object(s), not only one.

This fixes [#31828], patch by Philipp Oeser.
2012-06-14 14:02:15 +00:00
201e9d815a Bugfix for [#31829] Add lamp icons missing. Patch by Philipp Oeser.
Note: If you do code cleanups, and revert make sure you revert it correct and not halfway. ;-) r47034
2012-06-14 13:54:55 +00:00
02bcba341d OBJECT_OT_drop_named_material -- missing notifier for material panel UI update 2012-06-09 21:43:22 +00:00
909752a3da Fix #31752: Select All By Layer seems not to work when object belongs to several layers
Added option which changes match policy from exact match and shared layers when
selecting objects by layer.
2012-06-08 15:14:45 +00:00
87211a49ab Fix #31743: Applying Smooth modifier to a curve crashes Blender
Actually there were two different issues involved here:

- Recently enabled Smooth modifier wasn't actually designed for curves, so
  it in fact requires a bit bigger work to make it working.

  For now added check for object's typy in this modifier and if it's not
  mesh, it wouldn't try to use edges.

  The reason why it worked in 3d viewport is that creating DM from curve while
  displist is still ocntrcuting for would result in empty CDDM and that leads to
  not taking edges into account, only vertexCos passed to modifier would be used.

  This makes it behaving a bit differently from if it was a mesh, but still gives
  quite reasonable result. Would leave actual fix for a guy who enabled smooth
  modifier.

- Another issue is related on ensuring sculpt mask layer after applying modifier.
  This shall happen only for meshes.
2012-06-08 08:17:34 +00:00
6cff0b71a7 style cleanup 2012-06-05 21:54:21 +00:00
68a9dd54ec mask mode for clip editor developed by Sergey Sharybin, Pete Larabell and myself.
see:
http://wiki.blender.org/index.php/User:Nazg-gul/MaskEditor


note - mask editing tools need continued development, feather option is not working 100%
2012-06-04 16:42:58 +00:00
1ced356009 Action Group Colors for Bones (Part 2)
Colors used by Bone Groups are now copied/assigned to Action Groups too when
they're created now. This completes the work started in r.46960 to restore this
functionality from 2.48.

Currently, there is no control over when/whether these colors are copied over
(although it is possible to disable the display of these colors for relevant
animation editors if desired). Originally I was going to make this a more
generic Keying Sets feature, though that turned out to be a bit too complex to
manage.

Other notes:
* Split out the code for copying colors to a common library function
2012-06-01 13:54:44 +00:00
c3a7db28d3 Fix #31657: adding mesh objects did not take units into account for the grid
scale that sets the default size.
2012-05-31 16:04:03 +00:00
47584648dc split up proportional editing keymap functions (adding this in tomato branch was messy) 2012-05-30 08:02:49 +00:00
d4c7f2d53d clear active object when hiding unselected objects too. 2012-05-30 06:37:40 +00:00
52aad984b6 Outliner Drag & Drop fixes
OUTLINER_OT_parent_drop
 * use scene of child instead of active scene
 * poll to check if parent and child are in same scene

OUTLINER_OT_parent_clear
 * get scene from child instead of only working on active scene
 * poll to check if no parent

OUTLINER_OT_scene_drop && OBJECT_OT_make_links_scene
 * memory leak on error
 * would only link some objects on error
2012-05-29 18:12:13 +00:00
e0c2ddb886 OUTLINER_OT_scene_drop -- "Drag object to scene in Outliner" operator
Refactored the two (well, three now) other places where an object is linked to a scene into ED_object_scene_link()
2012-05-29 08:20:11 +00:00
2ab62ce126 code cleanup: defines with braces - end with '(void)0' so callers must end with ';' like normal function.
... without this some editors dont parse the source so well.
2012-05-27 12:21:13 +00:00
857dedbc58 style cleanup 2012-05-27 00:36:50 +00:00
54b64cfd61 code cleanup: use const float and define array size 2012-05-26 22:21:56 +00:00
ebdeed07e5 Delete skin customdata if all skin modifiers are removed.
Fix for bug [#31604] "Skin Modifier - Mark Root Bug?"

Essentially the same as multires customdata deletion.
2012-05-26 21:11:23 +00:00
49b6867e0c previous commit didnt build - add back enum and note that its a copy because of linking error 2012-05-26 00:41:11 +00:00
6dcef66468 code cleanup: remove duplicate enum 2012-05-26 00:06:30 +00:00
ad65b7b86b Animation playback: now all windows are update during playback, rather than
just the active window.
2012-05-25 12:37:11 +00:00
19e1d05461 Modifications to the view3d.select() operator:
1. Two new boolean options have been added to the operator: "deselect"
   and "toggle".
2. The previous behavior of "extend" (toggling the selection) has
   been moved to the "toggle" option.
3. "extend" now only extends the selection, it never deselects.
4. "deselect" is pretty self-explanatory: it deselects (i.e. opposite
   of extend).
5. The built-in keymap has been changed to use "toggle" where
   "extend" was used before for this operator, to maintain the
   previous behavior in the default keymap.

In short, this works towards making "extend" and "deselect" fully
consistent across all selection tools (adding to and removing from
selection, respectively), but still preserves the old behavior
as well.

(Patch reviewed by Brecht.)
2012-05-24 21:05:27 +00:00
f16f545c6e style cleanup
also fix example for mesh uv's
2012-05-22 16:24:09 +00:00
3fc3c9f3b4 style cleanup: relating to skin modifier 2012-05-22 16:09:31 +00:00
45265b326a Add operator to extract armature and vertex groups from skin.
* The operator creates bones for each input edge (does not subdivide
  them like the skin operator does), adds a fake root bone for skin
  roots with multiple children.

* The operator adds vertex weight groups to the original mesh.

* Make copy_object_transform() public, used to match the armature
  object to the mesh object.

Skin modifier documentation:
http://wiki.blender.org/index.php/User:Nicholasbishop/SkinModifier
2012-05-22 15:29:57 +00:00
11309a19e2 Add skin vertex operators.
* Add operator to mark selected vertices as skin roots.
* Add operator to mark/clear selected vertices as loose.
* Add operator to equalize skin radii.

Skin modifier documentation:
http://wiki.blender.org/index.php/User:Nicholasbishop/SkinModifier
2012-05-22 15:29:44 +00:00
0cdd5892fa Ensure skin nodes get created when adding modifier.
Skin modifier documentation:
http://wiki.blender.org/index.php/User:Nicholasbishop/SkinModifier
2012-05-22 15:29:37 +00:00
acd468f2b3 Fix #31500: Displacement Baking from Multires doesn't work
Issue was caused by wrong calculation of grid coordinates when switching
from low resolution mesh to high resolution mesh. Somehow was affected only
for face U or V equals to 1.0f.

Checked fix using all test files used during initial implementation of
multires baker and tested sample file from bug/ Seems everything is OK.
2012-05-22 07:06:48 +00:00
2d2d36fe3b code cleanup:
- style - multi-line ifs move braces onto new lines.
- iterators - convert some to macros, other split up and move brace.
2012-05-20 19:49:27 +00:00
5d92564041 use utf8 functions for new modifier names 2012-05-20 18:19:45 +00:00
c464654f5e Fix memory leak when trying to apply transformations to shared meshes 2012-05-20 11:06:46 +00:00
af3e348430 code cleanup: use TRUE/FALSE rather then 1/0 for better readability, also replace do prefix with do_ for bool vars. 2012-05-19 13:28:19 +00:00
f9043865a2 Disable setting non-object actions as the action used by the Action Constraint
(... I could've sworn there used to be some dynamic enums for filtering actions
by root type)
2012-05-17 10:28:30 +00:00
9dd981a440 style cleanup: block comments 2012-05-16 23:37:23 +00:00
ed33320e3f Code cleanup: simplify standard GHash creation.
Added four new functions as shortcuts to creating GHashes that use the
standard ptr/str/int/pair hash and compare functions.

GHash *BLI_ghash_ptr_new(const char *info);
GHash *BLI_ghash_str_new(const char *info);
GHash *BLI_ghash_int_new(const char *info);
GHash *BLI_ghash_pair_new(const char *info);

Replaced almost all occurrences of BLI_ghash_new() with one of the
above functions.
2012-05-16 00:51:36 +00:00
f964292630 fix geometry to origin in mesh editmode - was broken since bmesh merge. 2012-05-13 11:14:43 +00:00
305d341ec2 code cleanup: use vector math function minmax_v3v3_v3() and other minor vector function edits. 2012-05-13 11:05:52 +00:00
ce17c35240 style cleanup: mainly sculpt/whitespace 2012-05-11 08:05:47 +00:00
c9c0bfeeb8 Ensure mask layers are always present in sculpt mode. 2012-05-10 20:34:35 +00:00
f751d0f6ae Replace hardcoded DMGridData structure with CCGElem/CCGKey.
* Changes to DerivedMesh interface: DMGridData has been removed,
  getGridData() now returns an array of CCGElem pointers. Also added
  getGridKey() to initialize a CCGKey (implemented only by
  CCGDerivedMesh.)

* PBVH: added BLI_pbvh_get_grid_key().

* A lot of code is affected, but mainly is just replacing
  DMGridData.co, DMGridData.no, and sizeof(DMGridData) with the
  CCG_*_elem functions, removing the reliance on grid elements of
  exactly six floats.
2012-05-10 20:33:09 +00:00