Bladeren bron

add ground texture

Malf 2 jaren geleden
bovenliggende
commit
2522ca790b

+ 6 - 17
shader/ground_shader.tres

@@ -1,12 +1,10 @@
-[gd_resource type="ShaderMaterial" load_steps=9 format=2]
+[gd_resource type="ShaderMaterial" load_steps=7 format=2]
 
-[ext_resource path="res://tex/ground/gravel_path_Height.png" type="Texture" id=1]
-[ext_resource path="res://tex/ground/gravel_path-ao.png" type="Texture" id=2]
-[ext_resource path="res://tex/ground/gravel_path_Metallic.png" type="Texture" id=3]
-[ext_resource path="res://tex/ground/gravel_path_Roughness.png" type="Texture" id=4]
-[ext_resource path="res://tex/ground/gravel_path_Normal-dx.png" type="Texture" id=5]
-[ext_resource path="res://tex/ground/gravel_path-albedo.png" type="Texture" id=6]
-[ext_resource path="res://tex/180-91.png" type="Texture" id=7]
+[ext_resource path="res://tex/ground/rock/displacement.jpg" type="Texture" id=1]
+[ext_resource path="res://tex/ground/rock/ao.jpg" type="Texture" id=2]
+[ext_resource path="res://tex/ground/rock/roughness.jpg" type="Texture" id=4]
+[ext_resource path="res://tex/ground/rock/normal.jpg" type="Texture" id=5]
+[ext_resource path="res://tex/ground/rock/albedo.jpg" type="Texture" id=6]
 
 [sub_resource type="Shader" id=1]
 code = "// NOTE: Shader automatically converted from Godot Engine 3.4.4.stable's SpatialMaterial.
@@ -17,11 +15,8 @@ uniform vec4 albedo : hint_color;
 uniform sampler2D texture_albedo_big;
 uniform sampler2D texture_albedo : hint_albedo;
 uniform float specular;
-uniform float metallic;
 uniform float roughness : hint_range(0,1);
 uniform float point_size : hint_range(0,128);
-uniform sampler2D texture_metallic : hint_white;
-uniform vec4 metallic_texture_channel;
 uniform sampler2D texture_roughness : hint_white;
 uniform vec4 roughness_texture_channel;
 uniform sampler2D texture_normal : hint_normal;
@@ -78,8 +73,6 @@ void fragment() {
 	vec4 albedo_tex_big = texture(texture_albedo_big,base_uv);
 	ALBEDO = albedo.rgb * (albedo_tex.rgb + albedo_tex_big.rgb);
 	
-	float metallic_tex = dot(texture(texture_metallic,scaled_uv),metallic_texture_channel);
-	METALLIC = metallic_tex * metallic;
 	float roughness_tex = dot(texture(texture_roughness,scaled_uv),roughness_texture_channel);
 	ROUGHNESS = roughness_tex * roughness;
 	SPECULAR = specular;
@@ -94,10 +87,8 @@ void fragment() {
 shader = SubResource( 1 )
 shader_param/albedo = Color( 1, 1, 1, 1 )
 shader_param/specular = 0.5
-shader_param/metallic = 0.0
 shader_param/roughness = 1.0
 shader_param/point_size = 1.0
-shader_param/metallic_texture_channel = Plane( 1, 0, 0, 0 )
 shader_param/roughness_texture_channel = Plane( 1, 0, 0, 0 )
 shader_param/normal_scale = -1.0
 shader_param/ao_texture_channel = Plane( 1, 0, 0, 0 )
@@ -110,9 +101,7 @@ shader_param/uv1_scale = Vector3( 1, 1, 1 )
 shader_param/uv1_offset = Vector3( 0, 0, 0 )
 shader_param/uv2_scale = Vector3( 1, 1, 1 )
 shader_param/uv2_offset = Vector3( 0, 0, 0 )
-shader_param/texture_albedo_big = ExtResource( 7 )
 shader_param/texture_albedo = ExtResource( 6 )
-shader_param/texture_metallic = ExtResource( 3 )
 shader_param/texture_roughness = ExtResource( 4 )
 shader_param/texture_normal = ExtResource( 5 )
 shader_param/texture_ambient_occlusion = ExtResource( 2 )

BIN
tex/eso.jpg


BIN
tex/ground/rock/albedo.jpg


BIN
tex/ground/rock/ao.jpg


BIN
tex/ground/rock/displacement.jpg


BIN
tex/ground/rock/normal.jpg


BIN
tex/ground/rock/roughness.jpg


BIN
tex/ground/sandyRocks/albedo.png


BIN
tex/ground/sandyRocks/ao.png


BIN
tex/ground/sandyRocks/displacement.png


BIN
tex/ground/sandyRocks/metallic.png


BIN
tex/ground/sandyRocks/normal.png


BIN
tex/ground/sandyRocks/roughness.png