diff mbox

[2/3] tests: add hue area wraparound test for HGT

Message ID 20161004130915.28812-3-niklas.soderlund@ragnatech.se (mailing list archive)
State Not Applicable
Headers show

Commit Message

Niklas Söderlund Oct. 4, 2016, 1:09 p.m. UTC
From: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>

One configuration for HGT histograms are where hue area 0 is wrapped
around the hue input value space (0-255), for example area 0 can cover
hue values above 220 but bellow 40. Hue area 0 is the only area which
supports this mode where the areas lower limit uses a higher value then
it's higher limit hence the area wraparound the max hue value.

Add a test to verify this works now that gen-image supports generating
reference frames with wrapped around hue areas.

Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
---
 tests/vsp-unit-test-0018.sh | 1 +
 1 file changed, 1 insertion(+)

Comments

Laurent Pinchart Nov. 12, 2016, 2:06 a.m. UTC | #1
Hi Niklas,

Thank you for the patch.

On Tuesday 04 Oct 2016 15:09:14 Niklas Söderlund wrote:
> From: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
> 
> One configuration for HGT histograms are where hue area 0 is wrapped

s/is/

> around the hue input value space (0-255), for example area 0 can cover
> hue values above 220 but bellow 40. Hue area 0 is the only area which

s/bellow/below/

> supports this mode where the areas lower limit uses a higher value then

s/areas/area's/
s/then/than/

> it's higher limit hence the area wraparound the max hue value.

s/it's/its/
s/wraparound/wraps around/

I'll fix this while applying.

> Add a test to verify this works now that gen-image supports generating
> reference frames with wrapped around hue areas.
> 
> Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

> ---
>  tests/vsp-unit-test-0018.sh | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/tests/vsp-unit-test-0018.sh b/tests/vsp-unit-test-0018.sh
> index 2b49b54..944f7ac 100755
> --- a/tests/vsp-unit-test-0018.sh
> +++ b/tests/vsp-unit-test-0018.sh
> @@ -31,6 +31,7 @@ test_histogram() {
>  test_main() {
>  	test_histogram "0,255,255,255,255,255,255,255,255,255,255,255"
>  	test_histogram "0,40,40,80,80,120,120,160,160,200,200,255"
> +	test_histogram "220,40,40,80,80,120,120,160,160,200,200,220"
>  }
> 
>  test_init $0 "$features"
diff mbox

Patch

diff --git a/tests/vsp-unit-test-0018.sh b/tests/vsp-unit-test-0018.sh
index 2b49b54..944f7ac 100755
--- a/tests/vsp-unit-test-0018.sh
+++ b/tests/vsp-unit-test-0018.sh
@@ -31,6 +31,7 @@  test_histogram() {
 test_main() {
 	test_histogram "0,255,255,255,255,255,255,255,255,255,255,255"
 	test_histogram "0,40,40,80,80,120,120,160,160,200,200,255"
+	test_histogram "220,40,40,80,80,120,120,160,160,200,200,220"
 }
 
 test_init $0 "$features"