Re-packing video in new container file really working for all container types (AVI, MP4 MKV, WMV) and codecs?

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Re-packing video in new container file really working for all container types (AVI, MP4 MKV, WMV) and codecs?

Ben Stover
As I read I can lossless re-package an existing video from a source container file into a different target container file by issuing e.g. the following command:

FFmpeg.exe -i sample.mp4 -acodec copy -vcodec copy sample.avi

or

FFmpeg.exe -i sample.avi -acodec copy -vcodec copy sample.mkv

So the target container type is simply identified by the target file extension.
No additional parameter is required.
Correct?

"Lossless" means without re-encoding the video and audio content.
Meta data values are obviously lost when "downgrading" e.g. from MP4 to AVI.

Can someone please confirm that the target file (AVI, MP4, MKV, WMV) will be full compliant with container definition and not just a dirty workaround from ffmpeg.

Is this lossless re-packing possible for all types of video codecs (e.g. H.264, H.265, VP9 and Xvid) and audio codecs (MP3, AAC) or are there any restrictions
which require a re-encoding anyway?

Thank you
Ben
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".
Reply | Threaded
Open this post in threaded view
|

Re: Re-packing video in new container file really working for all container types (AVI, MP4 MKV, WMV) and codecs?

Carl Eugen Hoyos-2
2018-11-05 11:59 GMT+01:00, Ben <[hidden email]>:
> Can someone please confirm that the target file (AVI, MP4, MKV,
> WMV) will be full compliant with container definition and not just
> a dirty workaround from ffmpeg.

Please read the final clauses of the (L)GPL again, nobody can
confirm what you request.

Carl Eugen
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".
Reply | Threaded
Open this post in threaded view
|

Re: Re-packing video in new container file really working for all container types (AVI, MP4 MKV, WMV) and codecs?

Carl Eugen Hoyos-2
In reply to this post by Ben Stover
2018-11-05 11:59 GMT+01:00, Ben <[hidden email]>:

Splitting the answers to make sure that can be no misunderstanding
about the first one;-)

> Is this lossless re-packing possible for all types of video codecs

We call it "remuxing" and it makes sense to use this word here.

> (e.g. H.264, H.265, VP9 and Xvid) and audio codecs (MP3, AAC)
> or are there any restrictions which require a re-encoding anyway?

Not all containers allow all codecs and not all codecs in all
containers (that would be allowed) are necessarily implemented
in FFmpeg.

Carl Eugen
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".
Reply | Threaded
Open this post in threaded view
|

Re: Re-packing video in new container file really working for all container types (AVI, MP4 MKV, WMV) and codecs?

Kieran O Leary
In reply to this post by Ben Stover
Hi,

On Mon, Nov 5, 2018 at 10:59 AM Ben <[hidden email]> wrote:

>
> As I read I can lossless re-package an existing video from a source container file into a different target container file by issuing e.g. the following command:
>
> FFmpeg.exe -i sample.mp4 -acodec copy -vcodec copy sample.avi
>
> or
>
> FFmpeg.exe -i sample.avi -acodec copy -vcodec copy sample.mkv
>
> So the target container type is simply identified by the target file extension.
> No additional parameter is required.
> Correct?

Pretty much, but you might want to add `-map 0` so that all tracks in
your source file make their way into your output file. By default,
ffmpeg will only map one track of each type (audio/video etc).
https://trac.ffmpeg.org/wiki/Map

>
> "Lossless" means without re-encoding the video and audio content.
> Meta data values are obviously lost when "downgrading" e.g. from MP4 to AVI.
>
This loss of metadata is definitely something to watch out for.

Best,

Kieran.
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".