forked from kysucix/gipuma
-
Notifications
You must be signed in to change notification settings - Fork 0
/
globalstate.h
45 lines (40 loc) · 1.06 KB
/
globalstate.h
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
45
#pragma once
#include "algorithmparameters.h"
#include "cameraparameters.h"
#include "linestate.h"
#include "imageinfo.h"
#include "managed.h"
// Includes CUDA
#include <cuda_runtime.h>
#include <cuda.h>
#include <cuda_runtime_api.h>
#include <builtin_types.h>
#include <cuda_texture_types.h>
// includes, cuda
#include <vector_types.h>
#include <driver_functions.h>
#include <cuda_runtime.h>
#include <cuda_texture_types.h>
#include <cuda_gl_interop.h>
#include <curand_kernel.h>
class GlobalState : public Managed {
public:
CameraParameters_cu *cameras;
LineState *lines;
curandState *cs;
AlgorithmParameters *params;
cudaTextureObject_t imgs [MAX_IMAGES];
cudaArray *cuArray[MAX_IMAGES];
//cudaTextureObject_t gradx [MAX_IMAGES];
//cudaTextureObject_t grady [MAX_IMAGES];
GlobalState() {
//printf("GlobalState constructor\n");
cameras = new CameraParameters_cu;
lines = new LineState;
}
~GlobalState() {
//printf("GlobalState destructor\n");
delete cameras;
delete lines;
}
};