Lexpartizan/Godot_rain_shader

Cam Heightmap Size adds a blueish layer on top of my texture

Opened this issue · 4 comments

Hi i saw your youtube video on godot rain shaders nd figured out a way to use it in my project

but here is a problem i am facing

when i add/increases the amount on cam heightmap size it adds a blueish layer on top of my texture and on this blueish layer i can see the rain drops
where as if have to remove/decrees the amount of cam heightmap size the blueish layer goes and so the rain drops.

here are the image for reference.

Screenshot (60)
cam heightmap is 2

Screenshot (61)
cam heightmap is 0

here is the drive link to .rar folder

note: this folder isnt a godot project its just a scene

Hi. The blue hue is a godot default lighting problem https://www.youtube.com/watch?v=8kwnCxK8Vc8
This is not blue layer, this is just snow. But you forget set snow_normal texture.
Your heightmap camera nor working, becouse not have plane with shader for depth texture. Indeed, if there is no texture from the heitmap with the value cam_heightmap_size = 1, the shader operation is incorrect. In addition, the example with your textures showed the shortcomings of my shader, if the snow is wet, then you can see the stripes on the road through it. This means that first you need to apply snow and then make it wet, and I do the opposite. As a result, the stripes are brighter than snow. The second problem is that since I don't use displacement texture, I just use the texture color to overlay the snow. But in the case of the road due to patches, this does not work very well. So we need to make an option using displacement texture.

@itsDrac In general, I fixed this project a little, there should be no more problems with heightmap_size, at the same time I fixed the fact that you can see white stripes on the road in wet snow. To use the roofs, you need to carefully copy the ViewportCamera-Meshinstance nodes with their settings and install the shaders. Then create a New Resource in file System and specify the resource type as a viewport texture. Configure the path to the viewport in it. So far, this was conceived as a static scene, in order for the roof_camera to follow the game, it must be linked to the game and the rain shader must constantly transmit new coordinates of the roof_camera. And set the camera size in the shader and in the camera, respectively. However, you can do without roofs to begin with, so just leave the roofing_height value empty in the shader. The new version is uploaded to github. However, if necessary, I can redo your scene. Let me also remind you once again that the blue hue is due to the default lighting settings, so I use the hdr texture.
image
image

Thanks For taking the time to solve my issue and updating the project
can you make a detailed youtube video about this update?

Thanks

@itsDrac hate making videos. I'm too lazy for that. And english not my language. However, if you do not manage to configure something, do not hesitate to contact us here. This is not the simplest and most thoughtful project. Since I have not yet decided how to bind the same roof camera to the player's camera, and so on. Therefore, it is not surprising that there are problems with it. In addition, it is a fairly heavy and slow shader, so I'm going to use a texture atlas with it, so that there is a minimum of materials.