예제 #1
0
 /**
  * The program that this kernel belongs to
  *
  * @param kernel The kernel
  * @return The value
  */
 public static cl_program getProgram(cl_kernel kernel) {
   cl_program result = new cl_program();
   Infos.getPointer(Infos.FOR_KERNEL, kernel, CL_KERNEL_PROGRAM, result);
   if (result.equals(new cl_program())) {
     return null;
   }
   return result;
 }
예제 #2
0
 /**
  * The context of the program.
  *
  * @param program The program
  * @return The value
  */
 public static cl_context getContext(cl_program program) {
   cl_context result = new cl_context();
   Infos.getPointer(Infos.FOR_PROGRAM, program, CL_PROGRAM_CONTEXT, result);
   if (result.equals(new cl_context())) {
     return null;
   }
   return result;
 }
예제 #3
0
 /**
  * The context that this kernel belongs to
  *
  * @param kernel The kernel
  * @return The value
  */
 public static cl_context getContext(cl_kernel kernel) {
   cl_context result = new cl_context();
   Infos.getPointer(Infos.FOR_KERNEL, kernel, CL_KERNEL_CONTEXT, result);
   if (result.equals(new cl_context())) {
     return null;
   }
   return result;
 }