Commit Graph

53000 Commits

Author SHA1 Message Date
Brecht Van Lommel
07f4465c77 Fix scons/windows build error, missing pthreads include in blenfont for mutex. 2013-06-29 10:52:18 +00:00
Campbell Barton
32d5b52f59 re-arrange '--help' output into more useful sections (added debug, python).
also minor style cleanup
2013-06-29 10:09:15 +00:00
Gaia Clary
b70c844c5f fixed a compiler warning message in vs 2008 2013-06-29 08:41:20 +00:00
Gaia Clary
23d3c64b59 fixed Blender crash, but unclear when this situation can happen 2013-06-29 08:38:17 +00:00
Sergey Sharybin
11972c0d82 Towards threaded object update
This commit contains changes related on running function
BKE_object_handle_update_ex from multiple threads in order
to increase scene update time when having multiple
independent groups of objects.

Currently this required changes to two areas:

- scene.c, where scene_update_tagged_recursive is now using
  threads for updating the object

  There're some tricks to prevent threads from being spawned
  when it's not needed:

  * Threading will only happen if there're more than one CPU
    core.

  * Threading will happen only if there're more than single
    object which needed to be updated.

  There's currently one crappy part of the change: which is
  freeing object caches (derivedFinal, derivedDeform and so)
  from main thread. This is so because in case VBO are used
  freeing DM is not thread safe. This is because DrawObject
  used global array. Would look into possibility of making
  that code safe later.

  There're also currently some ifdef-ed debug-only code, which
  helps a lot troubleshooting whether everything is working
  fine. This code looks a bit ugly now, will either drop it
  later or make it more cleat.

  And one more thing: threaded update is CURRENTLY DISABLED.
  This is because of some thread-unsafe issues discovered
  while was working on this patch. Namely:

  * I have once a crash in Curve module. Wasn't been able
    to reproduce the crash, but could thing about some
    unsafe code there.

  * Virtual modifier list is not thread-safe (it uses static
    variables).

  * Armature modifier is also doesn't seem to be thread safe
    because of storing some temporary runtime data in actual
    armature.

  All this issues are to be solved next.

- depsgraph.c, where i've added a function which gives list
  of groups, each group contains objects and dependency is
  only allowed between objects inside one group.

  This is needed to make scheduling of objects easier, which
  means update threads will operate on groups, and will handle
  objects one-by-one inside group. Different threads will
  operate on different groups.

  Currently such groups will be generated on every update.
  Actually, on every run of scene_update_objects_threaded which
  only happens if there're objects marked for update. In the
  future we could consider storing such groups in graph itself,
  which will help saving CPU power on building such groups.
  But this is something to be discussed with Joshua first.

P.S. If you really want to test threaded update, you'll
     need to replace:

       #undef USE_THREADED_UPDATE

     with:

       #define USE_THREADED_UPDATE
2013-06-28 21:58:56 +00:00
Sergey Sharybin
f934825a4e Allow some operators when interface is locked
Now it's possible to mark operator as safe to be used
in locked interface mode by adding OPTYPE_ALLOW_LOCKED
bit to operator template flags.

This bit is completely handled by wm_evem_system, not
with operator run routines, so it's still possible to
run operators from drivers and handlers.

Currently allowed image editor navigation and zooming.
2013-06-28 21:58:52 +00:00
Sergey Sharybin
02483146ee Code cleanup: replace bunch of ifdef+if(do_debug_handler) with
a macro which checks all the stuff and keeps code easy to follow.
2013-06-28 21:58:48 +00:00
Campbell Barton
62ab3baea4 replace LATTICE_PT macro with BKE_lattice_index_from_uvw(). 2013-06-28 21:24:38 +00:00
Campbell Barton
f55ef8b3fc fix regression since early 2.5x, there was no way to copy library linked objects. 2013-06-28 19:33:58 +00:00
Campbell Barton
24e8f2f4ce fix for crash linking fonts to other objects with linked obdata (link, undo would crash). 2013-06-28 18:39:39 +00:00
Campbell Barton
b6ffc681b1 view-selected didnt work for metaballs in object mode (radius from previous commit was 2x too large too). 2013-06-28 18:19:55 +00:00
Brecht Van Lommel
77e0709e48 Fix #35551: the topology mirror setting affected shape key and vertex group but
this was confusing as there was no setting visible for it. Now these menus
contain an entry to mirror without and with topology mirror.
2013-06-28 17:13:09 +00:00
Campbell Barton
5d413b523a fix for crash when setting the cursor in background mode. 2013-06-28 16:37:39 +00:00
Campbell Barton
86515e5086 test operator script, add ability to load files from a path while testing operators. 2013-06-28 16:30:34 +00:00
Campbell Barton
8b96383b8f fix [#35860] crash if pressing <F8> in import dialog
disallow reloading scripts while running modal, python operators.
2013-06-28 16:15:44 +00:00
Brecht Van Lommel
dc85135045 Fix #35412: blender internal "from dupli" texture coordinates not working with
particles in linked groups.
2013-06-28 16:06:55 +00:00
Gaia Clary
9e709d82ae changed Pulldown box label for clarity 2013-06-28 15:12:54 +00:00
Brecht Van Lommel
e5f23c00c1 Fix: blender internal transparent shadows were not influenced by object color alpha. 2013-06-28 15:00:05 +00:00
Brecht Van Lommel
a7e7b69a65 Fix #35902: build navigation mesh crash with multiple meshes selected. 2013-06-28 14:15:14 +00:00
Brecht Van Lommel
c57d9cc44b Fix #35900: image editor save multilayer EXR was not using the compression
codec specified by the user.
2013-06-28 13:13:45 +00:00
Brecht Van Lommel
0d7dbbb6e1 Fix #35884: crash opening .blend with generated color grid image and preview render.
Printing text on the color grid image would initialize font glyphs from a thread at
the same time as the UI, causing conflicts. The freetype glyph renderer needs to be
mutex locked because it uses a shared buffer internally even when rendering for
different fonts. Also needed to change the image generate function to use the render
monospace font to avoid conflicts in blenfont.

What's still weak in the blenfont API is that there is no distinction between a font
and a thread using that font to render with some particular size, style, etc.
2013-06-28 13:05:15 +00:00
Campbell Barton
ca33bea285 view-select wasn't working for metaballs. 2013-06-28 06:54:49 +00:00
Campbell Barton
3370b765ec fix [#35901] Hooks on armature bones are calculated in wrong space 2013-06-28 06:00:38 +00:00
Campbell Barton
aa9ffc0bc2 avoid crashes running screendump and screen editing operators in background mode. (not that these would be useful but better not crash) 2013-06-28 05:39:05 +00:00
Brecht Van Lommel
6d400423f9 Fix #35808: blender internal viewport with freestyle would keep continuously
rerendering for no reason.

Update tags were not being done in the proper Main database.
2013-06-27 22:13:40 +00:00
Campbell Barton
eba9b4f6c1 fix for out of bounds read in BLI_path_rel 2013-06-27 20:47:59 +00:00
Campbell Barton
d1f4827a40 IK plugin range check was wrong, could do out of bounds reads. 2013-06-27 19:52:50 +00:00
Gaia Clary
e2e487a877 Fix: Check for locked Vertex Group (returned true where false was expected) 2013-06-27 18:23:03 +00:00
Campbell Barton
73fcfd8651 fix for memory leak in vgroup_copy_active_to_sel 2013-06-27 17:11:23 +00:00
Thomas Dinges
4a113cab0a Merged revision(s) 57768-57827 from trunk/blender into soc-2013-dingto 2013-06-27 16:16:54 +00:00
Thomas Dinges
c6ce8de20e Code cleanup / Cycles:
* Some cleanup for castings.
2013-06-27 15:48:16 +00:00
Campbell Barton
00d9344719 correct previous startup.blend - r57698 (which disabled cycles by accident).
also correct sequencer grid theme color.
2013-06-27 15:40:32 +00:00
Brecht Van Lommel
4d5fffa1a9 Fix #35809: dragging a non-active node in the node editor did not work reliably.
Disabled timer events from the properties editor were cancelling gestures.
2013-06-27 15:07:27 +00:00
Brecht Van Lommel
2403a23953 Fix #35802: searchbox menu not opening when opened from a popup near the bottom
of the window.
2013-06-27 14:30:26 +00:00
Thomas Dinges
ee85587a43 Blender 2.68 Release maintenance:
* Update readme and release-log links to 2.68.
2013-06-27 11:30:53 +00:00
Brecht Van Lommel
fcea195baa Fix a few DPI/retina scaling issues in the graph editor and movie clip editor.
Patch #35889 by David Jeske.
2013-06-27 11:29:53 +00:00
Sergey Sharybin
f7216eda79 Merging r57729 through r57815 from trunk into soc-2013-depsgraph_mt 2013-06-27 09:07:19 +00:00
Campbell Barton
d665c46a64 fix [#35884] evil bge.types.BL_Shader.setUniformMatrix3() 2013-06-27 07:49:20 +00:00
Gaia Clary
763a737fcc Changed Tool Tip for clarity 2013-06-27 07:03:40 +00:00
Gaia Clary
821c02ddb7 Added checks to Vertex Groups panel to respect locked Vertex Groups 2013-06-27 06:33:01 +00:00
Campbell Barton
35e92f54a1 make screenshot poll for background mode. 2013-06-27 06:21:10 +00:00
Campbell Barton
929bba2bac fix for crash reading from a freed scene when exiting blender. 2013-06-27 06:16:31 +00:00
Campbell Barton
d574fb95ad fix for recently added active-vertex weight operators crashing on lattice objects in edit mode. 2013-06-27 05:39:02 +00:00
Campbell Barton
ff39d7b4bf fix for incorrect selection when running MESH_OT_loop_to_region, running wire-frame operator directly after would crash. 2013-06-27 05:19:25 +00:00
Campbell Barton
3f2ecdcd42 use common suffix's for exec/poll functions in recently added vertex-group operators. 2013-06-27 04:41:04 +00:00
Campbell Barton
603258d763 fix for zero length normalize before scanfill for meshes and other minor changes. 2013-06-27 04:32:44 +00:00
Campbell Barton
3ff36f928c 3d text tool - 'insert lorem' was crashing, also add this to the text menu. 2013-06-27 04:18:01 +00:00
Campbell Barton
f3b7a49d5b fix for old bug, select more in a nurbs surface would crash (under allocing). 2013-06-27 03:57:59 +00:00
Campbell Barton
bb42703ea3 - remove edge collapse loop operator (now replaced by dissolve).
- fix missing null pointer check from own recent changes.
- add asserts if BLI path functions are given wrong id's
2013-06-27 01:10:19 +00:00
Campbell Barton
46808dd22c fix for python api bug: assigning the wrong size array to an RNA property wasn't checking the length and could crash, eg:
mesh.polygons[0].vertices = (10,)
2013-06-27 01:01:11 +00:00