Results 1 to 2 of 2

Thread: User defined functions in OpenCL code

  1. #1

    User defined functions in OpenCL code

    Is it possible to create our own functions in OpenCL code, so that the kernels could call them? Where can I see some simple example of doing this?

  2. #2
    Member
    Join Date
    Nov 2009
    Location
    Scotland
    Posts
    72

    Re: User defined functions in OpenCL code

    Quote Originally Posted by Rui
    Is it possible to create our own functions in OpenCL code, so that the kernels could call them? Where can I see some simple example of doing this?
    Yes, you can simply define functions in your .cl file. They look just like kernel functions, but without the __kernel keyword. You can probably find examples in the NVidia or ATI Stream SDK.

Similar Threads

  1. user defined data types in OpenCL
    By Linuxboy2007 in forum OpenCL
    Replies: 0
    Last Post: 10-12-2012, 06:12 AM
  2. What do you think of user defined clip plane
    By sichen78 in forum OpenGL ES general technical discussions
    Replies: 0
    Last Post: 06-01-2005, 09:40 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •