Commit Graph

75472 Commits

Author SHA1 Message Date
Clément Foucault
e47e60a9b9 Workbench: Shadows: Fix the remaining fail case.
Non-manifold geom was producing inverted result when the camera was inside
the shadow volume.

When rendering non manifold geometry with the depth fail method, we need to
emit the cap as if it was the same geometry with a virtual thickness.

Another way to view it is to imagine having a set of non-manifold geometry
all facing the light.

So for every tri we emit a front cap oriented toward the light and the
back cap pointing away from it (whatever the actual orientation of the tri).

Extrusion pass stay the same as the depth pass method (double the increment
if it's a manifold edge).
2018-06-04 15:15:00 +02:00
Sergey Sharybin
736a84ec66 Cleanup: Use proper type for original ID pointer
Helps debugging, no need to cast in a debugger.
2018-06-04 14:14:14 +02:00
William Reynish
acb5bbf9b2 UI: use subpanels for Cycles, render, scene, object, particle, curves. 2018-06-04 13:44:23 +02:00
Bastien Montagne
f430f14df4 Merge branch 'master' into blender2.8 2018-06-04 12:48:03 +02:00
Bastien Montagne
7277f8973b Fix T55260: load Text File with Python from GUI Button results in 0 User
Let's just always ensure user_one when loading text from operator...
2018-06-04 12:46:59 +02:00
Campbell Barton
c2ff37455e Fix selecting bones
Own error w/ recent USE_OBJECT_MODE_STRICT
2018-06-04 12:39:10 +02:00
Rohan Rathi
2903146826 Added UI support for seams and sharp edges and cleanup 2018-06-04 15:13:54 +05:30
Campbell Barton
95011f6d48 Merge branch 'master' into blender2.8 2018-06-04 09:39:04 +02:00
Campbell Barton
44505b38df Cleanup: strip trailing space in editors 2018-06-04 09:31:30 +02:00
Campbell Barton
0911acb5cf Merge branch 'master' into blender2.8 2018-06-04 09:11:45 +02:00
Campbell Barton
6654e109df Cleanup: strip trailing space in GPU module 2018-06-04 09:09:12 +02:00
Campbell Barton
5b64301834 Merge branch 'master' into blender2.8 2018-06-04 09:06:14 +02:00
Campbell Barton
7719c11006 Cleanup: strip trailing space in Python module 2018-06-04 08:54:40 +02:00
Campbell Barton
854db8951b Cleanup: strip trailing space in bmesh module 2018-06-04 08:49:47 +02:00
Brecht Van Lommel
d7c2b78822 UI: add subpanel support.
In the Python API, any panel becomes a subpanel by setting bl_parent_id
to the name of the parent panel. These subpanels can contain advanced or
less commonly used settings.
2018-06-03 21:30:35 +02:00
Rohan Rathi
79c0ac7c78 Added support for extending sharp edges with bevel 2018-06-03 22:50:35 +05:30
Campbell Barton
81dbf08eb4 Merge branch 'master' into blender2.8 2018-06-03 17:09:07 +02:00
Campbell Barton
38eb91c848 Cleanup: correct variable name, doxy sections 2018-06-03 17:06:13 +02:00
Clément Foucault
25ff7a4f2a DRW: Hair: Add additionnal subdivision smoothing support.
Only use catmull-rom interpolation for now. It's smoother and does not
exhibit artifacts.
2018-06-03 16:45:03 +02:00
Clément Foucault
06dd89b0ca GPUTexture: Fix memleak in orphaned texture management. 2018-06-03 16:45:03 +02:00
Campbell Barton
e657a4af13 Merge branch 'master' into blender2.8 2018-06-03 15:20:11 +02:00
Clément Foucault
4c4eb1ce20 Workbench: Fix memleaks. 2018-06-03 15:26:53 +02:00
Clément Foucault
d0f7ab27a8 Wireframe: Optimization for intel GPUs.
Intel GPU take more advantage of the geometry shader than other vendors.

Using a simple geom shader approach in this case is more performant.
2018-06-03 15:26:37 +02:00
Campbell Barton
335b193336 Cleanup: add argument names to screen callbacks 2018-06-03 15:11:31 +02:00
Clément Foucault
778a19a13a DRW: Fix hair disapearing if emitter is culled. 2018-06-03 12:36:03 +02:00
Clément Foucault
32c5972653 Workbench: Rework hair support.
Now hairs are shaded properly in workbench and support texturing.

I also added a 10% random normal direction per hair to have a bit more
variation in the shading. This is hardcoded for now.
2018-06-03 12:36:03 +02:00
Campbell Barton
38bf3b8d23 Merge branch 'master' into blender2.8 2018-06-03 11:24:57 +02:00
Campbell Barton
6221180963 Cleanup: remove blockscale & handler
Replace with link_flag, currently unused,
needed for dynamic space types which is planned.
2018-06-03 11:12:50 +02:00
Campbell Barton
c55e90da4c Cleanup: -Wswitch warning 2018-06-02 21:38:31 +02:00
Clément Foucault
6c6c4da718 GPU: Fix texture being freed in threads without ogl context bound.
This is a dirty fix. A bit more cleaner approach would be to check if a
context is bound and delay the deletion only in this case.
Also we may want to do this orphan deletion at some other places than
wm_window_swap_buffers.
2018-06-02 21:16:40 +02:00
Clément Foucault
bc6358a580 DRW: Add uniform name recording in debug mode. 2018-06-02 21:16:40 +02:00
Clément Foucault
f25e459f8f DRW: Make the Procedural hair update part of the drawmanager.
Instead of relying on the engine integration which is redundant.
2018-06-02 21:16:40 +02:00
Clément Foucault
98e4d548a1 Eevee: Hair: Make SSR works with hairs. 2018-06-02 21:16:40 +02:00
Clément Foucault
119423b252 Eevee: Cleanup unused Ghash 2018-06-02 21:16:40 +02:00
Clément Foucault
8ace49dedc Eevee: Add shadow support for hairs. 2018-06-02 21:16:40 +02:00
Clément Foucault
1de73fc6c3 Eevee: Hair: Make hairs visible even if the show emitter option is disabled. 2018-06-02 21:16:40 +02:00
Clément Foucault
08a2c5f224 Eevee: Add support for hair random property.
Do note that it does not match cycles implementation.

Also we could precompute the hash per strand before rendering but that would
suggest it's not per engine specific.

If we make the random value internal to blender then it won't be a matter
because other renderers will have access to the same value.
2018-06-02 21:16:40 +02:00
Clément Foucault
4430bd3644 Eevee: CodeStyle: Fix naming and confusion about the hairs vectors. 2018-06-02 21:16:40 +02:00
Dalai Felinto
fec317de8d --debug-gpu-shader: Dump GLSL shaders to disk
This is really convenient for development. Either for profiling the
generated shaders or to check if the generated code is correct.

It writes the shaders to the temporary blender session folder.

(ported over from blender2.8)
2018-06-02 20:29:27 +02:00
Germano
6de656b4f2 transform_snap_object: Do not use occlusion test when X-Ray is enabled. 2018-06-02 13:11:51 -03:00
Germano
58efa7d686 Fix inaccuracy of SCREEN_OT_area_split when snap to midpoint and adjacent.
By default when moving a edge of the screen it always snaps to an invisible grid with unit of 4 pixels.
This was also affecting the snap to the midpoint and adjacent.
The solution was to make the snap to areagrid optional and use values of `origmin` and `origsize` that match the transformations in screen_edit.c.
2018-06-02 12:19:49 -03:00
Campbell Barton
0de0cee9a2 Fix crash running in background mode 2018-06-02 14:53:07 +02:00
Campbell Barton
9cd2e4fa3f Cleanup: quiet warnings w/o Python 2018-06-02 13:10:27 +02:00
Campbell Barton
b608133075 Fix crash if no tool is set 2018-06-02 13:10:15 +02:00
Campbell Barton
a08a8aa928 Merge branch 'master' into blender2.8 2018-06-02 13:09:12 +02:00
Campbell Barton
c140f11946 Cleanup: warning 2018-06-02 11:58:01 +02:00
Campbell Barton
bfe1d0e0dc Merge branch 'master' into blender2.8 2018-06-01 18:26:42 +02:00
Campbell Barton
75fc1c3507 Cleanup: trailing whitespace (comment blocks)
Strip unindented comment blocks - mainly headers to avoid conflicts.
2018-06-01 18:19:39 +02:00
Campbell Barton
297bf7235b Cleanup: whitespace 2018-06-01 18:10:43 +02:00
Rohan Rathi
2f5704486d Added ability to apply seams to all middle edges
between the 2 marked edges. currently does not make changes to material
or sharpness of edges
2018-06-01 21:18:26 +05:30