[Bf-blender-cvs] [6deb908a5c9] blender2.8: Merge branch 'master' into blender2.8

Sergey Sharybin noreply at git.blender.org
Tue Jan 9 16:16:09 CET 2018


Commit: 6deb908a5c9f34deb4c19561082b14d8eda51e43
Author: Sergey Sharybin
Date:   Tue Jan 9 16:15:33 2018 +0100
Branches: blender2.8
https://developer.blender.org/rB6deb908a5c9f34deb4c19561082b14d8eda51e43

Merge branch 'master' into blender2.8

===================================================================



===================================================================

diff --cc source/blender/depsgraph/intern/eval/deg_eval.cc
index ee58a3b02a5,565bb041cb6..38a7470c0ec
--- a/source/blender/depsgraph/intern/eval/deg_eval.cc
+++ b/source/blender/depsgraph/intern/eval/deg_eval.cc
@@@ -100,9 -104,12 +100,11 @@@ static void deg_task_run_func(TaskPool 
  
  typedef struct CalculatePengindData {
  	Depsgraph *graph;
 -	unsigned int layers;
  } CalculatePengindData;
  
- static void calculate_pending_func(void *data_v, int i)
+ static void calculate_pending_func(void *data_v,
+                                    int i,
+                                    const ParallelRangeTLS * /*tls*/)
  {
  	CalculatePengindData *data = (CalculatePengindData *)data_v;
  	Depsgraph *graph = data->graph;
@@@ -126,12 -140,16 +128,15 @@@
  	}
  }
  
 -static void calculate_pending_parents(Depsgraph *graph, unsigned int layers)
 +static void calculate_pending_parents(Depsgraph *graph)
  {
  	const int num_operations = graph->operations.size();
- 	const bool do_threads = num_operations > 256;
+ 	const bool do_threads = (num_operations > 256);
  	CalculatePengindData data;
  	data.graph = graph;
 -	data.layers = layers;
+ 	ParallelRangeSettings settings;
+ 	BLI_parallel_range_settings_defaults(&settings);
+ 	settings.use_threading = do_threads;
  	BLI_task_parallel_range(0,
  	                        num_operations,
  	                        &data,
diff --cc source/blender/depsgraph/intern/eval/deg_eval_flush.cc
index af1d09ad54a,7650e907c0b..6dc35bb8aba
--- a/source/blender/depsgraph/intern/eval/deg_eval_flush.cc
+++ b/source/blender/depsgraph/intern/eval/deg_eval_flush.cc
@@@ -71,7 -70,22 +71,9 @@@ typedef std::deque<OperationDepsNode *
  
  namespace {
  
- void flush_init_operation_node_func(void *data_v, int i)
 -// TODO(sergey): De-duplicate with depsgraph_tag,cc
 -void lib_id_recalc_tag(Main *bmain, ID *id)
 -{
 -	id->recalc |= ID_RECALC;
 -	DEG_id_type_tag(bmain, GS(id->name));
 -}
 -
 -void lib_id_recalc_data_tag(Main *bmain, ID *id)
 -{
 -	id->recalc |= ID_RECALC_DATA;
 -	DEG_id_type_tag(bmain, GS(id->name));
 -}
 -
+ void flush_init_operation_node_func(void *data_v,
+                                     int i,
+                                     const ParallelRangeTLS * /*tls*/)
  {
  	Depsgraph *graph = (Depsgraph *)data_v;
  	OperationDepsNode *node = graph->operations[i];
@@@ -275,10 -290,12 +289,12 @@@ void deg_graph_flush_updates(Main *bmai
  		}
  	}
  	/* Inform editors about all changes. */
 -	flush_editors_id_update(bmain, graph);
 +	flush_editors_id_update(bmain, graph, &update_ctx);
  }
  
- static void graph_clear_func(void *data_v, int i)
+ static void graph_clear_func(void *data_v,
+                              int i,
+                              const ParallelRangeTLS * /*tls*/)
  {
  	Depsgraph *graph = (Depsgraph *)data_v;
  	OperationDepsNode *node = graph->operations[i];



More information about the Bf-blender-cvs mailing list