Commit Graph

65149 Commits

Author SHA1 Message Date
Sergey Sharybin
d3d1313ca4 Cycles: De-duplicate more checks around light emisive meshes
Once again, should be no functional changes.
2016-07-28 12:28:31 +02:00
Sergey Sharybin
87717c6449 Cycles: De-duplicate check for MIS shaders in meshes
Should be no functional changes.
2016-07-28 12:27:05 +02:00
Sergey Sharybin
aaac4e965e Cycles: Add some extra logging for light debugging 2016-07-28 12:13:11 +02:00
Sergey Sharybin
402d4ea0b6 DupliObject: Remove unused and confusing index argument from the context 2016-07-28 10:49:31 +02:00
Campbell Barton
3673a5adba Curve Fitting: Use normalized projection function 2016-07-28 18:33:14 +10:00
Campbell Barton
5ecc6a824a Fix T48404: Translate fails w/ snap orientation option
Rotate the object around the snap-target so it meets the snap-point.
2016-07-28 18:16:31 +10:00
Campbell Barton
8df5f97c2c Cleanup: unused transform member 2016-07-28 18:16:31 +10:00
Bastien Montagne
d66a27de2e Fix T48961: Material slots become easily desynced over linked duplicates.
Own mistake in recent changes (split to test_object_materials()/test_all_objects_materials()).
2016-07-28 09:23:46 +02:00
Campbell Barton
d60acd0e94 Fix crash fitting single point curve 2016-07-28 14:37:55 +10:00
Mitchell Stokes
3a4c307652 Use COMPAT_ENGINES instead of RenderEngine.use_game_engine for panel poll methods
This mostly affects physics panels. Any engines relying on
RenderEngine.use_game_engine flag to show/hide panels will need to be
updated. The COMPAT_ENGINES technique is how we usually deal with this.
One issue with use_game_engine is that I cannot find a way to set it; it
appears only the BGE can set it. This means (without this commit)
external RenderEngines cannot get rid of the default physics panels.

The RE_GAME flag (the C flag behind use_game_engine) is pretty hacky
and we should look into removing its usage where possible.
2016-07-27 19:00:35 -07:00
Campbell Barton
a27acefd0c Fix T48951: Crash refreshing some popups
Fix for T48874 caused popups to be tagged to be refreshed, that didnt support it.

Tag popups that can't be refreshed.
2016-07-28 11:16:11 +10:00
Julian Eisel
8f16181e9c Add comments on behavior of spacedata and regionbase lists 2016-07-28 02:36:12 +02:00
Julian Eisel
c59b21feec Fix own mistake from c05363e8895
Didn't know slink->regionbase is removed when area is active. Don't see why this is done, but it's confusing :S
2016-07-28 02:27:39 +02:00
b645e7081d Fix T48790: Cycles render bug with zero strength lights. 2016-07-27 23:09:38 +02:00
Julian Eisel
c05363e889 Fix crash closing Blender while in rendered local view
Happens because it was always using regionbase of active/visible area, not the correct one of the (possibly inactive) 3D view. Was pretty hidden because you had to be in local view to trigger it.
Could also remove ScrArea * argument from SpaceType.id_remap now, but leaving in there to avoid bigger changes (might also be useful for some case).

Steps to reproduce:
* Default startup.blend
* Enter local view with default cube (/-key)
* Render (or open a different editor where the 3D View is)
* Close Blender - should invoke crash
2016-07-27 21:05:44 +02:00
Julian Eisel
4559229163 Fix memory leak when closing Blender with operator popup open
Steps to reproduce:
* Default startup.blend
* RMB-Click on "Cube" item in outliner
* Select Remap Users
* Close Blender using window 'x' button
2016-07-27 19:45:43 +02:00
Sergey Sharybin
e4646c52c0 Fix T48946: Blender+Tahiti+DRI3+Unity+Linux GUI corruption/not rendering
Enable triple buffer by default for AMD cards on opensource driver.

Should be safe now, since it was only old cards causing problems,
which we don't support now most likely anyway.
2016-07-27 16:06:18 +02:00
Lukas Stockner
25bd01f2f7 Avoid creating multiple outputs connected to the same socket when creating a node group
This patch fixes the annoyance that when creating a node group where one of its nodes is connected
to several other nodes, a separate output will be created for each link, even though they're all
connected to the same socket in the group.
Now, before adding an output for an outgoing link, the existing outputs are checked to find whether
any output is already connected to the same socket. If such an output is found, it is reused instead of
creating a new one.

Reviewers: Severin

Subscribers: Blendify

Differential Revision: https://developer.blender.org/D1836
2016-07-27 15:56:48 +02:00
Alexander Gavrilov
d7bd64df5d Fix T48061: Crash with adaptive domain and cases when there's no smoke 2016-07-27 15:40:32 +02:00
Sergey Sharybin
ae881ddf43 Fix T48760: Changing Renderlayer Compositor node Layer does not update enabled outputs until script is finished 2016-07-27 15:17:15 +02:00
Sergey Sharybin
2e38c07e48 Cycles: Style, placement of asteric in pointers
Seems we are using `void *` much much more often in Cycles.
2016-07-27 14:10:09 +02:00
Sergey Sharybin
183874841b Cycles: Some minor tweaks to emission sharder
- Nodification of shader nodes changed default strength from 10 to 1.
  If that was intentional, IMO should happen as a separate commit.

- Fixed indentation.
2016-07-27 14:05:22 +02:00
Sergey Sharybin
5f95ffe350 Fix T48829: Memory leak on Blender Exit
It was possible to have missing outlink but GPUNodes in material.
2016-07-27 10:59:09 +02:00
Sergey Sharybin
3d8c2e25a3 Fix T48950: Movie Clip mode segfaults
Missing linking code in blenloader.
2016-07-27 10:18:54 +02:00
Julian Eisel
24b8e781f6 Correct UI names of ID types
Also correct typo.
2016-07-26 20:25:55 +02:00
Julian Eisel
3c59a5068f More useful block name for report popup blocks
Report popups simply reuse popup menu code, so their blocks got "UI_popup_menu_begin" assigned as name, which was a bit misleading. Now uses "UI_popup_menu_reports".
Ideally they'd have their own popup code.
2016-07-26 20:25:55 +02:00
Alexander Gavrilov
c1fd97f15d Fix T45936: invalid cycles motion blur for particle rotation and children.
Commit rB709ca0ece changed how rotation was handled for particles so
that unless actual rotation physics is enabled, there is no rotation.
However it only updated ptcache_particle_read, forgetting to change
exactly the same code in ptcache_particle_interpolate.

This means that for subframes old code that computes a rotation from
velocity is used, resulting in completely different rotation than for
integer frames. This causes rotational motion blur by itself, and also
mangles motion blur paths of child particles.

Reviewers: sergey, lukastoenne

Maniphest Tasks: T45936

Differential Revision: https://developer.blender.org/D2124
2016-07-26 18:06:42 +02:00
Bastien Montagne
f3f10e4515 Fix T48813: Custom icon is not drawn on header / addons prefs panel.
For now use 'brute force' and refresh whole UI when new icons get rendered.

See comment of T48813 for ideas about how to handle that in future (2.8 project ?).
2016-07-26 17:55:18 +02:00
Sergey Sharybin
f31f740bd0 Cycles: Proper fix for buffer overflow in volume intersect all 2016-07-26 17:16:23 +02:00
Sergey Sharybin
7030794171 Cycles: Revert previous fixes to intersect_all functions
While they prevent legit write past the array boundary error
those fixes introduced regression in behavior when having exact
max_hits transparent intersections and nothing else.

Previous code would have considered such case a totally opaque,
but it's not correct.

Fixes T48941: Some materials don't get transparent shadows anymore
2016-07-26 17:16:23 +02:00
Bastien Montagne
b91aea6096 Fix issues in ID usages checks - we are not interested in self-usages here.
Drivers or constraints referencing self object could break deletion of proxy objects
(due to their ambiguous, half-local, half-linked status).
2016-07-26 15:12:43 +02:00
Sergey Sharybin
01e3141ce6 Fix T48902: MCE Dopesheet does not respect Left Click select
Make the operator consistent with animation dopesheet now.
2016-07-26 14:39:06 +02:00
Sergey Sharybin
711d3a8a2b Depsgraph: Use proper check whether ID is an object
Fixes bug which resulted in making it so layers from all
layers are getting updated.

Reported by Juan Pablo Bouza.
2016-07-26 10:49:54 +02:00
Sergey Sharybin
40a0fa8a8f Depsgraph: Use proper unsigned int bitfield for layers flags 2016-07-26 10:45:07 +02:00
Campbell Barton
eececb0d80 Curve Drawing: use more closely spaced samples
Re-fitting makes better use of more samples.
2016-07-26 06:43:59 +10:00
Campbell Barton
4da8543d0d Resolve undefined M_PI w/ MSVC2013 2016-07-26 05:28:13 +10:00
Campbell Barton
6e131ce075 Call to python3 for stand-alone scripts
Needed since Debian & FreeBSD both move away from keeping a synlink to `python`.
2016-07-26 05:18:00 +10:00
Sergey Sharybin
1ea410c559 OpenSubdiv: Fix opensubdiv option obscuring the interface 2016-07-25 18:36:14 +02:00
Bastien Montagne
1870e166de Cleanup: factorize the 'ensure local' part of datablock copy into a single BKE_id_copy_ensure_local function. 2016-07-25 16:16:35 +02:00
Lukas Stockner
d9cc3ea2c6 Cycles: Fix rays parallel to the surface in the triangle refine and MultiGGX code
In the triangle intersection refinement code, rays that are parallel to the triangle caused a divide by zero.
These rays might initially hit the triangle due to the watertight intersection test, but are very rare - therefore, just skipping the refinement for them works fine.

Also, a few remaining issues in the MultiGGX code are fixed that were caused by rays parallel to the surface (which happened more often there due to smooth shading).
2016-07-25 16:14:25 +02:00
Lukas Stockner
83ae0a0e06 Cycles: Calculate differentials in the Multiscattering GGX closures
The Multiscattering GGX closures didn't set the omega_i differentials, which could cause undefined behaviour.
2016-07-25 16:14:25 +02:00
Sergey Sharybin
988ec3c40c OpenSubdiv: Support shadeless shading 2016-07-25 15:38:28 +02:00
Sergey Sharybin
c967a381fa OpenSubdiv: Fix missing support of flat shading in textured viewport 2016-07-25 15:27:38 +02:00
Sergey Sharybin
27db7ef81d OpenSubdiv: Use proper material index 2016-07-25 15:17:37 +02:00
Sergey Sharybin
e7721f5ec8 Cycles: Fix SSS with spatial splits and motion blur 2016-07-25 13:55:03 +02:00
Campbell Barton
a4db868092 Resolve build error on OSX 2016-07-25 20:30:24 +10:00
Bastien Montagne
bbf62931de Cleanup: debug-only variable. 2016-07-25 09:31:56 +02:00
Campbell Barton
f4cb6d45d5 Error in curve update, uninitialized var use 2016-07-25 15:12:46 +10:00
Campbell Barton
2aa5e44b5d Curve Drawing: Use cyclic for stroke with near start/end points 2016-07-25 14:55:16 +10:00
Campbell Barton
a323d8edbf Curve Drawing: Add option to use new refit method 2016-07-25 14:55:16 +10:00