blender.git
7 years agoruler tweak: don't, snap to edit-object, because it didnt work well when modifiers...
Campbell Barton [Thu, 25 Apr 2013 11:46:07 +0000 (11:46 +0000)]
ruler tweak: don't, snap to edit-object, because it didnt work well when modifiers are applied in editmode.

7 years agoruler snapping
Campbell Barton [Thu, 25 Apr 2013 10:14:19 +0000 (10:14 +0000)]
ruler snapping
- draw snap circle to make it more obvious when snapping succeeds.
- when not in wire-view, snap to the surface when adding new rulers.

7 years agoBugfix [#35075] Physics Panel of Particles Fluid is Truncated
Joshua Leung [Thu, 25 Apr 2013 10:05:49 +0000 (10:05 +0000)]
Bugfix [#35075] Physics Panel of Particles Fluid is Truncated

Some RNA Properties were not updated in UI scripts after a recent refactoring
there removing "use_" prefix from some of the boolean properties (strangely
though, while every other property attached to SPHFluidSettings.flag has gone
from "use_factor_blah" to "factor_blah", use_factor_density still keeps the old
prefix).

7 years agoruler snap adjustments
Campbell Barton [Thu, 25 Apr 2013 09:39:03 +0000 (09:39 +0000)]
ruler snap adjustments
- when in wireframe mode: don't snap to faces, instead snap to the closest edge/vertex.
- when not in wireframe mode: snap to the front-most element (was a problem that it could snap to an edge/vert behind the face)
- reduce the distance for selecting ruler points, was too easy to accidentally drag a ruler.

7 years agofix [#35072] View name of 3Dview is clamped in Japanese
Campbell Barton [Thu, 25 Apr 2013 08:13:46 +0000 (08:13 +0000)]
fix [#35072] View name of 3Dview is clamped in Japanese
just increase size of string to allow for utf8 chars.

7 years agoFix #29932 Left Shift + Numpad 1,2,3 not Aligning to Active
Francisco De La Cruz [Thu, 25 Apr 2013 05:32:32 +0000 (05:32 +0000)]
Fix #29932 Left Shift + Numpad 1,2,3 not Aligning to Active

Intermediate Shift+Key messages were resetting modifier flags.

7 years agoFix build error with scons + msvc, needs pthread include.
Brecht Van Lommel [Thu, 25 Apr 2013 00:06:43 +0000 (00:06 +0000)]
Fix build error with scons + msvc, needs pthread include.

7 years agoFix two more high DPI / retina draw issues with running jobs in info header and
Brecht Van Lommel [Wed, 24 Apr 2013 23:09:29 +0000 (23:09 +0000)]
Fix two more high DPI / retina draw issues with running jobs in info header and
the node tree name in the node editor.

7 years agoFix #34806: rigid body world settings were not copied with a full scene copy.
Brecht Van Lommel [Wed, 24 Apr 2013 23:09:25 +0000 (23:09 +0000)]
Fix #34806: rigid body world settings were not copied with a full scene copy.

Now copying a scene will also duplicate groups that consist entirely of objects
that are duplicated with the scene. The rigid body world will then also pointers
to these new groups.

7 years agoFix crash going to a scene with no camera, with an inactive 3D viewport space.
Brecht Van Lommel [Wed, 24 Apr 2013 23:09:22 +0000 (23:09 +0000)]
Fix crash going to a scene with no camera, with an inactive 3D viewport space.

The regions of the space are stored in a different place depending if it is
active or if another space is in use. The code here was iterating over both
but it should be only one because the other might contain regions of another
space.

7 years agoFix rigid body world Solver Iterations not showing in UI and throwing python error.
Brecht Van Lommel [Wed, 24 Apr 2013 23:09:19 +0000 (23:09 +0000)]
Fix rigid body world Solver Iterations not showing in UI and throwing python error.

7 years agominor fixes
Campbell Barton [Wed, 24 Apr 2013 20:19:01 +0000 (20:19 +0000)]
minor fixes
- build with netbsd works again.
- select uv more/less was crashing when called outside image space.
- node RNA property update was crashing when not called in node space.

7 years agoFix #34714: cycles viewport render would restart when minimizing and unminimizing
Brecht Van Lommel [Wed, 24 Apr 2013 20:12:12 +0000 (20:12 +0000)]
Fix #34714: cycles viewport render would restart when minimizing and unminimizing
a maximized Blender window in Ubuntu Unity. The window size would slightly change
as part of the unminimize effect.

Now cycles waits 0.2 seconds before restarting rendering after a viewport resize,
also a bit less flickery when changing the 3d view size in Blender itself.

7 years agoFix cycles build error, RNA C++ API did not properly handle output parameters.
Brecht Van Lommel [Wed, 24 Apr 2013 19:21:18 +0000 (19:21 +0000)]
Fix cycles build error, RNA C++ API did not properly handle output parameters.

7 years agoFix flickering black tiles in preview render, after viewport render commit, it's
Brecht Van Lommel [Wed, 24 Apr 2013 19:21:16 +0000 (19:21 +0000)]
Fix flickering black tiles in preview render, after viewport render commit, it's
nicer when the new preview draws over the old one.

The code was changed so that the render result is freed all the time because
freestyle manipulates render layers. Now it only does it when freestyle is
enabled so cycles and regular blender internal can still avoid it.

7 years agoFix blender internal preview rendering continuously restarting after recent
Brecht Van Lommel [Wed, 24 Apr 2013 19:21:14 +0000 (19:21 +0000)]
Fix blender internal preview rendering continuously restarting after recent
viewport render changes.

Actually was an older issue that would cause unnecessary preview render restarts
if the render result was not allocated before it was drawn. Now the render result
is being reallocated each time for freestyle which made the issue worse.

7 years agorna api function scene.ray_cast now returns the object and its matrix (incase its...
Campbell Barton [Wed, 24 Apr 2013 17:49:13 +0000 (17:49 +0000)]
rna api function scene.ray_cast now returns the object and its matrix (incase its a dupli).

7 years agoFix #34783: smoke simulation crash when changing frame while preview rendering.
Brecht Van Lommel [Wed, 24 Apr 2013 17:31:09 +0000 (17:31 +0000)]
Fix #34783: smoke simulation crash when changing frame while preview rendering.

Added a mutex lock for smoke data access. The render was already working with a
copy of the volume data, so it's just a short lock to copy things and should not
block the UI much.

7 years agoFix #35068: bpy.ops.node.output_file_add_socket() now works on the active node
Brecht Van Lommel [Wed, 24 Apr 2013 16:59:56 +0000 (16:59 +0000)]
Fix #35068: bpy.ops.node.output_file_add_socket() now works on the active node
if there is no "node" in the context, for scripting convenience.

7 years agoFix for #34739 and #35060, avoid ambiguity in compositor viewer nodes.
Lukas Toenne [Wed, 24 Apr 2013 16:36:50 +0000 (16:36 +0000)]
Fix for #34739 and #35060, avoid ambiguity in compositor viewer nodes.

The design changes coming with pynodes for the node editor allow editing multiple node groups or pinning. This is great for working on different node groups without switching between them all the time, but it causes a problem for viewer nodes: these nodes all write to the same Image data by design, causing access conflicts and in some cases memory corruption. This was not a problem before pynodes because the editor would only allow 1 edited node group at any time. With the new flexibility of node editors this restriction is gone.

In order to avoid concurrent write access to the viewer image buffer and resolve the ambiguity this patch adds an "active viewer key" to the scene->nodetree (added in bNodeTree instead of Scene due to otherwise circular DNA includes). This key identifies a specific node tree/group instance, which enables the compositor to selectively enable only 1 viewer node.

The active viewer key is switched when opening/closing node groups (push/pop on the snode->treepath stack) or when selecting a viewer node. This way only the "last edited" viewer will be active.

Eventually it would be nicer if each viewer had its own buffer per node space so one could actually compare viewers without switching. But that is a major redesign of viewer nodes and images, not a quick fix for bcon4 ...

7 years agoFix #35008: compositing nodes viewer border (ctrl + B) not working correct inside...
Brecht Van Lommel [Wed, 24 Apr 2013 15:39:19 +0000 (15:39 +0000)]
Fix #35008: compositing nodes viewer border (ctrl + B) not working correct inside node groups.

7 years agoallow to scale and rotate from edge/vertex slide.
Campbell Barton [Wed, 24 Apr 2013 15:15:01 +0000 (15:15 +0000)]
allow to scale and rotate from edge/vertex slide.

7 years agofix for crash changing transform modes rotate/edge-slide/grab. setCustomPoints()...
Campbell Barton [Wed, 24 Apr 2013 15:06:42 +0000 (15:06 +0000)]
fix for crash changing transform modes rotate/edge-slide/grab. setCustomPoints() assumed allocated member was big enough which wasnt the case when switching from rotate.

7 years agoFix #35063: GLSL texture node Value output was not outputting alpha.
Brecht Van Lommel [Wed, 24 Apr 2013 15:05:43 +0000 (15:05 +0000)]
Fix #35063: GLSL texture node Value output was not outputting alpha.

7 years agoFix material node editor not working when Blender Game is selected as render engine.
Brecht Van Lommel [Wed, 24 Apr 2013 15:05:40 +0000 (15:05 +0000)]
Fix material node editor not working when Blender Game is selected as render engine.

7 years agouse more rna-constant name for bevel clamping.
Campbell Barton [Wed, 24 Apr 2013 14:14:54 +0000 (14:14 +0000)]
use more rna-constant name for bevel clamping.

7 years agofix relating to r56260, when in vertex paint mode the mesh would have tessfaces alloc...
Campbell Barton [Wed, 24 Apr 2013 13:53:09 +0000 (13:53 +0000)]
fix relating to r56260, when in vertex paint mode the mesh would have tessfaces allocated, which prevented baking from updating vertex colors.
baking now clears tessfaces.

7 years agofix glitch where vertex baking wouldn't always refresh the mesh.
Campbell Barton [Wed, 24 Apr 2013 13:12:29 +0000 (13:12 +0000)]
fix glitch where vertex baking wouldn't always refresh the mesh.

7 years agoFix bug #34611: bevel overlap limit
Howard Trickey [Wed, 24 Apr 2013 12:39:37 +0000 (12:39 +0000)]
Fix bug #34611: bevel overlap limit
The previous fix limited overlap, but is sometimes
too conservative, and artists want way to turn off
the limiting, so added 'Allow Overlap' option to
modifier.

7 years agofix [#34657] Smoothing will not be updated in object mode, when hiding faces in edit...
Campbell Barton [Wed, 24 Apr 2013 12:07:13 +0000 (12:07 +0000)]
fix [#34657] Smoothing will not be updated in object mode, when hiding faces in edit mode and changing shape.
remove the option to skip hidden faces in BM_mesh_normals_update, use openmp to speedup recalculation for high poly meshes.

7 years agofix for mistake in own recent commit r56249 with rna_EffectorWeight_path
Campbell Barton [Wed, 24 Apr 2013 07:40:55 +0000 (07:40 +0000)]
fix for mistake in own recent commit r56249 with rna_EffectorWeight_path

7 years agosimple optimizations for bvhtree_from_mesh_faces() for editmesh, was quite inefficien...
Campbell Barton [Wed, 24 Apr 2013 00:25:12 +0000 (00:25 +0000)]
simple optimizations for bvhtree_from_mesh_faces() for editmesh, was quite inefficient (unneeded loops, not breaking out of face loop early).
also correct own oversight - use TRANSFORM_DIST_MAX_RAY rather then when checking for max value in snapDerivedMesh.

7 years agoFix for broken Material color/alpha/thickness modifiers.
Tamito Kajiyama [Wed, 24 Apr 2013 00:14:16 +0000 (00:14 +0000)]
Fix for broken Material color/alpha/thickness modifiers.
Reverted part of the trunk revision 56234 (RNA attribute consistency edits).

7 years agoalternate fix for [#24887] - r33294.
Campbell Barton [Tue, 23 Apr 2013 23:57:27 +0000 (23:57 +0000)]
alternate fix for [#24887] - r33294.

Casting a ray onto an editmesh was building a derivedMesh, raytree, then freeing for every ray-cast.
Noticed while using ruler+snapping in editmode.

Instead of attempting to align the MFace and edit-mesh tessfaces, just use editmesh for ray-casting.

7 years agoFix for full-sample anti-aliasing (FSAA) not working with Freestyle.
Tamito Kajiyama [Tue, 23 Apr 2013 22:40:13 +0000 (22:40 +0000)]
Fix for full-sample anti-aliasing (FSAA) not working with Freestyle.

Reverted the trunk revision 56136 and part of revision 56127 concerning the local Main
for Freestyle and temporary scene generation for stroke rendering.

The function do_merge_fullsample() in pipeline.c has access to the Scene of each Render,
so that the temporary Scene generated by Freestyle has to be kept for FSAA even after
stroke rendering has been done.  By the same token, the local Main has been moved from
the BlenderStrokeRenderer class to Render.  It is noted that free_all_freestyle_renders()
in pipeline.c is intended to get the temporary Scene of each Render released specifically
taking account of the FSAA case.

7 years agouse string escaping when renaming animation paths - BKE_animdata_fix_paths_rename()
Campbell Barton [Tue, 23 Apr 2013 20:24:10 +0000 (20:24 +0000)]
use string escaping when renaming animation paths - BKE_animdata_fix_paths_rename()

7 years agofix [#34958] keyframe many items would fail if there was a (") in the text.
Campbell Barton [Tue, 23 Apr 2013 20:10:22 +0000 (20:10 +0000)]
fix [#34958] keyframe many items would fail if there was a (") in the text.

7 years agoAnother little fix for #35010. Added better labeling for node groups, so it's possibl...
Lukas Toenne [Tue, 23 Apr 2013 17:49:26 +0000 (17:49 +0000)]
Another little fix for #35010. Added better labeling for node groups, so it's possible to see which node group type the sockets in the node tree view belong to. Otherwise would be virtually impossible to use it.

7 years agoremove negated string macros from BLI_utildefines.h, were unused and can just use...
Campbell Barton [Tue, 23 Apr 2013 16:27:45 +0000 (16:27 +0000)]
remove negated string macros from BLI_utildefines.h, were unused and can just use !STREQ(...)

7 years agoStrip unneeded folders and files from numpy
Sergey Sharybin [Tue, 23 Apr 2013 15:51:41 +0000 (15:51 +0000)]
Strip unneeded folders and files from numpy

7 years agofix [#34894] Ruler/Protractor: While it's active, one can open the file browser for...
Campbell Barton [Tue, 23 Apr 2013 15:42:41 +0000 (15:42 +0000)]
fix [#34894] Ruler/Protractor: While it's active, one can open the file browser for file saving + Crash

7 years agoBuildbot tweaks
Sergey Sharybin [Tue, 23 Apr 2013 15:29:39 +0000 (15:29 +0000)]
Buildbot tweaks

Add numpy installation to blender player configuration,
this is so because player is building first and it installs
python, which prevented numpy installation from blender
configuration.

7 years agofix [#35055] Crash in Edit Source feature for multilevel menus
Campbell Barton [Tue, 23 Apr 2013 15:22:22 +0000 (15:22 +0000)]
fix [#35055] Crash in Edit Source feature for multilevel menus
dont show the option when operating on a menu since its not supported.

7 years agofix for issues with ruler
Campbell Barton [Tue, 23 Apr 2013 14:58:23 +0000 (14:58 +0000)]
fix for issues with ruler
- disabling ruler snap wasn't setting the points depth back to its previous value before snapping.
- adding a new ruler uses the depth of the previous active ruler (fallback to view center as before)
- deleting the ruler now sets the prev/next ruler active.

7 years agoFix #35058: Mesh > Edge/Face > Bevel would do vertex bevel if that was used in
Brecht Van Lommel [Tue, 23 Apr 2013 14:12:12 +0000 (14:12 +0000)]
Fix #35058: Mesh > Edge/Face > Bevel would do vertex bevel if that was used in
the operator the previous time. However for these menus it makes more sense to
always use edge/face bevel and to leave vertex bevel for Mesh > Vertex > Bevel.

7 years agominor changes to get numpy working with locally bundled python.
Campbell Barton [Tue, 23 Apr 2013 13:51:20 +0000 (13:51 +0000)]
minor changes to get numpy working with locally bundled python.
- enable site-packages for bundled python distrobution, py3.2 had a problem where it would try to parse headers we didnt include, but its resolved now.
- workaround for glitch I was having on arch-linux where lib64 would be be used for the bundled python directory when it was just a symlink.

7 years agoFix missing feature: fit mask stencil to aspect.
Antony Riakiotakis [Tue, 23 Apr 2013 11:34:18 +0000 (11:34 +0000)]
Fix missing feature: fit mask stencil to aspect.

7 years agoFix issue reported by Campbell: Move texture existence check out of loop
Antony Riakiotakis [Tue, 23 Apr 2013 11:02:36 +0000 (11:02 +0000)]
Fix issue reported by Campbell: Move texture existence check out of loop
and exit ovelay display early. Avoids possible garbage value reading.
Thanks!

7 years agoedit to r56235, min/max are common abbreviations used in rna.
Campbell Barton [Tue, 23 Apr 2013 10:28:13 +0000 (10:28 +0000)]
edit to r56235, min/max are common abbreviations used in rna.

7 years agoAdded registerable size properties for node types in RNA. This allows pynodes to...
Lukas Toenne [Tue, 23 Apr 2013 09:51:32 +0000 (09:51 +0000)]
Added registerable size properties for node types in RNA. This allows pynodes to define min/max and default width for nodes. Height is also registerable, but will be ignored for the standard node layout doable with pynodes atm (height is calculated automatically based on sockets and extra buttons). It might be usable in the future, for now just added for completeness.

7 years agorna attribute consistency edits, use common prefix for booleans.
Campbell Barton [Tue, 23 Apr 2013 07:06:29 +0000 (07:06 +0000)]
rna attribute consistency edits, use common prefix for booleans.

7 years agostyle cleanup
Campbell Barton [Tue, 23 Apr 2013 05:29:06 +0000 (05:29 +0000)]
style cleanup

7 years agoBugfix [#34869] Switching actions does not trigger animation refresh
Joshua Leung [Tue, 23 Apr 2013 01:54:29 +0000 (01:54 +0000)]
Bugfix [#34869] Switching actions does not trigger animation refresh

Changing actions via RNA (or apparently from the Action Editor browse menu too)
didn't perform all the necessary updates/tagging/recalc needed to have the
results of the new action get immediately applied in the 3D view. This caused
problems for exporters, as the first frames exported would be incorrect (though
this could probably be worked around by manually stepping the current frame
forward one frame then back again).

7 years agoAllow hiding separate hiding of overlays on stroke.
Antony Riakiotakis [Tue, 23 Apr 2013 00:32:51 +0000 (00:32 +0000)]
Allow hiding separate hiding of overlays on stroke.

7 years agoAdd stencil control for mask overlay. Key combinations are the same as
Antony Riakiotakis [Tue, 23 Apr 2013 00:06:22 +0000 (00:06 +0000)]
Add stencil control for mask overlay. Key combinations are the same as
regular stencil but use Alt as well, so Alt-Rclick is translation, Alt-
clamping to avoid scaling of stencil to zero.

7 years agofix for UI annoyance with popups (such as new image popup) opening their menus to...
Campbell Barton [Mon, 22 Apr 2013 22:32:42 +0000 (22:32 +0000)]
fix for UI annoyance with popups (such as new image popup) opening their menus to the right of the button.

7 years agoOverlay fixes:
Antony Riakiotakis [Mon, 22 Apr 2013 22:20:38 +0000 (22:20 +0000)]
Overlay fixes:

* Clobbering enum
* Cursor overlay not dependent on mapping (again!)
* Brush overlay not updating when size is tweaked

7 years agoFix #35056: crash running bpy.ops.transform.rotate() in background mode.
Brecht Van Lommel [Mon, 22 Apr 2013 21:27:44 +0000 (21:27 +0000)]
Fix #35056: crash running bpy.ops.transform.rotate() in background mode.

7 years agofix [#34706] Projection precision is zoom dependent
Campbell Barton [Mon, 22 Apr 2013 21:13:30 +0000 (21:13 +0000)]
fix [#34706] Projection precision is zoom dependent
ED_view3d_project_float functions were rounding the results.

7 years agoFix part of #34882: mesh active face not drawing stippled with the mirror modifier.
Brecht Van Lommel [Mon, 22 Apr 2013 21:12:11 +0000 (21:12 +0000)]
Fix part of #34882: mesh active face not drawing stippled with the mirror modifier.

7 years agoFix silly mistake, cursor overlay does not depend on any brush texture
Antony Riakiotakis [Mon, 22 Apr 2013 21:10:50 +0000 (21:10 +0000)]
Fix silly mistake, cursor overlay does not depend on any brush texture
mapping

7 years agofix/workaround [#34983] bpy.ops.mesh.primitive_torus_add() ignores rotation-parameter
Campbell Barton [Mon, 22 Apr 2013 20:53:30 +0000 (20:53 +0000)]
fix/workaround [#34983] bpy.ops.mesh.primitive_torus_add() ignores rotation-parameter

7 years agoOverlay refactor:
Antony Riakiotakis [Mon, 22 Apr 2013 20:46:18 +0000 (20:46 +0000)]
Overlay refactor:

Allow separate control for tex/mask/cursor overlay. This commit implements
separate overlays for mask textures and cursor curves. The user can turn on
and off separate parts of the overlay by using the appropriate widgets.
The cursor overlay widgets are located at the tool selection panel

Also fixed alpha masks not getting correctly masked and mask texture mapping
not having the correct update callback

7 years agofrom bug report [#34984] bmesh.ops.recalc_face_normals() ignores use_flip=True
Campbell Barton [Mon, 22 Apr 2013 20:15:42 +0000 (20:15 +0000)]
from bug report [#34984] bmesh.ops.recalc_face_normals() ignores use_flip=True

the name `use_flip` is misleading, option in fact tags faces that have been flipped, rename to `use_face_tag`

7 years agofix [#35007] clipping border error
Campbell Barton [Mon, 22 Apr 2013 20:00:37 +0000 (20:00 +0000)]
fix [#35007] clipping border error
add clip option to ED_view3d_win_to_ray(), ED_view3d_win_to_segment()

7 years agoadd clip_segment_v3_plane_n() to clip a line segment to planes (as used for view...
Campbell Barton [Mon, 22 Apr 2013 19:39:10 +0000 (19:39 +0000)]
add clip_segment_v3_plane_n() to clip a line segment to planes (as used for view clipping).
use in ED_view3d_win_to_segment_clip() and fix error, was clipping by only 4 planes rather then 6.

7 years agocode cleanup: remove duplicate function _det_m3(), clip_line_plane was copying a...
Campbell Barton [Mon, 22 Apr 2013 18:32:06 +0000 (18:32 +0000)]
code cleanup: remove duplicate function _det_m3(), clip_line_plane was copying a vector for no reason.

7 years agoYet another Stupid Stub Fix™!
Bastien Montagne [Mon, 22 Apr 2013 17:51:08 +0000 (17:51 +0000)]
Yet another Stupid Stub Fix™!

7 years agofix for scaling on individual center in mesh editmode when the object has non-unit...
Campbell Barton [Mon, 22 Apr 2013 16:46:37 +0000 (16:46 +0000)]
fix for scaling on individual center in mesh editmode when the object has non-unit matrix. (own error when adding support for axismtx in editmode)

7 years agoNicer registration mechanism for node categories. The lists of node categories and...
Lukas Toenne [Mon, 22 Apr 2013 16:25:35 +0000 (16:25 +0000)]
Nicer registration mechanism for node categories. The lists of node categories and items are now stored in a dictionary with an identifier key, so they can be registered and unregistered individually. The Add menu is now persistent and gets extended with a draw function for each of the registered node category lists.

This allows pynodes to define their own list of node categories and items and register it at runtime without interfering with the standard nodes.

7 years agofix own mistake updating edge slide, even edge-slide was broken
Campbell Barton [Mon, 22 Apr 2013 16:07:50 +0000 (16:07 +0000)]
fix own mistake updating edge slide, even edge-slide was broken

7 years agoFix part of #34746: crash importing certain collada files with armatures. It still
Brecht Van Lommel [Mon, 22 Apr 2013 15:49:15 +0000 (15:49 +0000)]
Fix part of #34746: crash importing certain collada files with armatures. It still
imports the armature wrong though.

7 years agotweak to vertex slide drawing, reduce line alpha, could cover vertex and make it...
Campbell Barton [Mon, 22 Apr 2013 15:13:47 +0000 (15:13 +0000)]
tweak to vertex slide drawing, reduce line alpha, could cover vertex and make it hard to see whats happening.

7 years agoFix #35051: when viewing a complex node setup in the material properties, the
Brecht Van Lommel [Mon, 22 Apr 2013 15:03:19 +0000 (15:03 +0000)]
Fix #35051: when viewing a complex node setup in the material properties, the
properties were continuously redrawing, which slowed down everything else.

The problem was integer overflow, with a short only capable of storing values
up to 32767. Note that sockets are collapsed by default since the previous
release, and that's it's not very useful to edit such complex node setups in
the properties editor, it's mainly meant for simple setups or group nodes to
present just a few sockets.

7 years agoFix #34350: Maya Keyboard map preset problems
Sergey Sharybin [Mon, 22 Apr 2013 14:56:41 +0000 (14:56 +0000)]
Fix #34350: Maya Keyboard map preset problems

Two main things:

- Made a python operator for selection in a viewport
  which will de-select everything if nothing is under
  the mouse.

  To do so needed to modify VIEW3D_OT_select, so invoke
  sets mouse location which is later used by exec
  function.

  This way it's possible to select stuff from python
  defined operator.

  Not best-ever solution since ideally exec() shall not
  do OpenGL stuff, but we've got this issue in some
  other operators. We'll solve this later.

- Used a keymap from Gianmichele Mariani as a reference,
  updated his keymap to latest changes in operators.

  We shall match Maya keymap much better now, thanks
  for the keymap dude!

7 years agoAttempt to fix #35041 and #34725: cycles crash with OSL and both a 3D viewport
Brecht Van Lommel [Mon, 22 Apr 2013 14:27:12 +0000 (14:27 +0000)]
Attempt to fix #35041 and #34725: cycles crash with OSL and both a 3D viewport
and preview running at the same time.

It seems there's something in OSL/LLVM that's not thread safe, but I couldn't
figure out what exactly. Now all renders share the same OSL ShadingSystem which
should avoid the problem.

7 years agoFix #35054: adjust tooltip for Render Border option in 3D view panel to say
Brecht Van Lommel [Mon, 22 Apr 2013 14:26:57 +0000 (14:26 +0000)]
Fix #35054: adjust tooltip for Render Border option in 3D view panel to say
it has an effect outside of the camera view.

7 years agoBugfix [#34836] Crash when driver variable has path == 'data'
Joshua Leung [Mon, 22 Apr 2013 13:22:07 +0000 (13:22 +0000)]
Bugfix [#34836] Crash when driver variable has path == 'data'

Most of the places which relied on RNA_path_resolve() did so believing that if
it returned true, that it had found a valid property, and that the returned
pointer+property combination would be what the path referred to. However, it
turns out that if the property at the end of the path turns out to be a
"pointer" property (e.g. "data" for Object.data), this would automatically
become the pointer part, while the prop part would be set to null. Hence, if a
user accidentally (or otherwise) specifies a path for the single-property driver
variable type like this, then Blender would crash.

This commit introduces two convenience functions - RNA_path_resolve_property()
and RNA_path_resolve_property_full() - which mirror/wrap the existing
RNA_path_resolve() functions. The only difference though is that these include a
check to ensure that what was found from resolving the path was in fact a
property (they only return true iff this is the case), and make it explicitly
clear in the name that this is what they will do so that there's no further
confusion. It is possible to do without these wrapper functions by doing these
checks inline, but the few cases that had been patched already were pretty
hideous looking specimens. Using these just make it clearer and simpler for all.

I've also beefed up the docs on these a bit, and changed these to using bools.

7 years agofix [#35026] Curve build modifier
Campbell Barton [Mon, 22 Apr 2013 12:00:37 +0000 (12:00 +0000)]
fix [#35026] Curve build modifier

7 years agoFootage information panel
Sergey Sharybin [Mon, 22 Apr 2013 11:19:12 +0000 (11:19 +0000)]
Footage information panel

Displays such information as current frame dimension,
frame number within image sequence/movie and in case
of image sequence input displays current file name of
a frame.

Not entirely happy with such approach, but was requested
a lot by artists.

7 years agoSupport more mapping modes for alpha masks. Tiled, stencil and random
Antony Riakiotakis [Mon, 22 Apr 2013 10:46:01 +0000 (10:46 +0000)]
Support more mapping modes for alpha masks. Tiled, stencil and random

7 years agoFix #35037: Compositor: MultilayerEXR + undo loses image. Crash when selecting in...
Sergey Sharybin [Mon, 22 Apr 2013 10:08:58 +0000 (10:08 +0000)]
Fix #35037: Compositor: MultilayerEXR + undo loses image. Crash when selecting in Image Editor

Issue was cause dby ima->ibufs being stored in a ma on
undo/redo and ima->rr not. In case of multilayer image
ibufs hares pointer with render result, so current
undo/redo policy lead to a dead pointer stored in ibuf.

Made it so ima->rr also stores in the map and restores
on redo/undo keeping all the pointers fine.

7 years agoFix #35039: two other issues with curve caps
Sergey Sharybin [Mon, 22 Apr 2013 09:26:02 +0000 (09:26 +0000)]
Fix #35039: two other issues with curve caps

- Skip filling caps if spline is cyclic
- Use hard limit of 1024 for curve resolution

7 years agoUpdate Ceres to current upstream version
Sergey Sharybin [Mon, 22 Apr 2013 09:25:37 +0000 (09:25 +0000)]
Update Ceres to current upstream version

This brings a fixes for threading issue in BLAS
making BA step more robust (there were some in-detemrinacy
caused by this threading issue).

Also brings some optimizations, which does not directly
affect on blender.

7 years agofix for error in own recent changes to vertex weight drawing in editmode.
Campbell Barton [Mon, 22 Apr 2013 06:16:03 +0000 (06:16 +0000)]
fix for error in own recent changes to vertex weight drawing in editmode.
where disabling show_weight, the colors would still draw.

7 years agorevision r56196 adding uv select more/less used 4 nested 'for' loops,
Campbell Barton [Mon, 22 Apr 2013 06:02:30 +0000 (06:02 +0000)]
revision r56196 adding uv select more/less used 4 nested 'for' loops,
rewrite to use only 2.

also use generic, reusable functions for selection flushing so each operator doesn't need to implement its own.
and merge more-less operation into the same function, just call the selection flush function with select/deselect arg.

7 years agoremove unneeded null checks from commit r56194, also minor style cleanup.
Campbell Barton [Mon, 22 Apr 2013 03:08:56 +0000 (03:08 +0000)]
remove unneeded null checks from commit r56194, also minor style cleanup.

7 years agorigidbody: Add function to perform convex sweep test
Sergej Reich [Sun, 21 Apr 2013 19:53:40 +0000 (19:53 +0000)]
rigidbody: Add function to perform convex sweep test

This is a experimental collision detection function, so the API might
change in the future.

Note: The simulation needs to be stepped before this function can be
used, otherwise the rigid body world might not be valid.

Patch [#34989]  Bullet Convex sweep test API
by Vilem Novak (pildanovak), thanks!

7 years agoAdd Select More (ctrl np+) and Select Less (ctrl np-) to UV editor
Sv. Lockal [Sun, 21 Apr 2013 19:04:04 +0000 (19:04 +0000)]
Add Select More (ctrl np+) and Select Less (ctrl np-) to UV editor

These tools allow to extend or shrink uv selection like in edit mode, but also take selection mode, sync mode and sticky mode into account.

7 years agoFix for NULL pointer bug, reported by Jens Verwiebe in IRC. ED_node_tag_update_id...
Lukas Toenne [Sun, 21 Apr 2013 18:11:00 +0000 (18:11 +0000)]
Fix for NULL pointer bug, reported by Jens Verwiebe in IRC. ED_node_tag_update_id tries to get a node tree from the active id pointer, but this only works for standard node types, not for pynodes.

7 years agofix [#35043] Camera view breaks with multiple scenes and the "view center camera...
Campbell Barton [Sun, 21 Apr 2013 16:08:49 +0000 (16:08 +0000)]
fix [#35043] Camera view breaks with multiple scenes and the "view center camera" action.

7 years agoFix for add nodes search box showing nasty "UUUUUUUU"-like entries with some python...
Bastien Montagne [Sun, 21 Apr 2013 13:51:51 +0000 (13:51 +0000)]
Fix for add nodes search box showing nasty "UUUUUUUU"-like entries with some python builds...

Workaround for an issue with python: strings generated by py scripts should also exist in python as long as they are used in C. Else C code may access freed memory.

Simply store the generated list of items in the class, for now. :/

7 years agomissed this previous commit (r56188), using normalized angle function.
Campbell Barton [Sun, 21 Apr 2013 13:29:24 +0000 (13:29 +0000)]
missed this previous commit (r56188), using normalized angle function.

7 years agoutility function volume_tetrahedron(), for mathutils and BLI math.
Campbell Barton [Sun, 21 Apr 2013 13:24:45 +0000 (13:24 +0000)]
utility function volume_tetrahedron(), for mathutils and BLI math.

7 years agocode cleanup: avoid unneeded normalizations when joining tris -> quads, also correct...
Campbell Barton [Sun, 21 Apr 2013 13:10:05 +0000 (13:10 +0000)]
code cleanup: avoid unneeded normalizations when joining tris -> quads, also correct assert with edge-collapse-decimate.

7 years agoMinor code clean-up & removal of unused code segments.
Tamito Kajiyama [Sat, 20 Apr 2013 23:00:27 +0000 (23:00 +0000)]
Minor code clean-up & removal of unused code segments.

7 years agoFix for a crash due to uninitialized local Main (introduced in revision 56127).
Tamito Kajiyama [Sat, 20 Apr 2013 21:15:17 +0000 (21:15 +0000)]
Fix for a crash due to uninitialized local Main (introduced in revision 56127).

7 years agoRemoved the group_tree_idname property from node types. This was a bit of a hack...
Lukas Toenne [Sat, 20 Apr 2013 17:57:45 +0000 (17:57 +0000)]
Removed the group_tree_idname property from node types. This was a bit of a hack to associate node group types to specific tree types for node group operators. Since the node group operators now work independent from this property (see r56183) that property is no longer needed and just pollutes the bNodeType struct.

7 years agorevert own change from 56177, game bounds can be useful to see in editmode,
Campbell Barton [Sat, 20 Apr 2013 17:24:40 +0000 (17:24 +0000)]
revert own change from 56177, game bounds can be useful to see in editmode,
also use gcc attributes for smallhash header and some style edits to recent commit.

7 years agoFix #34846, Node->Ungroup menu entry is broken. The standard node group operators...
Lukas Toenne [Sat, 20 Apr 2013 16:50:05 +0000 (16:50 +0000)]
Fix #34846, Node->Ungroup menu entry is broken. The standard node group operators now don't require the node_type string property any more. They are limited to the Shader, Compositing and Texture node tree types and will pass through for other (pynodes) tree types. Associated node group types are hardcoded.

The original rationale for adding the node_type property was to allow node group operators work generically on any node group type automatically. The problem is that detecting the appropriate node group type and node tree type to use for a group depends on using a node base type. Due to the fact that RNA does not allow multiple inheritance (mixin classes) this is impossible to achieve if node types also have to use a base type such as ShaderNode, CompositingNode or TextureNode.

The idea is now to just "make it work" by limiting the node group operators to the standard tree types. For future pynodes we can implement these operators nicely in Python, which will allow pynodes to use mixin base classes or derive their own operator types and re-use the same keymapping.