Toggle navigation
Toggle navigation
This project
Loading...
Sign in
OnePoem
/
OnePoem-Server
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
李帅
2023-02-24 17:55:57 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
f0ad69cba272f2a7a9e7996866c89002f8691469
f0ad69cb
1 parent
9f8fb482
1.优化ffmpeg命令,适配各种类型视频
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletions
app/Jobs/AdminMakeImmerse.php
app/Jobs/AdminMakeImmerse.php
View file @
f0ad69c
...
...
@@ -403,13 +403,14 @@ class AdminMakeImmerse implements ShouldQueue
if
(
$this
->
media_info
[
'format'
][
'duration'
]
>
3
*
count
(
$contents
))
$FID
=
$FOD
=
1.5
;
$round
=
round
(
$this
->
media_info
[
'format'
][
'duration'
]
/
count
(
$contents
),
1
);
$sub_text
=
''
;
foreach
(
$contents
as
$key
=>
$content
){
$text_color
=
substr
(
$text_color
,
1
,
strlen
(
$text_color
));
$DS
=
$key
*
$round
;
$DE
=
$DS
+
$round
;
$text_file
=
$this
->
getAbsolutePath
(
$this
->
getTempPath
(
'.txt'
,
'text'
));
file_put_contents
(
$text_file
,
$content
);
$
draw
text
.=
'drawtext="'
.
$
sub_
text
.=
'drawtext="'
.
'fontfile='
.
escapeshellarg
(
$font_file
)
.
':'
.
'textfile='
.
escapeshellarg
(
$text_file
)
.
':'
.
'fontsize='
.
$this
->
calcFontSize
(
$component
->
font_size
)
.
':'
.
...
...
@@ -421,6 +422,8 @@ class AdminMakeImmerse implements ShouldQueue
'box=1:boxborderw='
.
$text_bg_box
.
':'
.
'boxcolor='
.
$text_bg_color
.
'@'
.
$opacity
.
'", '
;
}
$drawtext
.=
$sub_text
;
}
break
;
case
'weather'
:
...
...
Please
register
or
login
to post a comment