MetaBall support for Workbench + EEVEE

Note: Metaballs only support the first material slot. Splicing it per
material would create empty Batches. In order to overcome this we set
the batch for other materials to NULL. We added extra checks in EEVEE
and Workbench to not draw when the geom is NULL.
This commit is contained in:
2018-06-11 08:37:56 +02:00
parent 5aa8d981ec
commit a67cc72232
9 changed files with 67 additions and 8 deletions

View File

@@ -187,5 +187,6 @@ struct Gwn_Batch *DRW_cache_particles_get_prim(int type);
/* Metaball */
struct Gwn_Batch *DRW_cache_mball_surface_get(struct Object *ob);
struct Gwn_Batch **DRW_cache_mball_surface_shaded_get(struct Object *ob, struct GPUMaterial **gpumat_array, uint gpumat_array_len);
#endif /* __DRAW_CACHE_H__ */