ffmpeg bash script doesn't not work with subtitles when it comes to a filename with spaces
Here is my current script
#!/bin/bash
while true
do
for f in *.mkv;
do
/home5/user/ffmpeg_folder/./ffmpeg-git-20181101-64bit-static/ffmpeg
-i "$f" -c:v h264 -maxrate 12M -crf 16 -c:a copy -vf subtitles="$f" -pix_fmt yuv420p
"${f%.mkv}".mp4;
done
sleep 15m
done
and I just keep getting this error:
NUMBER_OF_BYTES-eng: 30679
_STATISTICS_WRITING_APP: no_variable_data
_STATISTICS_WRITING_APP-eng: no_variable_data
_STATISTICS_WRITING_DATE_UTC: 1970-01-01 00:00:00
_STATISTICS_WRITING_DATE_UTC-eng: 1970-01-01 00:00:00
_STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
Stream #0:3: Attachment: ttf
Metadata:
filename : OpenSans-Semibold.ttf
mimetype : application/x-truetype-font
File '[HorribleSubs] Seishun Buta Yarou wa Bunny Girl Senpai no Yume wo Minai - 07 [1080p].mp4' already exists. Overwrite ? [y/N] y
Stream mapping:
Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
[Parsed_subtitles_0 @ 0x5dfe3c0] No filename provided!
[AVFilterGraph @ 0x6da2c00] Error initializing filter 'subtitles' with args ''
Error reinitializing filters!
Failed to inject frame into filter network: Invalid argument
Error while processing the decoded data for stream #0:0
Conversion failed!
Everything would work if the -vf subtitles="$f"
wasn't in there. Is there any way to fix this?
linux ffmpeg
add a comment |
Here is my current script
#!/bin/bash
while true
do
for f in *.mkv;
do
/home5/user/ffmpeg_folder/./ffmpeg-git-20181101-64bit-static/ffmpeg
-i "$f" -c:v h264 -maxrate 12M -crf 16 -c:a copy -vf subtitles="$f" -pix_fmt yuv420p
"${f%.mkv}".mp4;
done
sleep 15m
done
and I just keep getting this error:
NUMBER_OF_BYTES-eng: 30679
_STATISTICS_WRITING_APP: no_variable_data
_STATISTICS_WRITING_APP-eng: no_variable_data
_STATISTICS_WRITING_DATE_UTC: 1970-01-01 00:00:00
_STATISTICS_WRITING_DATE_UTC-eng: 1970-01-01 00:00:00
_STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
Stream #0:3: Attachment: ttf
Metadata:
filename : OpenSans-Semibold.ttf
mimetype : application/x-truetype-font
File '[HorribleSubs] Seishun Buta Yarou wa Bunny Girl Senpai no Yume wo Minai - 07 [1080p].mp4' already exists. Overwrite ? [y/N] y
Stream mapping:
Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
[Parsed_subtitles_0 @ 0x5dfe3c0] No filename provided!
[AVFilterGraph @ 0x6da2c00] Error initializing filter 'subtitles' with args ''
Error reinitializing filters!
Failed to inject frame into filter network: Invalid argument
Error while processing the decoded data for stream #0:0
Conversion failed!
Everything would work if the -vf subtitles="$f"
wasn't in there. Is there any way to fix this?
linux ffmpeg
add a comment |
Here is my current script
#!/bin/bash
while true
do
for f in *.mkv;
do
/home5/user/ffmpeg_folder/./ffmpeg-git-20181101-64bit-static/ffmpeg
-i "$f" -c:v h264 -maxrate 12M -crf 16 -c:a copy -vf subtitles="$f" -pix_fmt yuv420p
"${f%.mkv}".mp4;
done
sleep 15m
done
and I just keep getting this error:
NUMBER_OF_BYTES-eng: 30679
_STATISTICS_WRITING_APP: no_variable_data
_STATISTICS_WRITING_APP-eng: no_variable_data
_STATISTICS_WRITING_DATE_UTC: 1970-01-01 00:00:00
_STATISTICS_WRITING_DATE_UTC-eng: 1970-01-01 00:00:00
_STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
Stream #0:3: Attachment: ttf
Metadata:
filename : OpenSans-Semibold.ttf
mimetype : application/x-truetype-font
File '[HorribleSubs] Seishun Buta Yarou wa Bunny Girl Senpai no Yume wo Minai - 07 [1080p].mp4' already exists. Overwrite ? [y/N] y
Stream mapping:
Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
[Parsed_subtitles_0 @ 0x5dfe3c0] No filename provided!
[AVFilterGraph @ 0x6da2c00] Error initializing filter 'subtitles' with args ''
Error reinitializing filters!
Failed to inject frame into filter network: Invalid argument
Error while processing the decoded data for stream #0:0
Conversion failed!
Everything would work if the -vf subtitles="$f"
wasn't in there. Is there any way to fix this?
linux ffmpeg
Here is my current script
#!/bin/bash
while true
do
for f in *.mkv;
do
/home5/user/ffmpeg_folder/./ffmpeg-git-20181101-64bit-static/ffmpeg
-i "$f" -c:v h264 -maxrate 12M -crf 16 -c:a copy -vf subtitles="$f" -pix_fmt yuv420p
"${f%.mkv}".mp4;
done
sleep 15m
done
and I just keep getting this error:
NUMBER_OF_BYTES-eng: 30679
_STATISTICS_WRITING_APP: no_variable_data
_STATISTICS_WRITING_APP-eng: no_variable_data
_STATISTICS_WRITING_DATE_UTC: 1970-01-01 00:00:00
_STATISTICS_WRITING_DATE_UTC-eng: 1970-01-01 00:00:00
_STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
Stream #0:3: Attachment: ttf
Metadata:
filename : OpenSans-Semibold.ttf
mimetype : application/x-truetype-font
File '[HorribleSubs] Seishun Buta Yarou wa Bunny Girl Senpai no Yume wo Minai - 07 [1080p].mp4' already exists. Overwrite ? [y/N] y
Stream mapping:
Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
[Parsed_subtitles_0 @ 0x5dfe3c0] No filename provided!
[AVFilterGraph @ 0x6da2c00] Error initializing filter 'subtitles' with args ''
Error reinitializing filters!
Failed to inject frame into filter network: Invalid argument
Error while processing the decoded data for stream #0:0
Conversion failed!
Everything would work if the -vf subtitles="$f"
wasn't in there. Is there any way to fix this?
linux ffmpeg
linux ffmpeg
edited Nov 20 '18 at 15:42


filbranden
7,3702836
7,3702836
asked Nov 20 '18 at 10:32
Naz NazD DerbignyNaz NazD Derbigny
11
11
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
did you not add the subtitle extension?
New contributor
Tim Evans is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "106"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f482931%2fffmpeg-bash-script-doesnt-not-work-with-subtitles-when-it-comes-to-a-filename-w%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
did you not add the subtitle extension?
New contributor
Tim Evans is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |
did you not add the subtitle extension?
New contributor
Tim Evans is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |
did you not add the subtitle extension?
New contributor
Tim Evans is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
did you not add the subtitle extension?
New contributor
Tim Evans is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Tim Evans is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
answered 1 min ago
Tim EvansTim Evans
1
1
New contributor
Tim Evans is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Tim Evans is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Tim Evans is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |
add a comment |
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f482931%2fffmpeg-bash-script-doesnt-not-work-with-subtitles-when-it-comes-to-a-filename-w%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown