Commit Graph

53118 Commits

Author SHA1 Message Date
Lukas Tönne
a7ed1db51f Fix T39319: Particle System Bug on Cycles Render.
Crashes due to bad dm face calculation in particle RNA/cycles hair.
This stuff is a total mess, but this kind of check is used in other
places and prevents crashing at least.
2014-03-25 12:34:30 +01:00
Sergey Sharybin
b7dbb2f48e Correction to the previous commit 2014-03-25 16:22:47 +06:00
Sergey Sharybin
d4cc81d552 Fix T38870: Freezes when jumping in front of a keyframe.
Issue was caused by inverting a degenerate matrix when
evaluating drivers.

Solved by using tweaked inverse code (same as used in Cycles).

Should have no affect on cases when matrix is not degenerate.
2014-03-25 16:07:13 +06:00
Campbell Barton
62a0350957 Editmode drawing: avoid glBegin/End for every tri (emDM_drawMappedFacesMat,GLSL) 2014-03-25 20:36:11 +11:00
Campbell Barton
436d6ec2e9 Code cleanup: editmode opengl drawing 2014-03-25 20:36:11 +11:00
Sergey Sharybin
cf148edb26 Followup to Ceres changes -- need to update bundling script 2014-03-25 15:08:22 +06:00
Lukas Tönne
ddc959691a Fix for own commit: mixed up ceres build defines when replacing cmake
check with a generalized macro.

rBbbfcb0b1e44636b73b8c46f1cb800fa53dda5277
2014-03-25 09:49:39 +01:00
Lukas Tönne
bbfcb0b1e4 Build file macro for testing unordered_map C++ container support.
Using unordered_map and unordered_set C++ container types currently
requires careful testing or usage of boost, due to the various confusing
C++ version differences in include paths and namespaces.

Libmv defines tests for these cases in cmake and scons, such that ceres
can use any available implementation, or fall back too std::map/std::set
if none can be found.

This patch generalizes this buildfile code by providing a Blender macro.
* cmake: defines both the variables used by libmv at them moment as well
as 2 variables UNORDERED_MAP_INCLUDE_PREFIX and UNORDERED_MAP_NAMESPACE,
which can later be used in other C++ parts for convenience.
* scons: adds a tool script returning the include prefix and namespace.
Libmv checks these to define the appropriate definitions for ceres.

Differential Revision: https://developer.blender.org/D425
2014-03-25 09:25:00 +01:00
Sergey Sharybin
6452d9f02f Fix T39395: Switching to "Textured solid" and "GLSL" view will cause the FPS drop to 0
Issue was caused by the cache limitor which was removing 4k textures from the
memory when accessing other images.

This is pretty much awful situation and solved by making it so only image sequences
and movies ace cache-guarded.

Could be optimized further so images used by viewport are not being freed, but
that's much more tricky to do..

This is a nice candidature for 'a'.
2014-03-25 12:30:41 +06:00
Campbell Barton
bd57ec686c Fix T39397: Leaving leaving camera from quadview set ortho 2014-03-25 15:14:34 +11:00
Mitchell Stokes
9d244e0ad7 Code cleanup: Removing KX_KetsjiEngine::m_drawingmode
The rasterizer is already handling this, and there is
no need to duplicate the data.
2014-03-24 20:11:11 -07:00
Mitchell Stokes
b66a9543bb Fix T38929: BGE: Strange behaving from addObject after trying to add an nonexisting overlay scene
If bge.logic.addScene() could not find the scene to add it would add the
first scene again, which is just silly. Now, if no scene is found, a warning
is printed and nothing is added.
2014-03-24 17:57:02 -07:00
Antony Riakiotakis
a2c002acb9 Add a slight shadow to the radial operator text. It helps when brush
color is close to the cursor color.
2014-03-25 01:25:01 +02:00
Campbell Barton
f0ca40f9c1 Code cleanup: function calls 2014-03-25 10:10:00 +11:00
Campbell Barton
05deec3204 Code cleanup: rename easing functions with BLI_easing_ prefix 2014-03-25 09:59:10 +11:00
Campbell Barton
673b665471 Code cleanup: rename BLI_math_easing to BLI_easing
Many hard coded values and really specific to time & keyframes.
2014-03-25 09:59:10 +11:00
Antony Riakiotakis
b701c92588 Code cleanup:
* Separate some common code for sculpt raycasting
* Cleanup to radial operator commit
2014-03-24 23:46:30 +02:00
Antony Riakiotakis
1c22ba1e0e UI naming:
Change topology panel labels to "dyntopo"
2014-03-24 23:17:29 +02:00
Campbell Barton
7bb84912ef Code cleanup: ifdef debug only checks and simplify manifold test 2014-03-25 07:54:41 +11:00
Campbell Barton
b0a8e4ced1 Fix T39262: Regression in 2.70, wire-frame editmode tool replaced all 2014-03-25 07:53:09 +11:00
Campbell Barton
25835ec977 Fix possible use of invalid face index with wireframe tool 2014-03-25 07:53:09 +11:00
Antony Riakiotakis
76d32a3f16 Improvements to radial control operator:
* Factor values get a minimum circle too, which denotes the maximum
value. This makes it easy to set the maximum value while previously
maximum was at center, much more difficult to set exactly.

* Added text indication of value at center of the widget.
2014-03-24 22:50:59 +02:00
Lukas Tönne
ff21f6aeef Fix for own mistake in rB83f2012300acadafd359307e7a00bd71e67e3fd7: used
bool instead of int.

Thanks to Campbell Barton for noticing.
2014-03-24 20:54:50 +01:00
Bastien Montagne
e9a64e2770 Fix T39392: Python bindings for geometry.box_pack_2d() return invalid total height 2014-03-24 17:39:54 +01:00
Jens Verwiebe
3b68c6304d OSX/sculpt/omp: missing initialisation of size_t pcount_len, oddly worked fine without on OSX 10.9, fixes < 10.9 2014-03-24 13:33:26 +01:00
Lukas Tönne
83f2012300 Fix T39341: Cycles Rendered view laggy while using particles.
There are a couple of bugs that come together here:
* Particle hacks: extra modifier stack evaluation just for particles in
rna_Object_create_duplilist. This is where the primary issue stems from,
the "for_render" setting replaced the G.is_rendering flag in threaded
depsgraph. This causes particles to recalculate the entire modifier
stack with _render_ settings instead of viewport settings now. Fixed by
taking the 'preview' parameter in Cycles into account.
* Buggy skin modifier: The skin modifier generates a different amount of
vertices and faces **on every execution**. This must be looked at
separately, but it could be another reason why cycles constantly
restarted the sync process.
* Particles get re-distributed randomly every time (changing seed). This
could be caused just by the broken skin modifier, but might still be an
issue when simply rendering with cycles, since the psys will be
evaluated for render settings, if just temporarily.
2014-03-24 13:10:58 +01:00
Bastien Montagne
07578bed4d Fix T39383: Blender crash when renaming bone in outliner (weight paint mode).
Outliner rename callback is supposed to activate affected element before actually renaming,
but for bones this was not working because the function used to activate the object explicitely
ignored ID_OB case! Added a bool flag to allow handing this case without (possibly) breaking
the other usecases.
2014-03-24 13:08:29 +01:00
Sergey Sharybin
f8c247f21b Remove the code which checked whether early object update skip didn't fail
Was a safety check which never triggered, so likely could be removed now.
2014-03-24 15:15:43 +06:00
Sergey Sharybin
f48828b64e Fix T39318: Blender 2.70 crash when I link an asset
Issue is a regression since threaded objetc update and caused
by the fact that some objects might share the same proxy object.

It's all fine but object_handle_update() will call update for
a proxy object which screws up threaded update.

The thing is, proxy object is marked as depending on a scene
object and such a call makes it so the children objetc is
being updated.

This is really bad and depsgraph is to take all responsibility
on updating the proxy objects.

So for now used a simple solution (which is safe to backport
to 'a') which is skipping proxy update if the scene update is
threaded and based on the DAG traversal.

There are some still areas which calls object update directly
and for that cases proxy object is still being updated from
object_handle_update().
2014-03-24 15:10:16 +06:00
Campbell Barton
b69809c820 Fix T39331: Dissolve vertex crash 2014-03-24 16:37:10 +11:00
Campbell Barton
32d5d072a0 Code cleanup: float/double promotion 2014-03-24 13:31:14 +11:00
Campbell Barton
3214d4fd5a Code Cleanup: PBVH, avoid sqrt and use bool for raycast functions 2014-03-24 13:21:58 +11:00
Campbell Barton
551d1a1ed5 Code cleanup: style 2014-03-24 13:14:19 +11:00
Campbell Barton
25b4b5fb9f Fix for invalid abs() use (from daccaa7) 2014-03-24 12:57:18 +11:00
Antony Riakiotakis
7d64054798 Change to sampling: Take biggest triangle side as detail size on
intersection, since detail determines the maximum allowed triangle edge
size
2014-03-23 21:49:01 +02:00
Bastien Montagne
7a21330421 Fix T39356: unsatisfied with uv pin unpin button, small bug 2014-03-23 14:30:10 +01:00
Thomas Dinges
d18e4cf6ee Fix typo in API documentation. 2014-03-23 12:31:08 +01:00
Thomas Dinges
8e0ee51b85 Cycles Standalone: XML Updates for Branched Path Multi Light. 2014-03-23 12:29:30 +01:00
Thomas Dinges
31cc49b5df Code cleanup: Move AA Samples variable, this is not exclusive to Branched Path. 2014-03-23 12:15:33 +01:00
Lukas Tönne
58c22d8fe8 Fix T39351: Blender crashes when enabling Mesh Analysis.
This code was using a //const// char array for fallback colors and then
writing to it (hidden to the compiler by explicit casting). Bad!
2014-03-23 11:37:04 +01:00
Bastien Montagne
4c73001093 Fix T39353: Make Single User menu entries do not work correctly. 2014-03-23 11:33:40 +01:00
Bastien Montagne
fcaa018249 Fix T39347: Pressing backspace during empty number input for translation results in 0.5828 increments
Interesting one, took me hours to understand the issue - a stupid typo checking the wrong value against the wrong flag (present since 2008!).
2014-03-23 10:59:52 +01:00
Bastien Montagne
3bad243cb8 Further tweaking to numinput - enhance 'Reset' behavior.
Ways how it was resetting its values (backspace) was far from satisfaying. Now, e.g. when scaling, it will reset at 1 (or whatever mouse-value it was before entering numinput), instead of some ugly 0.0 value.

Implementation details:
* Values passed to applyNumInput() are stored as default ones (val_org), if it is not EDITED.
* applyNumInput() returns a boolean saying whether it actually set values or not.
* When backspace hits its ultimate step (where it clears all EDITED flags and reset all default values),
  it sets a temp FAKE_EDITED flag that will be used to apply one last time values of numinput
  (so that default values actually get applied!).

There are important things to note here for code using numinput:
* Values passed to applyNumInput() should be valid and are stored as default ones (val_org), if it is not EDITED.
* bool returned by applyNumInput should be used to decide whether to apply numinput-specific post-process to data.
* *Once applyNumInput has been called*, hasNumInput returns a valid value to decide whether to use numinput as drawstr source or not.

Those two steps have to be separated (so do not use a common call to hasNumInput() to do both in the same time!).
2014-03-23 09:29:04 +01:00
Antony Riakiotakis
c359de2c3a Use eyeliner cursor for sampling. Thanks to Thomas Beck for the
suggestion :)
2014-03-23 00:33:55 +02:00
Antony Riakiotakis
97e26494ee Slight cosmetic improvement on UI. Add eyedropper icon to detail sample
operator and move it next to the detail slider
2014-03-23 00:01:46 +02:00
Antony Riakiotakis
e732c5809c Detail sampling operator
Located on topology panel.

To use just click on button and click on mesh.
Operator will just use the dimensions of the triangles below to set the
constant detail setting.

Also changed pair of scale/detail size with nice separate float
percentage value.
2014-03-22 23:35:41 +02:00
Sv. Lockal
c45c472e1b Cycles: SSE optimization for line segments/ribbons hair
Gives ~11% speedup for hair.blend, ~10% for koro_final.blend

Also extract few common subexpressions in hair calculation.

Reviewed By: brecht

Differential Revision: https://developer.blender.org/D318
2014-03-23 00:45:59 +04:00
Antony Riakiotakis
0ef416722e Flood fill for dyntopo constant detail mode.
Nothing spectacular here, fill tools are easy. Just take the dyntopo
code and repeat until nothing more to do.

The tool can be located in the dyntopo panel when the dyntopo constant
detail is on.

Also added scale factor for constant detail. This may change when detail
sampling gets in, I am not very happy with having two numbers here,
still it will give some more control for now.
2014-03-22 17:47:18 +02:00
Antony Riakiotakis
1206faeb99 Warning cleanup:
* Comparison in utf detection code always failed
* Cast to integer to silence grumpy 64bit gcc
2014-03-22 14:41:38 +02:00
Jens Verwiebe
877706b8eb Cleanup: Restrict the debug -gline-tables-only to cxx_debug in cycles and spelling 2014-03-22 11:33:32 +01:00