[x265] [PATCH]Add: Auto AQ Mode

Niranjan Bala niranjan at multicorewareinc.com
Thu Apr 16 09:41:34 CEST 2020


Hi Chen,
Thanks for spending your valuable time reviewing the patch and sharing the
comments. We have incorporated the suggested changes and adding a few more
to it. We will send you the updated patch soon :)

Thanks & Regards
*Niranjan Kumar B*
Video Codec Engineer
Media & AI Analytics
+91 958 511 1449
<https://multicorewareinc.com/>


On Thu, Feb 27, 2020 at 2:35 PM chen <chenm003 at 163.com> wrote:

>
> At 2020-02-27 16:59:18, "Niranjan Bala" <niranjan at multicorewareinc.com>
> wrote:
>
> +double computeBrightnessIntensity(pixel *inPlane, int width, int height,
> intptr_t stride)
> +{
> +    pixel* rowStart = inPlane;
> restrict with const prefix may better.
>
> +    double count = 0;
> why declare as Double?
>
> +
> +    for (int i = 0; i < height; i++)
> +    {
> +        for (int j = 0; j < width; j++)
> +        {
> +            if (rowStart[j] > BRIGHTNESS_THRESHOLD)
> +                count++;
> +        }
> +        rowStart += stride;
> +    }
> +
> +    /* Returns the brightness percentage of the input plane */
> +    return (count / (width * height)) * 100;
> +}
> +
> +double computeEdgeIntensity(pixel *inPlane, int width, int height,
> intptr_t stride)
> +{
> +    pixel* rowStart = inPlane;
> +    double count = 0;
> +
> +    for (int i = 0; i < height; i++)
> +    {
> +        for (int j = 0; j < width; j++)
> +        {
> +            if (rowStart[j] > 0)
> +                count++;
> +        }
> +        rowStart += stride;
> +    }
> +
> +    /* Returns the edge percentage of the input plane */
> +    return (count / (width * height)) * 100;
> 100 is integer, multiplication with Double.
>
>
> _______________________________________________
> x265-devel mailing list
> x265-devel at videolan.org
> https://mailman.videolan.org/listinfo/x265-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/x265-devel/attachments/20200416/3f4495b8/attachment.html>


More information about the x265-devel mailing list