You can clone with
HTTPS or Subversion.
First of all thanks for this nice tool. coding in glsl make far much sense :)
In Stage3d the only way to configure the sampler seems to be through agal. How do we deal we that ?
For example, let say I want the sampler to have the nearest filter instead of the linear filter.
In agal I add "nearest" instead of "linear" in the sampler options but since here the agal is generated from glsl, how can I specify to use nearest filter. Should we add this to the json config so that if you wanted to use the glsl on its own (in a native app) the native app could read that json and figure out what filter (or other sampler option) to apply?
Or maybe there a way to do it in glsl?
There's a feature coming in a future version of Flash Player you could use to configure all the sampler options per texture.
Context3D.setSamplerStateAt( index:int, wrapMode:String, filter:String, mipFilter:String )
There was a beta of the AIR 3.6 SDK with a preview of this (and other) features. But the link I used to get it no longer works . . .
We've solved this problem by patching the compiled byte code. Can't post the method because of copyright issues but it's less than 100 lines long. For a description of the AGAL opcodes see
But good to know that the next flash player will have the setSamplerStateAt method.
How can I handle the ATF textures? I think I need to use "tex ft0.xyzw, v0.xyyy, fs0 " in agal. However, glsl2agal seems not yet support atf