| 900 | //////////////////////////////////////////////////////////////////////////////// |
| 901 | #ifndef USE_TEXSUBIMAGE2D |
| 902 | void initCUDABuffers() |
| 903 | { |
| 904 | // set up vertex data parameter |
| 905 | num_texels = image_width * image_height; |
| 906 | num_values = num_texels * 4; |
| 907 | size_tex_data = sizeof(GLubyte) * num_values; |
| 908 | checkCudaErrors(cudaMalloc((void **)&cuda_dest_resource, size_tex_data)); |
| 909 | // checkCudaErrors(cudaHostAlloc((void**)&cuda_dest_resource, size_tex_data, |
| 910 | // )); |
| 911 | } |
| 912 | #endif |
| 913 | |
| 914 | //////////////////////////////////////////////////////////////////////////////// |