From 4bb9cab24c32aa91126bfede4a83aaaffd4278ea Mon Sep 17 00:00:00 2001 From: Marissa Wall Date: Thu, 19 Dec 2019 13:15:44 -0800 Subject: [PATCH] graphics.mapper@4.0: Document previously-implicit accessRegion behavior. Existing Android framework code (and transitively, CTS test) require that an accessRegion of (0,0,0,0) is treated the same as an accessRegion covering the entire buffer, when calling lock() or lockYCbCr(). Document this so that there is no confusion about this going forward, since this requirement pre-dates the HIDL HALs. Bug: 119440345 Test: Builds, passes CTS Change-Id: I5ff86539ee28a72dd972255ad405db357e62536d --- graphics/mapper/4.0/IMapper.hal | 3 +++ 1 file changed, 3 insertions(+) diff --git a/graphics/mapper/4.0/IMapper.hal b/graphics/mapper/4.0/IMapper.hal index 03dfef1e3f..d024c6e239 100644 --- a/graphics/mapper/4.0/IMapper.hal +++ b/graphics/mapper/4.0/IMapper.hal @@ -206,6 +206,9 @@ interface IMapper { * outside of @p accessRegion is undefined, except that it must not cause * process termination. * + * An accessRegion of all-zeros means the entire buffer. That is, it is + * equivalent to '(0,0)-(buffer width, buffer height)'. + * * This function can lock both single-planar and multi-planar formats. The caller * should use get() to get information about the buffer they are locking. * get() can be used to get information about the planes, offsets, stride,