1 Reply Latest reply on Sep 8, 2011 6:29 AM by himanshu.gautam

    How to create my own function?


      Hello. I was wondering whether it is possible to create multiple functions. For example function for creating context, command_queue, building kernel....?

      I'm a bit confused because I do not know what the specific function returns. For example function for creating context would return context.

      To illustrate what I mean:

      create_context() {

      create context.....;

              return context;





      Is it possible to create functions like this in my main program?