material-maker/addons/material_maker/preview.tscn

118 lines
3.7 KiB
Plaintext
Raw Normal View History

[gd_scene load_steps=9 format=2]
2018-08-05 18:46:23 +02:00
[ext_resource path="res://addons/material_maker/preview.gd" type="Script" id=1]
[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 ) ]
}
[sub_resource type="PanoramaSky" id=10]
2018-08-05 18:46:23 +02:00
radiance_size = 2
panorama = ExtResource( 3 )
2018-08-05 18:46:23 +02:00
[sub_resource type="Environment" id=11]
2018-08-05 18:46:23 +02:00
background_mode = 2
background_sky = SubResource( 10 )
2018-08-05 18:46:23 +02:00
[sub_resource type="Shader" id=12]
code = "shader_type canvas_item;
uniform sampler2D tex;
void fragment() {
COLOR = texture(tex, UV);
}"
[sub_resource type="ShaderMaterial" id=13]
shader = SubResource( 12 )
2018-08-05 18:46:23 +02:00
[node name="Preview" type="ViewportContainer"]
anchor_left = 1.0
anchor_right = 1.0
margin_left = -398.0
2018-08-05 18:46:23 +02:00
margin_top = 3.0
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 )
[node name="ObjectRotate" type="AnimationPlayer" parent="."]
2018-08-05 18:46:23 +02:00
autoplay = "rotate"
playback_speed = 0.1
anims/rotate = SubResource( 1 )
[node name="MaterialPreview" type="Viewport" parent="."]
size = Vector2( 395, 370 )
2018-08-05 18:46:23 +02:00
own_world = true
handle_input_locally = false
2018-08-05 18:46:23 +02:00
render_target_clear_mode = 1
render_target_update_mode = 3
[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
[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
[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 )
environment = SubResource( 11 )
2018-08-05 18:46:23 +02:00
current = true
[node name="WorldEnvironment" type="WorldEnvironment" parent="MaterialPreview"]
environment = SubResource( 11 )
2018-08-05 18:46:23 +02:00
[node name="Config" type="HBoxContainer" parent="."]
anchor_right = 1.0
margin_bottom = 20.0
2018-08-05 18:46:23 +02:00
[node name="Model" type="OptionButton" parent="Config"]
margin_right = 100.0
2018-08-05 18:46:23 +02:00
margin_bottom = 20.0
rect_min_size = Vector2( 100, 0 )
2018-08-05 18:46:23 +02:00
text = "Cube"
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
[node name="Environment" type="OptionButton" parent="Config"]
margin_left = 104.0
margin_right = 204.0
2018-08-05 18:46:23 +02:00
margin_bottom = 20.0
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
[node name="Preview2D" type="ColorRect" parent="."]
material = SubResource( 13 )
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"]