This repository has been archived by the owner on Aug 25, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Code from an old svn, still working
- Loading branch information
Théo
committed
Feb 8, 2017
0 parents
commit d4acfac
Showing
132 changed files
with
14,850 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
//varying vec3 normal, lightDir; | ||
uniform sampler2D tex; | ||
|
||
void main() | ||
{ | ||
vec4 color; | ||
vec4 texel; | ||
float alpha,r,g,b ; | ||
|
||
texel = texture2D(tex,gl_TexCoord[0].st); | ||
alpha = texel.a; | ||
|
||
r = ((-(alpha-1.0)*(alpha-1.0)/0.1)+1.0); | ||
g = (5.0*(-((alpha-0.5)*(alpha-0.5))/0.4)+1.0); | ||
b = ((-(alpha * alpha)/0.15)+1.0); | ||
|
||
if (r<0) r=0 ; | ||
if (g<0) g=0 ; | ||
if (b<0) b=0 ; | ||
|
||
color = vec4(r,g,b,alpha); | ||
gl_FragColor = color; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
|
||
void main() | ||
{ | ||
gl_TexCoord[0] = gl_MultiTexCoord0; | ||
gl_Position = ftransform(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
uniform sampler3D tex; | ||
|
||
void main() | ||
{ | ||
vec4 color; | ||
vec4 texel; | ||
float alpha,r,g,b ; | ||
|
||
texel = texture3D(tex,gl_TexCoord[0].xyz); | ||
alpha = texel.a; | ||
|
||
r = ((-(alpha-1.0)*(alpha-1.0)/0.1)+1.0); | ||
g = (5.0*(-((alpha-0.5)*(alpha-0.5))/0.4)+1.0); | ||
b = ((-(alpha * alpha)/0.15)+1.0); | ||
|
||
if (r<0) r=0 ; | ||
if (g<0) g=0 ; | ||
if (b<0) b=0 ; | ||
|
||
color = vec4(r,g,b,alpha); | ||
gl_FragColor = color; | ||
} |
Oops, something went wrong.