2019-09-29 10:07:32 +02:00
|
|
|
[gd_scene load_steps=9 format=2]
|
2018-08-05 18:46:23 +02:00
|
|
|
|
2018-09-03 21:35:44 +02:00
|
|
|
[ext_resource path="res://addons/material_maker/preview.gd" type="Script" id=1]
|
2019-09-29 10:07:32 +02:00
|
|
|
[ext_resource path="res://addons/material_maker/preview_objects.tscn" type="PackedScene" id=2]
|
|
|
|
[ext_resource path="res://addons/material_maker/panoramas/park.hdr" type="Texture" id=3]
|
2018-08-05 18:46:23 +02:00
|
|
|
|
|
|
|
[sub_resource type="Animation" id=1]
|
|
|
|
loop = true
|
|
|
|
tracks/0/type = "value"
|
|
|
|
tracks/0/path = NodePath("MaterialPreview/Objects:rotation_degrees")
|
|
|
|
tracks/0/interp = 1
|
|
|
|
tracks/0/loop_wrap = true
|
|
|
|
tracks/0/imported = false
|
|
|
|
tracks/0/enabled = true
|
|
|
|
tracks/0/keys = {
|
|
|
|
"times": PoolRealArray( 0, 1 ),
|
|
|
|
"transitions": PoolRealArray( 1, 1 ),
|
|
|
|
"update": 0,
|
|
|
|
"values": [ Vector3( 0, 0, 0 ), Vector3( 0, 360, 0 ) ]
|
|
|
|
}
|
|
|
|
|
2019-09-29 10:07:32 +02:00
|
|
|
[sub_resource type="PanoramaSky" id=10]
|
2018-08-05 18:46:23 +02:00
|
|
|
radiance_size = 2
|
2019-09-29 10:07:32 +02:00
|
|
|
panorama = ExtResource( 3 )
|
2018-08-05 18:46:23 +02:00
|
|
|
|
2019-09-29 10:07:32 +02:00
|
|
|
[sub_resource type="Environment" id=11]
|
2018-08-05 18:46:23 +02:00
|
|
|
background_mode = 2
|
2019-09-29 10:07:32 +02:00
|
|
|
background_sky = SubResource( 10 )
|
2018-08-05 18:46:23 +02:00
|
|
|
|
2019-09-29 10:07:32 +02:00
|
|
|
[sub_resource type="Shader" id=12]
|
2018-08-07 09:31:41 +02:00
|
|
|
code = "shader_type canvas_item;
|
|
|
|
|
2019-08-12 15:58:42 +02:00
|
|
|
uniform sampler2D tex;
|
|
|
|
|
|
|
|
void fragment() {
|
|
|
|
COLOR = texture(tex, UV);
|
|
|
|
}"
|
2018-08-07 09:31:41 +02:00
|
|
|
|
2019-09-29 10:07:32 +02:00
|
|
|
[sub_resource type="ShaderMaterial" id=13]
|
|
|
|
shader = SubResource( 12 )
|
2018-08-07 09:31:41 +02:00
|
|
|
|
2018-08-05 18:46:23 +02:00
|
|
|
[node name="Preview" type="ViewportContainer"]
|
|
|
|
anchor_left = 1.0
|
|
|
|
anchor_right = 1.0
|
2018-08-07 09:31:41 +02:00
|
|
|
margin_left = -398.0
|
2018-08-05 18:46:23 +02:00
|
|
|
margin_top = 3.0
|
2018-08-07 09:31:41 +02:00
|
|
|
margin_right = -3.0
|
|
|
|
margin_bottom = 373.0
|
|
|
|
rect_min_size = Vector2( 200, 200 )
|
2018-08-05 18:46:23 +02:00
|
|
|
mouse_filter = 2
|
|
|
|
size_flags_horizontal = 3
|
|
|
|
size_flags_vertical = 3
|
|
|
|
stretch = true
|
|
|
|
script = ExtResource( 1 )
|
|
|
|
|
2019-08-12 15:58:42 +02:00
|
|
|
[node name="ObjectRotate" type="AnimationPlayer" parent="."]
|
2018-08-05 18:46:23 +02:00
|
|
|
autoplay = "rotate"
|
|
|
|
playback_speed = 0.1
|
|
|
|
anims/rotate = SubResource( 1 )
|
|
|
|
|
2019-08-12 15:58:42 +02:00
|
|
|
[node name="MaterialPreview" type="Viewport" parent="."]
|
2018-08-07 09:31:41 +02:00
|
|
|
size = Vector2( 395, 370 )
|
2018-08-05 18:46:23 +02:00
|
|
|
own_world = true
|
2019-08-12 15:58:42 +02:00
|
|
|
handle_input_locally = false
|
2018-08-05 18:46:23 +02:00
|
|
|
render_target_clear_mode = 1
|
|
|
|
render_target_update_mode = 3
|
|
|
|
|
2019-09-29 10:07:32 +02:00
|
|
|
[node name="Objects" parent="MaterialPreview" instance=ExtResource( 2 )]
|
|
|
|
transform = Transform( 0.81104, 0, 0.584983, 0, 1, 0, -0.584983, 0, 0.81104, 0, 0, 0 )
|
2018-08-05 18:46:23 +02:00
|
|
|
|
2019-08-12 15:58:42 +02:00
|
|
|
[node name="OmniLight" type="OmniLight" parent="MaterialPreview"]
|
2018-08-05 18:46:23 +02:00
|
|
|
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 1.04729, 1.80471, -2.51024 )
|
|
|
|
omni_range = 6.46518
|
|
|
|
|
2019-08-12 15:58:42 +02:00
|
|
|
[node name="Camera" type="Camera" parent="MaterialPreview"]
|
2018-08-05 18:46:23 +02:00
|
|
|
transform = Transform( 1, 0, 0, 0, 0.766044, 0.642787, 0, -0.642787, 0.766044, 0, 1.83022, 2.2549 )
|
2019-09-29 10:07:32 +02:00
|
|
|
environment = SubResource( 11 )
|
2018-08-05 18:46:23 +02:00
|
|
|
current = true
|
|
|
|
|
2019-08-12 15:58:42 +02:00
|
|
|
[node name="WorldEnvironment" type="WorldEnvironment" parent="MaterialPreview"]
|
2019-09-29 10:07:32 +02:00
|
|
|
environment = SubResource( 11 )
|
2018-08-05 18:46:23 +02:00
|
|
|
|
2019-08-12 15:58:42 +02:00
|
|
|
[node name="Config" type="HBoxContainer" parent="."]
|
2018-08-07 09:31:41 +02:00
|
|
|
anchor_right = 1.0
|
|
|
|
margin_bottom = 20.0
|
2018-08-05 18:46:23 +02:00
|
|
|
|
2019-08-12 15:58:42 +02:00
|
|
|
[node name="Model" type="OptionButton" parent="Config"]
|
2018-08-07 09:31:41 +02:00
|
|
|
margin_right = 100.0
|
2018-08-05 18:46:23 +02:00
|
|
|
margin_bottom = 20.0
|
2018-08-07 09:31:41 +02:00
|
|
|
rect_min_size = Vector2( 100, 0 )
|
2018-08-05 18:46:23 +02:00
|
|
|
text = "Cube"
|
2019-09-29 10:07:32 +02:00
|
|
|
items = [ "Cube", null, false, -1, null, "Cylinder", null, false, -1, null, "Sphere", null, false, -1, null, "Plane", null, false, -1, null ]
|
2018-08-05 18:46:23 +02:00
|
|
|
selected = 0
|
|
|
|
|
2019-08-12 15:58:42 +02:00
|
|
|
[node name="Environment" type="OptionButton" parent="Config"]
|
2018-08-07 09:31:41 +02:00
|
|
|
margin_left = 104.0
|
|
|
|
margin_right = 204.0
|
2018-08-05 18:46:23 +02:00
|
|
|
margin_bottom = 20.0
|
2018-08-07 09:31:41 +02:00
|
|
|
rect_min_size = Vector2( 100, 0 )
|
2018-08-05 18:46:23 +02:00
|
|
|
text = "Park"
|
|
|
|
items = [ "Experiment", null, false, 0, null, "Lobby", null, false, 1, null, "Night", null, false, 2, null, "Park", null, false, 3, null, "Schelde", null, false, 4, null ]
|
|
|
|
selected = 3
|
2018-08-07 09:31:41 +02:00
|
|
|
|
2019-08-12 15:58:42 +02:00
|
|
|
[node name="Preview2D" type="ColorRect" parent="."]
|
2019-09-29 10:07:32 +02:00
|
|
|
material = SubResource( 13 )
|
2018-08-07 09:31:41 +02:00
|
|
|
anchor_top = 1.0
|
|
|
|
anchor_bottom = 1.0
|
|
|
|
margin_top = -64.0
|
|
|
|
margin_right = 64.0
|
|
|
|
rect_min_size = Vector2( 64, 64 )
|
|
|
|
mouse_filter = 1
|
|
|
|
size_flags_horizontal = 0
|
|
|
|
size_flags_vertical = 8
|
|
|
|
[connection signal="resized" from="." to="." method="_on_Preview_resized"]
|
|
|
|
[connection signal="item_selected" from="Config/Model" to="." method="_on_Model_item_selected"]
|
|
|
|
[connection signal="item_selected" from="Config/Environment" to="." method="_on_Environment_item_selected"]
|
|
|
|
[connection signal="gui_input" from="Preview2D" to="." method="_on_Preview2D_gui_input"]
|