So i've been poking around at GSLS code a bit, and I'm curious, could you somehow use the "water.png" I'm talking about the "overlay" that is much like the "pumpkinblur.png" how would you /could you reference that specific texture and then apply a shader just when those overlays are on the screen that way we could get underwater distortion? I see all these vertex shaders doing the trippy warping and can't hope but think if it could somehow be used to do underwater distortion, I tried to write/modify shaders to get the result with some interesting results but no luck. Couldn't you just grab the front layer of the z buffer and then apply a sin to it or something? or like a
if texture sample0 is present "warp vertexs"
else stop the loop or w/e maybe reset the float value?
again I'm just starting to dabble in programming and just wondering if something like this has/could be done
I hope someone understands what I mean and I'm not talking out of my ass here.
It would probably be easier just to do some fancy bump mapping (or whatever the word is) to those surfaces. Have a slow rippling effect.
Quote from RoadCrewWorker »
Quote from EvilMilk »
if you think that makes you sick now, try it with 3D glasses on
I would, i even have the whole 120Hz monitor + Nvidia 3d Vision glasses setup, but unfortunately their drivers don't support opengl in any form.
So yeah, anybody want to write a direct3d frontend for minecraft ahahahaha who am i kidding.
Quote from inzal »
Ofcourse when I had the idea of screenspace indirect illumination, I wasn't thinking of physical global illumination like you see in actual renders.
edit: here's an example;
Wow, that's actually very cool and i didn't know about that. Nice idea, and the code is easy enough to read.
Quote from azraeil »
I'm loving those two shaders. And yeah, doesn't it feel fun? Jumping on the vertex changing bandwagon that it.
That reminds me, if we had uniform real-time and ingame-time floats it'd be possible to have certain types of blocks (like monster spawners) rotate or swing. Why? Uhm... i'll get back to you once i figured that out...
I was thinking getting in game time would be great because then you could have a rippling effect across the terrain in the same manner I applied the sin transformation. Nothing really all that great about it, just kinda cool :tongue.gif:
Doesn't look like normals are in yet, gl_Normal is still zero for me? I thought there had been some progress?
Regarding optimization: Optimine has already sort of done that, althought you'd probably rewrite a few functions from scratch to switch the renderer instead of the code injection this mod currently does.
Regarding width/height as uniforms for pixel sampling
int aspectRatioU = ARBShaderObjects.glGetUniformLocationARB(program, "aspectRatio");
ARBShaderObjects.glUniform1fARB(aspectRatioU, (float)mc.displayWidth / (float)mc.displayHeight);
int sdisplayWidth = ARBShaderObjects.glGetUniformLocationARB(program, "displayWidth");
ARBShaderObjects.glUniform1fARB(sdisplayWidth, (float)mc.displayWidth);
int sdisplayHeight = ARBShaderObjects.glGetUniformLocationARB(program, "displayHeight");
ARBShaderObjects.glUniform1fARB(sdisplayHeight, (float)mc.displayHeight);
in Shaders.java (from this mod) should do the trick, right? I tried changing it, but apparently the mod supplies its already compiled Shaders.class, so we'll have to wait for dax to take a peek at this.
Yeah, I've made some good progress on the gl_Normal attribute. I'll see if I can include what I have on that in the next update. It's not complete but will be a good starting point for writing shaders that use it.
I'll definitely include width and height uniforms in an update sometime early this week. Right now it's looking like I'll have a lot of time tomorrow night to do this.
Considering that water is an animated texture the current findBlockID hack might not work, in that case we need a uniform variable in the base vertex shader that indicates material or block id.
I can't really do this because Minecraft renders large chunks of blocks in one draw. I can however (and probably will at some point), add a uniform that indicates the type of element (terrain, clouds, living entity, sign, etc.).
I hope someone understands what I mean and I'm not talking out of my ass here.
No, that's actually a cool idea. I don't know if actually refracting the view vector is possible with the current shader setup, but i guess you could just mark the water fragments with a specific alpha value and distort them later in the post-fx shader (or not if blending ****s it up).
Considering that water is an animated texture the current findBlockID hack might not work, in that case we need a uniform variable in the base vertex shader that indicates material or block id.
Quote from .jhn »
Fixed some problems with the ssao shader and tried dialing up the parameters to overly high levels. Produced interesting, if not entirely coherent, results.
Also, who the hell decided that dark grayscales should be transparant? I lost more of my life than I'd like to admit thinking it was some obscure shader error.
Also completely forgot to quote this yesterday, looks fantastic. I've never had the dark-grayscales=transparent problem though, could you post the shadercode that causes it? Might be another hardware dependant issue.
Edit: Seriously, let's not **** this thread up with discussions about taste in texture packs. :smile.gif: I see your point though, might think about that next time.
VVVVVVVVVVVVVVVV
Actually there are two files for the water, there is the "animation" and then when you go below the water like swimming underwater the game applies a 2d translucent texture over the whole scene it is called "water.png" it is different than what you see when you're above the water it creates a 3d sphere wrap of the overlay which to me looks to be a 2d effect but I could be wrong. It's kinda like the pumking blur effect.
I was saying to use that as a reference or whatever and apply your affects using just that layer.
And yah I know what you mean azraeil about the game time thing, all the swirling shaders I've seen reference a timer in the main program using uniform at least that's how I'm reading it, I think... because it has to *time
This is a great mod, but I seem to be having issues with both DOF shaders.
Here's an example of what happens. I'll be staring at a tree, maybe 10 blocks (units?) away. Anything near by in my peripheral vision is blurred as expected, but nothing else is. Not even in the distance past the tree. I walk toward the tree. As soon As I'm 3 blocks away the DOF effect kicks in, and everything in the distance blurs. From looking at screenshots, it seems there should be a gradual change, and should work at various distances.
I'm not sure exactly what information you need from me, but I'm on Windows 7 64, and have a GTX 460 with the latest drivers.
I'm having problems installing. I made @echo on. I'm using ATI but that shouldn't be important for the installation. Nothing is changed in my minecraft.jar
run from .minecraft
C:\Documents and Settings\name\Application Data\.minecraft>setlocal enabledelayedexpansion
C:\Documents and Settings\name\Application Data\.minecraft>set BASEDIR=C:\Documents and Settings\name\My Documents\Downloads\daxnitro\
C:\Documents and Settings\name\Application Data\.minecraft>(set TEMPDIR=C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp )
C:\Documents and Settings\name\Application Data\.minecraft>(set TOOLSDIR=C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\tools )
C:\Documents and Settings\name\Application Data\.minecraft>set MINECRAFTJAR=
C:\Documents and Settings\name\Application Data\.minecraft>set ANSWER=
C:\Documents and Settings\name\Application Data\.minecraft>java -help 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>if errorlevel 1 (
echo Unable to locate java.exe. Please verify that it is in the PATH.
goto :exit
)
C:\Documents and Settings\name\Application Data\.minecraft>if [""] == [""] (
(set MINECRAFTJAR=C:\Documents and Settings\name\Application Data\.minecraft\bin\minecraft.jar )
echo No minecraft.jar supplied.
set /P ANSWER="Would you like to use the default minecraft.jar (Y/N)? "
if /I {!ANSWER!} == {y} goto :yes
if /I {!ANSWER!} == {yes} goto :yes
echo Aborting . . .
goto :exit
)
No minecraft.jar supplied.
Would you like to use the default minecraft.jar (Y/N)?
C:\Documents and Settings\name\Application Data\.minecraft>echo Extracting JAR . . .
Extracting JAR . . .
C:\Documents and Settings\name\Application Data\.minecraft>rmdir /s /q "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>mkdir "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>"C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\tools\unzip.exe" -o "C:\Documents and Settings\name\Application Data\.minecraft\bin\minecraft.jar" * -d "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" 1>NUL
C:\Documents and Settings\name\Application Data\.minecraft>del "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\META-INF\MOJANG_C.DSA" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>del "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\META-INF\MOJANG_C.SF" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>echo Applying mods . . .
Applying mods . . .
C:\Documents and Settings\name\Application Data\.minecraft>for /F "tokens=*" %a in ('dir /b "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\*"') do call "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\%a\install.bat" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\%a"
C:\Documents and Settings\name\Application Data\.minecraft>call "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders\install.bat" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders"
C:\Documents and Settings\name\Application Data\.minecraft>echo shaders: Copying files . . .
shaders: Copying files . . .
C:\Documents and Settings\name\Application Data\.minecraft>rmdir /s /q "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\shaders" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>mkdir "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\shaders" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>copy "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders\files\shaders" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\shaders" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>copy "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders\files\Shaders.class" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>echo shaders: Patching bytecode . . .
shaders: Patching bytecode . . .
C:\Documents and Settings\name\Application Data\.minecraft>java -classpath "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders\patcher;C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\tools\javassist.jar;C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" Patcher "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" 1>NUL
C:\Documents and Settings\name\Application Data\.minecraft>echo Recreating JAR . . .
Recreating JAR . . .
C:\Documents and Settings\name\Application Data\.minecraft>java -classpath "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\tools" JarHelper "C:\Documents and Settings\name\Application Data\.minecraft\bin\minecraft.jar" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" . 1>NUL
C:\Documents and Settings\name\Application Data\.minecraft>echo Cleaning up . . .
Cleaning up . . .
C:\Documents and Settings\name\Application Data\.minecraft>rmdir /s /q "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>echo Done!
Done
C:\Documents and Settings\name\Application Data\.minecraft>pause
Press any key to continue . . .
C:\Documents and Settings\name\Application Data\.minecraft>setlocal enabledelayedexpansion
C:\Documents and Settings\name\Application Data\.minecraft>set BASEDIR=C:\Documents and Settings\name\My Documents\Downloads\daxnitro\
C:\Documents and Settings\name\Application Data\.minecraft>(set TEMPDIR=C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp )
C:\Documents and Settings\name\Application Data\.minecraft>(set TOOLSDIR=C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\tools )
C:\Documents and Settings\name\Application Data\.minecraft>set MINECRAFTJAR=
C:\Documents and Settings\name\Application Data\.minecraft>set ANSWER=
C:\Documents and Settings\name\Application Data\.minecraft>java -help 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>if errorlevel 1 (
echo Unable to locate java.exe. Please verify that it is in the PATH.
goto :exit
)
C:\Documents and Settings\name\Application Data\.minecraft>if [""] == [""] (
(set MINECRAFTJAR=C:\Documents and Settings\name\Application Data\.minecraft\bin\minecraft.jar )
echo No minecraft.jar supplied.
set /P ANSWER="Would you like to use the default minecraft.jar (Y/N)? "
if /I {!ANSWER!} == {y} goto :yes
if /I {!ANSWER!} == {yes} goto :yes
echo Aborting . . .
goto :exit
)
No minecraft.jar supplied.
Would you like to use the default minecraft.jar (Y/N)?
C:\Documents and Settings\name\Application Data\.minecraft>echo Extracting JAR . . .
Extracting JAR . . .
C:\Documents and Settings\name\Application Data\.minecraft>rmdir /s /q "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>mkdir "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>"C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\tools\unzip.exe" -o "C:\Documents and Settings\name\Application Data\.minecraft\bin\minecraft.jar" * -d "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" 1>NUL
C:\Documents and Settings\name\Application Data\.minecraft>del "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\META-INF\MOJANG_C.DSA" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>del "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\META-INF\MOJANG_C.SF" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>echo Applying mods . . .
Applying mods . . .
C:\Documents and Settings\name\Application Data\.minecraft>for /F "tokens=*" %a in ('dir /b "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\*"') do call "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\%a\install.bat" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\%a"
C:\Documents and Settings\name\Application Data\.minecraft>call "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders\install.bat" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders"
C:\Documents and Settings\name\Application Data\.minecraft>echo shaders: Copying files . . .
shaders: Copying files . . .
C:\Documents and Settings\name\Application Data\.minecraft>rmdir /s /q "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\shaders" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>mkdir "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\shaders" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>copy "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders\files\shaders" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\shaders" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>copy "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders\files\Shaders.class" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>echo shaders: Patching bytecode . . .
shaders: Patching bytecode . . .
C:\Documents and Settings\name\Application Data\.minecraft>java -classpath "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders\patcher;C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\tools\javassist.jar;C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" Patcher "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" 1>NUL
C:\Documents and Settings\name\Application Data\.minecraft>echo Recreating JAR . . .
Recreating JAR . . .
C:\Documents and Settings\name\Application Data\.minecraft>java -classpath "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\tools" JarHelper "C:\Documents and Settings\name\Application Data\.minecraft\bin\minecraft.jar" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" . 1>NUL
C:\Documents and Settings\name\Application Data\.minecraft>echo Cleaning up . . .
Cleaning up . . .
C:\Documents and Settings\name\Application Data\.minecraft>rmdir /s /q "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft>echo Done!
Done
C:\Documents and Settings\name\Application Data\.minecraft>pause
Press any key to continue . . .
From .minecraft/bin
C:\Documents and Settings\name\Application Data\.minecraft\bin>setlocal enabledelayedexpansion
C:\Documents and Settings\name\Application Data\.minecraft\bin>set BASEDIR=C:\Documents and Settings\name\My Documents\Downloads\daxnitro\
C:\Documents and Settings\name\Application Data\.minecraft\bin>(set TEMPDIR=C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp )
C:\Documents and Settings\name\Application Data\.minecraft\bin>(set TOOLSDIR=C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\tools )
C:\Documents and Settings\name\Application Data\.minecraft\bin>set MINECRAFTJAR=
C:\Documents and Settings\name\Application Data\.minecraft\bin>set ANSWER=
C:\Documents and Settings\name\Application Data\.minecraft\bin>java -help 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft\bin>if errorlevel 1 (
echo Unable to locate java.exe. Please verify that it is in the PATH.
goto :exit
)
C:\Documents and Settings\name\Application Data\.minecraft\bin>if [""] == [""] (
(set MINECRAFTJAR=C:\Documents and Settings\name\Application Data\.minecraft\bin\minecraft.jar )
echo No minecraft.jar supplied.
set /P ANSWER="Would you like to use the default minecraft.jar (Y/N)? "
if /I {!ANSWER!} == {y} goto :yes
if /I {!ANSWER!} == {yes} goto :yes
echo Aborting . . .
goto :exit
)
No minecraft.jar supplied.
Would you like to use the default minecraft.jar (Y/N)?
C:\Documents and Settings\name\Application Data\.minecraft\bin>echo Extracting JAR . . .
Extracting JAR . . .
C:\Documents and Settings\name\Application Data\.minecraft\bin>rmdir /s /q "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft\bin>mkdir "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft\bin>"C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\tools\unzip.exe" -o "C:\Documents and Settings\name\Application Data\.minecraft\bin\minecraft.jar" * -d "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" 1>NUL
C:\Documents and Settings\name\Application Data\.minecraft\bin>del "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\META-INF\MOJANG_C.DSA" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft\bin>del "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\META-INF\MOJANG_C.SF" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft\bin>echo Applying mods . . .
Applying mods . . .
C:\Documents and Settings\name\Application Data\.minecraft\bin>for /F "tokens=*" %a in ('dir /b "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\*"') do call "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\%a\install.bat" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\%a"
C:\Documents and Settings\name\Application Data\.minecraft\bin>call "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders\install.bat" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders"
C:\Documents and Settings\name\Application Data\.minecraft\bin>echo shaders: Copying files . . .
shaders: Copying files . . .
C:\Documents and Settings\name\Application Data\.minecraft\bin>rmdir /s /q "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\shaders" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft\bin>mkdir "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\shaders" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft\bin>copy "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders\files\shaders" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft\shaders" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft\bin>copy "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders\files\Shaders.class" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft\bin>echo shaders: Patching bytecode . . .
shaders: Patching bytecode . . .
C:\Documents and Settings\name\Application Data\.minecraft\bin>java -classpath "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\mods\shaders\patcher;C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\tools\javassist.jar;C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" Patcher "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" 1>NUL
C:\Documents and Settings\name\Application Data\.minecraft\bin>echo Recreating JAR . . .
Recreating JAR . . .
C:\Documents and Settings\name\Application Data\.minecraft\bin>java -classpath "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\tools" JarHelper "C:\Documents and Settings\name\Application Data\.minecraft\bin\minecraft.jar" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp\minecraft" . 1>NUL
C:\Documents and Settings\name\Application Data\.minecraft\bin>echo Cleaning up . . .
Cleaning up . . .
C:\Documents and Settings\name\Application Data\.minecraft\bin>rmdir /s /q "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\\temp" 1>NUL 2>NUL
C:\Documents and Settings\name\Application Data\.minecraft\bin>echo Done!
Done
C:\Documents and Settings\name\Application Data\.minecraft\bin>pause
Press any key to continue . . .
from C:\WINDOWS
C:\WINDOWS>setlocal enabledelayedexpansion
C:\WINDOWS>set BASEDIR=C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\
C:\WINDOWS>(set TEMPDIR=C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp )
C:\WINDOWS>(set TOOLSDIR=C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\tools )
C:\WINDOWS>set MINECRAFTJAR=
C:\WINDOWS>set ANSWER=
C:\WINDOWS>java -help 1>NUL 2>NUL
C:\WINDOWS>if errorlevel 1 (
echo Unable to locate java.exe. Please verify that it is in the PATH.
goto :exit
)
C:\WINDOWS>if [""] == [""] (
(set MINECRAFTJAR=C:\Documents and Settings\name\Application Data\.minecraft\bin\minecraft.jar )
echo No minecraft.jar supplied.
set /P ANSWER="Would you like to use the default minecraft.jar (Y/N)? "
if /I {!ANSWER!} == {y} goto :yes
if /I {!ANSWER!} == {yes} goto :yes
echo Aborting . . .
goto :exit
)
No minecraft.jar supplied.
Would you like to use the default minecraft.jar (Y/N)?
C:\WINDOWS>echo Extracting JAR . . .
Extracting JAR . . .
C:\WINDOWS>rmdir /s /q "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp" 1>NUL 2>NUL
C:\WINDOWS>mkdir "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp" 1>NUL 2>NUL
C:\WINDOWS>"C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\tools\unzip.exe" -o "C:\Documents and Settings\name\Application Data\.minecraft\bin\minecraft.jar" * -d "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp\minecraft" 1>NUL
C:\WINDOWS>del "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp\minecraft\META-INF\MOJANG_C.DSA" 1>NUL 2>NUL
C:\WINDOWS>del "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp\minecraft\META-INF\MOJANG_C.SF" 1>NUL 2>NUL
C:\WINDOWS>echo Applying mods . . .
Applying mods . . .
C:\WINDOWS>for /F "tokens=*" %a in ('dir /b "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\mods\*"') do call "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\mods\%a\install.bat" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\mods\%a"
C:\WINDOWS>call "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\mods\shaders\install.bat" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\mods\shaders"
C:\WINDOWS>echo shaders: Copying files . . .
shaders: Copying files . . .
C:\WINDOWS>rmdir /s /q "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp\minecraft\shaders" 1>NUL 2>NUL
C:\WINDOWS>mkdir "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp\minecraft\shaders" 1>NUL 2>NUL
C:\WINDOWS>copy "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\mods\shaders\files\shaders" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp\minecraft\shaders" 1>NUL 2>NUL
C:\WINDOWS>copy "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\mods\shaders\files\Shaders.class" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp\minecraft" 1>NUL 2>NUL
C:\WINDOWS>echo shaders: Patching bytecode . . .
shaders: Patching bytecode . . .
C:\WINDOWS>java -classpath "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\mods\shaders\patcher;C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\tools\javassist.jar;C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp\minecraft" Patcher "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp\minecraft" 1>NUL
C:\WINDOWS>echo Recreating JAR . . .
Recreating JAR . . .
C:\WINDOWS>java -classpath "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\tools" JarHelper "C:\Documents and Settings\name\Application Data\.minecraft\bin\minecraft.jar" "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp\minecraft" . 1>NUL
C:\WINDOWS>echo Cleaning up . . .
Cleaning up . . .
C:\WINDOWS>rmdir /s /q "C:\Documents and Settings\name\My Documents\Downloads\daxnitro\daxnitro\\temp" 1>NUL 2>NUL
C:\WINDOWS>echo Done!
Done
C:\WINDOWS>pause
Press any key to continue . . .
EDIT: I forgot. When I ran it from .minecraft I got a folder called %~dp0
I'm having trouble compiling your source -- the java compiler can't find the fields of the Minecraft and GameObjects classes, even when minecraft.jar is included in the classpath. I assume they're obfuscated, and I've tried making dummy classes (compiles but won't run). How do you compile Shaders.java?
I was trying to do this because I wanted to sprinkle some org.lwjgl.opengl.Util.checkGLError() calls around, I thought they might help debugging the ATI problems.
This is a great mod, but I seem to be having issues with both DOF shaders.
Here's an example of what happens. I'll be staring at a tree, maybe 10 blocks (units?) away. Anything near by in my peripheral vision is blurred as expected, but nothing else is. Not even in the distance past the tree. I walk toward the tree. As soon As I'm 3 blocks away the DOF effect kicks in, and everything in the distance blurs. From looking at screenshots, it seems there should be a gradual change, and should work at various distances.
I'm not sure exactly what information you need from me, but I'm on Windows 7 64, and have a GTX 460 with the latest drivers.
I designed that shader to work that way. I wanted it to be more on the realistic side. If you would prefer a different style of dof, feel free to use the blatant dof shader included in the alternative shaders folder.
This was from a previous post:
Quote from azraeil »
Quote from Ilsyde »
I don't understand how Azraeil's is supposed to work. When I do a full turn and look at the blurred areas, everything becomes sharp and stays that way. Only the blocks right next to me stay blurred (which is annoying) but mid-range and distant mountains etc. will stay sharp forever as if DoF wouldn't kick in.
EDIT: If specs help then I'm on Win7 64bit using a GeF9800GTX+ with the v258.96 driver. Mod works fine for me.
It's supposed to work more of the way your eyes actually see. When you look out into the distance at a mountain, the mountain behind it isn't blurry. In fact, with a given aperture there is a focal distance at which you have (roughly) infinite depth of field behind your subject (still limited DoF in front though). Any closer than that and your depth of field is reduced (mountains/things off in the distance start to get blurry) and the closer you are to your focus, the lower the DoF you have. Currently, if you look at something at least 7(ish) cubes in front of you, everything behind that should be pretty clear. Any closer and your rear DoF starts to drop exponentially.
If you like that, but want to mess around with the distance at which that sort of things happens, go ahead and open up the final.fsh and modify that line at the top that defines HYPERFOCAL:
// HYPERFOCAL = (Focal Distance ^ 2)/(Circle of Confusion * F Stop) + Focal Distance
const float HYPERFOCAL = 3.132;
Circle of confusion is usually about 0.03mm and for an explanation of f stops check here. Hyperfocal distance is explained pretty well in this article. Just for quick reference, the F Stop of the human eye is estimated to range between 2 and 8 depending on lighting conditions. I used 5 for a nice middle number. Make sure you keep your units in check too. The focal distance and CoC are typically measured in mm, thought the world units are in meters. Just divide your hyperfocal by 1000.
Some really interesting stuff can happen when you use a larger focal distance too. Pretend you have a 300mm lens (hyperfocal = 600.3) and you'll get a much much larger hyperfocal distance -- good for cool screen shots. Play around with different hyperfocal lengths to see what you like.
On a side note, something I need to do is to make sure I have a minimum focal distance and that I'm calculating the distance from the camera as the distance in all planes, not just in the z axis.
I'm having trouble compiling your source -- the java compiler can't find the fields of the Minecraft and GameObjects classes, even when minecraft.jar is included in the classpath. I assume they're obfuscated, and I've tried making dummy classes (compiles but won't run). How do you compile Shaders.java?
I was trying to do this because I wanted to sprinkle some org.lwjgl.opengl.Util.checkGLError() calls around, I thought they might help debugging the ATI problems.
Decompile Shaders.class using jad, then make the changes and recompile it. You don't have to worry about the obfuscation that way.
I get this error when running the install script (on OSX, 10.6.6).
Extracting JAR . . .
Applying mods . . .
Installing shaders . . .
shaders: Copying files . . .
shaders: Patching bytecode . . .
Exception in thread "main" java.lang.NoClassDefFoundError: Patcher
Caused by: java.lang.ClassNotFoundException: Patcher
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
Recreating JAR . . .
Exception in thread "main" java.lang.NoClassDefFoundError: JarHelper
Caused by: java.lang.ClassNotFoundException: JarHelper
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
Cleaning up . . .
Done!
I'm certain that Minecraft, Java, and the installer itself are all completely up to date. I'm attempting to patch a fresh install of Minecraft, and I've followed the install instructions to the letter (as far as I can tell). Does anyone know what could be causing this?
Cheers.
Edit:
Ahh, fixed it. The problem was that the folder in which my mods are stored had a / in its name. Doh.
Thanks for the reply. I guess it was working correctly. Using 600.3 right now and it's quite fun to play around with. I think I'll try something a bit more realistic later.
Is there anything similar like this for ATI cards?
Not yet, but I want to try to debug this on an ATI card this week. Some people with ATI cards have volunteered to let me use their box to test on. If you're willing to me use your machine, send me a PM with the subject "Test Machine". In the PM, include your operating system, graphics card, processor speed, amount of RAM, internet type/speed, and display resolution. I want people with Windows 7, an ATI card, and a fast computer/connection.
I'll message you back tomorrow if I want to use your machine. If I do, I'll want you to have a VNC server set up for me to connect to, and an FTP or SMB login with read/write access to Minecraft's application support folder. I'll want to be able to connect on Wednesday, around 4:30 PM EST, but if you want to be really cool, you can leave a machine set up for me all this week so I can debug in my random free time. My debug process itself will likely consist of uploading various Minecraft builds, opening them, looking at output, closing them, and repeating the process after I make some changes. It won't be much to look at.
Time to start putting together an update now . . . :smile.gif:
My debug process itself will likely consist of uploading various Minecraft builds, opening them, looking at output, closing them, and repeating the process after I make some changes. It won't be much to look at.
you forgot about the huge loads of porn you wanted to download onto those computers :wink.gif:
My debug process itself will likely consist of uploading various Minecraft builds, opening them, looking at output, closing them, and repeating the process after I make some changes. It won't be much to look at.
you forgot about the huge loads of porn you wanted to download onto those computers :wink.gif:
I just wanted to throw in a little extra tweak for anyone else that might be interested. The only issue I had with the default shaders that come along with the package is the curvature of the earth along the horizon is a bit too dramatic for my taste. I worked with azraeil over PM and he explained how easy it is to adjust the setting to where I liked it.
I created an animated gif to help explain what I'm talking about:
(Click to see larger)
After you've got GLSL installed and working, look inside your modified minecraft.jar (with 7zip or any app you can find to open JAR archives) Browse to the shaders folder and open up the base.vsh file inside there. Use wordpad or whatever text editor you prefer. Look for the following values:
The default 500/250000 values make the world look very small with at tight curve at the horizon, and I wanted to stretch it out and make the effect a bit more subtle. This is easy to do:
0. Save a backup of the base.vsh file in case you really fat finger something bad enough to break it!!
1. Change the WORLD_RADIUS to a higher value.
2. Make sure that you change the WORLD_RADIUS_SQUARED to the squared value of whatever WORLD_RADIUS you chose. (WORLD_RADIUS² or WORLD_RADIUS * WORLD_RADIUS for the math challenged...)
3. Save a copy of the new base.vsh.
4. Put the modified base.vsh back into the shaders folder inside minecraft.jar, overwriting the existing one.
The above change would stretch that effect slightly more towards a smoother horizon, and give the appearance of a larger "planet" for the Minecraft landscape. As you can see in the above screenshots once you get up around WORLD_RADIUS 10000, the effect is barely noticeable. You could also just remove the base.vsh file completely to remove the curvature altogether.
I just wanted to throw in a little extra tweak for anyone else that might be interested. The only issue I had with the default shaders that come along with the package is the curvature of the earth along the horizon is a bit too dramatic for my taste. I worked with azraeil over PM and he explained how easy it is to adjust the setting to where I liked it.
I created an animated gif to help explain what I'm talking about:
(Click to see larger)
After you've got GLSL installed and working, look inside your modified minecraft.jar (with 7zip or any app you can find to open JAR archives) Browse to the shaders folder and open up the base.vsh file inside there. Use wordpad or whatever text editor you prefer. Look for the following values:
The default 500/250000 values make the world look very small with at tight curve at the horizon, and I wanted to stretch it out and make the effect a bit more subtle. This is easy to do:
0. Save a backup of the base.vsh file in case you really fat finger something bad enough to break it!!
1. Change the WORLD_RADIUS to a higher value.
2. Make sure that you change the WORLD_RADIUS_SQUARED to the squared value of whatever WORLD_RADIUS you chose. (WORLD_RADIUS² or WORLD_RADIUS * WORLD_RADIUS for the math challenged...)
3. Save a copy of the new base.vsh.
4. Put the modified base.vsh back into the shaders folder inside minecraft.jar, overwriting the existing one.
The above change would stretch that effect slightly more towards a smoother horizon, and give the appearance of a larger "planet" for the Minecraft landscape. As you can see in the above screenshots once you get up around WORLD_RADIUS 10000, the effect is barely noticeable. You could also just remove the base.vsh file completely to remove the curvature altogether.
Thanks for posting this. :smile.gif: I'm gonna change the default to something more like 2500 in the update today, because I'd like it to much more closely match the arc you can see in the distant atmosphere.
Just to put it out there again, the update tonight is mainly for shader authors. All it does is add width/height uniforms and fix normal attributes (gl_Normal):
[*:1wpgaxw8]A fresh 1.2_02 Minecraft
[*:1wpgaxw8]OpenJDK 64-Bit Server VM as a JVM (Woops, hopefully this is not some Sun vs. OpenJVM stuff...)
[*:1wpgaxw8]OpenSuse Linux
This results the following output:
./install.sh /path/to/.minecraft/minecraft.jar
Extracting JAR . . .
Applying mods . . .
Installing shaders . . .
shaders: Copying files . . .
shaders: Patching bytecode . . .
Exception in thread "main" javassist.NotFoundException: ll
at javassist.ClassPool.get(ClassPool.java:439)
at Patcher.main(Patcher.java:13)
Recreating JAR . . .
Cleaning up . . .
Done!
Now, the timestamp of minecraft.jar is updated but it seems no modification is actually done due to this exection. (Some return value check might be good, btw :wink.gif:
I'd appreciate any tips you might have...
Are you positive you're using a brand new minecraft.jar? I would suggest trying it with the latest one found here.
It would probably be easier just to do some fancy bump mapping (or whatever the word is) to those surfaces. Have a slow rippling effect.
I was thinking getting in game time would be great because then you could have a rippling effect across the terrain in the same manner I applied the sin transformation. Nothing really all that great about it, just kinda cool :tongue.gif:
Yeah, I've made some good progress on the gl_Normal attribute. I'll see if I can include what I have on that in the next update. It's not complete but will be a good starting point for writing shaders that use it.
I'll definitely include width and height uniforms in an update sometime early this week. Right now it's looking like I'll have a lot of time tomorrow night to do this.
I can't really do this because Minecraft renders large chunks of blocks in one draw. I can however (and probably will at some point), add a uniform that indicates the type of element (terrain, clouds, living entity, sign, etc.).
minecraft has Red/Blue 3D glasses support in it's game options. not as nice as the Nvidia glasses but it should have you reaching for the airsick bag
Actually there are two files for the water, there is the "animation" and then when you go below the water like swimming underwater the game applies a 2d translucent texture over the whole scene it is called "water.png" it is different than what you see when you're above the water it creates a 3d sphere wrap of the overlay which to me looks to be a 2d effect but I could be wrong. It's kinda like the pumking blur effect.
I was saying to use that as a reference or whatever and apply your affects using just that layer.
And yah I know what you mean azraeil about the game time thing, all the swirling shaders I've seen reference a timer in the main program using uniform at least that's how I'm reading it, I think... because it has to *time
Here's an example of what happens. I'll be staring at a tree, maybe 10 blocks (units?) away. Anything near by in my peripheral vision is blurred as expected, but nothing else is. Not even in the distance past the tree. I walk toward the tree. As soon As I'm 3 blocks away the DOF effect kicks in, and everything in the distance blurs. From looking at screenshots, it seems there should be a gradual change, and should work at various distances.
I'm not sure exactly what information you need from me, but I'm on Windows 7 64, and have a GTX 460 with the latest drivers.
run from .minecraft
From .minecraft/bin
from C:\WINDOWS
EDIT: I forgot. When I ran it from .minecraft I got a folder called %~dp0
I'm having trouble compiling your source -- the java compiler can't find the fields of the Minecraft and GameObjects classes, even when minecraft.jar is included in the classpath. I assume they're obfuscated, and I've tried making dummy classes (compiles but won't run). How do you compile Shaders.java?
I was trying to do this because I wanted to sprinkle some org.lwjgl.opengl.Util.checkGLError() calls around, I thought they might help debugging the ATI problems.
I designed that shader to work that way. I wanted it to be more on the realistic side. If you would prefer a different style of dof, feel free to use the blatant dof shader included in the alternative shaders folder.
This was from a previous post:
If you like that, but want to mess around with the distance at which that sort of things happens, go ahead and open up the final.fsh and modify that line at the top that defines HYPERFOCAL:
Circle of confusion is usually about 0.03mm and for an explanation of f stops check here. Hyperfocal distance is explained pretty well in this article. Just for quick reference, the F Stop of the human eye is estimated to range between 2 and 8 depending on lighting conditions. I used 5 for a nice middle number. Make sure you keep your units in check too. The focal distance and CoC are typically measured in mm, thought the world units are in meters. Just divide your hyperfocal by 1000.
Some really interesting stuff can happen when you use a larger focal distance too. Pretend you have a 300mm lens (hyperfocal = 600.3) and you'll get a much much larger hyperfocal distance -- good for cool screen shots. Play around with different hyperfocal lengths to see what you like.
On a side note, something I need to do is to make sure I have a minimum focal distance and that I'm calculating the distance from the camera as the distance in all planes, not just in the z axis.
Decompile Shaders.class using jad, then make the changes and recompile it. You don't have to worry about the obfuscation that way.
I'm certain that Minecraft, Java, and the installer itself are all completely up to date. I'm attempting to patch a fresh install of Minecraft, and I've followed the install instructions to the letter (as far as I can tell). Does anyone know what could be causing this?
Cheers.
Edit:
Ahh, fixed it. The problem was that the folder in which my mods are stored had a / in its name. Doh.
Not yet, but I want to try to debug this on an ATI card this week. Some people with ATI cards have volunteered to let me use their box to test on. If you're willing to me use your machine, send me a PM with the subject "Test Machine". In the PM, include your operating system, graphics card, processor speed, amount of RAM, internet type/speed, and display resolution. I want people with Windows 7, an ATI card, and a fast computer/connection.
I'll message you back tomorrow if I want to use your machine. If I do, I'll want you to have a VNC server set up for me to connect to, and an FTP or SMB login with read/write access to Minecraft's application support folder. I'll want to be able to connect on Wednesday, around 4:30 PM EST, but if you want to be really cool, you can leave a machine set up for me all this week so I can debug in my random free time. My debug process itself will likely consist of uploading various Minecraft builds, opening them, looking at output, closing them, and repeating the process after I make some changes. It won't be much to look at.
Time to start putting together an update now . . . :smile.gif:
Oh. And viruses. Lots of viruses. ;P
I just wanted to throw in a little extra tweak for anyone else that might be interested. The only issue I had with the default shaders that come along with the package is the curvature of the earth along the horizon is a bit too dramatic for my taste. I worked with azraeil over PM and he explained how easy it is to adjust the setting to where I liked it.
(Click to see larger)
After you've got GLSL installed and working, look inside your modified minecraft.jar (with 7zip or any app you can find to open JAR archives) Browse to the shaders folder and open up the base.vsh file inside there. Use wordpad or whatever text editor you prefer. Look for the following values:
The default 500/250000 values make the world look very small with at tight curve at the horizon, and I wanted to stretch it out and make the effect a bit more subtle. This is easy to do:
0. Save a backup of the base.vsh file in case you really fat finger something bad enough to break it!!
1. Change the WORLD_RADIUS to a higher value.
2. Make sure that you change the WORLD_RADIUS_SQUARED to the squared value of whatever WORLD_RADIUS you chose. (WORLD_RADIUS² or WORLD_RADIUS * WORLD_RADIUS for the math challenged...)
3. Save a copy of the new base.vsh.
4. Put the modified base.vsh back into the shaders folder inside minecraft.jar, overwriting the existing one.
For example:
The above change would stretch that effect slightly more towards a smoother horizon, and give the appearance of a larger "planet" for the Minecraft landscape. As you can see in the above screenshots once you get up around WORLD_RADIUS 10000, the effect is barely noticeable. You could also just remove the base.vsh file completely to remove the curvature altogether.
Thanks for posting this. :smile.gif: I'm gonna change the default to something more like 2500 in the update today, because I'd like it to much more closely match the arc you can see in the distant atmosphere.
Just to put it out there again, the update tonight is mainly for shader authors. All it does is add width/height uniforms and fix normal attributes (gl_Normal):
Are you positive you're using a brand new minecraft.jar? I would suggest trying it with the latest one found here.
EDIT: Link removed.