summaryrefslogtreecommitdiff
path: root/src/mesa/shader/slang/library
AgeCommit message (Collapse)Author
2010-03-29glsl: avoid using rcp in length() functionsBrian Paul
See prev commit for related info.
2010-03-29glsl: remove rcp from sqrt()Brian Paul
Per a patch from Marek Olšák, we can simply multiply the incoming value by 1/sqrt(x) instead of using rcp. We're keeping the x==0 check to avoid generating NaN for sqrt(0).
2010-03-12Grammar and spelling fixesJeff Smith
Signed-off-by: Jeff Smith <whydoubt@yahoo.com> Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-25glsl: implement support for GL_EXT_texture_arrayBrian Paul
GL_EXT_texture_array is different from the existing GL_MESA_texture_array support in that the former is only supported for GLSL, not fixed-function. The shadow compare versions of the sampler functions haven't been tested yet. The non-shadow versions have been tested with a new piglit test.
2010-02-10scons: User friendly message for code generated filesJosé Fonseca
2009-12-20slang: Add gitignore for autogenerated files.Michal Krol
2009-12-12slang: Delete a file that is now autogenerated.Michal Krol
This file has been modified in master and removed in feature branch. This gave a merge conflict I couldn't resolve by removing and git adding it to index.
2009-12-12Merge branch 'master' into glsl-pp-rework-2Michal Krol
Conflicts: progs/perf/drawoverhead.c progs/perf/teximage.c progs/perf/vbo.c progs/perf/vertexrate.c src/mesa/shader/slang/library/slang_common_builtin_gc.h
2009-12-10scons: Get GLSL code building correctly when cross compiling.José Fonseca
This is quite messy. GLSL code has to be built twice: one for the host OS, another for the target OS.
2009-12-10Build mesa glsl with make.michal
Still don't know how to add glsl to mesa dependencies.
2009-11-25slang/library: Don't need the *_gc.h files, they are autogenerated now.Michal Krol
2009-11-25scons: Autogenerate GLSL builtin library *_gc.h from *.gc files.Michal Krol
2009-11-13slang: Regenerate .gc files.Michal Krol
2009-11-13slang: Get rid of the old syntax file and utilities.Michal Krol
2009-09-29glsl: regenerated fileBrian Paul
2009-09-29glsl: rewrite sqrt(x) intrinsic to handle x=0Brian Paul
Since sqrt() is basically implemented in terms of RSQ/RCP we'll do a divide by zero if x=0 and wind up with unpredictable results. Now use CMP instruction to test for x<=0 and return zero in that case.
2009-09-22slang: Differentiate between uints and floats.Michal Krol
2009-09-08slang: Correctly handle end of tokens marker.Michal Krol
2009-09-08slang: Do not parse whitespace.Michal Krol
The preprocessor tokeniser deals with those.
2009-09-08slang: Correctly parse numbers from the new preprocessor.Michal Krol
2009-09-08slang: Remove the old preprocessor.Michal Krol
2009-09-08slang: Remove dependencies on error tokens.Michal Krol
2009-09-07slang: Adapt shader syntax description to grammar parser changes.Michal Krol
2009-03-10glsl: fix typo: s/vec4_tex1d_proj/vec4_tex_1d_proj/Brian Paul
This regression came from commit c0b59420eec5ffdf22a5919d38851c3620b97c09.
2009-02-20glsl: use new IR opcodes for TEX instructions with shadow comparisonBrian Paul
Such TEX instructions will have the TexShadow flag set. The gl_program::ShadowSamplers field is now set in the linker. We missed that before.
2009-02-20glsl: rename GLSL texture assembly instructions to be more legibleBrian Paul
2009-01-14Merge commit 'origin/master' into gallium-0.2Alan Hourihane
Conflicts: docs/install.html docs/relnotes-7.3.html src/mesa/shader/slang/slang_codegen.c src/mesa/shader/slang/slang_compile.c src/mesa/shader/slang/slang_emit.c src/mesa/shader/slang/slang_preprocess.c src/mesa/shader/slang/slang_preprocess.h
2009-01-13glsl: add preprocessor support for #pragmaBrian Paul
Two forms are supported: Pragmas are silently ignored at this time.
2009-01-12glsl: better fix for for-loop scope issue (commit ↵Brian Paul
6333005f7aea3e5d1d86a5c47b3fa2a1ed2f3ff0)
2009-01-09glsl: fix typo in the vec2 += operator functionBrian Paul
2009-01-09glsl: fix broken +=, -=, *=, /= operatorsBrian Paul
These functions need to return the final computed value. Now expressions such as a = (b += c) work properly. Also, no need to use __asm intrinsics in these functions. The resulting code is the same when using ordinary arithmetic operators and is more legible.
2009-01-08glsl: fix typo in the vec2 += operator functionBrian Paul
2009-01-08glsl: fix broken +=, -=, *=, /= operatorsBrian Paul
These functions need to return the final computed value. Now expressions such as a = (b += c) work properly. Also, no need to use __asm intrinsics in these functions. The resulting code is the same when using ordinary arithmetic operators and is more legible.
2009-01-02Merge commit 'origin/master' into gallium-0.2Brian Paul
Conflicts: src/mesa/main/ffvertex_prog.c src/mesa/main/texenvprogram.c
2009-01-01mesa: updated comments about GLSL constantsBrian Paul
2008-12-30Merge commit 'origin/master' into gallium-0.2Brian Paul
Conflicts: src/mesa/main/config.h
2008-12-30mesa: allow variable indexing into the predefined uniform variable arraysBrian Paul
This allows code such as "vec4 a = gl_LightSource[i].ambient;" to work. When a built-in uniform array is indexed with a variable index we need to "unroll" the whole array into the parameter list (aka constant buffer) because we don't know which elements may be accessed at compile-time. In the case of the gl_LightSource array of size [8], we emit 64 state references into the parameter array (8 elements times 8 vec4s per gl_LightSourceParameters struct). Previously, we only allowed constant-indexed references to uniform arrays (such as gl_LightSource[2].position) which resulted in a single state reference being added to the parameter array, not 64. We still optimize this case. Users should be aware that using "gl_LightSource[i].ambient" in their shaders is a bit expensive since state validation will involve updating all 64 light source entries in the parameter list.
2008-12-16Merge commit 'origin/master' into gallium-0.2Brian Paul
2008-12-15mesa: bump glsl grammar revisionBrian Paul
And update some copyrights.
2008-12-11mesa: checkpoint commit of GLSL 1.20 array syntax.Brian Paul
This allows things like float[3] x = float[3](1., 2., 3.); Parsing and AST construction now. Codegen not working yet.
2008-11-25Merge commit 'origin/master' into gallium-0.2Alan Hourihane
2008-11-24mesa: added support for GLSL 1.20 array.length() methodBrian Paul
This is the only method supported in GLSL 1.20 so we take a few short-cuts.
2008-11-24mesa: support for GLSL 1.20 array typesBrian Paul
This allows syntax like "float[8] foo, bar;"
2008-11-20Merge commit 'origin/master' into gallium-0.2Alan Hourihane
2008-11-19mesa: minor comment reformatttingBrian Paul
2008-11-15Merge commit 'origin/master' into gallium-0.2Keith Whitwell
Conflicts: src/mesa/shader/prog_print.c
2008-11-13mesa: use the tighter definition of GLSL ftransform() from the gallium branchesBrian Paul
2008-11-13mesa: remove unused/obsolete __NormalMatrixTranspose matrixBrian Paul
2008-11-11Merge commit 'origin/master' into gallium-0.2Brian Paul
Conflicts: src/mesa/shader/prog_execute.c src/mesa/shader/slang/library/slang_vertex_builtin_gc.h
2008-11-10mesa: allows 'f' suffix on GLSL float literalsBrian Paul