Commit 7aca649a authored by Balint Balazs's avatar Balint Balazs
Browse files

simplified calling closeDirectCudaCompress and directCudaCompress

parent 3e70a0ba
......@@ -495,19 +495,19 @@ extern "C" {
return 0;
}
int closeDirectCudaCompress(GPUResources** res) {
(*res)->destroy();
delete *res;
int closeDirectCudaCompress(GPUResources* res) {
res->destroy();
delete res;
return 0;
}
int directCudaCompress(hid_t dset_id, hsize_t* offset, size_t* size, void* data,
uint dwtLevels, float quantStep, float bgLevel, int tileSize, float conversion, float readNoise, int onDevice, GPUResources** pRes) {
uint dwtLevels, float quantStep, float bgLevel, int tileSize, float conversion, float readNoise, int onDevice, GPUResources* res) {
herr_t r;
int outDataLength;
cudaError status;
GPUResources* res = *pRes;
//GPUResources* res = *pRes;
uint sizeX = size[2];
uint sizeY = size[1];
......
......@@ -74,8 +74,8 @@ herr_t H5Z_cudaCompress_set_local(hid_t dcpl, hid_t type, hid_t space);
size_t H5Z_cudaCompress_filter(unsigned int flags, size_t cd_nelmts, const unsigned int cd_values[], size_t nbytes, size_t *buf_size, void **buf);
DLL int initDirectCudaCompress(const size_t* size, GPUResources** res);
DLL int closeDirectCudaCompress(GPUResources** res);
DLL int directCudaCompress(hid_t dset_id, hsize_t* offset, size_t* size, void* data, uint dwtLevels, float quantStep, float bgLevel, int tileSize, float conversion, float readNoise, int onDevice, GPUResources** res);
DLL int closeDirectCudaCompress(GPUResources* res);
DLL int directCudaCompress(hid_t dset_id, hsize_t* offset, size_t* size, void* data, uint dwtLevels, float quantStep, float bgLevel, int tileSize, float conversion, float readNoise, int onDevice, GPUResources* res);
#ifdef __cplusplus
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment