@@ -184,10 +184,11 @@ TEST_CASE("[NoiseTexture3D][SceneTree] Generating a basic noise texture with mip
184184 noise_texture->set_noise (noise);
185185
186186 Ref<Gradient> gradient = memnew (Gradient);
187- Vector<Gradient::Point> points;
188- points.push_back ({ 0.0 , Color (1 , 0 , 0 ) });
189- points.push_back ({ 1.0 , Color (0 , 0 , 1 ) });
190- gradient->set_points (points);
187+ Vector<float > offsets = { 0.0 , 1.0 };
188+ Vector<Color> colors = { Color (1 , 0 , 0 ), Color (0 , 0 , 1 ) };
189+ gradient->set_offsets (offsets);
190+ gradient->set_colors (colors);
191+
191192 noise_texture->set_color_ramp (gradient);
192193 noise_texture->set_width (16 );
193194 noise_texture->set_height (16 );
@@ -219,10 +220,12 @@ TEST_CASE("[NoiseTexture3D][SceneTree] Generating a seamless noise texture") {
219220
220221 SUBCASE (" 16x16x16 modulated with default (transparent)black and white gradient (RGBA8), with seamless blend skirt of 1.0" ) {
221222 Ref<Gradient> gradient = memnew (Gradient);
222- Vector<Gradient::Point> points;
223- points.push_back ({ 0.0 , Color (0 , 0 , 0 , 0 ) });
224- points.push_back ({ 1.0 , Color (1 , 1 , 1 , 1 ) });
225- gradient->set_points (points);
223+
224+ Vector<float > offsets = { 0.0 , 1.0 };
225+ Vector<Color> colors = { Color (0 , 0 , 0 , 0 ), Color (1 , 1 , 1 , 1 ) };
226+ gradient->set_offsets (offsets);
227+ gradient->set_colors (colors);
228+
226229 noise_texture->set_color_ramp (gradient);
227230 noise_texture->set_seamless_blend_skirt (1.0 );
228231 noise_texture->connect_changed (callable_mp (tester.ptr (), &NoiseTexture3DTester::check_seamless_texture_rgba));
0 commit comments