From: Pascal Massimino Date: Thu, 14 Sep 2017 10:58:57 +0000 (+0200) Subject: fix compile error: "error: variable-sized object ‘red_data’ may not be initialized" X-Git-Tag: 1.6.0~78 X-Git-Url: https://git.sesse.net/?p=movit;a=commitdiff_plain;h=ed0f91ba6ff793cfa604c589c404146ed0f4c8a2 fix compile error: "error: variable-sized object ‘red_data’ may not be initialized" --- diff --git a/ycbcr_input_test.cpp b/ycbcr_input_test.cpp index deece92..92ef33b 100644 --- a/ycbcr_input_test.cpp +++ b/ycbcr_input_test.cpp @@ -1031,8 +1031,8 @@ private: // Basically the same test as EffectChainTest_MipmapGenerationWorks, // just with the data converted to Y'CbCr (as red only). TEST(EffectChainTest, MipmapGenerationWorks) { - unsigned width = 4; - unsigned height = 16; + const unsigned width = 4; + const unsigned height = 16; float red_data[width * height] = { // In 4x4 blocks. 1.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f,