VideoHelp Forum




+ Reply to Thread
Results 1 to 8 of 8
  1. Code:
    2160p / 23.976 fps / 16:9 / Main 10 @ Level 5.1 @ High / 4:2:0 / 10 bits / SDR / BT.709
    I have a clip like this.

    How can I resize and encode this 1080p 8 bit x264 with Avisynth plugins?

    Couldn't find any good way.

    Help would be great.
    Quote Quote  
  2. Originally Posted by max_cady View Post
    Code:
    2160p / 23.976 fps / 16:9 / Main 10 @ Level 5.1 @ High / 4:2:0 / 10 bits / SDR / BT.709
    I have a clip like this.

    How can I resize and encode this 1080p 8 bit x264 with Avisynth plugins?

    Couldn't find any good way.

    Help would be great.

    what kind of dithering and resizing algorithm did you want ?

    "floyd-steinberg" is common for dither. Spline36 is fairly sharp for downscaling, if it's too sharp for your source, try Spline16

    e.g

    Code:
    LWLibavVideoSource("your video.ext")
    Spline36Resize(1920,1080)
    ConvertBits(bits=8, dither=1)

    There are many different types of dithering and scaling algorithms. You can use dither tools for example to access others
    Quote Quote  
  3. Glad to receive your reply!

    I assume "Floyd–Steinberg dithering" is one of best? Just looking one of best bet for my video.


    I thought "ConvertFromStacked(bits=10)" also necessary, that fools me. Anyway here's my script:


    LWLibavVideoSource("<video>",format="YUV422P10")

    ConvertBits(bits=8, dither=1)

    z_ConvertFormat(1920,1080,pixel_type="YV12")
    Any additional advice is welcome.
    Quote Quote  
  4. Originally Posted by max_cady View Post

    I assume "Floyd–Steinberg dithering" is one of best? Just looking one of best bet for my video.
    It's pretty standard, and the most common method used. But one complaint is it can be slightly noisy on some types of video in some scenarios.

    On the other hand, some people actually add additional noise and grain on top of dithering, and encode with high bitrates to prevent 8bit banding

    Others don't dither at all , because of various reasons

    It depends on the source, and the encoding scenario, and what you're trying to do





    I thought "ConvertFromStacked(bits=10)" also necessary, that fools me. Anyway here's my script:


    LWLibavVideoSource("<video>",format="YUV422P10")

    ConvertBits(bits=8, dither=1)

    z_ConvertFormat(1920,1080,pixel_type="YV12")
    Any additional advice is welcome.
    It should automatically detect YUV420P10. You can check with info() . If you enter format=YUV422P10, you're actually upscaling to 10bit422 before downconverting, and causing unnecessary quality loss. So omit that.


    Newer versions of lsmash work with planar YUV directly, so there is need for stacked MSB/LSB format or ConvertFromStacked

    HolyWu's branch is the most frequently updated. Recommended
    https://github.com/HolyWu/L-SMASH-Works/releases


    If you're using z_ConvertFormat, You don't need to use convert bits separately

    z_ConvertFormat(width=1920, height=1080, pixel_type="YV12", dither_type="error_diffusion", resample_filter="spline36")

    You can change any of the parameters, for example, spline36 is often too sharp for Y scaling from UHD sources. And resample_filter_uv would control the UV downscaling method. Often a softer method like bicubic or bilinear is more pleasing for chroma scaling


    (And technically, if you were using convertbits instead of z_convertformat - you should get better results scaling in 10bit before converting to 8bit (although it can be difficult to see difference) . Because you have higher precision during the scaling step)
    Last edited by poisondeathray; 16th Mar 2020 at 08:50.
    Quote Quote  
  5. Holy cow!

    I learned a lot of things from you, I can't thank you enough.

    Great details, will try more parameters for z_ConvertFormat.

    Thank you again.
    Quote Quote  
  6. You can resize it and do 10bit to 8bit reencode with my smart FFMpeg gui
    https://forum.videohelp.com/threads/395425-New-small-GUI-for-FFmpeg

    Click image for larger version

Name:	pic1.jpg
Views:	241
Size:	51.1 KB
ID:	52368
    Last edited by ProWo; 16th Mar 2020 at 10:40.
    Quote Quote  
  7. Prowo, man, we all love to shove our beloved creation to everyone, but if you do this too much, it becomes a pollution, especially if you do it without any explanation.

    Besides almost any GUI can scale down like that,
    how do you set error diffusion in your GUI, dithering from 10 to 8 bit and how do you set downscale method?
    Quote Quote  
  8. Originally Posted by _Al_ View Post
    Prowo, man, we all love to shove our beloved creation to everyone, but if you do this too much, it becomes a pollution, especially if you do it without any explanation.

    Besides almost any GUI can scale down like that,
    how do you set error diffusion in your GUI, dithering from 10 to 8 bit and how do you set downscale method?
    Hi _A|_
    only meant to help
    Quote Quote  



Similar Threads

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