OSDN Git Service

media: v4l2-tpg: fix the SMPTE-2084 transfer function
authorHans Verkuil <hverkuil@xs4all.nl>
Tue, 8 Aug 2017 10:56:29 +0000 (06:56 -0400)
committerMauro Carvalho Chehab <mchehab@s-opensource.com>
Tue, 8 Aug 2017 11:05:09 +0000 (07:05 -0400)
commit079c6eaf80d9fb6d9cea7ad71e590c8425c1b0fe
treee7ee6287a3a76a9465fa1ba0c7d0ebf83f66df27
parente047c5e0dad14c7b6d1470dc2e237a7a55252233
media: v4l2-tpg: fix the SMPTE-2084 transfer function

The SMPTE-2084 transfer functions maps to the luminance range of
0-10000 cd/m^2. Other transfer functions use the traditional range of
0-100 cd/m^2.

I didn't take this into account so the luminance was off by a factor of
100.

Since qv4l2 made the same mistake in reverse I never noticed this until
I tested with actual SMPTE-2084 video.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
drivers/media/common/v4l2-tpg/v4l2-tpg-colors.c