| 185 | */ |
| 186 | template <typename vtkDataObjT> |
| 187 | void UpdateGeometryIfRequired(vtkDataObjT* data, vtkCompositeDataSet* compositeData, bool useCache, |
| 188 | bool meshGeometryChanged, vtkDataObjectMeshCache* meshCache) |
| 189 | { |
| 190 | if (useCache) |
| 191 | { |
| 192 | if (!meshGeometryChanged) |
| 193 | { |
| 194 | if (compositeData) |
| 195 | { |
| 196 | meshCache->CopyCacheToDataObject(compositeData); |
| 197 | } |
| 198 | else |
| 199 | { |
| 200 | meshCache->CopyCacheToDataObject(data); |
| 201 | } |
| 202 | } |
| 203 | else |
| 204 | { |
| 205 | if (compositeData) |
| 206 | { |
| 207 | meshCache->UpdateCache(compositeData); |
| 208 | } |
| 209 | else |
| 210 | { |
| 211 | meshCache->UpdateCache(data); |
| 212 | } |
| 213 | } |
| 214 | } |
| 215 | } |
| 216 | |
| 217 | } |
| 218 |
no test coverage detected