-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathSDF_Hashtable.h
More file actions
44 lines (34 loc) · 1.05 KB
/
Copy pathSDF_Hashtable.h
File metadata and controls
44 lines (34 loc) · 1.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#ifndef SDF_HASHTABLE_H
#define SDF_HASHTABLE_H
#include <cuda.h>
#include <cuda_runtime_api.h>
#include <cuda_gl_interop.h>
#include <thrust/device_vector.h>
#include <thrust/device_ptr.h>
#include <thrust/device_malloc.h>
#include <thrust/device_allocator.h>
#include <glm/glm.hpp>
#include "VoxelDataStructures.h"
#include "cuda_helper/cuda_SimpleMatrixUtil.h"
#include "cuda_helper/helper_cuda.h"
using namespace glm;
using namespace thrust;
extern HashTableParams d_hashtableParams;
class SDFRenderer;
class SDF_Hashtable {
private:
HashTableParams h_hashtableParams;
struct cudaGraphicsResource *numVisibleBlocks_res;
struct cudaGraphicsResource *compactHashtable_res;
struct cudaGraphicsResource *sdfBlocks_res;
public:
SDF_Hashtable();
~SDF_Hashtable();
//Our hashtable needs to support these operations at the very least
//void deleteHashEntry(uint id);
//HashEntry deleteHashEntry(HashEntry& hashEntry);
void integrate(const float4x4& deltaT, const float4*, const float4*);
void registerGLtoCUDA(SDFRenderer&);
void unmapCUDApointers();
};
#endif