Commit Graph

63597 Commits

Author SHA1 Message Date
Sergey Sharybin
48ed9fcb78 Fix memory leak in point density
The issue was happening when having unconnected point density which
will cache data but will not free it because there's no actual call
to the actual sampling.

Now the idea is to make sure cache is zeroed on file load and undo
and then caching via RNA will free the data if any exists. This could
leave us with a single copy of cache in the node if it's not used,
but it's quite small amount of memory and it's not leaking.
2016-02-23 12:01:16 +01:00
Campbell Barton
9c68ffc3b4 UI: disable undo for cycling render slot
This wasn't working and used extra undo steps.
2016-02-23 20:59:51 +11:00
Sergey Sharybin
90e9da423b CMake: Enable BLOSC for OpenVDB for the full config
This will respect the official build configuration where we should
have BLOSC enabled.

We can't really detect if OpenVDB was compiled with BLOSC or not,
so seems we can't really avoid this extra flag.
2016-02-23 09:48:47 +01:00
Sergey Sharybin
d3fa1bd4d5 Fix warnings reported by MSVC
Mainly it's related on a bad practice in SDL to force-define __SSE__
and __SSE2__ flags which generates quite some warnings and causes too
much noise.

There are some other warnings fixed. Should be no functional changes.

NeXyon, please check the changes in audaspace :)
2016-02-23 09:44:54 +01:00
Campbell Barton
073ce98231 Fix white balance sequencer modifier
- division often visibly clipped channels.
- division by zero caused NAN pixel values.
2016-02-23 14:54:42 +11:00
f5872d2747 Fix T47531: crash with particle roughness curve mapping, after fix for T46382. 2016-02-23 04:22:13 +01:00
Campbell Barton
e4e21480d6 Fix button display clamping values
Displaying a button would clamp the value if the button was outside the range.
This could be OK in some cases,
however it's problematic with object dimensions which would re-scale objects on showing the panel.

Add `ui_but_update_edited` when its OK to modify the value.
2016-02-23 10:15:36 +11:00
Campbell Barton
adab35ba02 Fix T47529: Selecting paths makes them relative
When selecting file-paths from the interface, initialize the 'Relative' setting from existing paths.
2016-02-23 06:39:34 +11:00
Campbell Barton
2a3bd4621b Sculpt: use Ctrl to set grab/sculpt normal-weight
Having to change this with the slider each time isn't so convenient
and invert in this case does nothing.
2016-02-23 06:21:14 +11:00
Campbell Barton
f8ee24b1a8 Sculpt: apply grab normal-weight to snake-hook 2016-02-23 06:04:23 +11:00
Campbell Barton
1e98435c85 Sculpt: Enable original-normal for grab brush
Without this, grabbing with normal weight will continually select new normals
based on where you move the cursor,
causing the normal location to flicker in a way which isn't controllable in any useful way.
2016-02-23 05:27:13 +11:00
Campbell Barton
36e732c89f Sculpt brush can now grab inwards w/ normal weight
Previously the grab brush could only move ourwards when normal aligned.
2016-02-23 05:04:32 +11:00
Campbell Barton
37915e0b79 Don't draw object center when outside the view 2016-02-23 03:24:30 +11:00
Campbell Barton
27f5a01056 Fix line-width (drawing hair at wrong width) 2016-02-23 02:53:22 +11:00
Campbell Barton
e3f997d47f Fix T47517: "Show Weights" edit-mode fails
Don't use materials when showing weight colors.
2016-02-23 01:24:42 +11:00
Campbell Barton
7a74738914 Fix memory leak in DM_to_mesh 2016-02-22 23:22:15 +11:00
Bastien Montagne
20104beea7 Fix T47482: take II, restore 2.76 behavior regarding groups when deleting an object.
Also re-reported through IRC by Thomas Beck (@plasmasolutions), thanks.

Though it's not ideal in theory, we have quite poor handling of object datablock currently
from user PoV - before this commit, it was not easily possible to get fully rid of an object
anymore if you did not removed it from all its groups before deleting it.

So for now, restore 2.76 behavior (namely, unlink an object from avaerything in Blender
once it is no more used by any scene).

Better handling of all this is TODO for later (also related to much more heavy changes
done in id-remap branch regarding sanitizing our ID deletion process).
2016-02-22 12:16:29 +01:00
Kévin Dietrich
9cfc203749 Compositor: fix memory leak in filter node operation.
Avoid allocating the (tiny) array on the heap in the first place.

Reviewers: sergey, lukastoenne

Differential Revision: https://developer.blender.org/D1815
2016-02-22 10:58:49 +01:00
Lukas Stockner
c359343f8d Fix T43388, fix T40369: Cycles baking not antialiasing textures.
This re-enables the AA jittering, but with proper clamping so that u >= 0,
v >= 0 and u+v <= 1.

Differential Revision: https://developer.blender.org/D1254
2016-02-21 15:10:51 +01:00
a447421dec Bake API: add assert to verify we have valid UVs. 2016-02-21 14:38:50 +01:00
a0e1e0047b Fix crash baking selected to active after recent fix for uninitialized variables. 2016-02-21 14:38:49 +01:00
Sergey Sharybin
12ca20e6c3 Attempt to fix GLog compilaton on FreeBSD
Copied some config variables from an original config file.
2016-02-21 13:40:22 +01:00
Sergey Sharybin
ae086225da Fix compositor using edge repeat policy when it shouldn't
Was easy to notice when alpha-overing smaller image with blur on
the bigger frame.
2016-02-21 13:16:56 +01:00
Campbell Barton
f6c11062bc Fix uninitialized var use initializing bake data 2016-02-21 16:20:36 +11:00
Julian Eisel
a66bc6c0f0 Correct incomplete doxgen file paths in WM 2016-02-21 02:10:29 +01:00
Gaia Clary
d2c5959834 fix T47484: Added fallback solution (copy exported file when rename is not supported) 2016-02-20 23:26:33 +01:00
Gaia Clary
4e95807db3 fix T47484: Added proper error reporting for Collada Exporter 2016-02-20 21:42:12 +01:00
Gaia Clary
edf9e8d4dc fix T47484: Added final status of exported file to Blender console 2016-02-20 20:33:42 +01:00
1b9039752a Fix unnecessary separators in image editor Image menu. 2016-02-20 20:22:51 +01:00
e608f2e7ec Fix crash enabling Use Multiview on images with an empty filepath. 2016-02-20 17:56:56 +01:00
95180a46ed Fix memory leak when saving OpenEXR half file fails. 2016-02-20 17:56:56 +01:00
Bastien Montagne
4dd406c7b7 Fix T47482: Own mistake in new handling of 'userone' ID usages when decrementing usercount.
Ended up not handling at all 'userone' case, now it increments usercount correctly when needed.
2016-02-20 16:49:44 +01:00
Sergey Sharybin
c0d43871e0 Make Blender ready for C++11
Did a full compile of debug build with C++11 enabled, it all passed compilation
apart from some deprecated type used in GE's Video Texture. Solved it inside of
ifdef block now.

In the future we should uncomment the MSVC part of it, it should all be safe and
correct (MSVC2013 does not define new C++ version but supports C++11). The reason
it is commented is to have absolutely no effect on the upcoming release.
2016-02-20 16:45:53 +01:00
Bastien Montagne
fe9b21a44a Add GHash/GSet pop() feature.
Behavior is similar to python's set.pop(), it removes and returns a 'random' entry from the hash.

Notes:
* Popping will return items in same order as ghash/gset iterators (i.e. increasing
  order in internal buckets-based storage), unless ghash/gset is modified in between.
* We are keeping a track of the latest bucket we popped out (through a 'state' parameter),
  this allows for similar performances to iterators when iteratively popping a whole hash
  (without it, we are roughly O(n!), with it we are roughly O(n)...).

Reviewers: campbellbarton

Differential Revision: https://developer.blender.org/D1808
2016-02-20 15:28:25 +01:00
Campbell Barton
90e77c871b Userpreferences Panel (for the 3DView)
This is an attempt to improve the User preferences panel for the 3DView. I made 2 changes:

- I reordered the sequence of properties by grouping them into more logical groups as it made sense to me. Please indicate where to rearrange the order if necessary.

- Then i added some changes in the code to get the groups better arranged visually. I am pretty sure that this can be done much better, more clever, more generic, whatever. This is just what i could figure out on my own so far.

Reviewers: aligorith, sergey, gaiaclary

Subscribers: sergey

Projects: #user_interface

Maniphest Tasks: T47295

Differential Revision: https://developer.blender.org/D1757
2016-02-20 14:07:20 +01:00
Sergey Sharybin
5f613f7b5d OCIO: Disable the warnings related on C4251
Those warnings are trigerred by stl classes in OCIO's public interface.

To quote MSDN: "C4251 can be ignored if you are deriving from a type in
the Standard C++ Library"

This is the only instance where those warnings hunts us, so for now we
can keep it all local in intern/opencolorio but this might be changed
in the future.
2016-02-20 14:06:11 +05:00
Sergey Sharybin
b2655167c6 GHost: Avoid macro re-definition by undefining the macro first
Should b totally harmless since the define was overriten anyway.
2016-02-20 14:06:10 +05:00
Sergey Sharybin
d9bf6b2d33 Carve: Silence 32/64 bit shit warning
There's no need to mix ints and size_t here at all
because all the values fits into integer.

It's unlikely we'll be re-bundling Carve, so didn't
bother with the patchset.
2016-02-20 14:06:10 +05:00
Sergey Sharybin
f1088bd9e1 CMake: Ignore paranoid MSVC linker warnings 2016-02-20 14:06:09 +05:00
Sergey Sharybin
ac5e989d4a Fix for NULL used instead of false 2016-02-20 14:06:08 +05:00
Sergey Sharybin
55aaa27018 Cleanup, avoid passing const pointer to MEM_freeN()
This generates warnings with MSVC. Similar typecast was
already done in other cases, so think it's all fine.
2016-02-20 14:06:07 +05:00
Sergey Sharybin
637f97b316 ImBuf: Cleanup, don't use using namespace, it's a bad practice 2016-02-20 14:06:07 +05:00
Sergey Sharybin
cfc8d80f2c ImBuf: Solve re-definition warnings
The idea now is to have FFmpeg/OIIO headers listed after
the system ones. This is because FFmpeg/OIIO might define
some constants with the same name as the ones from math.h.

FFmpeg/OIIO has ifdef around defines, but math.h doesn't
check whether constants were already defined or not, which
causes some noisy warnings.
2016-02-20 14:06:06 +05:00
Sergey Sharybin
b30ab24fb8 Cycles: Avoid re-definition of math cnstants with MSVC 2016-02-20 14:06:05 +05:00
Sergey Sharybin
aff60520bd Fix some warnings in GLog/GFlags when buildingwith MSVC2013
Those warnings were only addressed for MSVC2015 so far.
2016-02-20 14:06:05 +05:00
Sergey Sharybin
ff675f0367 CMake: Don't pass SSE2 flags in compositor for 64bit MSVC
ALl 64 bit platforms supports SSE2, hence the flag is ignored
and warning was generated.
2016-02-20 14:06:04 +05:00
Bastien Montagne
8132553553 Fix (unreported) crash when ungrouping a nodegroup with some animated node.
Was accessing already freed action in temp nodegroup animation data...
2016-02-20 13:15:40 +01:00
Joshua Leung
028c67c81e Fix T44453: Exporting Keying Sets referencing node tree properties generates invalid Python code/paths
The problem is that node trees (such as the Material, Lamp, and Compositor node trees)
are stored as "nested node trees" on the affected datablocks. They are particularly
troublesome to deal with, as the are not easily identified, and also cannot be easily
mapped back to the ID's which actually own them. As a result, the usual automated
methods do not work when dealing with these!
2016-02-20 17:55:11 +13:00
Joshua Leung
6c02c5fb09 Fix T47433: Driven shapekey values (from 2.4x) are not indicated as having drivers
Only Driver FCurves with named shapekeys (instead of shapekey indices) was
getting picked up by the UI code for testing whether a property had drivers
or not. So, while this version patching code worked when it was initially
written for the 2.4x -> 2.5 transition, some subsequent changes ended up
breaking this. As this stuff is not used often, the breakage wasn't noticed.
2016-02-20 17:55:11 +13:00
Joshua Leung
86c55a18e5 Fix T47492: Name is not displayed for newly renamed FCurve, when the path was broken
Thanks Alexander Romanov (a.romanov) for the fix!
2016-02-20 17:55:10 +13:00