GLSL Shaders

User avatar
sfan5
Member
 
Posts: 3636
Joined: Wed Aug 24, 2011 09:44
GitHub: sfan5
IRC: sfan5

by sfan5 » Sun Nov 03, 2013 10:01

hoodedice wrote:For me, I get it all red. (Using sfan's build posted above.) Windows x86 XP with intel GMA

Don't use DirectX
Mods: Mesecons | WorldEdit | Nuke
Minetest builds for Windows (32-bit & 64-bit)
 

User avatar
PilzAdam
Member
 
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam

by PilzAdam » Sun Nov 03, 2013 11:16

RealBadAngel wrote:Vanessa's issue with water is definitely caused by Irrlicht 1.8
Current tree (i made many updates yesterday) is working under 1.7.3

Actually thats wrong, I use Irrlicht 1.7.3 and all water is grey. It also says something about "reflection.png missing" (or similiar).
 

User avatar
Inocudom
Member
 
Posts: 2889
Joined: Sat Sep 29, 2012 01:14
IRC: Inocudom
In-game: Inocudom

by Inocudom » Sun Nov 03, 2013 13:16

RealBadAngel wrote:
Inocudom wrote:
tinoesroho wrote:... DirectX is on, innit?


There aren't any Direct X shaders currently.


First lets have OpenGL up n runnin.

Vanessa's issue with water is definitely caused by Irrlicht 1.8
Current tree (i made many updates yesterday) is working under 1.7.3


I heard that there are ways that OpenGL shaders can be converted to Direct X shaders. As you said, of course, the OpenGL shaders do have to be stable first.

One issue is that Direct X 9 is the highest version Irrlicht can use for the time being.
 

User avatar
RealBadAngel
Member
 
Posts: 556
Joined: Wed Jul 18, 2012 16:30

by RealBadAngel » Sun Nov 03, 2013 13:25

PilzAdam wrote:
RealBadAngel wrote:Vanessa's issue with water is definitely caused by Irrlicht 1.8
Current tree (i made many updates yesterday) is working under 1.7.3

Actually thats wrong, I use Irrlicht 1.7.3 and all water is grey. It also says something about "reflection.png missing" (or similiar).


Please do build it again and see first post about settings.
 

User avatar
PilzAdam
Member
 
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam

by PilzAdam » Sun Nov 03, 2013 13:32

RealBadAngel wrote:
PilzAdam wrote:
RealBadAngel wrote:Vanessa's issue with water is definitely caused by Irrlicht 1.8
Current tree (i made many updates yesterday) is working under 1.7.3

Actually thats wrong, I use Irrlicht 1.7.3 and all water is grey. It also says something about "reflection.png missing" (or similiar).


Please do build it again and see first post about settings.

I guess you mean pull and rebuild?

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
/home/adam/Minetest/minetest_rba_shaders/src/mapblock_mesh.cpp:1204:95: error: no matching function for call to 'ITextureSource::getTexture(<unresolved overloaded function type>)'

Fix:
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
diff --git a/src/mapblock_mesh.cpp b/src/mapblock_mesh.cpp
index f56a986..b907b64 100644
--- a/src/mapblock_mesh.cpp
+++ b/src/mapblock_mesh.cpp
@@ -1201,7 +1201,7 @@ MapBlockMesh::MapBlockMesh(MeshMakeData *data):
                if (enable_shaders) {
                        ITextureSource *tsrc = data->m_gamedef->tsrc();
                        material.setTexture(2, tsrc->getTexture("disable_img.png"));
-                       material.setTexture(3, tsrc->getTexture(getTexturePath("water_surface_normalmap.png").c_str));
+                       material.setTexture(3, tsrc->getTexture(getTexturePath("water_surface_normalmap.png").c_str()));
                        if (enable_bumpmapping) {
                                std::string fname_base = tsrc->getTextureName(p.tile.texture_id);
                                std::string normal_ext = "_normal.png";


EDIT: That fix doesnt work, here is the correct one:
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
diff --git a/src/mapblock_mesh.cpp b/src/mapblock_mesh.cpp
index f56a986..b907b64 100644
--- a/src/mapblock_mesh.cpp
+++ b/src/mapblock_mesh.cpp
@@ -1201,7 +1201,7 @@ MapBlockMesh::MapBlockMesh(MeshMakeData *data):
                if (enable_shaders) {
                        ITextureSource *tsrc = data->m_gamedef->tsrc();
                        material.setTexture(2, tsrc->getTexture("disable_img.png"));
-                       material.setTexture(3, tsrc->getTexture(getTexturePath("water_surface_normalmap.png").c_str));
+                       material.setTexture(3, tsrc->getTexture("water_surface_normalmap.png"));
                        if (enable_bumpmapping) {
                                std::string fname_base = tsrc->getTextureName(p.tile.texture_id);
                                std::string normal_ext = "_normal.png";
Last edited by PilzAdam on Sun Nov 03, 2013 13:43, edited 1 time in total.
 

User avatar
PilzAdam
Member
 
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam

by PilzAdam » Sun Nov 03, 2013 13:47

Here are some screenshots:
Default Texture Pack:
Image
Haven Texture Pack:
Image
Last edited by PilzAdam on Sun Nov 03, 2013 13:48, edited 1 time in total.
 

User avatar
PilzAdam
Member
 
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam

by PilzAdam » Sun Nov 03, 2013 14:10

Here is another patch that adds Jeijas waves to it (it contains the previous fixes so it should work if you apply it to 1c03fb5efb5095f177c27497200db27694baeea1):
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
diff --git a/client/shaders/liquids_shader/opengl_vertex.glsl b/client/shaders/liquids_shader/opengl_vertex.glsl
index 08c98cf..9ad16c8 100644
--- a/client/shaders/liquids_shader/opengl_vertex.glsl
+++ b/client/shaders/liquids_shader/opengl_vertex.glsl
@@ -4,6 +4,7 @@ uniform mat4 mInvWorld;
 uniform mat4 mTransWorld;
 uniform float dayNightRatio;
 uniform vec3 eyePosition;
+uniform float time;^M
 
 varying vec3 vPosition;
 varying vec3 viewVec;
@@ -14,9 +15,24 @@ varying vec3 viewPos;
 varying vec3 cameraPos;
 varying vec2 uv;
 
+float rand(vec2 co)^M
+{^M
+       return fract(sin(dot(co.xy ,vec2(12.9898,78.233))) * 43758.5453);^M
+}^M
+^M
 void main(void)
 {
-       gl_Position = mWorldViewProj * gl_Vertex;
+       int wavelength = 20;^M
+       float waveheight = 1.7;^M
+       int wavespeed = 100;^M
+       int height_randomness = 1;^M
+       ^M
+       vec4 pos2 = gl_Vertex;^M
+       pos2.y -= 3.0;^M
+       pos2.y -= sin (pos2.z/wavelength + time * wavespeed * wavelength) * waveheight^M
+               + sin ((pos2.z/wavelength + time * wavespeed * wavelength)/7) * waveheight * height_randomness;^M
+       ^M
+       gl_Position = mWorldViewProj * pos2;^M
 
        vPosition = (mWorldViewProj * gl_Vertex).xyz;
        vec3 pos = vec3(gl_Vertex);
diff --git a/src/game.cpp b/src/game.cpp
index 4c5e285..580ba8d 100644
--- a/src/game.cpp
+++ b/src/game.cpp
@@ -839,6 +839,8 @@ public:
                services->setPixelShaderConstant("useNormalmap" , (irr::s32*)&layer2, 1);
                services->setPixelShaderConstant("normalSampler" , (irr::s32*)&layer3, 1);
 #endif
+               float timeofday = m_client->getEnv().getTimeOfDayF();
+               services->setPixelShaderConstant("time", &timeofday, 1);
        }
 };
 
diff --git a/src/mapblock_mesh.cpp b/src/mapblock_mesh.cpp
index f56a986..fa6cf6a 100644
--- a/src/mapblock_mesh.cpp
+++ b/src/mapblock_mesh.cpp
@@ -1201,7 +1201,7 @@ MapBlockMesh::MapBlockMesh(MeshMakeData *data):
                if (enable_shaders) {
                        ITextureSource *tsrc = data->m_gamedef->tsrc();
                        material.setTexture(2, tsrc->getTexture("disable_img.png"));
-                       material.setTexture(3, tsrc->getTexture(getTexturePath("water_surface_normalmap.png").c_str));
+                       material.setTexture(3, tsrc->getTexture("water_surface_normalmap.png"));
                        if (enable_bumpmapping) {
                                std::string fname_base = tsrc->getTextureName(p.tile.texture_id);
                                std::string normal_ext = "_normal.png";
 

User avatar
Inocudom
Member
 
Posts: 2889
Joined: Sat Sep 29, 2012 01:14
IRC: Inocudom
In-game: Inocudom

by Inocudom » Sun Nov 03, 2013 14:46

PilzAdam wrote:Here is another patch that adds Jeijas waves to it (it contains the previous fixes so it should work if you apply it to 1c03fb5efb5095f177c27497200db27694baeea1):
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
diff --git a/client/shaders/liquids_shader/opengl_vertex.glsl b/client/shaders/liquids_shader/opengl_vertex.glsl
index 08c98cf..9ad16c8 100644
--- a/client/shaders/liquids_shader/opengl_vertex.glsl
+++ b/client/shaders/liquids_shader/opengl_vertex.glsl
@@ -4,6 +4,7 @@ uniform mat4 mInvWorld;
 uniform mat4 mTransWorld;
 uniform float dayNightRatio;
 uniform vec3 eyePosition;
+uniform float time;^M
 
 varying vec3 vPosition;
 varying vec3 viewVec;
@@ -14,9 +15,24 @@ varying vec3 viewPos;
 varying vec3 cameraPos;
 varying vec2 uv;
 
+float rand(vec2 co)^M
+{^M
+       return fract(sin(dot(co.xy ,vec2(12.9898,78.233))) * 43758.5453);^M
+}^M
+^M
 void main(void)
 {
-       gl_Position = mWorldViewProj * gl_Vertex;
+       int wavelength = 20;^M
+       float waveheight = 1.7;^M
+       int wavespeed = 100;^M
+       int height_randomness = 1;^M
+       ^M
+       vec4 pos2 = gl_Vertex;^M
+       pos2.y -= 3.0;^M
+       pos2.y -= sin (pos2.z/wavelength + time * wavespeed * wavelength) * waveheight^M
+               + sin ((pos2.z/wavelength + time * wavespeed * wavelength)/7) * waveheight * height_randomness;^M
+       ^M
+       gl_Position = mWorldViewProj * pos2;^M
 
        vPosition = (mWorldViewProj * gl_Vertex).xyz;
        vec3 pos = vec3(gl_Vertex);
diff --git a/src/game.cpp b/src/game.cpp
index 4c5e285..580ba8d 100644
--- a/src/game.cpp
+++ b/src/game.cpp
@@ -839,6 +839,8 @@ public:
                services->setPixelShaderConstant("useNormalmap" , (irr::s32*)&layer2, 1);
                services->setPixelShaderConstant("normalSampler" , (irr::s32*)&layer3, 1);
 #endif
+               float timeofday = m_client->getEnv().getTimeOfDayF();
+               services->setPixelShaderConstant("time", &timeofday, 1);
        }
 };
 
diff --git a/src/mapblock_mesh.cpp b/src/mapblock_mesh.cpp
index f56a986..fa6cf6a 100644
--- a/src/mapblock_mesh.cpp
+++ b/src/mapblock_mesh.cpp
@@ -1201,7 +1201,7 @@ MapBlockMesh::MapBlockMesh(MeshMakeData *data):
                if (enable_shaders) {
                        ITextureSource *tsrc = data->m_gamedef->tsrc();
                        material.setTexture(2, tsrc->getTexture("disable_img.png"));
-                       material.setTexture(3, tsrc->getTexture(getTexturePath("water_surface_normalmap.png").c_str));
+                       material.setTexture(3, tsrc->getTexture("water_surface_normalmap.png"));
                        if (enable_bumpmapping) {
                                std::string fname_base = tsrc->getTextureName(p.tile.texture_id);
                                std::string normal_ext = "_normal.png";


It pleases me greatly to see you supporting RealBadAngel's shaders, PilzAdam.

The new water shaders are very impressive, but may still be a little glitchy. Water that is in caves still has grayish coloration from time to time. Another thing I noticed is that lava also gets the water shaders, but ends up looking like water in the process.

The parallax mapping is working now, but the effect doesn't appear to be 3D from some viewing angles. Xonotic, Red Eclipse, and Sauerbraten have parallax mapping in them, so they can provide inspiration if it is needed. Calinou is involved in the communities of those games, so he might be of assistance.

I can tell that good progress is being made with the shaders. I know that the end result will be impressive.
Last edited by Inocudom on Sun Nov 03, 2013 16:49, edited 1 time in total.
 

User avatar
RealBadAngel
Member
 
Posts: 556
Joined: Wed Jul 18, 2012 16:30

by RealBadAngel » Sun Nov 03, 2013 17:41

I have updated first post with all the aviable config settings.

Issue with parallax not working perfectly is that we dont have properly calculated tangent.
I do have the code to calculate it in the engine, but theres no way to pass it to shaders.
Theres no way in irrlicht to use GLSL shaders attribute or to pass uniform sampler buffers.
 

User avatar
Inocudom
Member
 
Posts: 2889
Joined: Sat Sep 29, 2012 01:14
IRC: Inocudom
In-game: Inocudom

by Inocudom » Sun Nov 03, 2013 18:33

RealBadAngel wrote:I have updated first post with all the aviable config settings.

Issue with parallax not working perfectly is that we dont have properly calculated tangent.
I do have the code to calculate it in the engine, but theres no way to pass it to shaders.
Theres no way in irrlicht to use GLSL shaders attribute or to pass uniform sampler buffers.


That does not sound good. Why would Irrlicht not have such a feature?
 

User avatar
tkerwel
Member
 
Posts: 213
Joined: Fri Jan 13, 2012 07:35

by tkerwel » Mon Nov 04, 2013 09:53

i use minetest-0.4.7-54c8bdb-shaders-win32 and always get the error:


10:46:56: ERROR[main]: generate_shader(): failed to generate "liquids_shader", addHighLevelShaderMaterial failed.

can still play but the water looks strange. its like looking thru dark glass dosent matter if i play this on my laptop or my highend gaming pc.

settings are:

enable_water_wave = true
water_wave_height = 0.4
water_wave_speed = 50
water_wave_length = 20
enable_bumpmapping = true
parallax_mapping_mode = 2
parallax_mapping_scale = 0.08
parallax_mapping_bias = 0.04
++++ Kung walang tiyaga, walang nilaga. ++++
 

User avatar
RealBadAngel
Member
 
Posts: 556
Joined: Wed Jul 18, 2012 16:30

by RealBadAngel » Mon Nov 04, 2013 14:34

tkerwel wrote:i use minetest-0.4.7-54c8bdb-shaders-win32 and always get the error:


10:46:56: ERROR[main]: generate_shader(): failed to generate "liquids_shader", addHighLevelShaderMaterial failed.

can still play but the water looks strange. its like looking thru dark glass dosent matter if i play this on my laptop or my highend gaming pc.

settings are:

enable_water_wave = true
water_wave_height = 0.4
water_wave_speed = 50
water_wave_length = 20
enable_bumpmapping = true
parallax_mapping_mode = 2
parallax_mapping_scale = 0.08
parallax_mapping_bias = 0.04


Please add a few more lines around that error message, i need more details.
 

User avatar
sfan5
Member
 
Posts: 3636
Joined: Wed Aug 24, 2011 09:44
GitHub: sfan5
IRC: sfan5

by sfan5 » Mon Nov 04, 2013 15:05

It would be nice if you could fix these errors:
http://pastebin.com/WE4H6FGi
Mods: Mesecons | WorldEdit | Nuke
Minetest builds for Windows (32-bit & 64-bit)
 

User avatar
RealBadAngel
Member
 
Posts: 556
Joined: Wed Jul 18, 2012 16:30

by RealBadAngel » Mon Nov 04, 2013 17:53

sfan5 wrote:It would be nice if you could fix these errors:
http://pastebin.com/WE4H6FGi


Those are not errors but your OpenGL, I guess youre using open drivers.
Im not sure if i can make all the code run with it but i will try.
Whats your OpenGL version?
Last edited by RealBadAngel on Mon Nov 04, 2013 18:01, edited 1 time in total.
 

User avatar
sfan5
Member
 
Posts: 3636
Joined: Wed Aug 24, 2011 09:44
GitHub: sfan5
IRC: sfan5

by sfan5 » Mon Nov 04, 2013 20:12

RealBadAngel wrote:Those are not errors but your OpenGL

I'm pretty sure that are errors..
RealBadAngel wrote:Whats your OpenGL version?

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
$ glxinfo | grep version
server glx version string: 1.4
client glx version string: 1.4
GLX version: 1.4
OpenGL core profile version string: 3.1 (Core Profile) Mesa 9.2.1
OpenGL core profile shading language version string: 1.40
OpenGL version string: 3.0 Mesa 9.2.1
OpenGL shading language version string: 1.30
Mods: Mesecons | WorldEdit | Nuke
Minetest builds for Windows (32-bit & 64-bit)
 

User avatar
hoodedice
Member
 
Posts: 1372
Joined: Sat Jul 06, 2013 06:33

by hoodedice » Mon Nov 04, 2013 22:26

Jordach wrote:
hoodedice wrote: intel GMA
You will not be able to run shaders whatsoever.

Sorry bud.


They run in FlightGear, but they cause tons of lag. I was just gonna check out what they looked like.

sfan5 wrote:
hoodedice wrote:For me, I get it all red. (Using sfan's build posted above.) Windows x86 XP with intel GMA

Don't use DirectX


I'm not using it (I guess). Well, minetest reports that my OpenGL version is 2.0 so maybe I'm running OpenGL. Again, I don't think sfan made a build with DirectX.
7:42 PM - Bauglio: I think if you go to staples you could steal firmware from a fax machine that would run better than win10 does on any platform
7:42 PM - Bauglio: so fudge the stable build
7:43 PM - Bauglio: get the staple build
 

User avatar
Inocudom
Member
 
Posts: 2889
Joined: Sat Sep 29, 2012 01:14
IRC: Inocudom
In-game: Inocudom

by Inocudom » Tue Nov 05, 2013 01:43

With PilzAdam's latest build of RealBadAngel's shaders branch, I was able to record a video of the shaders. The video is of somewhat low quality, but the shaders are visible.
Attachments

[The extension avi has been deactivated and can no longer be displayed.]

 

User avatar
cHyper
Member
 
Posts: 587
Joined: Fri May 06, 2011 08:49
IRC: cHyper
In-game: cHyper

by cHyper » Tue Nov 05, 2013 05:11

are there any shaders planed for AMD video cards?

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
Irrlicht Engine version 1.8.0
Microsoft Windows 7 Home Premium Edition Service Pack 1 (Build 7601)
Using renderer: OpenGL 4.2.11631
AMD Radeon HD 6500M/5600/5700 Series: ATI Technologies Inc.
OpenGL driver version is 1.2 or better.
GLSL version: 4.2
--------------------------------------------------------
 

User avatar
VanessaE
Member
 
Posts: 3894
Joined: Sun Apr 01, 2012 12:38
GitHub: VanessaE
IRC: VanessaE
In-game: VanessaEzekowitz

by VanessaE » Tue Nov 05, 2013 05:34

In theory they should work with any video card, but they don't work for me. I assumed it was an incompatibility with my OpenGL version (4.3.12614), as RBA develops on an older OpenGL (2.2 or something) and AMD video.
You might like some of my stuff:
Plantlife ~ More Trees ~ Home Decor ~ Pipeworks ~ HDX Textures (16-512px)
Tips (BTC): 13LdcdUFcNCFAm7HfvAXh5GHTjCnnQj6KE
 

User avatar
tkerwel
Member
 
Posts: 213
Joined: Fri Jan 13, 2012 07:35

by tkerwel » Tue Nov 05, 2013 06:20

RealBadAngel wrote:
tkerwel wrote:i use minetest-0.4.7-54c8bdb-shaders-win32 and always get the error:


10:46:56: ERROR[main]: generate_shader(): failed to generate "liquids_shader", addHighLevelShaderMaterial failed.

can still play but the water looks strange. its like looking thru dark glass dosent matter if i play this on my laptop or my highend gaming pc.

settings are:

enable_water_wave = true
water_wave_height = 0.4
water_wave_speed = 50
water_wave_length = 20
enable_bumpmapping = true
parallax_mapping_mode = 2
parallax_mapping_scale = 0.08
parallax_mapping_bias = 0.04


Please add a few more lines around that error message, i need more details.


okay after i read your message i was looking whats the difference between the two computers. after a update for the newest OpenGL on the big one, i dont get this error anymore. so looks like this is something with the OpenGL drivers which cause the problem.
++++ Kung walang tiyaga, walang nilaga. ++++
 

User avatar
RealBadAngel
Member
 
Posts: 556
Joined: Wed Jul 18, 2012 16:30

by RealBadAngel » Tue Nov 05, 2013 06:34

Looks like on one end im using something that is not supported by older drivers and at the very same time things that were removed or altered in new ones.
Thats pretty weird :)

I think i removed most of the "errors" reported by sfan5, i think.
One remains for sure is texelFetch, will see what i can do about it.

Please do note if you see everything red, shaders were not compiled (due to errors) and are not workin at all.
Also if reporting errors, please do paste not only the message that shader is not working, but the lines around sayin what were the errors...
Last edited by RealBadAngel on Tue Nov 05, 2013 06:36, edited 1 time in total.
 

User avatar
RealBadAngel
Member
 
Posts: 556
Joined: Wed Jul 18, 2012 16:30

by RealBadAngel » Thu Nov 07, 2013 20:07

My "fork" is updated with brand new calculations of tangent space.
Finally parallax mapping is looking as it should from any angle.
One problem left is kinda texture sliding, which is natural for it.
But i propably may have an idea how to solve it...

Meanwhile some new shots:

Without/Bump/Bump+Parallax mode 1

Image
Image
Image

and some reworked HDX texture too:

Image
Last edited by RealBadAngel on Thu Nov 07, 2013 20:12, edited 1 time in total.
 

User avatar
Inocudom
Member
 
Posts: 2889
Joined: Sat Sep 29, 2012 01:14
IRC: Inocudom
In-game: Inocudom

by Inocudom » Thu Nov 07, 2013 21:48

I wish there was a way that this branch could be merged with proller's next branch. Maybe PilzAdam's version of this branch could be?
 

User avatar
LionsDen
Member
 
Posts: 525
Joined: Thu Jun 06, 2013 03:19

by LionsDen » Thu Nov 07, 2013 23:43

RealBadAngel wrote:My "fork" is updated with brand new calculations of tangent space.
Finally parallax mapping is looking as it should from any angle.
One problem left is kinda texture sliding, which is natural for it.
But i propably may have an idea how to solve it...

Meanwhile some new shots:

Without/Bump/Bump+Parallax mode 1

http://realbadangel.pl/images/wall1.png
http://realbadangel.pl/images/wall2.png
http://realbadangel.pl/images/wall3.png

and some reworked HDX texture too:

http://realbadangel.pl/images/hdx_bricks3.png


Why do your bricks look all glassy with the bump mapping turned on? They don't look glassy in normal mode.
 

User avatar
RealBadAngel
Member
 
Posts: 556
Joined: Wed Jul 18, 2012 16:30

by RealBadAngel » Fri Nov 08, 2013 03:27

LionsDen wrote:Why do your bricks look all glassy with the bump mapping turned on? They don't look glassy in normal mode.


Mainly to show the difference. Also, CrazyBump's default settings creates pretty "strong" bumpmaps ;)
 

User avatar
hoodedice
Member
 
Posts: 1372
Joined: Sat Jul 06, 2013 06:33

by hoodedice » Sat Nov 09, 2013 08:50

The windows debug console gave me a hard time. I however, managed to extract the following

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
GLSL shader failed to compile
ERROR: 0:19: 'texelFetch' : no matching overloaded function found - implicit con
version not allowed
ERROR: 0:19: 'r' :  field selection requires structure, vector, or matrix on lef
t hand side
ERROR: 0:23: '=' :  cannot convert from 'const int' to 'float'
ERROR: 0:32: '==' :  wrong operand types  no operation '==' exists that takes a
left-hand operand of type 'float' and a right operand of type 'const int' (or th
ere is no acceptable conversion)
ERROR: 0:32: '>' :  wrong operand types  no operation '>' exists that takes a le
ft-hand operand of type 'float' and a right operand of type 'const int' (or ther
e is no acceptable conversion)
ERROR: 0:38: '==' :  wrong operand types  no operation '==' exists that takes a
left-hand operand of type 'float' and a right operand of type 'const int' (or th
ere is no acceptable conversion)
ERROR: 0:38: '>' :  wrong operand types  no operation '>' exists that takes a le
ft-hand operand of type 'float' and a right operand of type 'const int' (or ther
e is no acceptable conversion)
ERROR: 0:55: '==' :  wrong operand types  no operation '==' exists that takes a
left-hand operand of type 'float' and a right operand of type 'const int' (or th
ere is no acceptable conversion)
ERROR: 0:55: '>' :  wrong operand types  no operation '>' exists that takes a le
ft-hand operand of type 'float' and a right operand of type 'const int' (or ther
e is no acceptable conversion)
ERROR: 0:59: Unary operation not folded into constant

14:13:42: ERROR[main]: generate_shader(): failed to generate "solids_shader", ad
dHighLevelShaderMaterial failed.
GLSL shader failed to compile
ERROR: 0:92: '*' :  wrong operand types  no operation '*' exists that takes a le
ft-hand operand of type 'uniform float' and a right operand of type 'const int'
(or there is no acceptable conversion)
ERROR: 0:97: 'assign' :  l-value required "uv" (can't modify a varying)
ERROR: 0:204: Unary operation not folded into constant
ERROR: 0:205: Unary operation not folded into constant
ERROR: 0:206: Unary operation not folded into constant

14:13:42: ERROR[main]: generate_shader(): failed to generate "liquids_shader", a
ddHighLevelShaderMaterial failed.
14:13:42: ERROR[main]: generateImage(): Could not load image "reflection.png" wh
ile building texture
14:13:42: ERROR[main]: generateImage(): Creating a dummy image for "reflection.p
ng"
Unsupported texture format
Loaded texture: E:/minetestshaders/minetest-0.4.7-382357d-rba-shaders-win32/text
ures/base/pack/sunrisebg.png
Loaded texture: E:/minetestshaders/minetest-0.4.7-382357d-rba-shaders-win32/text
ures/base/pack/sun.png
Loaded texture: E:/minetestshaders/minetest-0.4.7-382357d-rba-shaders-win32/text
ures/base/pack/moon.png
Loaded texture: E:/minetestshaders/minetest-0.4.7-382357d-rba-shaders-win32/text
ures/base/pack/sun_tonemap.png
Loaded texture: E:/minetestshaders/minetest-0.4.7-382357d-rba-shaders-win32/text
ures/base/pack/moon_tonemap.png
Font size: 8 17


So, the GLSL shaders did not compile after all...

And this from debug.txt

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
14:06:46: INFO[main]: SourceShaderCache::getOrLoad(): Loading path "E:\minetestshaders\minetest-0.4.7-382357d-rba-shaders-win32\bin\..\client\shaders\solids_shader\base.txt"
14:06:46: INFO[main]: SourceShaderCache::getOrLoad(): Loading path "E:\minetestshaders\minetest-0.4.7-382357d-rba-shaders-win32\bin\..\client\shaders\solids_shader\opengl_vertex.glsl"
14:06:46: INFO[main]: SourceShaderCache::getOrLoad(): Loading path "E:\minetestshaders\minetest-0.4.7-382357d-rba-shaders-win32\bin\..\client\shaders\solids_shader\opengl_fragment.glsl"
14:06:46: INFO[main]: SourceShaderCache::getOrLoad(): No path found for "solids_shader\opengl_geometry.glsl"
14:06:46: INFO[main]: Compiling high level shaders for solids_shader
14:06:46: ERROR[main]: generate_shader(): failed to generate "solids_shader", addHighLevelShaderMaterial failed.
14:06:46: INFO[main]: SourceShaderCache::getOrLoad(): Loading path "E:\minetestshaders\minetest-0.4.7-382357d-rba-shaders-win32\bin\..\client\shaders\liquids_shader\base.txt"
14:06:46: INFO[main]: SourceShaderCache::getOrLoad(): Loading path "E:\minetestshaders\minetest-0.4.7-382357d-rba-shaders-win32\bin\..\client\shaders\liquids_shader\opengl_vertex.glsl"
14:06:46: INFO[main]: SourceShaderCache::getOrLoad(): Loading path "E:\minetestshaders\minetest-0.4.7-382357d-rba-shaders-win32\bin\..\client\shaders\liquids_shader\opengl_fragment.glsl"
14:06:46: INFO[main]: SourceShaderCache::getOrLoad(): No path found for "liquids_shader\opengl_geometry.glsl"
14:06:46: INFO[main]: Compiling high level shaders for liquids_shader
14:06:46: ERROR[main]: generate_shader(): failed to generate "liquids_shader", addHighLevelShaderMaterial failed.
14:06:46: INFO[main]: SourceShaderCache::getOrLoad(): Loading path "E:\minetestshaders\minetest-0.4.7-382357d-rba-shaders-win32\bin\..\client\shaders\alpha_shader\base.txt"
14:06:46: INFO[main]: SourceShaderCache::getOrLoad(): Loading path "E:\minetestshaders\minetest-0.4.7-382357d-rba-shaders-win32\bin\..\client\shaders\alpha_shader\opengl_vertex.glsl"
14:06:46: INFO[main]: SourceShaderCache::getOrLoad(): Loading path "E:\minetestshaders\minetest-0.4.7-382357d-rba-shaders-win32\bin\..\client\shaders\alpha_shader\opengl_fragment.glsl"
14:06:46: INFO[main]: SourceShaderCache::getOrLoad(): No path found for "alpha_shader\opengl_geometry.glsl"
14:06:46: INFO[main]: Compiling high level shaders for alpha_shader
14:06:46: INFO[main]: SourceImageCache::getOrLoad(): Loading path "E:\minetestshaders\minetest-0.4.7-382357d-rba-shaders-win32\bin\..\textures\base\pack\disable_img.png"
14:06:46: INFO[main]: SourceImageCache::getOrLoad(): No path found for "reflection.png"
14:06:46: ERROR[main]: generateImage(): Could not load image "reflection.png" while building texture
14:06:46: ERROR[main]: generateImage(): Creating a dummy image for "reflection.png"


I don't know if it is relevant or if it will help out at all, but just trying. =)
Last edited by hoodedice on Sat Nov 09, 2013 08:52, edited 1 time in total.
7:42 PM - Bauglio: I think if you go to staples you could steal firmware from a fax machine that would run better than win10 does on any platform
7:42 PM - Bauglio: so fudge the stable build
7:43 PM - Bauglio: get the staple build
 

User avatar
RealBadAngel
Member
 
Posts: 556
Joined: Wed Jul 18, 2012 16:30

by RealBadAngel » Sat Nov 09, 2013 23:03

hoodedice wrote:The windows debug console gave me a hard time. I however, managed to extract the following

So, the GLSL shaders did not compile after all...

I don't know if it is relevant or if it will help out at all, but just trying. =)


Please tell me your version of OpenGL (You can see it when game starts within first lines)
Also most of those errors are already fixed in my branch (youre using older build)
 

User avatar
RealBadAngel
Member
 
Posts: 556
Joined: Wed Jul 18, 2012 16:30

by RealBadAngel » Sun Nov 10, 2013 09:01

Here comes windows build with up to date shaders.
All the errors reported in solids shaders should be gone.
Please let me know if it works for you.

http://realbadangel.pl/minetest/shaders/minetest_shaders_11-10.zip
Build comes with Haven texture pack to test the changes with, minetest_game and config file.
 

User avatar
hoodedice
Member
 
Posts: 1372
Joined: Sat Jul 06, 2013 06:33

by hoodedice » Sun Nov 10, 2013 11:08

OpenGL Version 2.1.0

[spoiler=PC Specs]
Intel Core 2 Duo E7500 @2.93 GHz
Intel G41 Chipset, settings tuned to Performance
4 GB RAM
Windows XP x86 SP3
[/spoiler]

Minetest - RBA build 11-10

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
GLSL shader failed to compile
ERROR: 0:62: '*' :  wrong operand types  no operation '*' exists that takes a le
ft-hand operand of type '3-component vector of float' and a right operand of typ
e 'const int' (or there is no acceptable conversion)
ERROR: 0:65: 'assign' :  cannot convert from '4-component vector of float' to '3
-component vector of float'

16:32:49: ERROR[main]: generate_shader(): failed to generate "solids_shader", ad
dHighLevelShaderMaterial failed.
GLSL shader failed to compile
ERROR: 0:32: '/' :  wrong operand types  no operation '/' exists that takes a le
ft-hand operand of type 'float' and a right operand of type 'int' (or there is n
o acceptable conversion)
ERROR: 0:32: '*' :  wrong operand types  no operation '*' exists that takes a le
ft-hand operand of type 'uniform float' and a right operand of type 'int' (or th
ere is no acceptable conversion)
ERROR: 0:32: '*' :  wrong operand types  no operation '*' exists that takes a le
ft-hand operand of type 'uniform float' and a right operand of type 'int' (or th
ere is no acceptable conversion)
ERROR: 0:33: '/' :  wrong operand types  no operation '/' exists that takes a le
ft-hand operand of type 'float' and a right operand of type 'int' (or there is n
o acceptable conversion)
ERROR: 0:33: '*' :  wrong operand types  no operation '*' exists that takes a le
ft-hand operand of type 'uniform float' and a right operand of type 'int' (or th
ere is no acceptable conversion)
ERROR: 0:33: '*' :  wrong operand types  no operation '*' exists that takes a le
ft-hand operand of type 'uniform float' and a right operand of type 'int' (or th
ere is no acceptable conversion)
ERROR: 0:33: '/' :  wrong operand types  no operation '/' exists that takes a le
ft-hand operand of type 'float' and a right operand of type 'const int' (or ther
e is no acceptable conversion)
ERROR: 0:33: '*' :  wrong operand types  no operation '*' exists that takes a le
ft-hand operand of type 'float' and a right operand of type 'int' (or there is n
o acceptable conversion)
16:32:49: ERROR[main]: generate_shader(): failed to generate "liquids_shader", a
ddHighLevelShaderMaterial failed.


End_Result = Same ol' red thingy
Last edited by hoodedice on Sun Nov 10, 2013 11:10, edited 1 time in total.
7:42 PM - Bauglio: I think if you go to staples you could steal firmware from a fax machine that would run better than win10 does on any platform
7:42 PM - Bauglio: so fudge the stable build
7:43 PM - Bauglio: get the staple build
 

User avatar
Inocudom
Member
 
Posts: 2889
Joined: Sat Sep 29, 2012 01:14
IRC: Inocudom
In-game: Inocudom

by Inocudom » Sun Nov 10, 2013 21:50

I tested the build that you made, RealBadAngel. I tested the tweaks you made to parallax mapping, and I can see that they are working better now. I can't really notice the parallax mapping effect on the plank and bookcase nodes, but it is noticeable on the dirt, sandstone brick, desert sand, brick, and sandstone nodes.

It appears that there is a red/purple discoloration in the fog towards the right side of the screen while underwater, and the shaders don't work on moving water (still water works fine.) Lava still does look like water at the moment.
Last edited by Inocudom on Sun Nov 10, 2013 21:52, edited 1 time in total.
 

PreviousNext

Return to Minetest Features

Who is online

Users browsing this forum: No registered users and 3 guests

cron