Blender V2.61 - r43446
|
#include <string.h>
#include "MEM_guardedalloc.h"
#include "BKE_bmeshCustomData.h"
#include "bmesh_private.h"
Go to the source code of this file.
Classes | |
struct | BME_LayerTypeInfo |
Typedefs | |
typedef struct BME_LayerTypeInfo | BME_LayerTypeInfo |
Functions | |
static const BME_LayerTypeInfo * | BME_layerType_getInfo (int type) |
void | BME_CD_Create (BME_CustomData *data, BME_CustomDataInit *init, int initalloc) |
void | BME_CD_Free (BME_CustomData *data) |
void | BME_CD_free_block (BME_CustomData *data, void **block) |
static void | BME_CD_alloc_block (BME_CustomData *data, void **block) |
void | BME_CD_copy_data (const BME_CustomData *source, BME_CustomData *dest, void *src_block, void **dest_block) |
void | BME_CD_set_default (BME_CustomData *data, void **block) |
Variables | |
const BME_LayerTypeInfo | BMELAYERTYPEINFO [BME_CD_NUMTYPES] |
Definition in file BME_Customdata.c.
typedef struct BME_LayerTypeInfo BME_LayerTypeInfo |
static void BME_CD_alloc_block | ( | BME_CustomData * | data, |
void ** | block | ||
) | [static] |
Definition at line 127 of file BME_Customdata.c.
References BLI_mempool_alloc(), BME_CD_free_block(), NULL, BME_CustomData::pool, and BME_CustomData::totsize.
Referenced by BME_CD_copy_data(), and BME_CD_set_default().
void BME_CD_copy_data | ( | const BME_CustomData * | source, |
BME_CustomData * | dest, | ||
void * | src_block, | ||
void ** | dest_block | ||
) |
Definition at line 138 of file BME_Customdata.c.
References BME_CD_alloc_block(), BME_layerType_getInfo(), BME_LayerTypeInfo::copy, BME_CustomData::layers, BME_CustomDataLayer::name, BME_CustomDataLayer::offset, BME_LayerTypeInfo::size, BME_CustomData::totlayer, and BME_CustomDataLayer::type.
void BME_CD_Create | ( | BME_CustomData * | data, |
BME_CustomDataInit * | init, | ||
int | initalloc | ||
) |
Definition at line 65 of file BME_Customdata.c.
References BME_CustomDataInit::active, BME_CustomDataLayer::active, BLI_mempool_create(), BME_CD_NUMTYPES, BME_layerType_getInfo(), FALSE, i, BME_CustomData::layers, BME_CustomDataInit::layout, MEM_callocN(), BME_CustomDataLayer::name, BME_CustomDataInit::nametemplate, NULL, BME_CustomDataLayer::offset, BME_CustomData::pool, BME_LayerTypeInfo::size, BME_CustomData::totlayer, BME_CustomData::totsize, and BME_CustomDataLayer::type.
void BME_CD_Free | ( | BME_CustomData * | data | ) |
Definition at line 103 of file BME_Customdata.c.
References BLI_mempool_destroy(), and BME_CustomData::pool.
void BME_CD_free_block | ( | BME_CustomData * | data, |
void ** | block | ||
) |
Definition at line 109 of file BME_Customdata.c.
References BLI_mempool_free(), BME_layerType_getInfo(), BME_LayerTypeInfo::free, i, BME_CustomData::layers, NULL, BME_CustomDataLayer::offset, BME_CustomData::pool, BME_LayerTypeInfo::size, BME_CustomData::totlayer, and BME_CustomDataLayer::type.
Referenced by BME_CD_alloc_block().
void BME_CD_set_default | ( | BME_CustomData * | data, |
void ** | block | ||
) |
Definition at line 182 of file BME_Customdata.c.
References BME_CD_alloc_block(), BME_layerType_getInfo(), i, BME_CustomData::layers, BME_CustomDataLayer::offset, BME_LayerTypeInfo::set_default, BME_CustomData::totlayer, and BME_CustomDataLayer::type.
static const BME_LayerTypeInfo* BME_layerType_getInfo | ( | int | type | ) | [static] |
Definition at line 59 of file BME_Customdata.c.
References CD_NUMTYPES, and NULL.
Referenced by BME_CD_copy_data(), BME_CD_Create(), BME_CD_free_block(), and BME_CD_set_default().
const BME_LayerTypeInfo BMELAYERTYPEINFO[BME_CD_NUMTYPES] |
{ {sizeof(BME_facetex), "TexFace", NULL, NULL, NULL, NULL}, {sizeof(BME_looptex), "UV", NULL, NULL, NULL, NULL}, {sizeof(BME_loopcol), "VCol", NULL, NULL, NULL, NULL}, {sizeof(BME_DeformVert), "Group", NULL, NULL, NULL, NULL} }
Definition at line 53 of file BME_Customdata.c.