Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sn03_playVideo
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
template admin
sn03_playVideo
Commits
2d7921af
Commit
2d7921af
authored
Oct 23, 2023
by
李维
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复实体机器播放被遮挡的问题
parent
71939b6a
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
312 additions
and
318 deletions
+312
-318
sn03_playVideo.fire
assets/sn03_playVideo/Scene/sn03_playVideo.fire
+297
-290
sn03_playVideo.ts
assets/sn03_playVideo/Scene/sn03_playVideo.ts
+12
-25
bg_bottom.png.meta
...eo/prefab/JJ_Video_01/Texture/newVideo/bg_bottom.png.meta
+1
-1
bg_left.png.meta
...ideo/prefab/JJ_Video_01/Texture/newVideo/bg_left.png.meta
+1
-1
bg_right.png.meta
...deo/prefab/JJ_Video_01/Texture/newVideo/bg_right.png.meta
+1
-1
No files found.
assets/sn03_playVideo/Scene/sn03_playVideo.fire
View file @
2d7921af
...
...
@@ -81,7 +81,7 @@
"__id__": 10
},
{
"__id__":
24
"__id__":
13
},
{
"__id__": 32
...
...
@@ -479,18 +479,14 @@
"_parent": {
"__id__": 2
},
"_children": [
{
"__id__": 11
}
],
"_children": [],
"_active": true,
"_components": [
{
"__id__":
22
"__id__":
11
},
{
"__id__":
23
"__id__":
12
}
],
"_prefab": null,
...
...
@@ -541,28 +537,87 @@
"groupIndex": 0,
"_id": "8bh6JRKctMb4af0b6FjAsw"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 10
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "7b1b9a24-6ffe-428a-94f7-a4167e2f58c9"
},
"_type": 0,
"_sizeMode": 0,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "60b9cz3NtNuKZFQjyHyQpB"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 10
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 45,
"_left": 1.9539925233402755e-14,
"_right": -1.9539925233402755e-14,
"_top": 0,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 1280,
"_originalHeight": 720,
"_id": "1dKfUaGQFC6YdTHXw74j25"
},
{
"__type__": "cc.Node",
"_name": "
bgN
ode",
"_name": "
video_n
ode",
"_objFlags": 0,
"_parent": {
"__id__":
10
"__id__":
2
},
"_children": [
{
"__id__": 1
2
"__id__": 1
4
},
{
"__id__": 1
5
"__id__": 1
7
},
{
"__id__":
18
"__id__":
20
}
],
"_active": true,
"_components": [
{
"__id__":
2
1
"__id__":
3
1
}
],
"_prefab": null,
...
...
@@ -576,8 +631,8 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width":
192
0,
"height":
1080
"width":
87
0,
"height":
542
},
"_anchorPoint": {
"__type__": "cc.Vec2",
...
...
@@ -588,8 +643,8 @@
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0
,
0
,
-6.121
,
141.782
,
0,
0,
0,
...
...
@@ -611,23 +666,23 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "
a45Agfi/ZP8JMF0qy3U0wQ
"
"_id": "
79FcrfhAJB1ZxFy+oGarZx
"
},
{
"__type__": "cc.Node",
"_name": "bg
_bottom
",
"_name": "bg",
"_objFlags": 0,
"_parent": {
"__id__": 1
1
"__id__": 1
3
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 1
3
"__id__": 1
5
},
{
"__id__": 1
4
"__id__": 1
6
}
],
"_prefab": null,
...
...
@@ -642,7 +697,7 @@
"_contentSize": {
"__type__": "cc.Size",
"width": 1920,
"height":
548
"height":
1080
},
"_anchorPoint": {
"__type__": "cc.Vec2",
...
...
@@ -653,8 +708,8 @@
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0
,
-
265.029
,
6.120999999999981
,
-
141.78200000000004
,
0,
0,
0,
...
...
@@ -676,14 +731,14 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "
efXCK6H4JD46f18GwkLeUQ
"
"_id": "
b2+lhhTKtNL6XR+jCG2/Ql
"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
2
"__id__": 1
4
},
"_enabled": true,
"_materials": [
...
...
@@ -694,7 +749,7 @@
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "
234ab084-10f0-444b-9317-05a2e79fc865
"
"__uuid__": "
7b1b9a24-6ffe-428a-94f7-a4167e2f58c9
"
},
"_type": 0,
"_sizeMode": 0,
...
...
@@ -708,19 +763,21 @@
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "
3dA0yKMQFM8rMIZ1FdjCFM
"
"_id": "
2dVQ2ey6VK+ate9eifEqQl
"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 1
2
"__id__": 1
4
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 40,
"_target": {
"__id__": 2
},
"_alignFlags": 45,
"_left": 0,
"_right": 0,
"_top": 0,
...
...
@@ -733,27 +790,24 @@
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 1
92
0,
"_originalHeight": 0,
"_id": "
aeJPNkD8hOWa8E5gRqq8jh
"
"_originalWidth": 1
28
0,
"_originalHeight":
72
0,
"_id": "
97UJh8Q/NAPp9mayeavQUf
"
},
{
"__type__": "cc.Node",
"_name": "
bg_left
",
"_name": "
videoBg
",
"_objFlags": 0,
"_parent": {
"__id__": 1
1
"__id__": 1
3
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 16
},
"_children": [
{
"__id__": 1
7
"__id__": 1
8
}
],
"_active": true,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
...
...
@@ -765,8 +819,8 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width":
223
,
"height":
274
"width":
0
,
"height":
0
},
"_anchorPoint": {
"__type__": "cc.Vec2",
...
...
@@ -777,8 +831,8 @@
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-848.5
,
298.628
,
0
,
-114.509
,
0,
0,
0,
...
...
@@ -800,82 +854,20 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "c6JjJ6+T1B+a0tWX1JMSiJ"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 15
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "6f7064ca-1a2b-40d6-9fd1-bee219ca78a8"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "9fCR3B1+BHEYugNSHWoxl0"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 15
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 9,
"_left": 0,
"_right": 0,
"_top": 104.37200000000001,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 0,
"_originalHeight": 0,
"_id": "5dETiB2RJCGqPqkd1R+frC"
"_id": "f2bfQ/iz9Kvbrhk3CR7krH"
},
{
"__type__": "cc.Node",
"_name": "bg_
right
",
"_name": "bg_
video_bottom
",
"_objFlags": 0,
"_parent": {
"__id__": 1
1
"__id__": 1
7
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 19
},
{
"__id__": 20
}
],
"_prefab": null,
...
...
@@ -889,8 +881,8 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width":
200
,
"height":
32
7
"width":
971
,
"height":
71
7
},
"_anchorPoint": {
"__type__": "cc.Vec2",
...
...
@@ -901,8 +893,8 @@
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
860
,
161.47000000000003
,
-3.9589999999999996
,
97.67
,
0,
0,
0,
...
...
@@ -924,7 +916,7 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "
c1+LQpeDxL/5GI+aUXp6eQ
"
"_id": "
dfu8qR4S5Aw77mPYJ1sJq6
"
},
{
"__type__": "cc.Sprite",
...
...
@@ -942,7 +934,7 @@
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "
8274ddd3-3e42-4e68-aa18-1cfc3385f7c7
"
"__uuid__": "
bbf1e3a9-27e1-420a-adf7-4bede4e54e51
"
},
"_type": 0,
"_sizeMode": 1,
...
...
@@ -956,140 +948,30 @@
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "58JRi99SVI7qz9iNwCmL0O"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 18
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 32,
"_left": 0,
"_right": 0,
"_top": 215.02999999999997,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 0,
"_originalHeight": 0,
"_id": "e8GntbbAFBs6vbHsdIoodR"
"_id": "babn0UewpJJ7bF/2HBprFh"
},
{
"__type__": "cc.
Widget
",
"_name": "",
"__type__": "cc.
Node
",
"_name": "
bgNode
",
"_objFlags": 0,
"node": {
"__id__": 11
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 45,
"_left": 0,
"_right": 0,
"_top": 0,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 0,
"_originalHeight": 0,
"_id": "d7qg9LKlZCZZzy6BXtjDnU"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 10
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "7b1b9a24-6ffe-428a-94f7-a4167e2f58c9"
},
"_type": 0,
"_sizeMode": 0,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "60b9cz3NtNuKZFQjyHyQpB"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 10
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 45,
"_left": 1.9539925233402755e-14,
"_right": -1.9539925233402755e-14,
"_top": 0,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 1280,
"_originalHeight": 720,
"_id": "1dKfUaGQFC6YdTHXw74j25"
},
{
"__type__": "cc.Node",
"_name": "video_node",
"_objFlags": 0,
"_parent": {
"__id__": 2
"_parent": {
"__id__": 13
},
"_children": [
{
"__id__": 2
5
"__id__": 2
1
},
{
"__id__": 28
"__id__": 24
},
{
"__id__": 27
}
],
"_active": true,
"_components": [
{
"__id__": 3
1
"__id__": 3
0
}
],
"_prefab": null,
...
...
@@ -1115,8 +997,8 @@
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-6.121
,
141.782
,
0
,
0
,
0,
0,
0,
...
...
@@ -1138,23 +1020,23 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "
79FcrfhAJB1ZxFy+oGarZx
"
"_id": "
a45Agfi/ZP8JMF0qy3U0wQ
"
},
{
"__type__": "cc.Node",
"_name": "bg",
"_name": "bg
_bottom
",
"_objFlags": 0,
"_parent": {
"__id__": 2
4
"__id__": 2
0
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 2
6
"__id__": 2
2
},
{
"__id__": 2
7
"__id__": 2
3
}
],
"_prefab": null,
...
...
@@ -1169,7 +1051,7 @@
"_contentSize": {
"__type__": "cc.Size",
"width": 1920,
"height":
1080
"height":
548
},
"_anchorPoint": {
"__type__": "cc.Vec2",
...
...
@@ -1180,8 +1062,8 @@
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
6.
307999999999993
,
-
178.485
,
6.
120999999999981
,
-
407.78200000000004
,
0,
0,
0,
...
...
@@ -1203,14 +1085,14 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "
b2+lhhTKtNL6XR+jCG2/Ql
"
"_id": "
efXCK6H4JD46f18GwkLeUQ
"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 2
5
"__id__": 2
1
},
"_enabled": true,
"_materials": [
...
...
@@ -1218,10 +1100,10 @@
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor":
770
,
"_srcBlendFactor":
1
,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "
7b1b9a24-6ffe-428a-94f7-a4167e2f58c9
"
"__uuid__": "
234ab084-10f0-444b-9317-05a2e79fc865
"
},
"_type": 0,
"_sizeMode": 0,
...
...
@@ -1235,23 +1117,25 @@
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "
2dVQ2ey6VK+ate9eifEqQl
"
"_id": "
3dA0yKMQFM8rMIZ1FdjCFM
"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 2
5
"__id__": 2
1
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 45,
"_left": -518.692,
"_right": -531.308,
"_top": -90.51500000000013,
"_bottom": -447.485,
"_target": {
"__id__": 2
},
"_alignFlags": 44,
"_left": 0,
"_right": 0,
"_top": 0,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
...
...
@@ -1260,24 +1144,27 @@
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 1
28
0,
"_originalHeight":
72
0,
"_id": "
97UJh8Q/NAPp9mayeavQUf
"
"_originalWidth": 1
92
0,
"_originalHeight": 0,
"_id": "
aeJPNkD8hOWa8E5gRqq8jh
"
},
{
"__type__": "cc.Node",
"_name": "
videoBg
",
"_name": "
bg_left
",
"_objFlags": 0,
"_parent": {
"__id__": 2
4
"__id__": 2
0
},
"_children": [
"_children": [],
"_active": true,
"_components": [
{
"__id__": 29
"__id__": 25
},
{
"__id__": 26
}
],
"_active": true,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
...
...
@@ -1289,8 +1176,8 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width":
0
,
"height":
0
"width":
223
,
"height":
274
},
"_anchorPoint": {
"__type__": "cc.Vec2",
...
...
@@ -1301,8 +1188,8 @@
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0
,
-114.50
9,
-842.379
,
111.2179999999999
9,
0,
0,
0,
...
...
@@ -1324,20 +1211,84 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "f2bfQ/iz9Kvbrhk3CR7krH"
"_id": "c6JjJ6+T1B+a0tWX1JMSiJ"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 24
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 1,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "6f7064ca-1a2b-40d6-9fd1-bee219ca78a8"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "9fCR3B1+BHEYugNSHWoxl0"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 24
},
"_enabled": true,
"alignMode": 1,
"_target": {
"__id__": 2
},
"_alignFlags": 9,
"_left": 0,
"_right": 0,
"_top": 150,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 0,
"_originalHeight": 0,
"_id": "5dETiB2RJCGqPqkd1R+frC"
},
{
"__type__": "cc.Node",
"_name": "bg_
video_bottom
",
"_name": "bg_
right
",
"_objFlags": 0,
"_parent": {
"__id__": 2
8
"__id__": 2
0
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 30
"__id__": 28
},
{
"__id__": 29
}
],
"_prefab": null,
...
...
@@ -1351,8 +1302,8 @@
},
"_contentSize": {
"__type__": "cc.Size",
"width":
971
,
"height":
71
7
"width":
200
,
"height":
32
7
},
"_anchorPoint": {
"__type__": "cc.Vec2",
...
...
@@ -1363,8 +1314,8 @@
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-3.9589999999999996
,
97.67
,
866.121
,
161.47000000000003
,
0,
0,
0,
...
...
@@ -1386,14 +1337,14 @@
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "
dfu8qR4S5Aw77mPYJ1sJq6
"
"_id": "
c1+LQpeDxL/5GI+aUXp6eQ
"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 2
9
"__id__": 2
7
},
"_enabled": true,
"_materials": [
...
...
@@ -1401,10 +1352,10 @@
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor":
770
,
"_srcBlendFactor":
1
,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "
bbf1e3a9-27e1-420a-adf7-4bede4e54e51
"
"__uuid__": "
8274ddd3-3e42-4e68-aa18-1cfc3385f7c7
"
},
"_type": 0,
"_sizeMode": 1,
...
...
@@ -1418,14 +1369,70 @@
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "babn0UewpJJ7bF/2HBprFh"
"_id": "58JRi99SVI7qz9iNwCmL0O"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 27
},
"_enabled": true,
"alignMode": 1,
"_target": {
"__id__": 2
},
"_alignFlags": 32,
"_left": 0,
"_right": 0,
"_top": 215.02999999999997,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 0,
"_originalHeight": 0,
"_id": "e8GntbbAFBs6vbHsdIoodR"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 20
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 45,
"_left": 1.9539925233402755e-14,
"_right": -1.9539925233402755e-14,
"_top": -2.842170943040401e-14,
"_bottom": 2.842170943040401e-14,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 0,
"_originalHeight": 0,
"_id": "d7qg9LKlZCZZzy6BXtjDnU"
},
{
"__type__": "cc.Mask",
"_name": "",
"_objFlags": 0,
"node": {
"__id__":
24
"__id__":
13
},
"_enabled": true,
"_materials": [
...
...
assets/sn03_playVideo/Scene/sn03_playVideo.ts
View file @
2d7921af
...
...
@@ -52,7 +52,7 @@ export default class VideoPlayerComponent extends cc.Component {
initSize
()
{
let
screen_size
=
cc
.
view
.
getFrameSize
().
width
/
cc
.
view
.
getFrameSize
().
height
;
let
design_size
=
cc
.
Canvas
.
instance
.
designResolution
.
width
/
cc
.
Canvas
.
instance
.
designResolution
.
height
;
console
.
log
(
"
原本尺寸
"
,
screen_size
,
"
现在尺寸
"
,
design_size
)
let
f
=
screen_size
>=
design_size
;
cc
.
Canvas
.
instance
.
fitHeight
=
f
;
cc
.
Canvas
.
instance
.
fitWidth
=
!
f
;
...
...
@@ -71,9 +71,6 @@ export default class VideoPlayerComponent extends cc.Component {
this
.
_mapScaleMin
=
Math
.
min
(
sx
,
sy
)
*
this
.
_cocosScale
;
this
.
_mapScaleMax
=
Math
.
max
(
sx
,
sy
)
*
this
.
_cocosScale
;
console
.
log
(
"
原本宽度
"
,
cc
.
director
[
"
_scene
"
].
width
,
"
现在宽度
"
,
frameSize
.
width
)
console
.
log
(
"
原本高度
"
,
cc
.
director
[
"
_scene
"
].
height
,
"
现在高度
"
,
frameSize
.
height
)
cc
.
director
[
"
_scene
"
].
width
=
frameSize
.
width
;
cc
.
director
[
"
_scene
"
].
height
=
frameSize
.
height
;
}
...
...
@@ -137,8 +134,8 @@ export default class VideoPlayerComponent extends cc.Component {
cc
.
debug
.
setDisplayStats
(
false
);
this
.
initSize
();
cc
.
find
(
'
Canvas/bg
'
).
scale
=
this
.
_mapScaleMax
;
cc
.
find
(
'
Canvas/video_node/bg
'
).
scale
=
this
.
_mapScaleMax
;
//
cc.find('Canvas/bg').scale = this._mapScaleMax;
//
cc.find('Canvas/video_node/bg').scale = this._mapScaleMax;
// cc.find('Canvas/bgwhite').zIndex=-2
// cc.find('Canvas/bg').zIndex=-1
...
...
@@ -208,20 +205,19 @@ export default class VideoPlayerComponent extends cc.Component {
}
});
this
.
videoPlayer
.
node
.
on
(
'
playing
'
,
()
=>
{
console
.
log
(
'
playing
'
);
this
.
durationLabel
.
string
=
this
.
formatTime
(
this
.
videoPlayer
.
getDuration
());
this
.
playButton
.
node
.
active
=
false
;
this
.
restartButton
.
node
.
active
=
false
;
this
.
pauseButton
.
node
.
active
=
true
;
});
this
.
videoPlayer
.
node
.
on
(
'
paused
'
,
()
=>
{
console
.
log
(
'
paused
'
);
});
this
.
videoPlayer
.
node
.
on
(
'
stopped
'
,
()
=>
{
console
.
log
(
'
stopped
'
);
});
this
.
videoPlayer
.
node
.
on
(
'
completed
'
,
async
()
=>
{
console
.
log
(
'
completed
'
);
this
.
_isPlayComplated
=
true
;
this
.
playButton
.
node
.
active
=
false
;
this
.
pauseButton
.
node
.
active
=
false
;
...
...
@@ -235,7 +231,6 @@ export default class VideoPlayerComponent extends cc.Component {
}
});
cc
.
view
.
setResizeCallback
(()
=>
{
console
.
log
(
'
Resize
'
);
this
.
initdDrag
();
});
...
...
@@ -250,6 +245,7 @@ export default class VideoPlayerComponent extends cc.Component {
if
(
this
.
videoItemList
)
cc
.
find
(
"
Canvas/btn_next
"
).
active
=
this
.
videoPlayIndex
!=
this
.
videoItemList
.
length
-
1
}
onClickNext
(){
const
nextItem
=
this
.
videoItemList
[
this
.
videoPlayIndex
+
1
];
if
(
nextItem
)
{
...
...
@@ -259,6 +255,7 @@ export default class VideoPlayerComponent extends cc.Component {
}
this
.
refreshLastNextBtns
()
}
onClickLast
(){
const
nextItem
=
this
.
videoItemList
[
this
.
videoPlayIndex
-
1
];
if
(
nextItem
)
{
...
...
@@ -272,7 +269,6 @@ export default class VideoPlayerComponent extends cc.Component {
initListener
()
{
if
(
window
[
'
air
'
])
{
window
[
"
air
"
].
dialogStatus
=
(
statusCode
:
number
)
=>
{
console
.
log
(
"
缓冲
"
,
statusCode
);
if
(
statusCode
==
701
)
{
this
.
loadingSprite
.
active
=
true
;
}
else
if
(
statusCode
==
702
)
{
...
...
@@ -291,7 +287,6 @@ export default class VideoPlayerComponent extends cc.Component {
if
(
!
this
.
_isReadyToPlay
)
{
return
;
}
console
.
log
(
"
TOUCH_START
"
);
});
this
.
barTag
.
off
(
cc
.
Node
.
EventType
.
TOUCH_MOVE
);
this
.
barTag
.
on
(
cc
.
Node
.
EventType
.
TOUCH_MOVE
,
(
e
)
=>
{
...
...
@@ -313,7 +308,6 @@ export default class VideoPlayerComponent extends cc.Component {
if
(
!
this
.
_isReadyToPlay
)
{
return
;
}
console
.
log
(
"
TOUCH_ENDED
"
);
this
.
updateBarByPos
(
this
.
barTag
.
x
);
});
this
.
barTag
.
off
(
cc
.
Node
.
EventType
.
MOUSE_UP
);
...
...
@@ -321,7 +315,6 @@ export default class VideoPlayerComponent extends cc.Component {
if
(
!
this
.
_isReadyToPlay
)
{
return
;
}
console
.
log
(
"
MOUSE_UP
"
);
this
.
updateBarByPos
(
this
.
barTag
.
x
);
});
}
...
...
@@ -441,9 +434,8 @@ export default class VideoPlayerComponent extends cc.Component {
}
cc
.
find
(
`Canvas/videolist`
).
active
=
this
.
data
.
dataArr
.
length
>
1
;
if
(
this
.
data
.
dataArr
.
length
<=
1
){
console
.
log
(
"
qsj???
"
)
cc
.
find
(
`Canvas/bg/videoBg`
).
scale
=
1.2
cc
.
find
(
`Canvas/bg/videoBg`
).
y
=-
136.058
cc
.
find
(
`Canvas/video_node/videoBg`
).
scale
=
1.2
cc
.
find
(
`Canvas/video_node/videoBg`
).
y
=-
136.058
// cc.find(`Canvas/video_node`).scale=1.2
cc
.
find
(
`Canvas/video_node`
).
width
*=
1.2
cc
.
find
(
`Canvas/video_node`
).
height
*=
1.2
...
...
@@ -531,18 +523,15 @@ export default class VideoPlayerComponent extends cc.Component {
}
play
()
{
console
.
log
(
"
PL
"
)
if
(
!
this
.
_isReadyToPlay
)
{
return
;
}
const
{
width
,
height
}
=
cc
.
find
(
`Canvas/bg`
);
cc
.
find
(
`Canvas/text_tips`
).
active
=
false
;
//
cc.find(`Canvas/bg`).active = false;
cc
.
find
(
`Canvas/bg`
).
active
=
false
;
cc
.
find
(
`Canvas/bgwhite`
).
active
=
false
;
const
videoContainer
=
cc
.
find
(
'
Canvas/video_node
'
);
cc
.
find
(
'
bg
'
,
videoContainer
).
width
=
width
;
cc
.
find
(
'
bg
'
,
videoContainer
).
height
=
height
;
this
.
videoPlayer
.
node
.
x
=
videoContainer
.
x
;
this
.
videoPlayer
.
node
.
y
=
videoContainer
.
y
;
this
.
videoPlayer
.
play
();
...
...
@@ -682,8 +671,6 @@ export default class VideoPlayerComponent extends cc.Component {
}
update
(
dt
:
number
)
{
console
.
log
(
"
==VIDEO==
"
,
this
.
node
.
active
);
if
(
!
this
.
_isReadyToPlay
)
{
return
;
}
...
...
assets/sn03_playVideo/prefab/JJ_Video_01/Texture/newVideo/bg_bottom.png.meta
View file @
2d7921af
...
...
@@ -4,7 +4,7 @@
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha":
fals
e,
"premultiplyAlpha":
tru
e,
"genMipmaps": false,
"packable": true,
"width": 1920,
...
...
assets/sn03_playVideo/prefab/JJ_Video_01/Texture/newVideo/bg_left.png.meta
View file @
2d7921af
...
...
@@ -4,7 +4,7 @@
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha":
fals
e,
"premultiplyAlpha":
tru
e,
"genMipmaps": false,
"packable": true,
"width": 223,
...
...
assets/sn03_playVideo/prefab/JJ_Video_01/Texture/newVideo/bg_right.png.meta
View file @
2d7921af
...
...
@@ -4,7 +4,7 @@
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha":
fals
e,
"premultiplyAlpha":
tru
e,
"genMipmaps": false,
"packable": true,
"width": 200,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment