You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
115 lines
3.0 KiB
115 lines
3.0 KiB
[gd_scene load_steps=4 format=3 uid="uid://df4gmjq2o1ttn"] |
|
|
|
[ext_resource type="Script" path="res://Example/LocalMediaViewer/Script/ViewLocalVideoMediaViewer.cs" id="1_hfhp3"] |
|
|
|
[sub_resource type="VideoStreamTheora" id="VideoStreamTheora_6wg02"] |
|
|
|
[sub_resource type="ImageTexture" id="ImageTexture_2g46x"] |
|
|
|
[node name="LocalMediaViewer" type="Control"] |
|
layout_mode = 3 |
|
anchors_preset = 15 |
|
anchor_right = 1.0 |
|
anchor_bottom = 1.0 |
|
grow_horizontal = 2 |
|
grow_vertical = 2 |
|
script = ExtResource("1_hfhp3") |
|
|
|
[node name="ViewVideo" type="VideoStreamPlayer" parent="."] |
|
visible = false |
|
layout_mode = 1 |
|
anchors_preset = -1 |
|
anchor_left = 0.2 |
|
anchor_right = 1.0 |
|
anchor_bottom = 0.8 |
|
grow_horizontal = 2 |
|
grow_vertical = 2 |
|
stream = SubResource("VideoStreamTheora_6wg02") |
|
expand = true |
|
metadata/_edit_use_anchors_ = true |
|
|
|
[node name="ViewImage" type="TextureRect" parent="."] |
|
layout_mode = 1 |
|
anchors_preset = -1 |
|
anchor_left = 0.2 |
|
anchor_right = 1.0 |
|
anchor_bottom = 0.8 |
|
grow_horizontal = 2 |
|
grow_vertical = 2 |
|
texture = SubResource("ImageTexture_2g46x") |
|
expand_mode = 1 |
|
metadata/_edit_use_anchors_ = true |
|
|
|
[node name="Tab" type="TabContainer" parent="."] |
|
layout_mode = 1 |
|
anchors_preset = -1 |
|
anchor_right = 0.2 |
|
anchor_bottom = 0.8 |
|
grow_horizontal = 2 |
|
grow_vertical = 2 |
|
current_tab = 0 |
|
metadata/_edit_use_anchors_ = true |
|
|
|
[node name="Media" type="ScrollContainer" parent="Tab"] |
|
layout_mode = 2 |
|
metadata/_edit_use_anchors_ = true |
|
metadata/_tab_index = 0 |
|
|
|
[node name="MediaList" type="VBoxContainer" parent="Tab/Media"] |
|
layout_mode = 2 |
|
size_flags_horizontal = 3 |
|
|
|
[node name="ControlList" type="HBoxContainer" parent="."] |
|
layout_mode = 1 |
|
anchors_preset = -1 |
|
anchor_left = 0.2 |
|
anchor_top = 0.8 |
|
anchor_right = 1.0 |
|
anchor_bottom = 1.0 |
|
grow_horizontal = 2 |
|
grow_vertical = 2 |
|
metadata/_edit_use_anchors_ = true |
|
|
|
[node name="ImportList" type="HBoxContainer" parent="."] |
|
layout_mode = 1 |
|
anchors_preset = -1 |
|
anchor_top = 0.8 |
|
anchor_right = 0.2 |
|
anchor_bottom = 1.0 |
|
grow_horizontal = 2 |
|
grow_vertical = 2 |
|
metadata/_edit_use_anchors_ = true |
|
|
|
[node name="UploadImage" type="Button" parent="ImportList"] |
|
layout_mode = 2 |
|
size_flags_horizontal = 3 |
|
text = "导入图片" |
|
|
|
[node name="UploadVideo" type="Button" parent="ImportList"] |
|
layout_mode = 2 |
|
size_flags_horizontal = 3 |
|
text = "导入视频" |
|
|
|
[node name="ImportImage" type="FileDialog" parent="."] |
|
title = "Open a File" |
|
initial_position = 1 |
|
size = Vector2i(960, 640) |
|
ok_button_text = "Open" |
|
file_mode = 0 |
|
access = 2 |
|
filters = PackedStringArray("*.png", "*.jpg") |
|
|
|
[node name="ImportVideo" type="FileDialog" parent="."] |
|
auto_translate_mode = 1 |
|
title = "Open a File" |
|
initial_position = 1 |
|
size = Vector2i(960, 640) |
|
ok_button_text = "Open" |
|
file_mode = 0 |
|
access = 2 |
|
filters = PackedStringArray("*.ogv") |
|
|
|
[connection signal="pressed" from="ImportList/UploadImage" to="." method="OpenImportImage"] |
|
[connection signal="pressed" from="ImportList/UploadVideo" to="." method="OpenImportVideo"] |
|
[connection signal="file_selected" from="ImportImage" to="." method="UploadImage"] |
|
[connection signal="file_selected" from="ImportVideo" to="." method="UploadVideo"]
|
|
|