Commit Graph

58065 Commits

Author SHA1 Message Date
Campbell Barton
483fa4c387 CMake: picky style edit
'cmake_consistency_check.py' relies on this formattng.
2015-02-19 07:15:00 +11:00
Campbell Barton
bbc7dc169d RNA: assert when non 0/1 values used as bool
Prepare for using 'bool' type.
2015-02-19 07:08:10 +11:00
Campbell Barton
86e04c4ca9 RNA: assert on over-sized array index access 2015-02-19 07:01:49 +11:00
Campbell Barton
9d464a7538 RNA: use __func__ for alloc-id's 2015-02-19 06:57:45 +11:00
Jorge Bernal
4ed8b70870 BGE: Fix T42437: Physics/Compound bug
Null check to verify that parent has a character controller. Otherwise (i.e empty) it will crash.

Reviewers: moguri, campbellbarton

Reviewed By: campbellbarton

Differential Revision: https://developer.blender.org/D1115
2015-02-18 19:59:21 +01:00
Jorge Bernal
9bd2a7c0a8 BGE: Fix T41570: Blender crash when physics createConstraint
Move physicsid type to unsigned long long to avoid crashes on Windows 8.1 64bits.
Other systems also modified to put them inline with this solution.

Reviewers: dfelinto, brita_, moguri, juicyfruit, campbellbarton

Reviewed By: juicyfruit, campbellbarton

Subscribers: juicyfruit

Differential Revision: https://developer.blender.org/D1122
2015-02-18 19:52:54 +01:00
Antony Riakiotakis
839a6b22d6 Fix T43716 regression in mask modifier - edges could access out of
bounds indices of vertices.

Issue here is that if we copy edge customdata the MEdge data that were
previously written get overwritten, solution is to write indices and
flags last (probably writing flags is superfluous here).
2015-02-18 17:59:16 +01:00
Sergey Sharybin
c9fa37fbcd Cycles: Initialize "headless" flags on engine initialization
This flag is global for all the sessions and never changes. so it doesn't
really make sense to pass it around to all sessions and synchronization
routines.

Switched to a static member of BlenderSession now, but it's probably more
logical to introduce some sort of BlenderGlobals. Doesn't currently worth
a hassle for a single boolean flag tho.
2015-02-18 21:52:51 +05:00
Thomas Dinges
6f3500db05 Cleanup: Remove unused SD_PHASE_HAS_EVAL flag.
We only have a non-singular volume closure and therefore no need to distinguish it.
2015-02-18 16:33:31 +01:00
Thomas Dinges
a2366a3a2e Cleanup for Cycles hair shader ifdefs.
sc->T and sc->data2 were behind __HAIR__ ifdef, now they are not anymore, so we can always assign the correct value.
2015-02-18 15:57:39 +01:00
Thomas Dinges
bf0a001e61 Cleanup: Remove support for Boost filesystem 2.
This is deprecated since Boost 1.48.
2015-02-18 13:49:49 +01:00
Bastien Montagne
55fd389a70 New filebrowser bookmarks: Some minor fix/optimization from latest coverity report. 2015-02-18 13:18:04 +01:00
Bastien Montagne
2967253ae4 Fix Windows build.
Mighty M$VC never heard of 'strcasecmp' family of functions, it prefers its
own names, as usual...
2015-02-18 12:22:58 +01:00
Sybren A. Stüvel
6920735cff Include SDL information in system info text.
Adds bpy.app.sdl to expose SDL version information.

When SDL is not available on a Linux system, certain Blender features
are silently disabled (like joystick support in the BGE). This change
is the first step towards making it more obvious why something isn't
working.

SDL information is exposed to Python via bpy.app.sdl, in the same way
as OCIO and OIIO information is exposed.

Generated system-info.txt contains SDL loading method (linked or
dynamically loaded by Blender) and SDL version number.

Reviewed by: sergey, campbellbarton

Differential Revision: https://developer.blender.org/D1112
2015-02-18 12:08:20 +01:00
Thomas Dinges
7f7413bce2 Cleanup: Use bools in BVHParams class. 2015-02-18 12:05:59 +01:00
Antony Riakiotakis
6fe23b60dd Use clamp to border for brushes or textures can "leak" after rotating
texture coordinates of brushes (in rake mode).
2015-02-18 11:59:55 +01:00
Joshua Leung
fda119866d GPencil: RMB menu tools in Outliner works for GP Layers now
It would be even better if these used their own dedicated menu which could include
the protect values too, but this one at least works now
2015-02-18 14:49:42 +13:00
Joshua Leung
c7c711bb72 GPencil Fix: Added checks to ensure that copy/paste doesn't paste incompatible strokes
There was a problem with the copy/paste functionality, where it would be possible to
paste 3d strokes into 2D editors, or 2D strokes into the 3D view. The problem with
that though is that these will not show up, and because there's no feedback at the
time, users may end up doing this pasting several times.
2015-02-18 14:49:41 +13:00
Thomas Dinges
bd92168643 Cycles / BVH: Remove unused temp copy of prim_object.
This will save some memory during BVH Build.
2015-02-18 01:14:59 +01:00
Campbell Barton
5eecfbd980 Quiet uninitialized mem use for blank cursor
harmless but may as well initialize.
2015-02-18 10:44:28 +11:00
Campbell Barton
1fa98b374f Fix free'd memory use removing constraint 2015-02-18 10:44:17 +11:00
Antony Riakiotakis
b337cc1c21 Do not allocate an XRay buffer if compositing is dnot one for offscreen
rendering.
2015-02-17 23:38:28 +01:00
Campbell Barton
d74189a78a cleanup & missing break 2015-02-18 09:08:24 +11:00
Sergey Sharybin
ef11be0e77 Cycles: Avoid over-allocation in decouple ray marching
It could have happened with really long rays and small steps.

Step size will be adjusted to the clamped number of steps in order
to preserve render result compatibility as much as possible.

We should probably reformulate this a bit, so it will give the
same looking results without step tweaks. But this new behavior
should already be much better that it was before.
2015-02-18 02:26:24 +05:00
Campbell Barton
a9dbaf3755 Ensure BLI_stat() return value is checked.
also add function attrs on BLI_fileops to ensure they're used correctly.
2015-02-18 07:27:27 +11:00
Bastien Montagne
e089b0e911 Amend to previous own Fix T43684: only use hack on WIN32, and use case-insensitive comparison.
Thanks to Campbell for the headup.
2015-02-17 21:10:08 +01:00
Campbell Barton
5115e86246 Fix T38808: Re-opening an image makes absolute 2015-02-18 06:39:28 +11:00
Campbell Barton
9d879c43f3 Fix T43708: Wrong manipulator in individual origin
Manipulator and actual behavior were out-of-sync with a single edge selected.
2015-02-18 06:08:59 +11:00
Campbell Barton
6133d14028 BMesh: calc_manipulator_stats can only check verts
Code assumed selection wasn't correctly flushed, which we ensure now.
2015-02-18 05:41:13 +11:00
Bastien Montagne
07ba8b96e5 Tweak to new UIList bookmarks & co: extend up to ten entries before using scrollbars.
But again, what we really need to fix is UI saving for that temp area...
2015-02-17 19:27:14 +01:00
Thomas Dinges
7e73b6aa25 Cleanup: Add comment about light_p being modified in one case. 2015-02-17 19:24:37 +01:00
Sergey Sharybin
1aa93dd9fd Cycles: Cleanup after recent changes 2015-02-17 23:21:53 +05:00
Bastien Montagne
21a2b73a1e Fix T43684 (again!): Mighty Windows thinks it’s perfectly sensible to block everyone during 5 seconds for a mere stat() call on "A:\" path...
For now, just always consider those floppy entries ("A:\" and "B:\") as valid... sigh.
2015-02-17 19:13:22 +01:00
Thomas Dinges
e6f40b4ceb Some tweaks to last commit, this is better. 2015-02-17 19:03:50 +01:00
Sergey Sharybin
f3e831f02d Cycles: Fix for hair transmission BSDF not returning proper label 2015-02-17 22:40:00 +05:00
Thomas Dinges
6f820664c4 Cleanup: Deduplicate area light sampling code. 2015-02-17 18:39:37 +01:00
Antony Riakiotakis
f05f99f9d4 Fix crash when rendering to offscreen OpenGL, fix scons build 2015-02-17 18:35:56 +01:00
Antony Riakiotakis
ff7220349d Compositing works with X-Ray.
Basically, before drawing X-Rays, we now bind a second depth buffer.
After drawing XRays, we do an extra resolve pass where we overwrite the
non-XRay depth buffer in pixels where the depth is not maximum (which
means background pixel, since depth is cleared before drawing X-Ray
objects).

This ensures both scene and X-Rays keep their depth values and are ready
for compositing. Well, the odd effect due to depth discontinuities can be
expected, and X-Rays are a bit more expensive (extra buffer + resolve pass)
but at least X-Rays won't invalidate depth values anymore. Whee!
2015-02-17 18:11:22 +01:00
Thomas Dinges
a0d7db503d Cycles: Small tweaks for Henyey Greenstein closure code.
* Avoid duplicative fabs(g) check in sample code.
* Avoid dot product in eval code.

Helps like ~1% when Scatter Anisotropy is 0.
2015-02-17 17:48:18 +01:00
Lukas Tönne
ea2fc5b9d6 Fix for particle path drawing with black tips.
The last path segment can be shortended due to randomized path length.
In that case the last segment's color vector was not defined.
2015-02-17 15:22:02 +01:00
Bastien Montagne
9b845359a6 Quick fix/hack for too small 'operator' panel in filebrowser
Real issue is that temp area used to draw modal filebrowser is never saved,
so non of UI 'edits' (like UIList resize, regions resize, panels reorder, etc.)
are ever saved. Should be addressed, but no time for that currently.
2015-02-17 15:18:02 +01:00
Joshua Leung
18e849b05d GPencil: On the fly switching between Drawing and Erasing when using "Continuous Drawing"
It is now possible to switch between drawing and erasing strokes when in
the modal "Continous Drawing" sessions. This makes the drawing experience
just a little more fluid, saving some unncessary steps to get out of
the editing mode to activate the intended tool.

TODO: Is there interest for tablet support for this too?
2015-02-18 03:16:33 +13:00
Thomas Dinges
bf878d3c3d Cycles: Remove empty closure blur code and the corresponding entries in the switch.
Most compilers will probably optimize that out, but I still don't see a reason to keep it.
2015-02-17 13:44:25 +01:00
Sergey Sharybin
4660c00ac5 Cycles: Make blender session aware of rendering from command line
This way we can do some more aggressive policy about releasing temporary
data during synchronization.
2015-02-17 16:25:16 +05:00
Sergey Sharybin
7307f3b485 Fix T43706: Creating a directory in the file browser (by typing it in the file path) crashes Blender
Issue was caused by 2e9105c, free() does nothing if pointer is NULL, but guarded
allocator expects you to not free NULL.
2015-02-17 15:55:18 +05:00
Antony Riakiotakis
2c1b0536c9 Fix T43697, grid drawing over wires and grease pencil. Props to Julian
for figuring out a simple solution to that :)
2015-02-17 11:37:20 +01:00
Sergey Sharybin
cdc1dab073 Fix T43685: New pointiness attribute error with auto-smooth enabled
Simple fix: all vertex attributes should be filled in before split.
2015-02-17 13:49:11 +05:00
Sergey Sharybin
587d8771e0 Cycles: Minor code cleanup in recent attributes changes 2015-02-17 13:46:25 +05:00
Campbell Barton
86a2e9d0e4 etch-a-ton: off by one error
was writing past the buffer when inserting strokes
2015-02-17 17:12:19 +11:00
Campbell Barton
28f31bdfd8 etch-a-ton: fix crash selecting strokes 2015-02-17 16:49:30 +11:00