22 lines
605 B
C
22 lines
605 B
C
|
#include <voxula/internals/ecs/lookup.h>
|
||
|
#include <voxula/internals/ecs/head.h>
|
||
|
#include <stdlib.h>
|
||
|
|
||
|
vecs_s * vecs_new()
|
||
|
{
|
||
|
vecs_s *ecs = malloc(sizeof(vecs_s));
|
||
|
ecs->resolver = vecs_create_tag_name_resolver();
|
||
|
ecs->lookup_map = vecs_create_lookup_map();
|
||
|
ecs->shadow_pool = vx_new_pool(sizeof(vecs_shadow_s), 8192);
|
||
|
ecs->tag_pool = vx_new_pool(sizeof(vecs_tag_s), 32768);
|
||
|
ecs->uuid_table = vx_new_uuid_table();
|
||
|
return ecs;
|
||
|
}
|
||
|
|
||
|
void vecs_free(vecs_s *ecs)
|
||
|
{
|
||
|
vecs_delete_tag_name_resolver(&ecs->resolver);
|
||
|
vx_free_pool(ecs->shadow_pool);
|
||
|
vx_free_pool(ecs->tag_pool);
|
||
|
}
|