Re: [FFmpeg-user] Is there a way to re-encode an inefficiently encoded file without losing quality and reducing file size?
Every time you transcode, you lose more quality, same as making a VHS to VHS tape copy. If space is an issue, buy a Series 40 nVidia card that supports AV1 encoding. Transcode your blu-ray source directly to AV1 for the smallest file at the highest quality. True lossless file sizes are FAR larger than those found on a blu-ray, which are H264 encoded. On Saturday, September 30, 2023 at 04:51:30 PM PDT, MediaMouth wrote: What about using a hash to check your existing against your possibly new / possibly matching file. If it's a match don't run ffmpeg on it. Assuming i'm understanding what you're trying to achieve, it would seem better practice not to touch the file with ffmpeg when you can avoid it. > On Sep 30, 2023, at 16:43, Stéphane Archer wrote: > > Let's say you have a video file encoded with high bitrate with the > ultra-fast preset in H.264 because you couldn't afford CPU at that time. > Now you have a huge file mostly because it was encoded quickly. > > You are now two days later with access to a good CPU and GPU. > > If you re-encode that file to save space then you are going to lose quality > because even AV1 with a high bitrate is lossy (and you want to reduce that > high bitrate) > > Otherwise, you can try transcoding using lossless compression but during my > testing, this is making the file way bigger no matter what I tried. > > So basically, I can lose quality, or keep the big original file... > Do you know a better way? Is there a way to re-encode that inefficiently > encoded file without losing quality and reducing file size? > > Best regards > > Stéphane Archer > ___ > ffmpeg-user mailing list > ffmpeg-user@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > To unsubscribe, visit link above, or email > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] How do you keep all video metadata when transcoding using ffmpeg?
Consider - Always retaining camera originals - Extracting the metadata using ffmpeg and maybe exiftool and capturing that either in matching-named sidecar files and/or in a media asset manager. > On Sep 29, 2023, at 04:46, Stéphane Archer wrote: > > This includes: > > - > > EXIF > - > > IPTC > - > > XMP > - > > other metadata type I may not be aware of that my camera writes when > creating the file > > > -- > Best Regards, > > Stephane Archer > ___ > ffmpeg-user mailing list > ffmpeg-user@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > To unsubscribe, visit link above, or email > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there a way to re-encode an inefficiently encoded file without losing quality and reducing file size?
> On Sep 30, 2023, at 17:47, Stéphane Archer wrote: > > I'm not sure I understand what you mean, do you mean a hash like md5 and > sha1? > Could you please elaborate and simplify a bit? I checked-- I was referencing this from your OP > Is there any good reason why FFmpeg which sees that the video file input > and output match every single characteristic doesn't copy the stream to > avoid useless reencoding? > Basically doing "-vcodec copy" automatically. Based on that I was assuming you had existing files and arriving files new files that might or might not match your existing files (Your actual situation may be different. Might be helpful if you can provide more context about what you're trying to achieve.) But to answer your question re hash: yes an md5 or sha. I cobbled up a quick algorithm but instead of solving the problem it reveals a logic flaw Take the following ExistingFile = some file you might want to update NewFile = The file that might update it. ExistingFileHash = shasum -a 512 /path/to/ExistingFile NewFileHash = shasum -a 512 /path/to/NewFile if(NewFileHash <> ExistingFile){ delete ExistingFile (or archive it, depending on your workflow) ffmpeg -i ExistingFile -whateversettings NewFile **Here's the logic flaw** } else { Don't do anything to the ExistingFile } * An Existing File that was transcoded ffmpeg would never match hashes with a new file. or if it did match, it would seem there's no reason to transcode it. So it sounds like there's more to the story of what you're trying to achieve. Are you maybe instead trying to see if the metadata of a NewFile matches stored metadata of an Existing file, and if not, then do a transcode? ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there a way to re-encode an inefficiently encoded file without losing quality and reducing file size?
вс, 1 окт. 2023 г., 02:43 Stéphane Archer : > Let's say you have a video file encoded with high bitrate with the > ultra-fast preset in H.264 because you couldn't afford CPU at that time. > Now you have a huge file mostly because it was encoded quickly. > > You are now two days later with access to a good CPU and GPU. > > If you re-encode that file to save space then you are going to lose quality > because even AV1 with a high bitrate is lossy (and you want to reduce that > high bitrate) > > Otherwise, you can try transcoding using lossless compression but during my > testing, this is making the file way bigger no matter what I tried. > > So basically, I can lose quality, or keep the big original file... > Do you know a better way? Is there a way to re-encode that inefficiently > encoded file without losing quality and reducing file size? > may be try two-pass encoding? > > Best regards > > Stéphane Archer > ___ > ffmpeg-user mailing list > ffmpeg-user@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > To unsubscribe, visit link above, or email > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". > ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there a way to re-encode an inefficiently encoded file without losing quality and reducing file size?
I'm not sure I understand what you mean, do you mean a hash like md5 and sha1? Could you please elaborate and simplify a bit? On Sat, Sep 30, 2023 at 7:51 PM MediaMouth wrote: > What about using a hash to check your existing against your possibly new / > possibly matching file. If it's a match don't run ffmpeg on it. Assuming > i'm understanding what you're trying to achieve, it would seem better > practice not to touch the file with ffmpeg when you can avoid it. > > > On Sep 30, 2023, at 16:43, Stéphane Archer > wrote: > > > > Let's say you have a video file encoded with high bitrate with the > > ultra-fast preset in H.264 because you couldn't afford CPU at that time. > > Now you have a huge file mostly because it was encoded quickly. > > > > You are now two days later with access to a good CPU and GPU. > > > > If you re-encode that file to save space then you are going to lose > quality > > because even AV1 with a high bitrate is lossy (and you want to reduce > that > > high bitrate) > > > > Otherwise, you can try transcoding using lossless compression but during > my > > testing, this is making the file way bigger no matter what I tried. > > > > So basically, I can lose quality, or keep the big original file... > > Do you know a better way? Is there a way to re-encode that inefficiently > > encoded file without losing quality and reducing file size? > > > > Best regards > > > > Stéphane Archer > > ___ > > ffmpeg-user mailing list > > ffmpeg-user@ffmpeg.org > > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > > > To unsubscribe, visit link above, or email > > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". > ___ > ffmpeg-user mailing list > ffmpeg-user@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > To unsubscribe, visit link above, or email > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". > -- Best Regards, Stephane Archer ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-user] [freezedetect filter] discard frozen frames option ever added?
I'm trying to remove frozen frames from a video with gaps in the input stream, and the freezedetect filter appears to accurately find/list those sections. I was hoping to use the results of freezedetect to trim those sections of video, and there was a freezedetect "discard" ("f") option in the dev builds a few years back which appears to do exactly that ( https://patchwork.ffmpeg.org/project/ffmpeg/patch/20191008035428.19474-1-lance.lmw...@gmail.com/#46233 ) It doesn't seem to have made its way into any of the builds (including dev branches) as far as I can find, and it's definitely not in the official docs. To my untrained eye, the patch looks complete, though possibly abandoned. is there any chance of it being incorporated into the mainline source? It would be quite useful. -- ub ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there a way to re-encode an inefficiently encoded file without losing quality and reducing file size?
What about using a hash to check your existing against your possibly new / possibly matching file. If it's a match don't run ffmpeg on it. Assuming i'm understanding what you're trying to achieve, it would seem better practice not to touch the file with ffmpeg when you can avoid it. > On Sep 30, 2023, at 16:43, Stéphane Archer wrote: > > Let's say you have a video file encoded with high bitrate with the > ultra-fast preset in H.264 because you couldn't afford CPU at that time. > Now you have a huge file mostly because it was encoded quickly. > > You are now two days later with access to a good CPU and GPU. > > If you re-encode that file to save space then you are going to lose quality > because even AV1 with a high bitrate is lossy (and you want to reduce that > high bitrate) > > Otherwise, you can try transcoding using lossless compression but during my > testing, this is making the file way bigger no matter what I tried. > > So basically, I can lose quality, or keep the big original file... > Do you know a better way? Is there a way to re-encode that inefficiently > encoded file without losing quality and reducing file size? > > Best regards > > Stéphane Archer > ___ > ffmpeg-user mailing list > ffmpeg-user@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > To unsubscribe, visit link above, or email > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-user] Is there a way to re-encode an inefficiently encoded file without losing quality and reducing file size?
Let's say you have a video file encoded with high bitrate with the ultra-fast preset in H.264 because you couldn't afford CPU at that time. Now you have a huge file mostly because it was encoded quickly. You are now two days later with access to a good CPU and GPU. If you re-encode that file to save space then you are going to lose quality because even AV1 with a high bitrate is lossy (and you want to reduce that high bitrate) Otherwise, you can try transcoding using lossless compression but during my testing, this is making the file way bigger no matter what I tried. So basically, I can lose quality, or keep the big original file... Do you know a better way? Is there a way to re-encode that inefficiently encoded file without losing quality and reducing file size? Best regards Stéphane Archer ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there any good reason why FFmpeg doesn't do "-vcodec copy" automatically.
Dear Reindl Harald, Seeing the sarcastic tone of your emails and finishing your emails with "case closed" when someone is asking a question and is opening a discussion doesn't make you appear smart, on the contrary actually. Yes, you can always specify "-vcodec copy" when you need to, that is not what the discussion is about. It's about whether we can make it automatic so we don't have to specify it. "case closed" lol Stéphane Archer On Sat, Sep 30, 2023 at 4:39 PM Reindl Harald wrote: > > > Am 30.09.23 um 21:29 schrieb Carl Zwanzig: > > On 9/30/2023 12:07 PM, Reindl Harald wrote: > >> is there a good reason to throw a video file through ffmpeg when you > >> don't want to touch it? > > > > Changing the container or working only with the audio or subtitle tracks. > > > > So yes, there is a good reason > > whatever the default is you will always have workloads where it don't > match - hence you have options to specify your needs > > if you have a godd reason for "-vcodec copy" the specify it, case closed > > ___ > ffmpeg-user mailing list > ffmpeg-user@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > To unsubscribe, visit link above, or email > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". > -- Best Regards, Stephane Archer ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] How to merge and map 1 video file with 4 audio files?
сб, 30 сент. 2023 г., 20:58 MediaMouth : > > > > On Sep 30, 2023, at 09:31, Andrew Randrianasulu > wrote: > > > > may be remove all OUTPUT_CHx lines so output will be clearly into one mxf > > file? > > Thanks Andrew, will try! > > What made you think removing the "remove all OUTPUT_CHx " was the right > move? > I thought so only from my limited expirience with ffmpeg cli, it looked like ffmpeg was trying to output to those OUTPUT_CHx as files and failed because it was not obvious (usually from extension) what kind of container it must be. I think there is option for channel rerouting in containers from man ffmpeg -layouts Show channel names and standard channel layouts. > What I'm hoping for, big picture, is to understand in detail routing > source to dest. The documentation seems clear enough, but the errors I got > suggest I didn't quite figure it out yet. > > Thx > > > ___ > ffmpeg-user mailing list > ffmpeg-user@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > To unsubscribe, visit link above, or email > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". > ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there any good reason why FFmpeg doesn't do "-vcodec copy" automatically.
Am 30.09.23 um 21:29 schrieb Carl Zwanzig: On 9/30/2023 12:07 PM, Reindl Harald wrote: is there a good reason to throw a video file through ffmpeg when you don't want to touch it? Changing the container or working only with the audio or subtitle tracks. So yes, there is a good reason whatever the default is you will always have workloads where it don't match - hence you have options to specify your needs if you have a godd reason for "-vcodec copy" the specify it, case closed ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there any good reason why FFmpeg doesn't do "-vcodec copy" automatically.
> is there a good reason to throw a video file through ffmpeg when you> don't >want to touch it? I guess you might want to touch the audio but not the video, maybe? In general, I suspect the reason it's not easy to implement the requested feature is that it isn't often trivial, or even possible, to know even quite roughly what settings were used to encode a video. As far as I know it'd be perfectly valid to have a video in certain codecs that might contain an enormous string of millions of I-frames, followed after hours, days or weeks with a single B-frame, and there wouldn't be any way to anticipate that other than just examining the whole file. You can't, as far as I know, know what the requested bitrate was when encoding the file. You can only know what the bitrate is. Different encoders use different techniques in different ways; there is no standard H.264 encoder, only a reference decoder, so there's not even a standard collection of settings to use as a basis. As far as I know it's not actually possible to do what the OP seems to want to do, regardless. P ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there any good reason why FFmpeg doesn't do "-vcodec copy" automatically.
> On Sep 30, 2023, at 12:07 PM, Reindl Harald wrote: > > > Am 30.09.23 um 20:46 schrieb Stéphane Archer: >> Is there any good reason why FFmpeg which sees that the video file input >> and output match every single characteristic doesn't copy the stream to >> avoid useless reencoding? >> Basically doing "-vcodec copy" automatically. > > is there a good reason to throw a video file through ffmpeg when you don't > want to touch it? > > yeah, there may be a few reasons, and for the really *few* reasons you are > supposed to state that Perhaps the user has an automated workflow that accepts X, Y, Z, and W, but always outputs W. If any particular incoming file happens to be W, it would be more efficient to not re-encode that particular file. ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there any good reason why FFmpeg doesn't do "-vcodec copy" automatically.
On 9/30/2023 12:07 PM, Reindl Harald wrote: is there a good reason to throw a video file through ffmpeg when you don't want to touch it? Changing the container or working only with the audio or subtitle tracks. So yes, there is a good reason. z! ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there any good reason why FFmpeg doesn't do "-vcodec copy" automatically.
Am 30.09.23 um 20:46 schrieb Stéphane Archer: Is there any good reason why FFmpeg which sees that the video file input and output match every single characteristic doesn't copy the stream to avoid useless reencoding? Basically doing "-vcodec copy" automatically. is there a good reason to throw a video file through ffmpeg when you don't want to touch it? yeah, there may be a few reasons, and for the really *few* reasons you are supposed to state that ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-user] Is there any good reason why FFmpeg doesn't do "-vcodec copy" automatically.
Is there any good reason why FFmpeg which sees that the video file input and output match every single characteristic doesn't copy the stream to avoid useless reencoding? Basically doing "-vcodec copy" automatically. -- Best Regards, Stephane Archer ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] How to merge and map 1 video file with 4 audio files?
> On Sep 30, 2023, at 09:31, Andrew Randrianasulu > wrote: > > may be remove all OUTPUT_CHx lines so output will be clearly into one mxf > file? Thanks Andrew, will try! What made you think removing the "remove all OUTPUT_CHx " was the right move? What I'm hoping for, big picture, is to understand in detail routing source to dest. The documentation seems clear enough, but the errors I got suggest I didn't quite figure it out yet. Thx ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there an equivalent of Drobox Lepton but for h.264 videos?
Hi, I have no information on how Lepton actually works, but it's presumably making use of redundancy inherent to JPEG which make it possible for lossless compression to reduce their size so dramatically. JPEG is a very old standard, developed at a time of very limited computer resources, and all compression is a compromise of image quality, file size, and computer horsepower. Conversely, at least some video codecs already use lossless compression such as Huffman and arithmetic coding and it's quite possible that the kind of feature being requested here is more or less already implemented. Main and High profile H.264, HEVC and possibly others use context-based adaptive binary arithmetic coding, which is a type of lossless compression. This does more or less what Lepton appears to be doing for JPEGs. So the answer is that basically, it's already there. It might theoretically be possible to do better by using more computer resources (CPU time, memory, etc) to apply some other or more extensive type of lossless compression, but I would not expect it to be possible to achieve the sort of large gains that Lepton achieves with JPEG, at least with reasonable computer resources. P ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there an equivalent of Drobox Lepton but for h.264 videos?
On 9/30/2023 7:00 AM, Andrew Randrianasulu wrote: well, h264 videos already heavy and usually lossy compressed, any further compression will be not lossless There's one-way compression that reduces size by throwing away data (e.g. jpg) and two-way compression that reduces size but the result can't be used without reversal (e.g. gzip/lzma, etc). Dropbox Lepton is one of the latter; it's also been deprecated by Dropbox - https://github.com/dropbox/lepton. Often it's more precise to talk about "image compression" vs "file compression". Media and graphics people usually seem to mean one-way compression while computer people usually mean two-way. z! ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there an equivalent of Drobox Lepton but for h.264 videos?
сб, 30 сент. 2023 г., 19:31 Stéphane Archer : > On Sat, Sep 30, 2023 at 11:00 AM David Bernat > wrote: > > > Been very seriously considering design scope. Dropbox is a no-go. Want to > > connect offline to describe your use case? > > > > > > On Sat, Sep 30, 2023 at 10:10 AM Stéphane Archer < > archersteph...@gmail.com > > > > > wrote: > > > > > On Sat, Sep 30, 2023 at 10:00 AM Andrew Randrianasulu < > > > randrianas...@gmail.com> wrote: > > > > > > > сб, 30 сент. 2023 г., 16:58 Stéphane Archer < > archersteph...@gmail.com > > >: > > > > > > > > > Is there an equivalent of Drobox Lepton but for h.264 videos? > > > > > Lepton is a lossless compression algorithm to compress jpeg at > around > > > 20% > > > > > there initial file size without any data loss. This is ideal to > > > > > achieve jpeg. > > > > > What about h.264 videos? > > > > > > > > > > > > > > > > > well, h264 videos already heavy and usually lossy compressed, any > > further > > > > compression will be not lossless > > > > > > > > > > lepton works on jpeg that are lossy, yet they manage to have a smaller > > file > > > size adding a lossless compression on top of it. > > > I'm not sure why it won't be possible to do the same on a h.264 file > and > > > get a smaller file size. I know h.265 and av1 have lossless video > > > compression. And I recently heard about FFV1. > > > > > > > Dear David, I don't understand what you mean by "design scope". > > I would like to try a different analogy > > If the data was text and I wanted lossy compression then I would replace > all the vowels with an "a" and then compress the resulting data with gzip. > > now if I switch gzip by using lzma instead, I would end up with a file > smaller or the same size as the gzip version. Why does lossless h.265 or > lossless av1 give me a larger file size than the original h.264? Why is > this different for video? > As far as I understand all those h26x series of codes use https://en.m.wikipedia.org/wiki/Motion_estimation so only small difference between non-keyframes encoded, making file smaller (unless you try to compress say analog tv noise ...) DCT part is usually lossy by dropping some numbers ... so, if I understand correctly you can repack jpeg slightly differently, or recompress it completely into something like jpeg-xl, but video usually get a lot more info already removed, due to way only parts of image usually changes from frame to frame. > I hope my text compression analogy was clear. > > -- > Best Regards, > > Stephane Archer > ___ > ffmpeg-user mailing list > ffmpeg-user@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > To unsubscribe, visit link above, or email > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". > ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there an equivalent of Drobox Lepton but for h.264 videos?
On Sat, Sep 30, 2023 at 11:00 AM David Bernat wrote: > Been very seriously considering design scope. Dropbox is a no-go. Want to > connect offline to describe your use case? > > > On Sat, Sep 30, 2023 at 10:10 AM Stéphane Archer > > wrote: > > > On Sat, Sep 30, 2023 at 10:00 AM Andrew Randrianasulu < > > randrianas...@gmail.com> wrote: > > > > > сб, 30 сент. 2023 г., 16:58 Stéphane Archer >: > > > > > > > Is there an equivalent of Drobox Lepton but for h.264 videos? > > > > Lepton is a lossless compression algorithm to compress jpeg at around > > 20% > > > > there initial file size without any data loss. This is ideal to > > > > achieve jpeg. > > > > What about h.264 videos? > > > > > > > > > > > > > well, h264 videos already heavy and usually lossy compressed, any > further > > > compression will be not lossless > > > > > > > lepton works on jpeg that are lossy, yet they manage to have a smaller > file > > size adding a lossless compression on top of it. > > I'm not sure why it won't be possible to do the same on a h.264 file and > > get a smaller file size. I know h.265 and av1 have lossless video > > compression. And I recently heard about FFV1. > > > Dear David, I don't understand what you mean by "design scope". I would like to try a different analogy If the data was text and I wanted lossy compression then I would replace all the vowels with an "a" and then compress the resulting data with gzip. now if I switch gzip by using lzma instead, I would end up with a file smaller or the same size as the gzip version. Why does lossless h.265 or lossless av1 give me a larger file size than the original h.264? Why is this different for video? I hope my text compression analogy was clear. -- Best Regards, Stephane Archer ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] How to merge and map 1 video file with 4 audio files?
сб, 30 сент. 2023 г., 19:08 Media Mouth : > How to merge and map 1 video file with 4 audio files? > > We've have 1 video file, 4 audio files, all same length. > The video file is DNxHD36 > The audio tracks are all .wav > > The goal is to merge all 5 files in sync > > Based on https://ffmpeg.org/ffmpeg.html#Advanced-options I tried the > following: > > ffmpeg \ > -i 'Video.mxf' \ > -i 'Audio1.wav' \ > -i 'Audio2.wav' \ > -i 'Audio3.wav' \ > -i 'Audio4.wav' \ > -c:v copy \ > -c:a pcm_s24le \ > -map 0:v:0 \ > -map_channel 1.0.0 OUTPUT_CH0 \ > -map_channel 2.0.0 OUTPUT_CH1 \ > -map_channel 3.0.0 OUTPUT_CH2 \ > -map_channel 4.0.0 OUTPUT_CH3 \ > '/Volumes/ANF_VFX/prjx531-Xfers/ANF_103_230908_Soft Lock_MixStage_test.mxf' > > Getting error > [NULL @ 0x7f814601a200] Unable to find a suitable output format for > 'OUTPUT_CH0' > OUTPUT_CH0: Invalid argument > may be remove all OUTPUT_CHx lines so output will be clearly into one mxf file? > > Also tried removing the extra 0 in the -map_channel lines, > e.g. -map_channel 1.0 OUTPUT_CH0 instead of > -map_channel 1.0.0 OUTPUT_CH0 > > Got error > Syntax error, mapchan usage: [file.stream.channel|-1][:syncfile:syncstream] > > > > ___ > ffmpeg-user mailing list > ffmpeg-user@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > To unsubscribe, visit link above, or email > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". > ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-user] How to merge and map 1 video file with 4 audio files?
How to merge and map 1 video file with 4 audio files? We've have 1 video file, 4 audio files, all same length. The video file is DNxHD36 The audio tracks are all .wav The goal is to merge all 5 files in sync Based on https://ffmpeg.org/ffmpeg.html#Advanced-options I tried the following: ffmpeg \ -i 'Video.mxf' \ -i 'Audio1.wav' \ -i 'Audio2.wav' \ -i 'Audio3.wav' \ -i 'Audio4.wav' \ -c:v copy \ -c:a pcm_s24le \ -map 0:v:0 \ -map_channel 1.0.0 OUTPUT_CH0 \ -map_channel 2.0.0 OUTPUT_CH1 \ -map_channel 3.0.0 OUTPUT_CH2 \ -map_channel 4.0.0 OUTPUT_CH3 \ '/Volumes/ANF_VFX/prjx531-Xfers/ANF_103_230908_Soft Lock_MixStage_test.mxf' Getting error [NULL @ 0x7f814601a200] Unable to find a suitable output format for 'OUTPUT_CH0' OUTPUT_CH0: Invalid argument Also tried removing the extra 0 in the -map_channel lines, e.g. -map_channel 1.0 OUTPUT_CH0 instead of -map_channel 1.0.0 OUTPUT_CH0 Got error Syntax error, mapchan usage: [file.stream.channel|-1][:syncfile:syncstream] ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there an equivalent of Drobox Lepton but for h.264 videos?
Been very seriously considering design scope. Dropbox is a no-go. Want to connect offline to describe your use case? On Sat, Sep 30, 2023 at 10:10 AM Stéphane Archer wrote: > On Sat, Sep 30, 2023 at 10:00 AM Andrew Randrianasulu < > randrianas...@gmail.com> wrote: > > > сб, 30 сент. 2023 г., 16:58 Stéphane Archer : > > > > > Is there an equivalent of Drobox Lepton but for h.264 videos? > > > Lepton is a lossless compression algorithm to compress jpeg at around > 20% > > > there initial file size without any data loss. This is ideal to > > > achieve jpeg. > > > What about h.264 videos? > > > > > > > > > well, h264 videos already heavy and usually lossy compressed, any further > > compression will be not lossless > > > > lepton works on jpeg that are lossy, yet they manage to have a smaller file > size adding a lossless compression on top of it. > I'm not sure why it won't be possible to do the same on a h.264 file and > get a smaller file size. I know h.265 and av1 have lossless video > compression. And I recently heard about FFV1. > > -- > Best Regards, > > Stephane Archer > ___ > ffmpeg-user mailing list > ffmpeg-user@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > To unsubscribe, visit link above, or email > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". > ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there an equivalent of Drobox Lepton but for h.264 videos?
On Sat, Sep 30, 2023 at 10:00 AM Andrew Randrianasulu < randrianas...@gmail.com> wrote: > сб, 30 сент. 2023 г., 16:58 Stéphane Archer : > > > Is there an equivalent of Drobox Lepton but for h.264 videos? > > Lepton is a lossless compression algorithm to compress jpeg at around 20% > > there initial file size without any data loss. This is ideal to > > achieve jpeg. > > What about h.264 videos? > > > > > well, h264 videos already heavy and usually lossy compressed, any further > compression will be not lossless > lepton works on jpeg that are lossy, yet they manage to have a smaller file size adding a lossless compression on top of it. I'm not sure why it won't be possible to do the same on a h.264 file and get a smaller file size. I know h.265 and av1 have lossless video compression. And I recently heard about FFV1. -- Best Regards, Stephane Archer ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Is there an equivalent of Drobox Lepton but for h.264 videos?
сб, 30 сент. 2023 г., 16:58 Stéphane Archer : > Is there an equivalent of Drobox Lepton but for h.264 videos? > Lepton is a lossless compression algorithm to compress jpeg at around 20% > there initial file size without any data loss. This is ideal to > achieve jpeg. > What about h.264 videos? > well, h264 videos already heavy and usually lossy compressed, any further compression will be not lossless > > -- > Best Regards, > > Stephane Archer > ___ > ffmpeg-user mailing list > ffmpeg-user@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > To unsubscribe, visit link above, or email > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". > ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-user] Is there an equivalent of Drobox Lepton but for h.264 videos?
Is there an equivalent of Drobox Lepton but for h.264 videos? Lepton is a lossless compression algorithm to compress jpeg at around 20% there initial file size without any data loss. This is ideal to achieve jpeg. What about h.264 videos? -- Best Regards, Stephane Archer ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] av1_vaapi encoding testing
On Mon, 25 Sep 2023 04:39:53 + "Xiang, Haihao" wrote: > On Vr, 2023-09-22 at 22:11 +0200, Patrick M. wrote: > > On Fri, 22 Sep 2023 20:04:57 +0300 > > Dennis Mungai wrote: > > > > > > > > > That's good to hear. You may also want to ensure that the likes of OneVPL > > > are up to date if you're using any of its encoder wrappers. It was > > > formerly > > > called (and implemented as) QuickSync (QSV). > > > > > > > > > > ___ > > > ffmpeg-user mailing list > > > ffmpeg-user@ffmpeg.org > > > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > > > > > To unsubscribe, visit link above, or email > > > ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". > > > > > > > Well i think they are - av1_vaapi works now without issues so far. > > oneVPL-intel-gpu 23.3.2 and > > oneVPL 2023.3.1 > > > > With direct QSV i had no luck yet - see > > https://community.intel.com/t5/Media-Intel-oneAPI-Video/ffmpeg-6-using-qsv-on-ARC380/m-p/1524165/emcs_t/S2h8ZW1haWx8dG9waWNfc3Vic2NyaXB0aW9ufExNS0o5N1ZLMzlUMkRIfDE1MjQxNjV8U1VCU0NSSVBUSU9OU3xoSw > > Could you double check whether /dev/dri/renderD129 is your Intel GPU ? Yes, sure: vainfo --display drm --device /dev/dri/renderD129 Trying display: drm libva info: VA-API version 1.19.0 libva info: Trying to open /usr/lib64/va/drivers/iHD_drv_video.so libva info: Found init function __vaDriverInit_1_19 libva info: va_openDriver() returns 0 vainfo: VA-API version: 1.19 (libva 2.18.2) vainfo: Driver version: Intel iHD driver for Intel(R) Gen Graphics - 23.3.2 () vainfo: Supported profile and entrypoints ... VAProfileAV1Profile0: VAEntrypointVLD VAProfileAV1Profile0: VAEntrypointEncSliceLP l /dev/dri/by-path/ total 0 lrwxrwxrwx 1 root root 8 Sep 30 2023 pci-:2f:00.0-card -> ../card0 lrwxrwxrwx 1 root root 13 Sep 30 2023 pci-:2f:00.0-render -> ../renderD128 lrwxrwxrwx 1 root root 8 Sep 30 2023 pci-:32:00.0-card -> ../card1 lrwxrwxrwx 1 root root 13 Sep 30 2023 pci-:32:00.0-render -> ../renderD129 and from lspci 32:00.0 VGA compatible controller: Intel Corporation DG2 [Arc A380] (rev 05) (prog-if 00 [VGA controller]) Subsystem: ASRock Incorporation DG2 [Arc A380] Flags: bus master, fast devsel, latency 0, IRQ 46, IOMMU group 2 Memory at fa00 (64-bit, non-prefetchable) [size=16M] Memory at 7fc000 (64-bit, prefetchable) [size=256M] Expansion ROM at fb00 [disabled] [size=2M] Capabilities: [40] Vendor Specific Information: Len=0c Capabilities: [70] Express Endpoint, MSI 00 Capabilities: [ac] MSI: Enable+ Count=1/1 Maskable+ 64bit+ Capabilities: [d0] Power Management version 3 Capabilities: [100] Alternative Routing-ID Interpretation (ARI) Capabilities: [420] Physical Resizable BAR Capabilities: [400] Latency Tolerance Reporting Kernel driver in use: i915 > > Thanks > Haihao > > > > > > Would there be a noticable difference to be expected between av1 using vaapi > > vs direct qsv? > -- Patrick M. ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".