blender.git
2 years agoMerge branch 'master' into blender2.8
Sergey Sharybin [Fri, 4 May 2018 09:51:07 +0000 (11:51 +0200)]
Merge branch 'master' into blender2.8

2 years agoFix T54935: Particle group instances don't render when hidden in viewport
Sergey Sharybin [Fri, 4 May 2018 09:40:27 +0000 (11:40 +0200)]
Fix T54935: Particle group instances don't render when hidden in viewport

Seems to be only related on linked nature of particles.

This is caused by some conflicting optimization done for viewport, which
does not do particles re-calculation if they do not depend on time
(which is crucial for big layout scene grass fields) and particle render
setting  switch which was relying on fact that render pipeline will do
particle update via time dependency.

Now we extent an old workaround for invisible objects, which now also
deals with particles in the same way as old dependency graph was dealing
with this: tag object data for update if there is particle system.

There shouldn't be any speed difference between old and new depsgraph,
since tagging was already needed and was happening.

In Blender 2.8 such things should be easier to deal with since the whole
depsgraph is to be evaluated for render engine anyway.

2 years agoMerge branch 'master' into blender2.8
Philipp Oeser [Fri, 4 May 2018 08:31:16 +0000 (10:31 +0200)]
Merge branch 'master' into blender2.8

2 years agoModifiers: add back dirty normal flag
Campbell Barton [Fri, 4 May 2018 08:05:57 +0000 (10:05 +0200)]
Modifiers: add back dirty normal flag

2 years agoFix T54341: Particle Instance Modifier doesn't preserve edge data
Philipp Oeser [Fri, 4 May 2018 07:20:57 +0000 (09:20 +0200)]
Fix T54341: Particle Instance Modifier doesn't preserve edge data

2 years agoCleanup: avoid local definitions for one-off args
Campbell Barton [Fri, 4 May 2018 07:04:33 +0000 (09:04 +0200)]
Cleanup: avoid local definitions for one-off args

2 years agoCleanup: avoid local definitions for one-off args
Campbell Barton [Fri, 4 May 2018 06:51:04 +0000 (08:51 +0200)]
Cleanup: avoid local definitions for one-off args

2 years agoModifiers: ported wire modifier to mesh
Campbell Barton [Fri, 4 May 2018 06:45:43 +0000 (08:45 +0200)]
Modifiers: ported wire modifier to mesh

2 years agoMerge branch 'master' into blender2.8
Campbell Barton [Fri, 4 May 2018 06:39:43 +0000 (08:39 +0200)]
Merge branch 'master' into blender2.8

2 years agoFix wireframe modifier w/ even offset
Campbell Barton [Fri, 4 May 2018 06:38:01 +0000 (08:38 +0200)]
Fix wireframe modifier w/ even offset

Was passing non-normalized axis to angle_on_axis.

2 years agoMerge branch 'master' into blender2.8
Campbell Barton [Fri, 4 May 2018 06:02:11 +0000 (08:02 +0200)]
Merge branch 'master' into blender2.8

2 years agoLogging: setting log level wasn't working
Campbell Barton [Fri, 4 May 2018 06:00:22 +0000 (08:00 +0200)]
Logging: setting log level wasn't working

2 years agoMerge branch 'master' into blender2.8
Campbell Barton [Fri, 4 May 2018 05:30:14 +0000 (07:30 +0200)]
Merge branch 'master' into blender2.8

2 years agoIDProp API: expose repr utility function
Campbell Barton [Fri, 4 May 2018 05:26:42 +0000 (07:26 +0200)]
IDProp API: expose repr utility function

Useful for logging properties passed to operators.

2 years agoMerge branch 'master' into blender2.8
Germano [Thu, 3 May 2018 21:47:14 +0000 (18:47 -0300)]
Merge branch 'master' into blender2.8

2 years agoBKE: BVHtree: make `bvhtree_from_mesh_edges` a static function.
Germano [Thu, 3 May 2018 21:33:16 +0000 (18:33 -0300)]
BKE: BVHtree: make `bvhtree_from_mesh_edges` a static function.

This will help us have more control over bvhtrees that are cached.

2 years agoFix `Transfer Mesh Data` with `Edge Mapping` of type `Projected Edge Interpolated...
Germano [Thu, 3 May 2018 21:19:36 +0000 (18:19 -0300)]
Fix `Transfer Mesh Data` with `Edge Mapping` of type `Projected Edge Interpolated` and `Ray Radius` other than 0.0.

`MREMAP_RAYCAST_APPROXIMATE_BVHEPSILON(ray_radius)` greatly increased the radius making for example that 0.1 becoming 1.5
Now the result is much more predictable.

2 years agoEdit-Mesh: multi-object un-subdivide
Dalai Felinto [Thu, 3 May 2018 19:56:59 +0000 (21:56 +0200)]
Edit-Mesh: multi-object un-subdivide

2 years agoEdit-Mesh: multi-object edge rotate
Dalai Felinto [Thu, 3 May 2018 19:44:53 +0000 (21:44 +0200)]
Edit-Mesh: multi-object edge rotate

2 years agoEdit-Mesh: multi-object dissolve limited
Dalai Felinto [Thu, 3 May 2018 18:59:02 +0000 (20:59 +0200)]
Edit-Mesh: multi-object dissolve limited

2 years agoMerge branch 'master' into blender2.8
Germano [Thu, 3 May 2018 18:54:26 +0000 (15:54 -0300)]
Merge branch 'master' into blender2.8

2 years agoParticle Edit: Shape Cut: Create and use bvhtree with AABB hull.
Germano [Thu, 3 May 2018 18:52:09 +0000 (15:52 -0300)]
Particle Edit: Shape Cut: Create and use bvhtree with AABB hull.

This bvhtree is only used for raycast. Currently the raycast does not benefit from general hull.

2 years agoDynamic Paint: Create and use bvhtree with AABB hull.
Germano [Thu, 3 May 2018 18:50:48 +0000 (15:50 -0300)]
Dynamic Paint: Create and use bvhtree with AABB hull.

This bvhtree is only used for raycast and find_nearest which currently do not benefit from general hull.

2 years agoMerge branch 'master' into blender2.8
Campbell Barton [Thu, 3 May 2018 18:24:44 +0000 (20:24 +0200)]
Merge branch 'master' into blender2.8

2 years agoFix T54927: BMesh Py error w/ select history slice
Campbell Barton [Thu, 3 May 2018 18:23:32 +0000 (20:23 +0200)]
Fix T54927: BMesh Py error w/ select history slice

2 years agoMerge branch 'master' into blender2.8
Campbell Barton [Thu, 3 May 2018 17:53:19 +0000 (19:53 +0200)]
Merge branch 'master' into blender2.8

2 years agoCleanup: correct solidify logic
Campbell Barton [Thu, 3 May 2018 17:48:28 +0000 (19:48 +0200)]
Cleanup: correct solidify logic

Code for side normals isn't executing at the moment,
so not essential, but better correct it.

2 years agoCleanup: parentheses warning
Campbell Barton [Thu, 3 May 2018 17:37:20 +0000 (19:37 +0200)]
Cleanup: parentheses warning

2 years agoMerge branch 'master' into blender2.8
Germano [Thu, 3 May 2018 17:33:52 +0000 (14:33 -0300)]
Merge branch 'master' into blender2.8

2 years agoBKE bvhtree: Add `tree_type` parameter to `bvhtree_from_mesh_get`.
Germano [Thu, 3 May 2018 17:26:39 +0000 (14:26 -0300)]
BKE bvhtree: Add `tree_type` parameter to `bvhtree_from_mesh_get`.

This will allow greater control of the bvhtrees that are obtained, and helps identify problems.
It is also an additional step to unify the functions.

2 years agoCleanup "Sync Mode" (i.e. Av Sync/Framedropping) stuff
Joshua Leung [Thu, 3 May 2018 16:50:53 +0000 (18:50 +0200)]
Cleanup "Sync Mode" (i.e. Av Sync/Framedropping) stuff

* Remove the "sync_mode" dropdown from timeline header, and move it into
  the Playback menu instead.
* Remove the confusing "Frame Dropping" and "AV Sync" entries from the
  Playback menu. These were supposed to be mutually exclusive (or else,
  the "sync_mode" menu would break).
* Turn AV Sync on by default
* Commented out the Frame Dropping and Av Sync RNA Properties too.
  THere doesn't seem to be any valid reason for these to exist?

2 years agoMulti-Object Pose: Fix POSE_OT_flip_names
Joshua Leung [Thu, 3 May 2018 14:34:25 +0000 (16:34 +0200)]
Multi-Object Pose: Fix POSE_OT_flip_names

2 years agoFix 3D cursor being hidden on existing 2.8 files
Campbell Barton [Thu, 3 May 2018 15:56:06 +0000 (17:56 +0200)]
Fix 3D cursor being hidden on existing 2.8 files

Flip logic for the flag avoids versioning code.

2 years agoSculpt: Fix crash when using grab brush
Sergey Sharybin [Thu, 3 May 2018 15:42:46 +0000 (17:42 +0200)]
Sculpt: Fix crash when using grab brush

Was wrong paint structure deducted from context.

Test plan:

With default cube, go to sculpt mode, switch to grab brush
and try to sculpt.

2 years agoCleanup: fix warnings, removed unused code.
Brecht Van Lommel [Wed, 2 May 2018 08:32:01 +0000 (10:32 +0200)]
Cleanup: fix warnings, removed unused code.

2 years agoDepsgraph: Keep edit bones around, fixes missing edit mode with copy on write
Sergey Sharybin [Thu, 3 May 2018 14:22:47 +0000 (16:22 +0200)]
Depsgraph: Keep edit bones around, fixes missing edit mode with copy on write

2 years agoFix T54805: Bones are white in edit mode
Dalai Felinto [Thu, 3 May 2018 14:17:45 +0000 (16:17 +0200)]
Fix T54805: Bones are white in edit mode

2 years agoDepsgraph: Make sure evaluated pose channels are pointing to evaluated bones
Sergey Sharybin [Thu, 3 May 2018 14:10:37 +0000 (16:10 +0200)]
Depsgraph: Make sure evaluated pose channels are pointing to evaluated bones

2 years agoEevee: Shadows: Perf: Do not update shadows that are not inside the view.
Clément Foucault [Thu, 3 May 2018 13:44:19 +0000 (15:44 +0200)]
Eevee: Shadows: Perf: Do not update shadows that are not inside the view.

2 years agoDRW: Add plane culling test.
Clément Foucault [Thu, 3 May 2018 13:43:42 +0000 (15:43 +0200)]
DRW: Add plane culling test.

Usefull to see if the view frustum is totally behind a plane.

2 years agoDRW: Silence unused function warning in release.
Clément Foucault [Thu, 3 May 2018 12:37:53 +0000 (14:37 +0200)]
DRW: Silence unused function warning in release.

2 years agoMerge branch 'master' into blender2.8
Bastien Montagne [Thu, 3 May 2018 14:01:43 +0000 (16:01 +0200)]
Merge branch 'master' into blender2.8

2 years agoFix tooltip for constraints' subtarget.
Bastien Montagne [Thu, 3 May 2018 14:00:34 +0000 (16:00 +0200)]
Fix tooltip for constraints' subtarget.

Thanks @aligorith for the head-up.

2 years agoWorkbench: selection method for studio lighting
Jeroen Bakker [Thu, 3 May 2018 13:31:37 +0000 (15:31 +0200)]
Workbench: selection method for studio lighting

2 years agoWorkbench: studiolight
Jeroen Bakker [Thu, 3 May 2018 13:31:03 +0000 (15:31 +0200)]
Workbench: studiolight

2 years agoFix: Tag armature for copy on write when selecting bones, so active bone gets updated
Joshua Leung [Thu, 3 May 2018 13:18:24 +0000 (15:18 +0200)]
Fix: Tag armature for copy on write when selecting bones, so active bone gets updated

Note: This still needs some copy-on-write magic to get the bone pointers
to get remapped properly (e.g. evaluated pose still refers to original
arm->bones, and arm->act_bone isn't getting remapped).

2 years agoMerge branch 'master' into blender2.8
Bastien Montagne [Thu, 3 May 2018 13:02:05 +0000 (15:02 +0200)]
Merge branch 'master' into blender2.8

2 years agoCleanup: factorize RNA constraint targets definition.
Bastien Montagne [Thu, 3 May 2018 13:00:12 +0000 (15:00 +0200)]
Cleanup: factorize RNA constraint targets definition.

No expected changes in behavior from that commit!

2 years agoFix crash selecting envelope bone joint
Campbell Barton [Thu, 3 May 2018 12:28:40 +0000 (14:28 +0200)]
Fix crash selecting envelope bone joint

2 years agoRender preview: Assign proper depsgraph for icon preview
Sergey Sharybin [Thu, 3 May 2018 12:25:09 +0000 (14:25 +0200)]
Render preview: Assign proper depsgraph for icon preview

Wondering why it only was visible when running without copy on write.

2 years agoDepsgraph: Fix missing action re-map with node tree update
Sergey Sharybin [Thu, 3 May 2018 12:15:09 +0000 (14:15 +0200)]
Depsgraph: Fix missing action re-map with node tree update

After copying animation data we need to re-map action, otherwise
our original DNA values will go out of symc, causing flickering
when tweaking values on animated node tree.

2 years agoRender preview: Make it to preserve unkeyed animation
Sergey Sharybin [Thu, 3 May 2018 10:58:48 +0000 (12:58 +0200)]
Render preview: Make it to preserve unkeyed animation

The idea is to re-use evaluated datablock from within current context.

This relies on the following factors:

- It expects scene to be fully evaluated before preview jobs starts.
- It expects datablocks to be localized.

2 years agoRestored HQ normals in Solidify modifier
Sybren A. Stüvel [Thu, 3 May 2018 12:02:05 +0000 (14:02 +0200)]
Restored HQ normals in Solidify modifier

2 years agoMetaball: Move handles shader to draw/modes/shader and reference them in draw_common.c
Germano [Thu, 3 May 2018 12:11:02 +0000 (09:11 -0300)]
Metaball: Move handles shader to draw/modes/shader and reference them in draw_common.c

2 years agoFix pose transformation helper lines
Dalai Felinto [Thu, 3 May 2018 10:57:34 +0000 (12:57 +0200)]
Fix pose transformation helper lines

This was broken since 33bb8b785a9 (triple-buffer changes).
This also helps help lines as a whole.

2 years agoRender preview: Remove dedicated depsgraph
Sergey Sharybin [Thu, 3 May 2018 10:57:54 +0000 (12:57 +0200)]
Render preview: Remove dedicated depsgraph

It is not needed since render pipeline will create its own depsgraph.

2 years agoDepsgraph: Tag IDs for animation update on visible update
Sergey Sharybin [Thu, 3 May 2018 10:43:32 +0000 (12:43 +0200)]
Depsgraph: Tag IDs for animation update on visible update

Without this it's quite unpredictable what state of unkeyed changes
datablock will end up with.

2 years agoDepsgraph: Fix threading conflict between node animation and shading update
Sergey Sharybin [Thu, 3 May 2018 10:41:03 +0000 (12:41 +0200)]
Depsgraph: Fix threading conflict between node animation and shading update

2 years agoDepsgraph: Fix wrong debug message
Sergey Sharybin [Thu, 3 May 2018 10:15:37 +0000 (12:15 +0200)]
Depsgraph: Fix wrong debug message

2 years agoFix sculpt grab cursor
Dalai Felinto [Thu, 3 May 2018 09:35:23 +0000 (11:35 +0200)]
Fix sculpt grab cursor

This was broken since 33bb8b785a9 (triple-buffer changes).
We need to account to the area limits when drawing the cursor.

2 years agoFix for material/node tree localization
Sergey Sharybin [Thu, 3 May 2018 09:07:09 +0000 (11:07 +0200)]
Fix for material/node tree localization

The workaround removal was wrong, the whole id->adt of a local
copy is to be NULL.

But now instead of modifying original datablock, we tell library
manager to not copy animation data.

2 years agoUI: Fix region_draw_azone_tab_plus missing/broken background.
Clément Foucault [Thu, 3 May 2018 09:20:10 +0000 (11:20 +0200)]
UI: Fix region_draw_azone_tab_plus missing/broken background.

This was due to the background being drawn by a batch that had its VAO
generated in the windows "UI" context.

Since we use the DRW ogl context to draw the entire area, we have to
regenerate the VAO for thoses UI batches to be drawn correctly.

2 years agoWorkbench: Show 3D Cursor Overlay
Jeroen Bakker [Thu, 3 May 2018 08:55:28 +0000 (10:55 +0200)]
Workbench: Show 3D Cursor Overlay

2 years agoInitialize alpha discard for uiWidgetBaseParameters
Dalai Felinto [Thu, 3 May 2018 07:56:20 +0000 (09:56 +0200)]
Initialize alpha discard for uiWidgetBaseParameters

No functional change, just playing safe and documenting how to
initialize the parameter in most of the cases.

2 years agoMerge branch 'master' into blender2.8
Campbell Barton [Thu, 3 May 2018 06:22:00 +0000 (08:22 +0200)]
Merge branch 'master' into blender2.8

2 years agoCleanup: split out extrude spin/screw
Campbell Barton [Thu, 3 May 2018 06:13:17 +0000 (08:13 +0200)]
Cleanup: split out extrude spin/screw

Since these will have their own manipulators,
its more convenient to keep them separate.

2 years agoWM: warn when tool widget not found
Campbell Barton [Thu, 3 May 2018 05:31:55 +0000 (07:31 +0200)]
WM: warn when tool widget not found

This happens when testing adding tools, assert isn't useful.

2 years agoCleanup: trailing space
Campbell Barton [Thu, 3 May 2018 05:22:04 +0000 (07:22 +0200)]
Cleanup: trailing space

2 years agoCleanup: remove axis bounds ifdef
Campbell Barton [Thu, 3 May 2018 05:21:06 +0000 (07:21 +0200)]
Cleanup: remove axis bounds ifdef

This was added for scale-cage manipulator, but seems generally useful.

2 years agoTransform: expose 3D center/axis calculation
Campbell Barton [Thu, 3 May 2018 05:15:34 +0000 (07:15 +0200)]
Transform: expose 3D center/axis calculation

This is needed for other manipulator placement.

2 years agoWM: add function to access last_properties
Campbell Barton [Wed, 2 May 2018 15:59:43 +0000 (17:59 +0200)]
WM: add function to access last_properties

2 years agoMetaball: pointers used in `DRW_shgroup_call_dynamic_add` don't need to hold the...
Germano [Thu, 3 May 2018 00:26:43 +0000 (21:26 -0300)]
Metaball: pointers used in `DRW_shgroup_call_dynamic_add` don't need to hold the reference.

2 years agoArmature: Envelope: Small cleanup + don't smooth the distance display.
Clément Foucault [Wed, 2 May 2018 06:58:29 +0000 (08:58 +0200)]
Armature: Envelope: Small cleanup + don't smooth the distance display.

The actual weighting calculation is not smooth as the bone display.

The bone itself can be smooth for esthetic purpose but the distance display
should match the underlying weighting formula.

2 years agoArmature: Envelope: Optimize outline shader.
Clément Foucault [Wed, 2 May 2018 06:45:06 +0000 (08:45 +0200)]
Armature: Envelope: Optimize outline shader.

2 years agoArmature: Envelope: Revisit envelope drawing again.
Clément Foucault [Wed, 2 May 2018 06:44:24 +0000 (08:44 +0200)]
Armature: Envelope: Revisit envelope drawing again.

Past shader was too slow and had bad artifacts. This method is much simpler
and eficient and only exhibit some popping when the raidus of the head/tail
is changed.

2 years agoGPUShader: Remove unused envelope shaders.
Clément Foucault [Mon, 30 Apr 2018 20:48:12 +0000 (22:48 +0200)]
GPUShader: Remove unused envelope shaders.

2 years agoArmature: More work and cleanup on envelope bones drawing.
Clément Foucault [Mon, 30 Apr 2018 20:47:40 +0000 (22:47 +0200)]
Armature: More work and cleanup on envelope bones drawing.

- Draw tail & head sphere with point shader (no needs for another way).
- Use the same function for issuing the calls for wire and solid envelope.

2 years agoArmature: Add envelope outline shader.
Clément Foucault [Mon, 30 Apr 2018 20:35:30 +0000 (22:35 +0200)]
Armature: Add envelope outline shader.

2 years agoArmature: Envelope Bones: Change drawing method.
Clément Foucault [Sun, 29 Apr 2018 17:39:44 +0000 (19:39 +0200)]
Armature: Envelope Bones: Change drawing method.

We now use a more pleasant and efficient way to display enveloppe bones
and their radius.

For this we use a capsule geometry that is displaced (in the vertex shader)
to a signed distance field that represents the bone shape.

The bone distance radius are now drawn in 3D using a "pseudo-fresnel" effect.
This gives a better understanding of what is inside the radius of influence.

When capsules are not needed, we switch to default raytraced points.
The capsules are not distorded by the bone's matrix (same as their actual
influence radius) and are correctly displayed even with complex scaled
parents hierarchy.

2 years agoArmature: Draw envelope on non MSAA buffer.
Clément Foucault [Sun, 29 Apr 2018 17:28:43 +0000 (19:28 +0200)]
Armature: Draw envelope on non MSAA buffer.

Appart from the performance issue, the MSAA resolve pass is not compatible
with additive passes.

2 years agoArmature: Add multisampling to posemode.
Clément Foucault [Fri, 27 Apr 2018 14:30:03 +0000 (16:30 +0200)]
Armature: Add multisampling to posemode.

2 years agoDRW: Convert DRW_cache_circle_get to use GWN_PRIM_LINE_LOOP
Clément Foucault [Fri, 27 Apr 2018 14:28:49 +0000 (16:28 +0200)]
DRW: Convert DRW_cache_circle_get to use GWN_PRIM_LINE_LOOP

2 years agoArmature: "Raytrace" bones endpoint spheres.
Clément Foucault [Fri, 27 Apr 2018 14:27:47 +0000 (16:27 +0200)]
Armature: "Raytrace" bones endpoint spheres.

Here is how it works:
We render a high poly disc that we orient & scale towards the camera so that
it covers the same pixel of the sphere it's supposed to represent.

Then the pixel shader raytrace the sphere (effectively starting from
the poly disc depth) and outputs the depth to gl_FragDepth.

This approach has many benefit:
- high quality obviously: per pixel accurate depth!
- compatible with MSAA: since the sphere horizon is delimited by polygons,
  we get the coverage computed by the rasterizer. However we still gets
  aliasing if the sphere intersect directly other meshes.
- virtually no overdraw: there is no backface to shade but we still get
  overdraw because by little triangle [gpus rasterize pixel by groups of 4].
- allows early depth test: since the poly disc is set at the nearest depth
  we can output, we can use GL_ARB_conservative_depth to enable early depth
  test and discard pixels that are already behind geometry.
- can draw outline pretty easily without geometry shader.

2 years agoDRW: Make use of new multisample resolve pass.
Clément Foucault [Mon, 23 Apr 2018 21:11:29 +0000 (23:11 +0200)]
DRW: Make use of new multisample resolve pass.

2 years agoDRW: Add DRW_multisamples_resolve function
Clément Foucault [Mon, 23 Apr 2018 21:10:59 +0000 (23:10 +0200)]
DRW: Add DRW_multisamples_resolve function

This manually resolve the content of a multisample FB to a single sample FB.

It resolves color (combine the 2 framebuffers in a logical maner keeping
depth buffer occlusion etc..) instead of a plain glBlitFramebuffer copy.

2 years agoGPUShader: Optimize Multisample resolve shader.
Clément Foucault [Mon, 23 Apr 2018 21:07:58 +0000 (23:07 +0200)]
GPUShader: Optimize Multisample resolve shader.

Group all fetches together without interleived alu to let compiler optimize.

Also do the color samples only if needed.

Went from 3.86ms to [1.11-2.22]ms [min-max] for the 16samples resolve pass
on my nvidia card.

2 years agoDRW: Add DRW_STATE_BLEND_PREMUL blend mode.
Clément Foucault [Mon, 23 Apr 2018 20:58:47 +0000 (22:58 +0200)]
DRW: Add DRW_STATE_BLEND_PREMUL blend mode.

2 years agoGPUShader: Add GPU_SHADER_2D_IMAGE_MULTISAMPLE_2/4/8/16
Clément Foucault [Mon, 23 Apr 2018 19:08:11 +0000 (21:08 +0200)]
GPUShader: Add GPU_SHADER_2D_IMAGE_MULTISAMPLE_2/4/8/16

This shader is used instead of blitting back and forth to a single sample
buffer.

This means it resolves the color and depth samples and outputs a fragment
which can be depth tested and blended on top of an existing framebuffer.

We do static shader variation with manual loop unrolling for performance
reason. In my test I get 25% more perf with intel integrated gpu and 75%
performance gain with dedicated nvidia card compared to a single shader
with a uniform for sample count.

2 years agoGWN: Add GWN_batch_uniform_mat4.
Clément Foucault [Mon, 23 Apr 2018 19:01:16 +0000 (21:01 +0200)]
GWN: Add GWN_batch_uniform_mat4.

2 years agoGPUShader: Fix simple lighting modulating alpha color
Clément Foucault [Mon, 23 Apr 2018 19:00:32 +0000 (21:00 +0200)]
GPUShader: Fix simple lighting modulating alpha color

2 years agoObject Mode: Draw non meshes before outline.
Clément Foucault [Sun, 22 Apr 2018 20:56:07 +0000 (22:56 +0200)]
Object Mode: Draw non meshes before outline.

This makes the outlines occluded by the other objects. This was a problem
before the outline refactor but now there is no need for it.

2 years agoDRW: Armature: New bone outline shader.
Clément Foucault [Sun, 22 Apr 2018 20:49:36 +0000 (22:49 +0200)]
DRW: Armature: New bone outline shader.

This fix the issue with the zfighting we were getting at bones edges.

Moreover, this enables us to render arbitrarly large outline with
varying thickness.

2 years agoDRW: Add Adjacency info for bone shapes.
Clément Foucault [Sun, 22 Apr 2018 19:55:05 +0000 (21:55 +0200)]
DRW: Add Adjacency info for bone shapes.

Only for cube and octahedral shapes for now.

2 years agoGWN: Add GL_TRIANGLES_ADJACENCY to supported primitive types.
Clément Foucault [Sun, 22 Apr 2018 19:33:58 +0000 (21:33 +0200)]
GWN: Add GL_TRIANGLES_ADJACENCY to supported primitive types.

2 years agoGPUTexture: Fix wrong multisample texture size.
Clément Foucault [Sun, 22 Apr 2018 19:20:23 +0000 (21:20 +0200)]
GPUTexture: Fix wrong multisample texture size.

2 years agoPaint Vertex Mode: Fix shader not free.
Clément Foucault [Wed, 2 May 2018 16:39:44 +0000 (18:39 +0200)]
Paint Vertex Mode: Fix shader not free.

2 years agoEevee: Add Lamp Specular multiplier.
Clément Foucault [Wed, 2 May 2018 16:39:17 +0000 (18:39 +0200)]
Eevee: Add Lamp Specular multiplier.

It's usefull in some scenario to tweak the specular intensity of a light
without modifying the diffuse contribution.

Cycles allows it via lamps material which we currently not support in Eevee.

This is a good workaround for now.

2 years agoFix T54864: Assert when changing interface display scale
Dalai Felinto [Wed, 2 May 2018 16:22:09 +0000 (18:22 +0200)]
Fix T54864: Assert when changing interface display scale

The asserts were introduced on rB5f6c45498c92 (top-bar).

Although the asserts are technically correct, they would fail even in master.
And the commit simply added the asserts without fixing the situation itself
(as you can see in the report, it is really simple to reproduce this issue).

I propose we remove the asserts and bring them back only when the situation
itself is fixed. It doesn't make sense to introduce asserts that would fail
with the current state of the code.

2 years agoMerge branch 'blender2.8' of git.blender.org:blender into blender2.8
Jeroen Bakker [Wed, 2 May 2018 15:37:37 +0000 (17:37 +0200)]
Merge branch 'blender2.8' of git.blender.org:blender into blender2.8

2 years agoWorkbench: Linear => srgb conversion
Jeroen Bakker [Wed, 2 May 2018 15:37:11 +0000 (17:37 +0200)]
Workbench: Linear => srgb conversion