diff options
author | Nicholas Bishop <nicholasbishop@gmail.com> | 2012-05-11 00:33:24 +0400 |
---|---|---|
committer | Nicholas Bishop <nicholasbishop@gmail.com> | 2012-05-11 00:33:24 +0400 |
commit | aa77bbd38daff45725d7e726e89f2e681cee863d (patch) | |
tree | b2db3709f12af1c7a67700ffc3c095cafdd1fa5c /source/blender/makesdna/DNA_meshdata_types.h | |
parent | f751d0f6ae7de155343e24e36965956bd7a061e3 (diff) |
Add DNA and customdata entries for paint masks.
CD_PAINT_MASK is a layer of per-vertex floats for non-multires
meshes. Multires meshes use CD_GRID_PAINT_MASK, which is a layer of
per-loop GridPaintMask structures. GridPaintMask is similar to MDisp,
but contains an array of scalar floats.
Note: the GridPaintMask could be folded into MDisp, but this way
should be easier to add mask layers in the future (if we do fold
GridPaintMask into MDisp, the mask array should probably be an array
of arrays with a 'totmask' field so that mask layers can be easily
supported.)
Includes blenload read/write support for CD_PAINT_MASK and
CD_GRID_PAINT_MASK.
Diffstat (limited to 'source/blender/makesdna/DNA_meshdata_types.h')
-rw-r--r-- | source/blender/makesdna/DNA_meshdata_types.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/source/blender/makesdna/DNA_meshdata_types.h b/source/blender/makesdna/DNA_meshdata_types.h index a0806481aea..ff23b37ad0c 100644 --- a/source/blender/makesdna/DNA_meshdata_types.h +++ b/source/blender/makesdna/DNA_meshdata_types.h @@ -247,6 +247,16 @@ typedef struct MRecast { int i; } MRecast; +typedef struct GridPaintMask { + /* The data array contains gridsize*gridsize elements */ + float *data; + + /* The maximum multires level associated with this grid */ + unsigned int level; + + int pad; +} GridPaintMask; + /* mvert->flag (1=SELECT) */ #define ME_SPHERETEST 2 #define ME_VERT_TMP_TAG 4 |