VideoHelp Forum




+ Reply to Thread
Results 1 to 17 of 17
  1. Banned
    Join Date
    Oct 2023
    Location
    Los Angeles
    Search Comp PM
    How do I extract frames from videos into lossless avif, heic/heif, or any other lossless formats (not tiff) that support YUV (4:2:0, 4:2:2, and 4:4:4)? From both H.264 and H.265 videos?

    Are there any guis for these? How do I use them and/or ffmpeg to make image sequences of those files?
    https://github.com/AOMediaCodec/libavif
    https://github.com/strukturag/libheif

    Also, when making jxl files, I noticed that making them regularly and making them with the special commands to make them lossless look the same. Is that true? How do I set the primaries and transfer needed to fix the error I mentioned in a previous post and hopefully make the process do faster?
    Quote Quote  
  2. I don't know, but want to say after monitoring your questions in recent days, that you actually might start to look into Avisynth or Vapoursynth, meaning read their manuals, what they do, like conversions from format to other format the best way possible, there is also imwri plugin available to write rgb 8bit to disk. As pdr mentioned, it does not matter what video format you have, as humans, we can only observe it on screen as RGB 8 bit (regular monitors). Are you aware what Avisynth or Vapoursynth can do?

    There are filters available that are temporal, not treating video as images (spatial only), filters work in yuv or rgb. And if your processes need to be automatized, I'd recommend vapoursynth (using python). You still did not reveal why you need to get yuv images from your video.
    Quote Quote  
  3. Originally Posted by Jay123210599 View Post
    Also, when making jxl files, I noticed that making them regularly and making them with the special commands to make them lossless look the same. Is that true?
    No, it was explained in your other post and the help file. READ IT!

    -distance 0 is lossless. -distance > 0 is not . Lower values are higher in quality for lossy mode


    Encoder libjxl [libjxl JPEG XL]:
    General capabilities: threads
    Threading capabilities: other
    Supported pixel formats: rgb24 rgba rgb48le rgba64le gray ya8 gray16le ya16le grayf32le
    libjxl AVOptions:
    -effort <int> E..V....... Encoding effort (from 1 to 9) (default 7)
    -distance <float> E..V....... Maximum Butteraugli distance (quality setting, lower = better, zero = lossless, default 1.0) (from -1 to 15) (default -1)
    -modular <int> E..V....... Force modular mode (from 0 to 1) (default 0)


    How do I set the primaries and transfer needed to fix the error I mentioned in a previous post
    Code:
    -color_primaries bt709 -color_trc iec61966-2-1


    and hopefully make the process do faster?
    Again, it's "effort". Higher values are slower, produce smaller filesizes . If you want faster, filesizes for lossless will be larger, use a lower effort number

    -effort <int> E..V....... Encoding effort (from 1 to 9) (default 7)
    Quote Quote  
  4. You can extract video frames exactly same way as in case of previously asked PNG/APNG. If you wish to use different video codec then use it instead PNG/APNG - ffmpeg command line stays similar - difference will be related to selected video codec.
    Quote Quote  
  5. Banned
    Join Date
    Oct 2023
    Location
    Los Angeles
    Search Comp PM
    Originally Posted by poisondeathray View Post
    Originally Posted by Jay123210599 View Post
    Also, when making jxl files, I noticed that making them regularly and making them with the special commands to make them lossless look the same. Is that true?
    No, it was explained in your other post and the help file. READ IT!

    -distance 0 is lossless. -distance > 0 is not . Lower values are higher in quality for lossy mode


    Encoder libjxl [libjxl JPEG XL]:
    General capabilities: threads
    Threading capabilities: other
    Supported pixel formats: rgb24 rgba rgb48le rgba64le gray ya8 gray16le ya16le grayf32le
    libjxl AVOptions:
    -effort <int> E..V....... Encoding effort (from 1 to 9) (default 7)
    -distance <float> E..V....... Maximum Butteraugli distance (quality setting, lower = better, zero = lossless, default 1.0) (from -1 to 15) (default -1)
    -modular <int> E..V....... Force modular mode (from 0 to 1) (default 0)


    How do I set the primaries and transfer needed to fix the error I mentioned in a previous post
    Code:
    -color_primaries bt709 -color_trc iec61966-2-1


    and hopefully make the process do faster?
    Again, it's "effort". Higher values are slower, produce smaller filesizes . If you want faster, filesizes for lossless will be larger, use a lower effort number

    -effort <int> E..V....... Encoding effort (from 1 to 9) (default 7)
    What's -color_trc iec61966-2-1?
    Quote Quote  
  6. Originally Posted by Jay123210599 View Post

    What's -color_trc iec61966-2-1?
    sRGB transfer as described in the IEC 61966-2-1:1999 document
    https://en.wikipedia.org/wiki/SRGB

    RGB is a standard RGB (red, green, blue) color space that HP and Microsoft created cooperatively in 1996 to use on monitors, printers, and the World Wide Web.[2] It was subsequently standardized by the International Electrotechnical Commission (IEC) as IEC 61966-2-1:1999
    Check Table E.4 in the h.265 document for commonly used transfer characteristics , including sRGB
    Quote Quote  
  7. Banned
    Join Date
    Oct 2023
    Location
    Los Angeles
    Search Comp PM
    Originally Posted by poisondeathray View Post
    Originally Posted by Jay123210599 View Post

    What's -color_trc iec61966-2-1?
    sRGB transfer as described in the IEC 61966-2-1:1999 document
    https://en.wikipedia.org/wiki/SRGB

    RGB is a standard RGB (red, green, blue) color space that HP and Microsoft created cooperatively in 1996 to use on monitors, printers, and the World Wide Web.[2] It was subsequently standardized by the International Electrotechnical Commission (IEC) as IEC 61966-2-1:1999
    Check Table E.4 in the h.265 document for commonly used transfer characteristics , including sRGB
    Can you tell the difference between these two jxl files?
    Image Attached Files
    Quote Quote  
  8. Originally Posted by Jay123210599 View Post
    Can you tell the difference between these two jxl files?
    Yes
    Quote Quote  
  9. Banned
    Join Date
    Oct 2023
    Location
    Los Angeles
    Search Comp PM
    Originally Posted by poisondeathray View Post
    Originally Posted by Jay123210599 View Post
    Can you tell the difference between these two jxl files?
    Yes
    Show me.
    Quote Quote  
  10. Originally Posted by Jay123210599 View Post
    Originally Posted by poisondeathray View Post
    Originally Posted by Jay123210599 View Post
    Can you tell the difference between these two jxl files?
    Yes
    Show me.
    Zoom in with an image editor
    Quote Quote  
  11. Banned
    Join Date
    Oct 2023
    Location
    Los Angeles
    Search Comp PM
    Originally Posted by poisondeathray View Post
    Originally Posted by Jay123210599 View Post
    Originally Posted by poisondeathray View Post
    Originally Posted by Jay123210599 View Post
    Can you tell the difference between these two jxl files?
    Yes
    Show me.
    Zoom in with an image editor
    But it was visually lossless, right?
    Quote Quote  
  12. Originally Posted by Jay123210599 View Post

    But it was visually lossless, right?

    I wouldn't call it visually lossless, but it might be for some people. There are larger differences between these two , than the differences between other two in the other example
    Quote Quote  
  13. Banned
    Join Date
    Oct 2023
    Location
    Los Angeles
    Search Comp PM
    Originally Posted by poisondeathray View Post
    Originally Posted by Jay123210599 View Post

    But it was visually lossless, right?

    I wouldn't call it visually lossless, but it might be for some people. There are larger differences between these two , than the differences between other two in the other example
    Are there lossless formats that have the same file size as the lossy jxl, or at least close to it?
    Quote Quote  
  14. Originally Posted by Jay123210599 View Post
    Are there lossless formats that have the same file size as the lossy jxl, or at least close to it?
    No

    Anything lossless will have substantially larger file sizes

    Also any image format will be larger than the equivalent compression for video, because there is no benefit temporal compression for that image format .
    Quote Quote  
  15. Originally Posted by Jay123210599 View Post
    Can you tell the difference between these two jxl files?
    Comparison of details between those two images,
    click on each image about three time to get full size into a browser tab, then clicking those tabs you see differences. Each little square represents actual pixel.
    Image Attached Thumbnails Click image for larger version

Name:	clip01[64, 36, 803, 527]_1920x1059_WYSIWYG_frame_0000000.png
Views:	19
Size:	37.7 KB
ID:	76251  

    Click image for larger version

Name:	clip02[64, 36, 803, 527]_1920x1059_WYSIWYG_frame_0000000.png
Views:	22
Size:	37.4 KB
ID:	76252  

    Click image for larger version

Name:	detail.png
Views:	20
Size:	190.6 KB
ID:	76253  

    Last edited by _Al_; 16th Jan 2024 at 20:48.
    Quote Quote  
  16. Banned
    Join Date
    Oct 2023
    Location
    Los Angeles
    Search Comp PM
    @poisondeathray and @_Al_

    How about now? And let's be honest, nobody's going to bother zoom in on images to check for small differences these days, right?
    Image Attached Files
    Quote Quote  
  17. Originally Posted by Jay123210599 View Post

    How about now? And let's be honest, nobody's going to bother zoom in on images to check for small differences these days, right?
    Yes you can see differences.

    But vast majority of general public won't care or notice.

    It depends on why you are posting it, where you post it, and who your audience is.

    Honestly - Die hard anime fans tend to notice those types of things. Especially edge and line noise, textures (noise or loss). They are probably among the pickiest videophiles
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!