Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Websites UFRPE
Wagtail Videos
Commits
f8b56365
Unverified
Commit
f8b56365
authored
Apr 01, 2021
by
seb-b
Committed by
GitHub
Apr 01, 2021
Browse files
Merge pull request #78 from neon-jungle/aac-transcode
Transcode audio instead of copy
parents
81776618
15252526
Changes
1
Hide whitespace changes
Inline
Side-by-side
wagtailvideos/models.py
View file @
f8b56365
...
@@ -42,7 +42,7 @@ class VideoQuality(ChoiceEnum):
...
@@ -42,7 +42,7 @@ class VideoQuality(ChoiceEnum):
class
MediaFormats
(
ChoiceEnum
):
class
MediaFormats
(
ChoiceEnum
):
webm
=
'VP8 and Vorbis in WebM'
webm
=
'VP8 and Vorbis in WebM'
mp4
=
'H.264 and
MP3
in Mp4'
mp4
=
'H.264 and
AAC
in Mp4'
ogg
=
'Theora and Vorbis in Ogg'
ogg
=
'Theora and Vorbis in Ogg'
def
get_quality_param
(
self
,
quality
):
def
get_quality_param
(
self
,
quality
):
...
@@ -279,7 +279,7 @@ class TranscodingThread(threading.Thread):
...
@@ -279,7 +279,7 @@ class TranscodingThread(threading.Thread):
'-codec:v'
,
'libx264'
,
'-codec:v'
,
'libx264'
,
'-preset'
,
'slow'
,
# TODO Checkout other presets
'-preset'
,
'slow'
,
# TODO Checkout other presets
'-crf'
,
quality_param
,
'-crf'
,
quality_param
,
'-codec:a'
,
'
copy
'
,
'-codec:a'
,
'
aac
'
,
output_file
,
output_file
,
],
stdin
=
FNULL
,
stderr
=
subprocess
.
STDOUT
)
],
stdin
=
FNULL
,
stderr
=
subprocess
.
STDOUT
)
elif
media_format
is
MediaFormats
.
webm
:
elif
media_format
is
MediaFormats
.
webm
:
...
...
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