From 863fcc779550286cf51796bc66e9fd82e0c3170f Mon Sep 17 00:00:00 2001 From: Adam Wieckowski Date: Mon, 18 Nov 2024 16:47:56 +0100 Subject: [PATCH] Change input to signed 16 bit --- test/vvenc_unit_test/vvenc_unit_test.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/vvenc_unit_test/vvenc_unit_test.cpp b/test/vvenc_unit_test/vvenc_unit_test.cpp index 9d787d4f..90dae9b2 100644 --- a/test/vvenc_unit_test/vvenc_unit_test.cpp +++ b/test/vvenc_unit_test/vvenc_unit_test.cpp @@ -90,7 +90,7 @@ class InputGenerator T operator()() const { - return rand() & ( ( 1 << m_bits ) - 1 ); + return ( rand() & ( ( 1 << m_bits ) - 1 ) ) - ( 1 << m_bits >> 1 ); } private: @@ -208,7 +208,7 @@ static bool check_one_fastFwdCore_2D( TCoeffOps* ref, TCoeffOps* opt, unsigned i static bool check_fastInvCore( TCoeffOps* ref, TCoeffOps* opt, unsigned num_cases, unsigned idx, unsigned trSize ) { printf( "Testing TCoeffOps::fastInvCore trSize=%d\n", trSize ); - InputGenerator g{ 10 }; + InputGenerator g{ 16 }; TrafoGenerator t{ 8 }; DimensionGenerator rng; @@ -231,7 +231,7 @@ static bool check_fastInvCore( TCoeffOps* ref, TCoeffOps* opt, unsigned num_case static bool check_fastFwdCore_2D( TCoeffOps* ref, TCoeffOps* opt, unsigned num_cases, unsigned idx, unsigned trSize ) { printf( "Testing TCoeffOps::fastFwdCore_2D trSize=%d\n", trSize ); - InputGenerator g{ 10 }; + InputGenerator g{ 16 }; TrafoGenerator t{ 8 }; DimensionGenerator rng;