Commit Graph

38887 Commits

Author SHA1 Message Date
Campbell Barton
36e7a98459 fix [#35007] clipping border error
add clip option to ED_view3d_win_to_ray(), ED_view3d_win_to_segment()
2013-04-22 20:00:37 +00:00
Campbell Barton
556705f84e 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.
2013-04-22 19:39:10 +00:00
Campbell Barton
bf51e80799 code cleanup: remove duplicate function _det_m3(), clip_line_plane was copying a vector for no reason. 2013-04-22 18:32:06 +00:00
Bastien Montagne
f9250ad515 Yet another Stupid Stub Fix™! 2013-04-22 17:51:08 +00:00
Campbell Barton
f09efad242 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) 2013-04-22 16:46:37 +00:00
Campbell Barton
8be5f035f4 fix own mistake updating edge slide, even edge-slide was broken 2013-04-22 16:07:50 +00:00
Brecht Van Lommel
cd7fbf9749 Fix part of #34746: crash importing certain collada files with armatures. It still
imports the armature wrong though.
2013-04-22 15:49:15 +00:00
Campbell Barton
150ce958b6 tweak to vertex slide drawing, reduce line alpha, could cover vertex and make it hard to see whats happening. 2013-04-22 15:13:47 +00:00
Brecht Van Lommel
6fb9f5bd41 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.
2013-04-22 15:03:19 +00:00
Sergey Sharybin
75f1157b80 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!
2013-04-22 14:56:41 +00:00
Brecht Van Lommel
919ecbe55d Fix #35054: adjust tooltip for Render Border option in 3D view panel to say
it has an effect outside of the camera view.
2013-04-22 14:26:57 +00:00
Joshua Leung
5580b56876 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.
2013-04-22 13:22:07 +00:00
Campbell Barton
319036f2d5 fix [#35026] Curve build modifier 2013-04-22 12:00:37 +00:00
Sergey Sharybin
1b10643920 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.
2013-04-22 11:19:12 +00:00
Antony Riakiotakis
c0eadedb70 Support more mapping modes for alpha masks. Tiled, stencil and random 2013-04-22 10:46:01 +00:00
Sergey Sharybin
53479be581 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.
2013-04-22 10:08:58 +00:00
Sergey Sharybin
f3dbfddc8a Fix #35039: two other issues with curve caps
- Skip filling caps if spline is cyclic
- Use hard limit of 1024 for curve resolution
2013-04-22 09:26:02 +00:00
Campbell Barton
a7f869df64 fix for error in own recent changes to vertex weight drawing in editmode.
where disabling show_weight, the colors would still draw.
2013-04-22 06:16:03 +00:00
Campbell Barton
6e6d00604d 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.
2013-04-22 06:02:30 +00:00
Campbell Barton
fa103d391e remove unneeded null checks from commit r56194, also minor style cleanup. 2013-04-22 03:08:56 +00:00
Sergej Reich
ed19108891 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!
2013-04-21 19:53:40 +00:00
Sv. Lockal
edab815137 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.
2013-04-21 19:04:04 +00:00
Lukas Toenne
c44888bbbe 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. 2013-04-21 18:11:00 +00:00
Campbell Barton
54c6af6016 fix [#35043] Camera view breaks with multiple scenes and the "view center camera" action. 2013-04-21 16:08:49 +00:00
Campbell Barton
d404f7fbe4 missed this previous commit (r56188), using normalized angle function. 2013-04-21 13:29:24 +00:00
Campbell Barton
c667f1ff10 utility function volume_tetrahedron(), for mathutils and BLI math. 2013-04-21 13:24:45 +00:00
Campbell Barton
1fe7657b4f code cleanup: avoid unneeded normalizations when joining tris -> quads, also correct assert with edge-collapse-decimate. 2013-04-21 13:10:05 +00:00
Tamito Kajiyama
5725be6f08 Minor code clean-up & removal of unused code segments. 2013-04-20 23:00:27 +00:00
Tamito Kajiyama
62e6d8e757 Fix for a crash due to uninitialized local Main (introduced in revision 56127). 2013-04-20 21:15:17 +00:00
Lukas Toenne
c66acbf3d9 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. 2013-04-20 17:57:45 +00:00
Campbell Barton
01f8b229c9 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.
2013-04-20 17:24:40 +00:00
Lukas Toenne
ef170c16be 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.
2013-04-20 16:50:05 +00:00
Campbell Barton
46b40e112b skip checks in statvis_calc_thickness(). also remove paranoid NULL checks in smallhash.c 2013-04-20 16:49:02 +00:00
Campbell Barton
106d41699a fix [#35025] Mesh Debug samples strange behavior 2013-04-20 16:29:37 +00:00
Campbell Barton
5999aebe4e fix for glitch in object drawing, color of texspace was last used editmode draw color.
also disable BGE bounds drawing when outside of object mode.
2013-04-20 06:22:17 +00:00
Campbell Barton
0e5d4fcd7d code cleanup: remove unused var from drawobject 'warning_recursive'. also remove unused colors from 'colortab'. 2013-04-20 05:50:22 +00:00
Sergey Sharybin
349b71fd02 Bring back support of FFmpeg >= 0.7
After planar codecs support minimal FFmpeg was
bumped to 0.10 which was not so much nice because
it was only released only later last year.

Didn't find a way to make compatibility code local
in ffmpeg_compat, so there're some ifdefs in
audaspace and writeffmpeg.

Not entirely happy, but having a bit of ifdefs in
code better than lots of real PITA for platform
maintainers.
2013-04-19 17:23:08 +00:00
Campbell Barton
1210c8493c style cleanup: edge slide 2013-04-19 15:53:24 +00:00
Campbell Barton
98ef2d1d2e uv project from camera now sets defaults so the image maps to the camera bounds,
also rename newly added `Mesh Debug` -> `Mesh Analysis`
2013-04-19 15:50:17 +00:00
Bastien Montagne
7776e7e7d8 Usual Stupid Blenderplayer Stub Fix™! :P 2013-04-19 15:46:32 +00:00
Ton Roosendaal
ed8b199ac5 UI drawing fix:
Wrongly replaced a "&" with "|" for a define. That made node headers in node editor
draw too dark. Also made header for default node not use alpha.

In general this drawing is not very good - it gets too transparent and dark.
Needs nicer AA function in interface, will be done later.
2013-04-19 15:02:37 +00:00
Gaia Clary
1c502d8316 Added minimal support for progressbar in python 2013-04-19 14:47:11 +00:00
Sergey Sharybin
1d008de24f Fix #34818: Sculpting Mode only rotates around geometry origin (bring bug back)
Made it so average coordinate of previous stroke is used as
a viewport rotation center when Rotate Around Selection is
enabled in user preferences.
2013-04-19 13:26:17 +00:00
Bastien Montagne
e430ee20d5 More fix (cleanup) to r56063: remove call to RNA_create_pointer, it has already been called by uiButGetOperatorPtrRNA() if needed.
(I thought it would also copy idproperties, but as it does not...).
2013-04-19 13:03:30 +00:00
Campbell Barton
c4dbd8bc49 fix for crash in r56063, was just missing an ID property copy (which menu does) 2013-04-19 12:14:15 +00:00
Campbell Barton
5977fa5e2b fix for bug where edge slide could set mouse start/end points to the same value - so you couldnt move the edge loop at all,
now check that the screenspace projection of the start/end points have some length and fallback to fixed offset if none do.

also rename confusingly named vars.
2013-04-19 10:23:48 +00:00
Campbell Barton
73ee226647 fix for incorrect edge slide interpolation at loop endpoings with ngons. 2013-04-19 10:04:23 +00:00
Campbell Barton
0f7fbe13ba fix [#35009] Edge/Vertex Slide issue using G-G.
add support for edge slide on boundary edge loops as well as loops with mixed in boundary faces.
2013-04-19 08:42:11 +00:00
Lukas Toenne
9f8c3783cd Fix for bug reported by Dalai Felinto on IRC, crash in blenderplayer after r56055. The ntreeUpdateTree function uses G.main, which is not defined in blenderplayer (NULL). Using G.main is in itself an ugly hack required for the node verification. Just added a sanity check for now. 2013-04-19 06:50:07 +00:00
Campbell Barton
5aef06fc04 code cleanup: edge slide, avoid building BVH tree, more logical var names. 2013-04-19 02:47:31 +00:00