Commit Graph

32771 Commits

Author SHA1 Message Date
Mitchell Stokes
ecc15e53bd Removing channel manipulation from the Action Actuator Python API since this has been broken since the animation changes from Pepper. BL_ArmatureObject.channels should be used instead. For more information see bug #28843 for more info:
http://projects.blender.org/tracker/index.php?func=detail&aid=28843&group_id=9&atid=306
2012-06-28 06:22:47 +00:00
Dalai Felinto
7016538974 bge.logic.keyboard.getClipboard() and .setClipboard methods
the idea of using methods instead of attributes is to avoid users abusing of the system calls.

Thanks Campbell Barton for reviewing and small corrections
2012-06-27 21:57:33 +00:00
Campbell Barton
a09feb7386 option so operators can be executed with undo enabled (and redo). 2012-06-27 21:41:17 +00:00
Campbell Barton
d30c7356b7 missed tiff using 150 dpi as default in previous commit, use a define now. 2012-06-27 19:28:44 +00:00
Nicholas Bishop
f57c1c8b34 Avoid adding overlapping triangles in convex hull
Add an epsilon value to the point-outside-hull test, helps when some
of the input vertices are nearly coplanar.

Fixes bug [#31941] convex hull fails (and depends on vertex order when it shouldn't)
http://projects.blender.org/tracker/index.php?func=detail&aid=31941&group_id=9&atid=498
2012-06-27 18:39:17 +00:00
Campbell Barton
32478997ec style cleanup 2012-06-27 18:29:47 +00:00
Campbell Barton
25a018fad0 change default DPI for images to 72, aparently 150 gives issues with adobe apps (which is stupid but default value isnt so important). 2012-06-27 18:11:24 +00:00
Campbell Barton
d008807a2d style cleanup: header comments, use more doxy compat formatting 2012-06-27 17:48:39 +00:00
Antony Riakiotakis
ae2f3a4e5e Fix for #31581, UVs shrink on edge slide.
Issue is that all loops of a face adjacent to the sliding verts were 
getting project-corrected. Introduced a test to only project the
affected loops. 

The projection code introduces a small offset to the boundaries so that
any boundary tests can work as expected, but this leads to shrinking of
the barycentric coordinates of the projection, causing a shrink of the
uvs in turn. This even affects the uvs that -should- be affected though
the unfixed behavior works strangely in a correctish way (my guess is
because the projection uses the same face as the opposite sliding loop).

I fixed the behaviour by taking the mean value of the uvs. This won't
support seams but current code doesn't either. Also, all CustomData to
exhibit this unfixed behaviour. I only fixed the uv case, other data
(Vcolors, etc) will have discontinuities when edge sliding. I expect
that the CorrectUV code I am working on may address some of these
issues.

Also, added NULL checks for utility function (was intended for this bug
but wasn't needed after all)
2012-06-27 17:08:12 +00:00
Antony Riakiotakis
df201548ea Utility function to get the first loop of a vert. Behaves identical to
the iterator initialization function.
2012-06-27 15:39:14 +00:00
Campbell Barton
7518654a51 add access to dissolve_limit from python. 2012-06-27 14:01:58 +00:00
Campbell Barton
78ae6ac2a5 utility function to get the points inside a list of planes. 2012-06-27 09:51:22 +00:00
Campbell Barton
9beef7442c style cleanup: also some spelling correction. 2012-06-27 05:59:41 +00:00
Campbell Barton
3e305c1018 bmesh.ops module for bmesh operator access, only remove_doubles and convex_hull at the moment. 2012-06-26 21:40:01 +00:00
Campbell Barton
200584e5c6 fix for a handful of memory leaks relating to parsing and allocating arbitrary sized vectors from python args.
Vector.dot() was always leaking memory, and would crash if args sizes didnt match.

These errors were introduced with n-dimensional vector support.

also fixed an error with bmesh py api allocation.
2012-06-26 16:58:58 +00:00
Sergey Sharybin
de00723049 Fix for crash of keying screen node in cases when there's no
triangulation generated for tracks setup
2012-06-26 15:26:16 +00:00
Campbell Barton
e32c467713 mathutils.Vector(kw=value) wasn't raising an error as it should. 2012-06-26 14:49:49 +00:00
Sergey Sharybin
00bbf5a72f Fix issue with resetting active nurb when sawing from edit mode
Issue was caused by loading editNurb into normal nurbs when saving,
this used to set active nurb to NULL.

This isn't actually needed, because active nurb would be set properly
on making editNurb and even if one accessed to active spline via PY API
when object is in object it'll be completely harmless.
2012-06-26 10:18:53 +00:00
Campbell Barton
79ab7f95f9 mask and grease pencil now display in the dope sheet summery 2012-06-26 10:14:50 +00:00
Sergey Sharybin
cd6ed0bee5 Optimization of keying screen node
When creating tile data include only triangles which have got intersection
with tile's rectangle only. This saves quite a lot of per-pixel iterations
through triangles which simply can not affect on current tile.

In fact, it's AABB check is used here. It could be improved further, but
it'll slowdown tile data generation with questionable speedup.

Another major slowdown is in fact caused by voronoi triangulation code.
Currently it's used naive algorithm which is O(N^2) where N is number
of edges. Added few euristics there and removed unused part of code, which
gave quite noticeable speedup already.

This could be improved further, but this node is not ment to be used for
lots of markers. It's also generates wrong triangulation when there're
many sites used. Need to be investigated further.
2012-06-26 09:46:24 +00:00
Campbell Barton
bf19327465 fix for checking wrong flag with removing mask shape keys doubles on the dope sheet. 2012-06-26 08:25:17 +00:00
Campbell Barton
d4cfdc69ef quiet all -Wshadow warnings in the compositor. 2012-06-26 07:32:24 +00:00
Campbell Barton
69ab13a7db rename remaining class members with m_ prefix. 2012-06-26 07:09:49 +00:00
Campbell Barton
6a1d82490e use m_ prefix for compositor class members (all compositor operations). 2012-06-26 01:22:05 +00:00
Joshua Leung
7a0ab62d3f Bugfix [#31930] DopeSheet - Grease Pencil mode collapses visible channels when
switch channel

This was caused by a typo, which would end up toggling the expanded status of
the Grease Pencil datablock (gpd->flag & 4) instead of the layer active status
(gpl->flag & 4).
2012-06-26 00:35:05 +00:00
Sergey Sharybin
01dea9ff85 Fixed crash when trying to perform transformation in Clip Editor without clip opened
Reported by JumboCoDeC in IRC. Thanks for the report.
2012-06-25 19:48:05 +00:00
Campbell Barton
4da7b7089d make hue correct grid more faded out. 2012-06-25 19:42:10 +00:00
Campbell Barton
fa0c5a100d fix for crash with blur - happened most when there was a size input, need to mutex lock before allocating the gauss array.
also add suspiciously missing call to BlurBaseOperation::initExecution, X had but Y was missing.
2012-06-25 18:01:01 +00:00
Jeroen Bakker
6badc77cb0 code cleanup 2012-06-25 17:27:54 +00:00
Jeroen Bakker
2e7f7d177a fix for [#31899] Compositor: scale to rendersize doesn't work on
separate channels
2012-06-25 17:26:18 +00:00
Campbell Barton
0ec6d28352 correct free command for an array in the compositor 2012-06-25 17:09:11 +00:00
Sergey Sharybin
c41b91f8c2 Ignore disabled markers when building keying screen. 2012-06-25 16:36:22 +00:00
Sergey Sharybin
1080c43d1c Camera solver: take track offset into account
This helps in cases when it's needed to track a feature which
goes out of screen for a while to prevent jump of camera.
2012-06-25 16:36:12 +00:00
Bastien Montagne
d68fc2b916 Fix for [#31900] Loop Selection on wireframe selects vertex behind.
Revert part of r48105 (calling mouse_mesh() in mouse_mesh_loop() is not a good idea, as it might select another element ouside the selected loop, and is anyway overkill!), added lighter code that simply checks for the nearest vertex/face of current edge.
2012-06-25 13:32:04 +00:00
Jeroen Bakker
f80d0913c6 fix for #31914 2012-06-25 12:58:53 +00:00
Brecht Van Lommel
32bf9567d3 Fix #31920: switching from cycles to blender internal with 3d view in rendered
draw mode did not draw the 3d view properly.
2012-06-25 12:13:21 +00:00
Brecht Van Lommel
3271850a2f Fix cycles not working in 3d local view, and missing update when toggling hiding
in the outliner.
2012-06-25 11:43:22 +00:00
Campbell Barton
158a70c8a3 the mutex struct seems to be different across systems, use memset rather then an initializer value.
also quiet warning in cycles.
2012-06-25 11:19:38 +00:00
Jens Verwiebe
23f632a49c Fix compile after 48262 ( braces) 2012-06-25 11:13:27 +00:00
Sergey Sharybin
1755a0ada6 Added feather control to keying node
Behaves in the same way as feather dilate/erode node, applies
after dilate/erode in node.

Also use distance dilate/erode instead of size.
2012-06-25 10:50:24 +00:00
Campbell Barton
3c8a4c458b more guardedalloc use in C++, also make compositorMutex a static var, was allocated and never freed. 2012-06-25 10:35:24 +00:00
Campbell Barton
cc0784c1b9 optionally use guarded alloc for tiles compositor, also replace allocation functions with a macro. 2012-06-25 09:14:37 +00:00
Campbell Barton
78196d60d1 comment for TODO - rgb_to_bw / rgb_to_grayscale usage. 2012-06-25 08:58:50 +00:00
Sergey Sharybin
44c82198d4 Optimization of Keying Blur operation
Separate X and Y passes of blurring like it's done for flat
gaussian blur. This reduces computing difficulty from size^2
to 2*size without any visual changes in matte.
2012-06-25 08:21:55 +00:00
Campbell Barton
15cb064e1b style cleanup 2012-06-25 07:24:48 +00:00
Nicholas Bishop
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
Sergey Sharybin
4f0551bca5 Tracking dopesheet missed tagigng for update in some cases. 2012-06-24 18:00:14 +00:00
Sergey Sharybin
93fd3f11f7 Skip edge matte operation creation if output socket is not connected. 2012-06-24 17:38:14 +00:00
Bastien Montagne
df9ca0455c Fix [#31807] Ngon triangulation error
Notes:
*This implements a quite simple algorithm, which simply checks angles (actually, absolute cosines) of created tri and remaining face (which may be a tri, quad, or more NGon), so that both are "best" (ie avoid as much as possible too much narrow/wide corners), and also checks the new edge is OK (i.e. does not goes "out" of original face).
*Incidently, it fixes a typo in that bm_face_goodline() func!
*It's quite performant (a bit quicker than previous code, as far as I have tested it) and prevent creation of completely flat triangles as much as possible, but it's far from being a "best" solution (as it is still a "progressive" one)!
*It also introduces a new math func (in BLI_math_vector.h), cos_v3v3v3, which computes cosine (ie dot product of normalized vectors) and is roughly a quicker replacement for angle_v3v3v3, when real angles are not needed.
2012-06-24 16:19:19 +00:00
Sergey Sharybin
09e31a41bf Optimization of keying screen node
Use AABB check before calculating barycentric coordinates.

In simple tests with FullHD image and 4-9 tracks used for gradient
gave 1.5-2x speedup.
2012-06-24 15:29:43 +00:00