aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tests/validation/reference/ColorConvertHelper.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/tests/validation/reference/ColorConvertHelper.h b/tests/validation/reference/ColorConvertHelper.h
index 50040d9a92..b4255a0f20 100644
--- a/tests/validation/reference/ColorConvertHelper.h
+++ b/tests/validation/reference/ColorConvertHelper.h
@@ -228,10 +228,10 @@ inline void colorconvert_yuyv_to_rgb(const SimpleTensor<T> src, const Format for
template <typename T>
inline void colorconvert_iyuv_to_rgb(const TensorShape &shape, const std::vector<SimpleTensor<T>> &tensor_planes, SimpleTensor<T> &dst)
{
- SimpleTensor<T> yvec(TensorShape{ tensor_planes[0].shape().x(), tensor_planes[0].shape().y() }, Format::U8);
- SimpleTensor<T> uvec(TensorShape{ tensor_planes[0].shape().x(), tensor_planes[0].shape().y() }, Format::U8);
- SimpleTensor<T> yyvec(TensorShape{ tensor_planes[0].shape().x(), tensor_planes[0].shape().y() }, Format::U8);
- SimpleTensor<T> vvec(TensorShape{ tensor_planes[0].shape().x(), tensor_planes[0].shape().y() }, Format::U8);
+ SimpleTensor<T> yvec(TensorShape{ tensor_planes[0].shape().x() / 2, tensor_planes[0].shape().y() }, Format::U8);
+ SimpleTensor<T> uvec(TensorShape{ tensor_planes[0].shape().x() / 2, tensor_planes[0].shape().y() }, Format::U8);
+ SimpleTensor<T> yyvec(TensorShape{ tensor_planes[0].shape().x() / 2, tensor_planes[0].shape().y() }, Format::U8);
+ SimpleTensor<T> vvec(TensorShape{ tensor_planes[0].shape().x() / 2, tensor_planes[0].shape().y() }, Format::U8);
Coordinates elem_coord{ 0, 0 };
const int yvec_width = yvec.shape().x();
@@ -282,10 +282,10 @@ inline void colorconvert_iyuv_to_rgb(const TensorShape &shape, const std::vector
template <typename T>
inline void colorconvert_nv12_to_rgb(const TensorShape &shape, const Format format, const std::vector<SimpleTensor<T>> &tensor_planes, SimpleTensor<T> &dst)
{
- SimpleTensor<T> yvec(TensorShape{ tensor_planes[0].shape().x(), tensor_planes[0].shape().y() }, Format::U8);
- SimpleTensor<T> uvec(TensorShape{ tensor_planes[0].shape().x(), tensor_planes[0].shape().y() }, Format::U8);
- SimpleTensor<T> yyvec(TensorShape{ tensor_planes[0].shape().x(), tensor_planes[0].shape().y() }, Format::U8);
- SimpleTensor<T> vvec(TensorShape{ tensor_planes[0].shape().x(), tensor_planes[0].shape().y() }, Format::U8);
+ SimpleTensor<T> yvec(TensorShape{ tensor_planes[0].shape().x() / 2, tensor_planes[0].shape().y() }, Format::U8);
+ SimpleTensor<T> uvec(TensorShape{ tensor_planes[0].shape().x() / 2, tensor_planes[0].shape().y() }, Format::U8);
+ SimpleTensor<T> yyvec(TensorShape{ tensor_planes[0].shape().x() / 2, tensor_planes[0].shape().y() }, Format::U8);
+ SimpleTensor<T> vvec(TensorShape{ tensor_planes[0].shape().x() / 2, tensor_planes[0].shape().y() }, Format::U8);
const int offset = (Format::NV12 == format) ? 0 : 1;