Bug 1065746
| Summary: | REQUEST: Please allow passing of -ss and -to (-t) to ffmpeg | ||
|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Ali Akcaagac <aliakc> |
| Component: | youtube-dl | Assignee: | Till Maas <opensource> |
| Status: | CLOSED WORKSFORME | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
| Severity: | unspecified | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 20 | CC: | aliakc, i, metherid, opensource |
| Target Milestone: | --- | Keywords: | Reopened |
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2015-02-10 11:20:53 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
Ali Akcaagac
2014-02-16 16:28:58 UTC
Closing because of no feedback from package owner. This still needs to be forwarded to upstream. Reported upstream: https://github.com/rg3/youtube-dl/issues/4803 Upstream comment:
jaimeMF commented 28 minutes ago
For a few versions, youtube-dl has the --exec option which allows you to execute arbitrary commands after each file has been downloaded. This can be used for you usercase:
Create the file cut.sh and make it executable:
#!/bin/sh
start=$1
duration=$2
file="$3"
tempfile="$file.tmp"
mv "$file" "$tempfile"
ffmpeg -y -i "$tempfile" -ss "$start" -t "$duration" -c copy "$file"
rm "$tempfile"
Then run, for example, youtube-dl test:youtube_1 --exec "./cut.sh 20 40 {}". You can even use options like --extract-audio. You may want to give it a proper name to the script and put it in your $PATH, so that you can call it from everywhere.
I thinks that's enough and youtube-dl shouldn't have special support for it, for a few reasons:
You can adapt it to any options you need.
You can use any program you want, you are not limited to ffmpeg/avconv.
We could of course ad an option --ffmpeg-options which would add the arguments in the ffmpeg command (before the output filename). But this can't be done in the existing postprocessors (for example if you combine the --add-metadata and --embed-subtitles options, ffmpeg would be run twice with -ss 20 -t 40 which is not the expected behaviour). So it would need its own postprocessor, which would be equivalent to the script I posted.
This is just my opinion, so if you (or someone else) thinks that we should really add support for passing these options, I don't mind reopening the issue.
----------------------------
Please reply, whether you would like me to reopen the issue.
This package has changed ownership in the Fedora Package Database. Reassigning to the new owner of this component. Yes closing it that's fine. The RFE was old anyways. |