|
Blender V5.0
|
#include <stddef.h>Go to the source code of this file.
Macros | |
| #define | CDF_TYPE_IMAGE 0 |
| #define | CDF_TYPE_MESH 1 |
| #define | CDF_LAYER_NAME_MAX 64 |
Typedefs | |
| typedef struct CDataFile | CDataFile |
| typedef struct CDataFileLayer | CDataFileLayer |
Functions | |
| CDataFile * | cdf_create (int type) |
| void | cdf_free (CDataFile *cdf) |
| bool | cdf_read_open (CDataFile *cdf, const char *filepath) |
| bool | cdf_read_layer (CDataFile *cdf, const CDataFileLayer *blay) |
| bool | cdf_read_data (CDataFile *cdf, unsigned int size, void *data) |
| void | cdf_read_close (CDataFile *cdf) |
| bool | cdf_write_open (CDataFile *cdf, const char *filepath) |
| bool | cdf_write_layer (CDataFile *cdf, CDataFileLayer *blay) |
| bool | cdf_write_data (CDataFile *cdf, unsigned int size, const void *data) |
| void | cdf_write_close (CDataFile *cdf) |
| void | cdf_remove (const char *filepath) |
| CDataFileLayer * | cdf_layer_find (CDataFile *cdf, int type, const char *name) |
| CDataFileLayer * | cdf_layer_add (CDataFile *cdf, int type, const char *name, size_t datasize) |
| #define CDF_LAYER_NAME_MAX 64 |
Definition at line 16 of file BKE_customdata_file.h.
| #define CDF_TYPE_IMAGE 0 |
Definition at line 13 of file BKE_customdata_file.h.
Referenced by cdf_read_header(), cdf_write_header(), and cdf_write_open().
| #define CDF_TYPE_MESH 1 |
Definition at line 14 of file BKE_customdata_file.h.
Referenced by cdf_read_header(), cdf_write_header(), cdf_write_open(), CustomData_external_read(), and CustomData_external_write().
| typedef struct CDataFile CDataFile |
Definition at line 18 of file BKE_customdata_file.h.
| typedef struct CDataFileLayer CDataFileLayer |
Definition at line 19 of file BKE_customdata_file.h.
| CDataFile * cdf_create | ( | int | type | ) |
Definition at line 91 of file customdata_file.cc.
References MEM_callocN(), and CDataFile::type.
Referenced by CustomData_external_read(), and CustomData_external_write().
| void cdf_free | ( | CDataFile * | cdf | ) |
Definition at line 100 of file customdata_file.cc.
References cdf_read_close(), cdf_write_close(), CDataFile::layer, and MEM_freeN().
Referenced by CustomData_external_read(), and CustomData_external_write().
| CDataFileLayer * cdf_layer_add | ( | CDataFile * | cdf, |
| int | type, | ||
| const char * | name, | ||
| size_t | datasize ) |
Definition at line 413 of file customdata_file.cc.
References CDF_DATA_FLOAT, CDataFileLayer::datasize, CDataFileLayer::datatype, CDataFile::layer, MEM_calloc_arrayN(), CDataFileLayer::name, name, STRNCPY(), CDataFileLayer::structbytes, CDataFile::totlayer, and CDataFileLayer::type.
Referenced by CustomData_external_write().
| CDataFileLayer * cdf_layer_find | ( | CDataFile * | cdf, |
| int | type, | ||
| const char * | name ) |
Definition at line 397 of file customdata_file.cc.
References CDataFile::layer, CDataFileLayer::name, name, STREQ, CDataFile::totlayer, and CDataFileLayer::type.
Referenced by CustomData_external_read(), and CustomData_external_write().
| void cdf_read_close | ( | CDataFile * | cdf | ) |
Definition at line 313 of file customdata_file.cc.
References CDataFile::readf.
Referenced by cdf_free(), cdf_read_open(), and CustomData_external_read().
Definition at line 300 of file customdata_file.cc.
References data, CDataFile::readf, and size().
Referenced by layerRead_mdisps().
| bool cdf_read_layer | ( | CDataFile * | cdf, |
| const CDataFileLayer * | blay ) |
Definition at line 282 of file customdata_file.cc.
References BLI_fseek(), CDataFile::dataoffset, CDataFileLayer::datasize, CDataFile::layer, CDataFile::readf, and CDataFile::totlayer.
Referenced by CustomData_external_read().
| bool cdf_read_open | ( | CDataFile * | cdf, |
| const char * | filepath ) |
Definition at line 258 of file customdata_file.cc.
References BLI_fopen(), cdf_read_close(), cdf_read_header(), CDataFile::header, CDataFile::readf, CDataFile::type, and CDataFileHeader::type.
Referenced by CustomData_external_read().
| void cdf_remove | ( | const char * | filepath | ) |
Definition at line 390 of file customdata_file.cc.
References BLI_delete().
| void cdf_write_close | ( | CDataFile * | cdf | ) |
Definition at line 382 of file customdata_file.cc.
References CDataFile::writef.
Referenced by cdf_free(), and CustomData_external_write().
Definition at line 372 of file customdata_file.cc.
References data, size(), and CDataFile::writef.
Referenced by layerWrite_mdisps().
| bool cdf_write_layer | ( | CDataFile * | cdf, |
| CDataFileLayer * | blay ) |
Definition at line 367 of file customdata_file.cc.
Referenced by CustomData_external_write().
| bool cdf_write_open | ( | CDataFile * | cdf, |
| const char * | filepath ) |
Definition at line 321 of file customdata_file.cc.
References BLI_fopen(), CDataFile::btype, cdf_endian(), CDF_SUBVERSION, CDF_TILE_SIZE, CDF_TYPE_IMAGE, CDF_TYPE_MESH, CDF_VERSION, cdf_write_header(), CDataFileHeader::endian, CDataFile::header, CDataFileHeader::ID, CDataFile::image, CDataFile::mesh, CDataFileHeader::structbytes, CDataFileImageHeader::structbytes, CDataFileMeshHeader::structbytes, CDataFileHeader::subversion, CDataFileImageHeader::tile_size, CDataFile::totlayer, CDataFileHeader::totlayer, CDataFile::type, CDataFileHeader::type, CDataFileHeader::version, and CDataFile::writef.
Referenced by CustomData_external_write().