VTK
vtkOSPRayVolumeCache.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkOSPRayVolumeCache.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
26 #ifndef vtkOSPRayVolumeCache_h
27 #define vtkOSPRayVolumeCache_h
28 
29 #include "vtkRenderingOSPRayModule.h" // For export macro
30 #include "vtkSystemIncludes.h" //dll warning suppression
31 #include <map> // for stl
32 
33 #include "ospray/ospray.h" // for ospray handle types
34 
35 class VTKRENDERINGOSPRAY_EXPORT vtkOSPRayVolumeCache {
36 public:
39 
43  void AddToCache(double tstep, OSPVolume payload);
44 
49  OSPVolume GetFromCache(double tstep);
50 
52 
56  void SetSize(int);
57  int GetSize();
59 
60 private:
61 
62  // deletes all of the content in the cache
63  void Empty();
64  int Size;
65 
66  std::map<double, OSPVolume> Contents;
67 };
68 
69 #endif //vtkOSPRayVolumeCache_h
70 // VTK-HeaderTest-Exclude: vtkOSPRayVolumeCache.h
temporal cache ospray structures to speed flipbooks