@@ -87,8 +87,7 @@ class TestVtkScene : public AbstractCellBasedTestSuite
87
87
CellsGenerator<UniformCellCycleModel, 2 > cells_generator;
88
88
cells_generator.GenerateBasicRandom (cells, p_mesh->GetNumElements (), p_transit_type);
89
89
90
- boost::shared_ptr<PottsBasedCellPopulation<2 > > p_cell_population =
91
- boost::shared_ptr<PottsBasedCellPopulation<2 > >(new PottsBasedCellPopulation<2 > (*p_mesh, cells));
90
+ auto p_cell_population = boost::make_shared<PottsBasedCellPopulation<2 > >(*p_mesh, cells);
92
91
p_cell_population->SetTemperature (0.1 );
93
92
p_cell_population->SetNumSweepsPerTimestep (1 );
94
93
@@ -98,14 +97,14 @@ class TestVtkScene : public AbstractCellBasedTestSuite
98
97
simulator.SetDt (0.1 );
99
98
simulator.SetSamplingTimestepMultiple (10 );
100
99
101
- boost::shared_ptr<VtkScene< 2 > > p_scene = boost::shared_ptr <VtkScene<2 > >(new VtkScene< 2 > );
100
+ auto p_scene = boost::make_shared <VtkScene<2 > >();
102
101
p_scene->SetCellPopulation (p_cell_population);
103
102
p_scene->SetIsInteractive (true );
104
103
p_scene->SetSaveAsImages (false );
105
104
p_scene->GetCellPopulationActorGenerator ()->SetShowPottsMeshEdges (true );
106
105
p_scene->SetOutputFilePath (file_handler1.GetOutputDirectoryFullPath ()+" /cell_population" );
107
106
108
- boost::shared_ptr<VtkSceneModifier< 2 > > p_scene_modifier = boost::shared_ptr <VtkSceneModifier<2 > >(new VtkSceneModifier< 2 > );
107
+ auto p_scene_modifier = boost::make_shared <VtkSceneModifier<2 > >();
109
108
p_scene_modifier->SetVtkScene (p_scene);
110
109
p_scene_modifier->SetUpdateFrequency (10 );
111
110
p_scene->Start ();
@@ -132,8 +131,7 @@ class TestVtkScene : public AbstractCellBasedTestSuite
132
131
CellsGenerator<UniformCellCycleModel, 3 > cells_generator;
133
132
cells_generator.GenerateBasicRandom (cells, p_mesh->GetNumElements (), p_transit_type);
134
133
135
- boost::shared_ptr<PottsBasedCellPopulation<3 > > p_cell_population =
136
- boost::shared_ptr<PottsBasedCellPopulation<3 > >(new PottsBasedCellPopulation<3 > (*p_mesh, cells));
134
+ auto p_cell_population = boost::make_shared<PottsBasedCellPopulation<3 > >(*p_mesh, cells);
137
135
p_cell_population->SetTemperature (0.1 );
138
136
p_cell_population->SetNumSweepsPerTimestep (1 );
139
137
@@ -143,15 +141,15 @@ class TestVtkScene : public AbstractCellBasedTestSuite
143
141
simulator.SetDt (0.1 );
144
142
simulator.SetSamplingTimestepMultiple (100 );
145
143
146
- boost::shared_ptr<VtkScene< 3 > > p_scene = boost::shared_ptr <VtkScene<3 > >(new VtkScene< 3 > );
144
+ auto p_scene = boost::make_shared <VtkScene<3 > >();
147
145
p_scene->SetCellPopulation (p_cell_population);
148
146
p_scene->SetIsInteractive (true );
149
147
p_scene->SetSaveAsImages (false );
150
148
p_scene->GetCellPopulationActorGenerator ()->SetShowCellCentres (true );
151
149
p_scene->GetCellPopulationActorGenerator ()->SetShowPottsMeshOutlines (true );
152
150
p_scene->SetOutputFilePath (file_handler1.GetOutputDirectoryFullPath ()+" /cell_population" );
153
151
154
- boost::shared_ptr<VtkSceneModifier< 3 > > p_scene_modifier = boost::shared_ptr <VtkSceneModifier<3 > >(new VtkSceneModifier< 3 > );
152
+ auto p_scene_modifier = boost::make_shared <VtkSceneModifier<3 > >();
155
153
p_scene_modifier->SetVtkScene (p_scene);
156
154
p_scene->Start ();
157
155
0 commit comments