Skip to content

Commit

Permalink
improved javadoc.
Browse files Browse the repository at this point in the history
  • Loading branch information
mbien committed Feb 8, 2011
1 parent 3ed09af commit 8e915ca
Showing 1 changed file with 26 additions and 1 deletion.
27 changes: 26 additions & 1 deletion src/com/jogamp/opencl/CLPlatform.java
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,32 @@
import static com.jogamp.opencl.CL.*;

/**
* CLPlatfrorm representing an OpenCL installation (e.g. graphics driver).
* CLPlatfrorm representing a OpenCL implementation (e.g. graphics driver).
*
* optional eager initialization:
* <p><pre>
* try{
* CLPlatform.initialize();
* }catch(JogampRuntimeException ex) {
* throw new RuntimeException("could not load Java OpenCL Binding");
* }
* </pre></p>
*
* Example initialization:
* <p><pre>
* CLPlatform platform = CLPlatform.getDefault(type(GPU));
*
* if(platform == null) {
* throw new RuntimeException("please update your graphics drivers");
* }
*
* CLContext context = CLContext.create(platform.getMaxFlopsDevice());
* try {
* // use it
* }finally{
* context.release();
* }
* </pre></p>
*
* @author Michael Bien
* @see #initialize()
Expand Down

0 comments on commit 8e915ca

Please sign in to comment.