This is the last part of a series of posts about the new shader architecture in Processing 2.0. This post focuses on how to integrate low-level OpenGL calls with the standard Processing API. This integration has been possible since very early releases of the 1.0 branch, and allowed users through the use of OpenGL functions to implement advanced rendering functionality not available in Processing. The main drawback of the GL integration in Processing 1.x is that it makes the sketches incompatible with regular Processing code (other 3D renderers for example), and harder to understand by many users. Although the latter will continue to be problem as long as OpenGL calls are explicitly included in Processing sketches, the compatibility issue is addressed by Processing 2.0 now that OpenGL is much more deeply integrated with the P2D and P3D renderers.
Update: The shader API changed slightly in the betas, please refer to this post for more information.
Archive for the ‘opengl’ Tag
Shaders in Processing 2.0 – Part 3 Leave a comment
Shaders in Processing 2.0 – Part 1 3 comments
The new OpenGL renderers in Processing 2.0 (P2D/P3D) rely extensively on GLSL shaders. Although in most common situations the use of shaders is invisible to the user, Processing includes a new PShader class that allows to apply custom shaders to the drawing of the sketch. This post describes the shader architecture in Processing 2.0, and the common interfaces that custom GLSL shader code needs to include in order to be accepted by the OpenGL renderers in Processing.
Update: The shader API changed slightly in the betas, please refer to this post for more information.
OpenGL in Processing 2.0 alpha 5 14 comments
The march towards the 2.0 version of Processing reached an important milestone with the alpha 5 release, available for download since last Friday. The detailed list of changes is here, while the wiki offers a more in-depth discussion of the new features and ongoing changes. A major update in alpha 5 is the inclusion of the new OpenGL renderer for the desktop and Android modes, called P3D, which has been rewritten from the ground up in order to offer improved performance. I will describe some important elements of P3D in this post.
Syphon Client working in Processing 9 comments
Syphon is an OSX framework to share frames between applications. The authors of Syphon, Tom Butterworth and Anton Marini, made it very easy to create Syphon plugins for other languages, frameworks, VJ’ing and mapping tools, etc. So a while ago I wrote a simple Processing library that allowed to send frames out. This was quite useful, but still missing half of the Syphon functionality. With some additional coding, we were able to add the client part, and I just put the new version (0.4) of the Syphon-Processing library up for download (it requires Processing 2.0a4 or newer).
At Fathom (and first tablet app) Leave a comment
Hello! A few days ago I started working at Fathom, the information visualization studio run by Ben Fry. While here I will work on various data visualization projects, specially those requiring real-time, interactive graphics with OpenGL, as well as continue with my involvement with the development of the Processing language and environment. This job also encompasses an exciting collaboration with the lab of Pardis Sabeti at Harvard university, focused in the creation of new tools for visualizing epidemiological data and helping understand the factors that determine the origin and spread of various diseases. During my first week at Fathom I got started by working on an Android port of the “Stats of the Union” visualization, originally available for iPad tablets.