[FFmpeg-devel] [PATCH] avfilter: add ANSNR filter
Michael Niedermayer
michael at niedermayer.cc
Fri Mar 31 03:17:01 EEST 2017
On Thu, Mar 30, 2017 at 11:06:36PM +0200, Betty Wu wrote:
> A new filter ANSNR is added. libavfilter/Makefile is changed.
> Run 'ffmpeg -i input1 -i input2 -lavfi ansnr -f null -' to get an overall score while per-frame value is stored but not printed.
> This implementation is for constructing the vmaf filter later since ANSNR is one of individual tools used in vmaf.
>
> Signed-off-by: Betty Wu <lumosomul at gmail.com>
> ---
>
[...]
> +static void *aligned_malloc(size_t size, size_t alignment)
> +{
> + void *ptr;
> +
> + if (posix_memalign(&ptr, alignment, size))
> + return 0;
> + else
> + return ptr;
> +}
please use av_malloc()
posix_memalign is not portable
> +
> +static void aligned_free(void *ptr)
> +{
> + free(ptr);
> +}
use av_freep()
also please see tools/patcheck
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
There will always be a question for which you do not know the correct answer.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20170331/99e5062a/attachment.sig>
More information about the ffmpeg-devel
mailing list