Skip to content
fifield edited this page Dec 20, 2011 · 3 revisions

node-webcl wiki

Introduction

node-webcl is an implementation of WebCL for node.js. WebCL is a set of bindings of OpenCL for JavaScript. There is currently no standardized API for WebCL. This implementation of WebCL for node.js is similar to the API proposed by Nokia Research.

Installation

node-webcl first requires that you have an OpenCL SDK installed. Once that is done, continue below.

Linux

If the location of your OpenCL header and library files are not in the default search path of the compiler, add the following environment varables:

$ export OPENCL_LIB_PATH=path_to_libOpenCL.so
$ export OPENCL_INC_PATH=path_to_OpenCL_headers

Then install using npm:
$ cd my_install_path
$ npm install webcl

The node-webcl module currently uses a dynamic library written by Nokia. So you must next make sure this is in the search path:
$ cd webcl
$ export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$PWD/build

Now test that the installation worked:
$ examples/lesson1.js 
Excellent! Your system does support WebCL.

Other Operating Systems

node-webcl is currently developed and tested on Linux. If you are using node-webcl on a different platform, please consider contributing any instructions specific to your environment.

API Reference

The API Reference describes the WebCL API implemented in node-webcl.

Examples

Clone this wiki locally