diff options
Diffstat (limited to 'source/blender/blenlib/BLI_array_store.h')
-rw-r--r-- | source/blender/blenlib/BLI_array_store.h | 47 |
1 files changed, 17 insertions, 30 deletions
diff --git a/source/blender/blenlib/BLI_array_store.h b/source/blender/blenlib/BLI_array_store.h index 5a7d21dd6f6..1dc4a504884 100644 --- a/source/blender/blenlib/BLI_array_store.h +++ b/source/blender/blenlib/BLI_array_store.h @@ -25,38 +25,25 @@ typedef struct BArrayState BArrayState; typedef struct BArrayStore BArrayStore; -BArrayStore *BLI_array_store_create( - unsigned int stride, unsigned int chunk_count); -void BLI_array_store_destroy( - BArrayStore *bs); -void BLI_array_store_clear( - BArrayStore *bs); +BArrayStore *BLI_array_store_create(unsigned int stride, unsigned int chunk_count); +void BLI_array_store_destroy(BArrayStore *bs); +void BLI_array_store_clear(BArrayStore *bs); /* find the memory used by all states (expanded & real) */ -size_t BLI_array_store_calc_size_expanded_get( - const BArrayStore *bs); -size_t BLI_array_store_calc_size_compacted_get( - const BArrayStore *bs); - -BArrayState *BLI_array_store_state_add( - BArrayStore *bs, - const void *data, const size_t data_len, - const BArrayState *state_reference); -void BLI_array_store_state_remove( - BArrayStore *bs, - BArrayState *state); - -size_t BLI_array_store_state_size_get( - BArrayState *state); -void BLI_array_store_state_data_get( - BArrayState *state, - void *data); -void *BLI_array_store_state_data_get_alloc( - BArrayState *state, - size_t *r_data_len); +size_t BLI_array_store_calc_size_expanded_get(const BArrayStore *bs); +size_t BLI_array_store_calc_size_compacted_get(const BArrayStore *bs); + +BArrayState *BLI_array_store_state_add(BArrayStore *bs, + const void *data, + const size_t data_len, + const BArrayState *state_reference); +void BLI_array_store_state_remove(BArrayStore *bs, BArrayState *state); + +size_t BLI_array_store_state_size_get(BArrayState *state); +void BLI_array_store_state_data_get(BArrayState *state, void *data); +void *BLI_array_store_state_data_get_alloc(BArrayState *state, size_t *r_data_len); /* only for tests */ -bool BLI_array_store_is_valid( - BArrayStore *bs); +bool BLI_array_store_is_valid(BArrayStore *bs); -#endif /* __BLI_ARRAY_STORE_H__ */ +#endif /* __BLI_ARRAY_STORE_H__ */ |