#include <include/flecs.h> FLECS_API int ecs_filter_finalize(const ecs_world_t *world, ecs_filter_t *filter)
Finalize filter. When manually assigning an array of terms to the filter struct (so not when using ecs_filter_init), this operation should be used to ensure that all terms are assigned properly and all (derived) fields have been set.
When ecs_filter_init is used to create the filter, this function should not be called. The purpose of this operation is to support creation of filters without allocating memory.
filter- The filter to finalize.
- Zero if filter is valid, non-zero if it contains errors. @