Commit Graph

47594 Commits

Author SHA1 Message Date
Thomas Dinges
a9eccaf85e Fix for #36150, missing Preview Render Updates with Add/Remove material slot. 2013-07-17 11:02:51 +00:00
Campbell Barton
4c41ad2299 fix/resolve [#36173] Current frame doesn't update while OpenGL Rendering Animation
there was no feedback to the user about the current frame rendering, for longer renders this is no good.
2013-07-17 09:57:02 +00:00
Sergey Sharybin
30445b8252 Merging r58280 through r58329 from trunk into soc-2013-depsgaph_mt 2013-07-17 09:31:57 +00:00
Mitchell Stokes
eb21bdd249 Merging changes from trunk r58091-58323. 2013-07-17 01:40:26 +00:00
Sergey Sharybin
f2e8df2ee2 Remove workaround for draw object free
Code around draw objects became safe for threading
and no special workaround is needed in scene update
anymore.

Unused buffers will be freed next time window is
drawing. Some further tweaks maybe needed to how
buffers are freeing, but things shall work for now
nice and stable.
2013-07-16 20:11:08 +00:00
Sergey Sharybin
52c0940c6d Statistics calculation for threaded update
This commit adds per-thread statics for object
update threads which would give you information
about:

- How much objects each thread handled
- How much overall time thread spend on running
  object_handle_update.
- How long each of object_handle_update took.

Enabled by ./blender -d

The code is surrounded by ifdef, so shall be
not a problem to drop the code when we don't
need it anymore.

Also added special value for rt (debug_value)
of 13666 which switches scene update to a
single thread. Useful for benchmarking.
2013-07-16 20:11:05 +00:00
Bastien Montagne
20d6cd008b Style cleanup of UI messages.
Mostly, "weight groups" -> "vertex groups", and usual case/endpoints/typos/etc.

As a remainder, please read http://wiki.blender.org/index.php/Dev:Doc/CodeStyle#UI_Messages before writing UI messages!
2013-07-16 13:12:58 +00:00
Brecht Van Lommel
78a3c2ae57 Fix missing render info text in blender internal rendered viewport after
previous fix for checking char arrays against NULL.
2013-07-16 12:22:31 +00:00
Campbell Barton
925c5010e8 fix for checking char arrays against NULL, instead check their first character. also remove some dead code (return directly after return). 2013-07-16 11:42:07 +00:00
Campbell Barton
7430701600 correct own incorrect check bmesh edgerin subdivide, also add missing break in orthogonalize_m3 though this one wouldn't effect release builds. 2013-07-16 11:39:48 +00:00
Campbell Barton
922320f86e fix own regression [#36154] Simple deform modifier doesn't recalculate normals
get_cddm and get_dm are called within modifiers so they wont ensure normals are valid, added an arg to optionally ensure valid normals.
2013-07-16 08:24:53 +00:00
Campbell Barton
8a95fccbba fix [#36153] Crash when choosing a brush. 2013-07-16 06:49:03 +00:00
Campbell Barton
2a417a597d fix [#36155] Crash with __contains__ 2013-07-16 05:29:19 +00:00
Campbell Barton
bbc1945f36 revert part of own commit r58304, gives different behavior when de-selecting with the lasso in some cases, will look into this after release. 2013-07-16 03:41:09 +00:00
Campbell Barton
cf20aa8344 move ED_armature_edit_bone_select() into a more general utility function so view3d-select bone operators can use it and get matching selection behavior when entering editmode.
- specifically - write to the connected parents tipsel flag when setting the rootsel flag.
2013-07-16 01:49:20 +00:00
Campbell Barton
6026f133f2 fix for the tip of the bones without connected children de-selecting when entering editmode. 2013-07-16 00:40:12 +00:00
Antony Riakiotakis
e68618a5f2 Fix memory leak in BKE_mesh_vert_poly_map_create. 2013-07-16 00:34:03 +00:00
Mitchell Stokes
5ba2f4367d BGE: adding a fix so 2D filters work properly with side-by-side stereoscopic rendering. 2013-07-15 22:44:48 +00:00
Mitchell Stokes
efc4b08094 BGE: Fix for [#36023] "Objects of added scene are lit by lights of current scene" reported by Raf Colson (raco).
The material caching now keeps a cache per scene. Before materials from different scenes were sharing the same cache.
2013-07-15 22:35:09 +00:00
Sergey Sharybin
39834dbdb5 Style cleanup: task scheduler
Campbell will clean this stuff anyway, but better do it
in the branch, so trunk history would stay clean.
2013-07-15 21:51:22 +00:00
Campbell Barton
60e64bcfa7 revert part of own commit r58254, utf8 isnt stepping by 1 always so use less-than comparison. 2013-07-15 21:34:48 +00:00
Sergey Sharybin
2f0e79b684 This shouldn't have gone to svn 2013-07-15 19:18:48 +00:00
Sergey Sharybin
82570cbd47 Utility benchmarking macros
This new macros could be used to benchmark overall
execution time of some chunk of code, running in cycle.

The usage is:

  void foo(void) {
    TIMEIT_BLOCK_INIT(overall_bar);

    for (...) {
      ...

      TIMEIT_BLOCK_BEGIN(over_bar);
      bar();
      TIMEIT_BLOCK_END(oberall_bar);

      ...
    }

    TIMEIT_BLOCK_STATS(overall_bar)
  }

This would print total time which was spent on
running function bar().
2013-07-15 19:17:45 +00:00
Brecht Van Lommel
28a27e2e9d Fix text object text entry being broken after recent fix to BLI_strncpy_wchar_from_utf8.
Checked other usages of this function but they seem to be fine.
2013-07-15 19:04:49 +00:00
Sergey Sharybin
9dc2fa3e92 Merging r58266 through r58279 from trunk into soc-2013-depsgraph_mt 2013-07-15 18:48:34 +00:00
Sergey Sharybin
c8d39fb0c2 Made armatures evaluation safe(r) for threading
Apparently, some routines in armature deformation code
were using static arrays. This is probably just an
optimization thing, but it's very bad for threading.

Now made it so bbone matrices array is allocating in
callee function stack. This required exposing
MAX_BBONE_SUBDIV to an external API, This is not so
much crappy from code side, and it shall be the same
fast as before.
2013-07-15 18:46:19 +00:00
Sergey Sharybin
70de1690b8 Make lattice deform safe for threading
Lattice deformation used to store some runtime data
inside of lattice datablock itself. It's something
which is REALLY bad. Ideally DNA shouldn't contain
and runtime data.

For now solved it in a way that initialization of
lattice deform will create a structure which contains
lattice object for which deformation is calculating
and that runtime data which used to be stored in
lattice datablock itself.

It works really fine for mesh deform modifier, but
there's still runtime data stored in particle system
DNA, It didn't look something easy to be solved, so
leaving this as-is for now.
2013-07-15 18:46:15 +00:00
Sergey Sharybin
3ede7482af Make GPU buffers allocation/freeing safe for threading
Code in GPU_buffers_free was already trying to be safe
for threading, by skipping OGL calls there, but in fact
it was still buggy.

Namely, freeing was doing buffers shift in a cycle, and
if two threads will call this function shifting will go
crazy.

Now made it so GPU_buffers_alloc and GPU_buffers_free
are using mutex lock, so they're completely safe for
threading. Same goes to gpu_buffer_setup function.

It required minor functions reshuffle, so there're no
locks happening from locked thread, but it's all very
straightforward change.
2013-07-15 18:46:08 +00:00
Sergey Sharybin
1dd7156c4c Fix #36058: Displace Modifier errors using a baked Image and displace baking inconsistency between 2.67/2.68RC and previous versions
This was in fact really nasty bug, caused by multitex_nodes
function using global variable R (which is a copy of current
renderer). this variable is not initialized to anything
meaningful for until first rendering (preview or final)
happened.

Since multitex_nodes might be used outside of render pipeline,
made it so whether CM is on or off as an argument to functions
multitex_ext_safe and multitex_ext. Now multitex_nodes() is
only shall be used for stuff happening from render pipeline!

Also needed to make some changes to other places, so all the
usages of texture sampling knows for the fact whether CM is
on or off.

And one more change is related on behavior of dispalcement,
wave, warp, weightvg modifiers and smoke. They'll be always
using CM off since texture is used for influence, not for
color.

It's rather bigger patch, but it's mostly straightforward
changes, which we really need to be done.

Reviewed by Brecht, thanks!
2013-07-15 14:47:58 +00:00
Brecht Van Lommel
86ba5c4fc5 Fix #36127: 10 bit DPX render would crash when doing rendering animations from
the UI on OS X.

The problem is due to a large variable on the stack, and pthreads have a smaller
stack size than the main thread by default. On Linux the pthread stack size seems
to be 2MB, OS X 512KB and Windows 256KB - 512KB.
2013-07-15 14:33:19 +00:00
Campbell Barton
8a2a323991 fix for sequence strips being given non utf8 names, where the filepath wasn't utf8.
also correct bad assumption in BKE_image_load_exists() that all paths are relative to the current blend file.
2013-07-15 11:26:43 +00:00
Sergey Sharybin
d44fb5bd8b Merging r58196 through r58265 from trunk into soc-2013-depsgraph_mt 2013-07-15 11:25:56 +00:00
Brecht Van Lommel
abe84a4f43 Fix #36139: cycles not taking texture spacing settings into account for
generated coordinates on text objects.
2013-07-15 11:11:36 +00:00
Gaia Clary
61cb92f701 fix: #36122 Collada import - Keyframes offset after recording and playing 2013-07-15 11:01:23 +00:00
Gaia Clary
bd863ce58d Collada miport: Report 'unknown animation class' only when relevant 2013-07-15 10:50:04 +00:00
Sergey Sharybin
cd88217b98 Fix #36145: Error in inverting channels in the UV/Image Editor
Issue was caused by operator redo saving values for previous
inverted channels, meaning the same channels will be inverted
next time operator runs.

Don't think it's useful to save operator values here, since
you don;t have visual feedback about which channels were
inverted. So marked all this properties as SKIP_SAVE. Gives
much more predictable results.
2013-07-15 10:44:17 +00:00
Campbell Barton
76ccf2403a correct placement of debug memset() for DEBUG_STRSIZE 2013-07-15 09:10:51 +00:00
Campbell Barton
dc591a633e previous commit r58256, had error in editmode (somehow it worked in most tests still).
also don't decrement active indices below zero (also a problem in 2.67).
2013-07-15 09:03:28 +00:00
Campbell Barton
02ba328ca8 clang/cmake - quiet warnings for external libs and reference moto as a system include. 2013-07-15 08:26:16 +00:00
Sergey Sharybin
c0b28134cb Fix #36124: VSE - Input Color doesn't invalidate cache properly for movies
Animation structure holds some buffers inside,
so for proper cache invalidation we need to
re-open the animation.
2013-07-15 07:58:15 +00:00
Campbell Barton
dc9beee3e2 fix for error (-1 index into array) when removing customdata layers with no data, delete_customdata_layer was using layer data pointer to check weather to adjust index values (but both pointers can be NULL). Remove this code and do in customdata.c 2013-07-15 06:29:09 +00:00
Campbell Barton
bf77d35f69 fix for bad lengths being passed to string functions. 2013-07-15 05:11:14 +00:00
Campbell Barton
2b6f35d686 fix for error in string copy
- BLI_strncpy_wchar_from_utf8 wasn't NULL terminating the destination string, caused uninitialized memory use in BPY_python_start().
- BLI_strncpy_wchar_as_utf8 could write one byte past the buffer bounds.
2013-07-15 05:09:06 +00:00
Campbell Barton
02f5b0fc08 debug option (off by default), for BLI_string to help find incorrect sizes being passed in (enable in source files only) 2013-07-15 03:54:57 +00:00
Campbell Barton
a91f51b67b allow deselection when bones BONE_UNSELECTABLE flag is set (lasso/box/circle select) 2013-07-15 02:03:31 +00:00
Campbell Barton
d94fe64d72 fix [#36128] Not deselect all bone when I press the A button in edit mode 2013-07-15 01:47:01 +00:00
Campbell Barton
d4ab6f3a9e fix [#36107] Moving origin of instanced objects doesn't work properly
now use the active object first if its selected, this means when multiple instances are selected, using the active object gives a predictable outcome.
2013-07-15 01:34:59 +00:00
Campbell Barton
3c4c2478b6 fix for own regression, face index ranges still need checking in some places. 2013-07-14 23:41:33 +00:00
Campbell Barton
878608d1cf fix regression [#36141] Crash with skin and remesh modifier in edit mode. 2013-07-14 23:27:47 +00:00
Campbell Barton
9c8516703d replace strncpy with BLI_strncpy for cases we expect the string to be NULL terminated. 2013-07-14 22:08:56 +00:00