Open Sourcing: decora-compiler
joseph.andresen at oracle.com
Wed Nov 7 10:33:36 PST 2012
Just to avoid confusion here are some names.
Decora - An effects framework used by JavaFX.
decora-compiler - Name of the project we are open sourcing.
JSL - Name of the shader language in the decora-compiler project (ie.
Java Shader Language).
JSL is implemented using ANTLR... the jsl.g file contains the rules.
Also note that JSL is not a full implementation of a shader language
(haven't had a dire need for it).
We don't have support for some of the shader semantics like BINORMAL[n]
and NORMAL[n] (the vertex shader specific ones).
PS... DSL in Rich's email stood for "Domain Specific Language", not a
typo... but it confused me :).
On 11/6/2012 8:13 AM, Richard Bair wrote:
> I'm going to be open sourcing today another one of our projects called decora-compiler. We have our own DSL for shader languages called Decora. What we do is generate shaders for OpenGL and D3D from this language. We also generate Java code and SSE native code. For some shaders, we ended up generating them and then hand-tweaking them from there.
> The decora-compiler is used during the build process, but is not itself part of either the JDK or JRE, and so has mostly remained invisible to everybody. There is an "ME" based backend for JavaME which I don't think is even being used anymore, so there is stuff here we could remove to reduce the size of the project (and I will be filing a JIRA for this).
> decora-compiler isn't really that interesting in isolation, although at one time we had entertained the idea of popularizing it so that people could write their own shaders with JSL (the decora shader language), in which case the compiler would be part of the JDK such that you could create your own effects. Decora is predominantly used for the "effects" -- blur, box blur, etc. Although it is also used for prism shaders, we don't generate SSE or Java backends for those, and many of these have been tweaked by hand vs. simply generated.
More information about the openjfx-dev