Cleanup: Use std::mutex for mesh runtime mutexes

Instead of allocating three separate ThreadMutex pointers,
just embed std::mutex into the struct directly.
This commit is contained in:
2022-10-12 22:31:02 -05:00
parent 375dafe3ef
commit c67e5628d2
13 changed files with 53 additions and 104 deletions

View File

@@ -9,6 +9,10 @@
#pragma once
#ifdef __cplusplus
# include <mutex>
#endif
#include "DNA_customdata_types.h"
#include "DNA_meshdata_types.h"
@@ -56,9 +60,11 @@ BLI_STATIC_ASSERT(sizeof(DRW_MeshCDMask) <= sizeof(uint32_t), "DRW_MeshCDMask ex
void drw_attributes_clear(DRW_Attributes *attributes);
#ifdef __cplusplus
void drw_attributes_merge(DRW_Attributes *dst,
const DRW_Attributes *src,
ThreadMutex *render_mutex);
std::mutex &render_mutex);
#endif
/* Return true if all requests in b are in a. */
bool drw_attributes_overlap(const DRW_Attributes *a, const DRW_Attributes *b);