Fix build error with GCC, make depsgraph iterator compatible with C++.

This commit is contained in:
2018-04-09 15:01:41 +02:00
parent 867f96c234
commit d533b70b23
2 changed files with 7 additions and 6 deletions

View File

@@ -86,11 +86,12 @@ typedef enum eDepsObjectIteratorMode {
typedef struct DEGObjectIterData {
struct Depsgraph *graph;
eDepsObjectIteratorMode mode;
int flag;
struct Scene *scene;
struct EvaluationContext eval_ctx;
int flag;
eDepsObjectIteratorMode mode;
int visibility_check; /* eObjectVisibilityCheck. */
/* **** Iteration over dupli-list. *** */
@@ -127,9 +128,9 @@ void DEG_iterator_objects_end(struct BLI_Iterator *iter);
#define DEG_OBJECT_ITER_BEGIN(graph_, instance_, mode_, flag_) \
{ \
DEGObjectIterData data_ = { \
.graph = (graph_), \
.mode = (mode_), \
.flag = (flag_), \
graph_, \
mode_, \
flag_ \
}; \
\
ITER_BEGIN(DEG_iterator_objects_begin, \

View File

@@ -60,9 +60,9 @@ extern "C" {
#include "BLI_iterator.h"
#include "BLI_listbase.h"
#include "BLI_math.h"
}
#include "DEG_depsgraph_query.h"
}
#ifdef WITH_CXX_GUARDEDALLOC
#include "MEM_guardedalloc.h"