Bastien Montagne
1ac311cedc
Fix/cleanup another bunch of UI messages issues.
...
Also (mostly in comments): behaviour -> behavior (we use American English).
2018-12-24 12:32:43 +01:00
Brecht Van Lommel
0edd93effb
Fix inconsistent/broken Cycles object visibility for instances.
...
Object visibility is now handled by the depsgraph iterator, but this API
was incomplete as it made no distinction for visibility of the object itself,
particles and generated instances.
The depsgraph iterator API now includes information about which part of the
object is visible, and this is used by Cycles to replace the old custom logic.
Cycles and EEVEE visibility should now be consistent, which unfortunately does
means some subtle compatibility breakage for both.
Fixes T58956, T58202, T59284.
Differential Revision: https://developer.blender.org/D4109
2018-12-21 16:05:48 +01:00
Campbell Barton
7a26e930a8
Cleanup: macro hygiene, line length
2018-12-21 10:46:26 +11:00
Clément Foucault
217727cb35
Mesh Batch Cache: Fix missing flag for looptris indexbuf generation
...
Fix T59637: Crash report - Overlays -> Face Orientation causes crash
2018-12-20 23:42:21 +01:00
Clément Foucault
a9706476e3
Mesh Batch Cache: Fix uninitialized loop variable
2018-12-19 22:56:15 +01:00
Clément Foucault
1a7fe54a85
Fix T59578: enabling "vertex group weights" in edit mode results in crash
2018-12-19 12:32:13 +01:00
Clément Foucault
5b277d7a18
Mesh Batch Cache: Port loose_edges to batch request
2018-12-18 22:17:53 +01:00
Clément Foucault
2f00e0a37b
Mesh Batch Cache: Cleanup / Reorder function for more consistency
2018-12-18 22:17:53 +01:00
Clément Foucault
604101d262
Mesh Batch Cache: Port edge_detection to batch request
...
Also add proper support for mapped meshes (deformed by modifiers in edit
mode). So this fixes the shadows of workbench in edit mode.
2018-12-18 20:51:52 +01:00
Clément Foucault
99fb654ffd
DRW: Cleanup / Renaming of mesh batch cache functions
...
THis is in order to avoid the jungle of names being different at each
step of the API.
Also removes some unused functions.
2018-12-18 20:51:52 +01:00
Clément Foucault
df88b6a48d
Mesh Batch Cache: Port all_edges batch to batch request
2018-12-18 20:51:52 +01:00
Clément Foucault
d4dcad0ad6
Fix crash with armature custom bone in wireframe mode
2018-12-18 14:51:05 +01:00
Philipp Oeser
8e08e323a7
Fix T59484: Particles Lattice deform fails
...
this was working for object/collection display/render but lattice was
not taken into account for non object/collection display/render types
(halo, axis, cross, circle, ...)
Reviewers: sergey, brecht
Maniphest Tasks: T59484
Differential Revision: https://developer.blender.org/D4096
2018-12-18 14:39:45 +01:00
Clément Foucault
8839152abf
Fix T59529: Auto smooth not working
2018-12-18 14:27:13 +01:00
Clément Foucault
c92cffb56d
DRW: Instance: Makes it possible to have instances of a non-init batch
2018-12-18 13:08:17 +01:00
Clément Foucault
77d9ddc5ea
Armature: temp workaround for crash caused by custom bone drawing
2018-12-18 13:08:17 +01:00
Campbell Barton
f71ae30962
Fix edit-mode wire color being used for other objects
2018-12-18 21:21:48 +11:00
Campbell Barton
b4d625c88e
Fix 3D view depth buffer ignoring overlay option
...
The depth buffer would include lamps, cameras.. etc
event overlays turned off.
2018-12-18 20:25:19 +11:00
Clément Foucault
a68edaf11d
Mesh Batch Cache: Port vertex paint surface to batch request
2018-12-18 02:19:52 +01:00
Clément Foucault
bcf390a6c3
Mesh Batch Cache: Port weight paint surface to batch request
2018-12-18 02:19:52 +01:00
Clément Foucault
8ded149bfc
DRW: Polygon Offset: Also offset lines and points
2018-12-18 02:19:52 +01:00
Clément Foucault
6a1315d6e7
Weight Paint Overlay: Refactor wire drawing
...
This reduce the number of batch/data needed. Stores a select/visiblee
flag inside the vert/loop normals.
2018-12-18 02:19:52 +01:00
Antonioya
f6a77a759b
Fix error when Blender starts - variable not initializated
2018-12-17 19:09:27 +01:00
Clément Foucault
4cd558b711
Mesh Batch Cache: Port Texture paint wires to new batch request
2018-12-17 17:11:45 +01:00
Clément Foucault
7ac49a07c6
Mesh Batch Cache: Port Texture paint batches to new batch request
2018-12-17 17:05:57 +01:00
Clément Foucault
9bb70e59b8
Curve Batch Cache: Fix issue with cd_used
...
cd_used needs to be the combination of generated data.
2018-12-17 17:05:57 +01:00
Clément Foucault
36cc42e796
Mesh Batch Cache: Optimization & Refactor shaded surface support
...
This now only upload data per loops to the GPU, making use of index buffer
to draw polygon. This make use of the vertex cache, speed up renders
and saves a lot of vram.
Update performance is also slightly faster and can even be improved further
by updating only uvs or vcol independently.
This commits breaks texture paint batches. It will be added back in another
commit.
2018-12-17 17:05:57 +01:00
Jacques Lucke
bb58354232
Fix T59490: wrong curve handle lines
2018-12-17 14:34:32 +01:00
Campbell Barton
3e311fdcd1
Cleanup: style
2018-12-16 09:30:05 +11:00
Antonioya
780f0f646d
GP: Rename CTX and OB modes
...
Part of T59335.
2018-12-14 16:52:12 +01:00
Clément Foucault
f371e633f9
Curve Batch Cache: Add support for loose edges and curve/surf modifier
...
Fixes T58298 Nurbs circle and curve dont draw in objectmode
Fixes T58107 Modified curves/surfaces/fonts do not show their eval mesh
2018-12-14 16:17:29 +01:00
Clément Foucault
e4b3fe4b69
Wireframe: Fix wireframe color in edit mode for surfaces
2018-12-14 16:17:29 +01:00
Clément Foucault
f37e45c26b
DRW Batch Cache: Fix hack being a bit too much hacky
2018-12-14 16:17:29 +01:00
Clément Foucault
531e5ad49a
Displist: Reuse tesselated pos and nor for wireframes
...
This lower the memory usage and also fix a bug with metaballs normals/tris
winding being reversed.
2018-12-14 16:17:29 +01:00
Clément Foucault
18d0566013
Curve Batch Cache: Add back support for shaded geometry
...
This changes a bit the batches data structure. Instead of using one
vbo per material we use one for all material and use index buffers for
selecting the correct triangles.
This is less optimized than before but has potential to become more
optimized by merging the wireframe data vbo into the shading one.
Also the index buffers are not strictly necessary and could be just
ranges inside the buffer. But this needs more adding things inside
GPUIndexBuf.
2018-12-14 16:17:29 +01:00
Clément Foucault
2afed99da3
Curve Batch Cache: Rework Implementation to use new batch request
...
Shaded triangles are not yet implemented (request from gpumaterials).
This also changes the mechanism to draw curve normals to make it not
dependant on normal size display. This way different viewport can
reuse the same batch.
2018-12-14 16:17:29 +01:00
Campbell Barton
dd4c87cd04
Merge branch 'master' into blender2.8
2018-12-14 11:09:42 +11:00
Campbell Barton
7d4d9e9dbd
Cleanup: style
2018-12-13 12:30:38 +11:00
Clément Foucault
10eb92035c
Fix T59234: Crash when enter in Edit mode
...
Edit mode triangles does always need to have access to faces for visibility
and select/active flags.
2018-12-12 15:19:21 +01:00
Clément Foucault
cf92795953
Mesh Batch Cache: Fix crash when using edit mode normal display.
2018-12-12 15:19:21 +01:00
Campbell Barton
b87b6e8e28
Fix T59211: Edit-mesh display crashes
...
Caused by ae1f563899
2018-12-12 11:16:56 +11:00
Clément Foucault
5049322e62
GPUState: Change isolated glLineWidth usage to GPU_line_width
2018-12-11 23:05:36 +01:00
Clément Foucault
c541f3abef
DRW: Fix redundant texture creation
2018-12-11 21:25:17 +01:00
Clément Foucault
1b8e1bb635
DRW: Add polygon offset mode.
2018-12-11 18:18:36 +01:00
Campbell Barton
c7ec1fa5e6
Cleanup: use BKE_object_* prefix for object API
...
Also minor style cleanup.
2018-12-11 15:09:09 +11:00
Campbell Barton
9a8b6d51c1
Fix T58850: NDOF navigation guide not shown
2018-12-11 12:35:18 +11:00
Clément Foucault
8c8e9b5586
DRW: Deprecate / Remove DRW_STATE_STIPPLE_*
...
This was unused and used the old drawing paradygm
2018-12-10 23:17:20 +01:00
Clément Foucault
8e37eb10a1
Edit Mesh: Make "fresnel effect" not transparent but mix between 2 colors
...
Alpha blending is causing too many issues.
Revert back to something simpler.
2018-12-10 19:02:17 +01:00
Clément Foucault
834bf357c8
Edit Mesh: Draw inner edge selected in vert edit mode if both verts selected
...
This only make the edge fully selected. There is still no gradient like in
2.79 when only one vertex is selected.
2018-12-10 19:02:17 +01:00
Clément Foucault
f7b558cbdc
DRW: Batch Cache: Mesh: Port edit mesh batches to batch request method
...
This also do some renaming/cleanups.
2018-12-10 19:02:17 +01:00