diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2020-01-17 18:05:19 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2020-01-17 18:29:20 +0300 |
commit | 6eaf51ef3e5b7d37170473449bcda60bad025e67 (patch) | |
tree | 4dff167f66b8d2befe0303fff168573ad943379c /source/blender/draw/intern/draw_cache.h | |
parent | 9410e5dc97c4f21e19865ca8a9e1e185fcf5a1d4 (diff) |
DRW: Use USHORT for vertex color and upload them in linear color to the GPU
This way we remove the need for the srgb boolean uniform and a lot of code complexity. However, mesh update is going to be a bit slower.
I did not benchmark the performance impact.
This also fix a typo in draw_cache_impl_particles.c and fix hair not using vertex color in workbench.
Reviewed By: jbakker
Differential Revision: https://developer.blender.org/D6610
Diffstat (limited to 'source/blender/draw/intern/draw_cache.h')
-rw-r--r-- | source/blender/draw/intern/draw_cache.h | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/source/blender/draw/intern/draw_cache.h b/source/blender/draw/intern/draw_cache.h index 11564464546..3759654931a 100644 --- a/source/blender/draw/intern/draw_cache.h +++ b/source/blender/draw/intern/draw_cache.h @@ -54,10 +54,7 @@ struct GPUBatch *DRW_cache_object_surface_get(struct Object *ob); struct GPUBatch *DRW_cache_object_loose_edges_get(struct Object *ob); struct GPUBatch **DRW_cache_object_surface_material_get(struct Object *ob, struct GPUMaterial **gpumat_array, - uint gpumat_array_len, - char **auto_layer_names, - int **auto_layer_is_srgb, - int *auto_layer_count); + uint gpumat_array_len); struct GPUBatch *DRW_cache_object_face_wireframe_get(struct Object *ob); /* Empties */ @@ -127,10 +124,7 @@ struct GPUBatch *DRW_cache_mesh_surface_get(struct Object *ob); struct GPUBatch *DRW_cache_mesh_surface_edges_get(struct Object *ob); struct GPUBatch **DRW_cache_mesh_surface_shaded_get(struct Object *ob, struct GPUMaterial **gpumat_array, - uint gpumat_array_len, - char **auto_layer_names, - int **auto_layer_is_srgb, - int *auto_layer_count); + uint gpumat_array_len); struct GPUBatch **DRW_cache_mesh_surface_texpaint_get(struct Object *ob); struct GPUBatch *DRW_cache_mesh_surface_texpaint_single_get(struct Object *ob); struct GPUBatch *DRW_cache_mesh_surface_vertpaint_get(struct Object *ob); |