[BUG] S905X (maybe all AMLogic?) HEVC decoding is flawed: bad image quality

  • In box KIII Pro (S912) with Android 7.1.1 this issue is presented.

    The box from boot2k3 uses Android 6 and the issue is not present, yours is on 7 and it is.


    Could we not compare the code for HEVC decoding on these two to identify the difference?

    Mini M8S II 2G/16G (S905X)

  • Could we not compare the code for HEVC decoding on these two to identify the difference?

    We don't have source code for them.


    Android: Video decoder: amc-h265 (HW)

    pixel format: Surface

    LibreElec: Video decoder: am-h265 (HW)

    pixel format: unknown

    AMC is Android Media Codec which is a proxy layer between Android apps and AMCodec.

  • I am desperately grasping for straws. ;)

    Could you create a LibreELEC build based on that Kernel?
    That was my idea...

    Mini M8S II 2G/16G (S905X)

  • No, I can't. I need kernel source code to build LE image. Besides, Marshmallow kernel would be a step back.

  • OK, sorry to hear it.

    I know that Marshmallow would technically be a step back, but I would prefer flawless HEVC playback over the benefits of Nougat.


    Do you have any other ideas?
    What about contacting AMLogic? Is that somehow possible?

    Mini M8S II 2G/16G (S905X)

  • All my devices (S905X, S912) running Android 6 have this issue.


    Unfortunately I don't have any way to contact Amlogic.

  • Have you ever tried just getting in contact "the usual way"?
    Amlogic -晶晨

    Technical: [email protected]gic.com

    I mean... all they can say is no. ;)
    Best case scenario - they actually refer you to a developer.

    I'd offer to do it, but all I can do is link to this thread.
    You however could actually get into the technical details of the code with them... :)

    Mini M8S II 2G/16G (S905X)

  • It's not white. It's just sharper.

    All my x265 seems to sharper than x264 but the difference is really little.

    I wouldn't notice it if not this thread. Nothing that bothers me.

    TX5 PRO S905X

  • A type of edge enhancement could certainly be responsible for the double contours.

    Maybe another route to investigate:
    wrxtasy recently told us about AMLogic's always-on Noise Reduction...

    Maybe something similar applies to HEVC decoding?
    Something like (pseudo):

    for hevc

    edge_enhancement=1


    ...or...


    for hevc
    sharpness=+2


    Just an idea...?

    Mini M8S II 2G/16G (S905X)

  • Amlogic modifies their decoder from one kernel release to another and it's quite possible that the issue was not present at some point.

    I am happy to test various older generations of your builds (before 7.0.3.012) - maybe I will find an "HEVC decoding gem".
    Could you make these accessible to me? The old download links are all down (7.0.3.011 and older)...

    Mini M8S II 2G/16G (S905X)