diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2016-07-12 01:01:38 +0300 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2016-07-12 01:07:44 +0300 |
commit | cfbd605567f48229a923df382baf6db98fbafc61 (patch) | |
tree | d4218c49672047d6c3b37517034660b3b5dcd966 /source/blender/makesdna | |
parent | 71a57a37b2eebbed53b5335019287b4df9c30519 (diff) | |
parent | 7212ebd09f9720883581221be923ae5e97ff5d76 (diff) |
Merge branch 'master' into blender2.8
Conflicts:
intern/cycles/blender/addon/ui.py
source/blender/blenkernel/BKE_particle.h
source/blender/blenkernel/intern/dynamicpaint.c
source/blender/blenkernel/intern/library.c
source/blender/blenkernel/intern/object.c
source/blender/blenkernel/intern/particle.c
source/blender/blenkernel/intern/particle_distribute.c
source/blender/blenkernel/intern/texture.c
source/blender/editors/object/object_add.c
source/blender/editors/object/object_relations.c
source/blender/editors/physics/particle_edit.c
source/blender/editors/physics/particle_object.c
source/blender/editors/transform/transform_snap_object.c
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r-- | source/blender/makesdna/DNA_ID.h | 2 | ||||
-rw-r--r-- | source/blender/makesdna/DNA_action_types.h | 5 | ||||
-rw-r--r-- | source/blender/makesdna/DNA_curve_types.h | 1 | ||||
-rw-r--r-- | source/blender/makesdna/DNA_genfile.h | 4 | ||||
-rw-r--r-- | source/blender/makesdna/DNA_scene_types.h | 1 | ||||
-rw-r--r-- | source/blender/makesdna/DNA_sdna_types.h | 3 | ||||
-rw-r--r-- | source/blender/makesdna/DNA_space_types.h | 4 | ||||
-rw-r--r-- | source/blender/makesdna/DNA_userdef_types.h | 5 | ||||
-rw-r--r-- | source/blender/makesdna/intern/dna_genfile.c | 20 |
9 files changed, 35 insertions, 10 deletions
diff --git a/source/blender/makesdna/DNA_ID.h b/source/blender/makesdna/DNA_ID.h index 5eb7afb4e00..60701e96edb 100644 --- a/source/blender/makesdna/DNA_ID.h +++ b/source/blender/makesdna/DNA_ID.h @@ -268,6 +268,8 @@ typedef struct PreviewImage { #define ID_MISSING(_id) (((_id)->tag & LIB_TAG_MISSING) != 0) +#define ID_IS_LINKED_DATABLOCK(_id) (((ID *)(_id))->lib != NULL) + #ifdef GS # undef GS #endif diff --git a/source/blender/makesdna/DNA_action_types.h b/source/blender/makesdna/DNA_action_types.h index 4d82e4528d6..9a19606d6c8 100644 --- a/source/blender/makesdna/DNA_action_types.h +++ b/source/blender/makesdna/DNA_action_types.h @@ -330,7 +330,7 @@ typedef enum ePchan_DrawFlag { /* PoseChannel->bboneflag */ typedef enum ePchan_BBoneFlag { - /* Use custom reference bones (for roll and handle alignment), instead of immediate neighbours */ + /* Use custom reference bones (for roll and handle alignment), instead of immediate neighbors */ PCHAN_BBONE_CUSTOM_HANDLES = (1 << 1), /* Evaluate start handle as being "relative" */ PCHAN_BBONE_CUSTOM_START_REL = (1 << 2), @@ -627,8 +627,9 @@ typedef enum eDopeSheet_FilterFlag { typedef enum eDopeSheet_Flag { ADS_FLAG_SUMMARY_COLLAPSED = (1 << 0), /* when summary is shown, it is collapsed, so all other channels get hidden */ ADS_FLAG_SHOW_DBFILTERS = (1 << 1), /* show filters for datablocks */ - + ADS_FLAG_FUZZY_NAMES = (1 << 2), /* use fuzzy/partial string matches when ADS_FILTER_BY_FCU_NAME is enabled (WARNING: expensive operation) */ + ADS_FLAG_NO_DB_SORT = (1 << 3), /* do not sort datablocks (mostly objects) by name (NOTE: potentially expensive operation) */ /* NOTE: datablock filter flags continued (1 << 10) onwards... */ } eDopeSheet_Flag; diff --git a/source/blender/makesdna/DNA_curve_types.h b/source/blender/makesdna/DNA_curve_types.h index 61169e4b1b1..902fa4ce987 100644 --- a/source/blender/makesdna/DNA_curve_types.h +++ b/source/blender/makesdna/DNA_curve_types.h @@ -424,6 +424,7 @@ typedef enum eBezTriple_KeyframeType { BEZT_KEYTYPE_EXTREME = 1, /* 'extreme' keyframe */ BEZT_KEYTYPE_BREAKDOWN = 2, /* 'breakdown' keyframe */ BEZT_KEYTYPE_JITTER = 3, /* 'jitter' keyframe (for adding 'filler' secondary motion) */ + BEZT_KEYTYPE_MOVEHOLD = 4, /* one end of a 'moving hold' */ } eBezTriple_KeyframeType; /* checks if the given BezTriple is selected */ diff --git a/source/blender/makesdna/DNA_genfile.h b/source/blender/makesdna/DNA_genfile.h index d62369803d6..77877f7bada 100644 --- a/source/blender/makesdna/DNA_genfile.h +++ b/source/blender/makesdna/DNA_genfile.h @@ -74,7 +74,9 @@ enum eSDNA_StructCompare { SDNA_CMP_NOT_EQUAL = 2, }; -struct SDNA *DNA_sdna_from_data(const void *data, const int datalen, bool do_endian_swap); +struct SDNA *DNA_sdna_from_data( + const void *data, const int datalen, + bool do_endian_swap, bool data_alloc); void DNA_sdna_free(struct SDNA *sdna); int DNA_struct_find_nr(struct SDNA *sdna, const char *str); diff --git a/source/blender/makesdna/DNA_scene_types.h b/source/blender/makesdna/DNA_scene_types.h index 2928e10d215..87b6813712f 100644 --- a/source/blender/makesdna/DNA_scene_types.h +++ b/source/blender/makesdna/DNA_scene_types.h @@ -902,6 +902,7 @@ typedef struct GameData { #define GAME_GLSL_NO_COLOR_MANAGEMENT (1 << 15) #define GAME_SHOW_OBSTACLE_SIMULATION (1 << 16) #define GAME_NO_MATERIAL_CACHING (1 << 17) +#define GAME_GLSL_NO_ENV_LIGHTING (1 << 18) /* Note: GameData.flag is now an int (max 32 flags). A short could only take 16 flags */ /* GameData.playerflag */ diff --git a/source/blender/makesdna/DNA_sdna_types.h b/source/blender/makesdna/DNA_sdna_types.h index cb7a371c7c5..791aca77558 100644 --- a/source/blender/makesdna/DNA_sdna_types.h +++ b/source/blender/makesdna/DNA_sdna_types.h @@ -35,8 +35,9 @@ # # typedef struct SDNA { - char *data; /* full copy of 'encoded' data */ + const char *data; /* full copy of 'encoded' data */ int datalen; /* length of data */ + bool data_alloc; int nr_names; /* total number of struct members */ const char **names; /* struct member names */ diff --git a/source/blender/makesdna/DNA_space_types.h b/source/blender/makesdna/DNA_space_types.h index 8f85a62e527..4c5cb5a473a 100644 --- a/source/blender/makesdna/DNA_space_types.h +++ b/source/blender/makesdna/DNA_space_types.h @@ -252,7 +252,7 @@ typedef struct SpaceOops { struct BLI_mempool *treestore; /* search stuff */ - char search_string[32]; + char search_string[64]; struct TreeStoreElem search_tse; short flag, outlinevis, storeflag, search_flags; @@ -412,6 +412,8 @@ typedef enum eSpaceNla_Flag { SNLA_NOSTRIPCURVES = (1 << 5), /* don't perform realtime updates */ SNLA_NOREALTIMEUPDATES = (1 << 6), + /* don't show local strip marker indications */ + SNLA_NOLOCALMARKERS = (1 << 7), } eSpaceNla_Flag; diff --git a/source/blender/makesdna/DNA_userdef_types.h b/source/blender/makesdna/DNA_userdef_types.h index 1c64522cd83..d338d279b72 100644 --- a/source/blender/makesdna/DNA_userdef_types.h +++ b/source/blender/makesdna/DNA_userdef_types.h @@ -284,7 +284,10 @@ typedef struct ThemeSpace { char nodeclass_pattern[4], nodeclass_layout[4]; char movie[4], movieclip[4], mask[4], image[4], scene[4], audio[4]; /* for sequence editor */ - char effect[4], transition[4], meta[4], text_strip[4], pad[4]; + char effect[4], transition[4], meta[4], text_strip[4]; + + float keyframe_scale_fac; /* for dopesheet - scale factor for size of keyframes (i.e. height of channels) */ + char editmesh_active[4]; char handle_vertex[4]; diff --git a/source/blender/makesdna/intern/dna_genfile.c b/source/blender/makesdna/intern/dna_genfile.c index 99ab29fbdcc..9135d7bab7d 100644 --- a/source/blender/makesdna/intern/dna_genfile.c +++ b/source/blender/makesdna/intern/dna_genfile.c @@ -196,7 +196,10 @@ int DNA_elem_array_size(const char *str) void DNA_sdna_free(SDNA *sdna) { - MEM_freeN(sdna->data); + if (sdna->data_alloc) { + MEM_freeN((void *)sdna->data); + } + MEM_freeN((void *)sdna->names); MEM_freeN(sdna->types); MEM_freeN(sdna->structs); @@ -549,15 +552,24 @@ static void init_structDNA(SDNA *sdna, bool do_endian_swap) /** * Constructs and returns a decoded SDNA structure from the given encoded SDNA data block. */ -SDNA *DNA_sdna_from_data(const void *data, const int datalen, bool do_endian_swap) +SDNA *DNA_sdna_from_data( + const void *data, const int datalen, + bool do_endian_swap, bool data_alloc) { SDNA *sdna = MEM_mallocN(sizeof(*sdna), "sdna"); sdna->lastfind = 0; sdna->datalen = datalen; - sdna->data = MEM_mallocN(datalen, "sdna_data"); - memcpy(sdna->data, data, datalen); + if (data_alloc) { + char *data_copy = MEM_mallocN(datalen, "sdna_data"); + memcpy(data_copy, data, datalen); + sdna->data = data_copy; + } + else { + sdna->data = data; + } + sdna->data_alloc = data_alloc; init_structDNA(sdna, do_endian_swap); |