@@ -1066,9 +1066,9 @@ LOCAL_libvideo_swblitter_stretch_rdwrap1(LOCAL_struct_video_blitter const *__res
10661066
10671067 if (dst->vx_flags & VIDEO_GFX_F_XWRAP) {
10681068 video_dim_t out_endx;
1069- /* Do some preliminary clamping on destination coords.
1070- * This is needed so we can properly calculate tiled
1071- * repeated when wrapping is enabled in "dst ". */
1069+ /* Do some preliminary clamping on output coords.
1070+ * This is needed so we can properly calculate tiled
1071+ * repeated when wrapping is enabled in "rddst ". */
10721072 if unlikely (out_x < 0 ) {
10731073 video_dim_t delta = (video_dim_t )-out_x;
10741074 video_dim_t new_dst_size_x;
@@ -1095,9 +1095,9 @@ LOCAL_libvideo_swblitter_stretch_rdwrap1(LOCAL_struct_video_blitter const *__res
10951095
10961096 if (dst->vx_flags & VIDEO_GFX_F_YWRAP) {
10971097 video_dim_t out_endy;
1098- /* Do some preliminary clamping on destination coords.
1099- * This is needed so we can properly calculate tiled
1100- * repeated when wrapping is enabled in "dst ". */
1098+ /* Do some preliminary clamping on output coords.
1099+ * This is needed so we can properly calculate tiled
1100+ * repeated when wrapping is enabled in "rddst ". */
11011101 if unlikely (out_y < 0 ) {
11021102 video_dim_t delta = (video_dim_t )-out_y;
11031103 video_dim_t new_dst_size_y;
@@ -1296,8 +1296,8 @@ LOCAL_libvideo_swblitter_stretch_rdwrap1(LOCAL_struct_video_blitter const *__res
12961296 dst_x = 0 ; /* Fallthru to render the last part */
12971297 } else if (dst_size_y > dst_maxsy) {
12981298 video_dim_t firsttile_src_size_y = ydst2src (dst_maxsy);
1299- LOCAL_stretch (out_y , out_y, dst_y , dst_y, dst_maxsy, dst_size_y ,
1300- src_y , src_y, firsttile_src_size_y, src_size_y );
1299+ LOCAL_stretch (out_x , out_y, dst_x , dst_y, dst_size_x, dst_maxsy ,
1300+ src_x , src_y, src_size_x, firsttile_src_size_y );
13011301 dst_size_y -= dst_maxsy;
13021302 out_y += dst_maxsy;
13031303 src_y += firsttile_src_size_y;
@@ -1310,12 +1310,12 @@ LOCAL_libvideo_swblitter_stretch_rdwrap1(LOCAL_struct_video_blitter const *__res
13101310 video_dim_t wholetiles_src_size_y = src_size_y - lasttile_src_size_y;
13111311 video_coord_t base_src_y = src_y;
13121312 for (ywholetiles_i = 0 ; ywholetiles_i < ywholetiles_count; ++ywholetiles_i) {
1313- video_coord_t neyt_src_y ;
1314- neyt_src_y = base_src_y + (wholetiles_src_size_y * (ywholetiles_i + 1 )) / ywholetiles_count;
1315- LOCAL_stretch (out_y , out_y, 0 , dst_y , dst->vx_hdr .vxh_cysiz , dst_size_y ,
1316- src_y , src_y, neyt_src_y - src_y, src_size_y );
1317- out_y += (neyt_src_y - src_y);
1318- src_y = neyt_src_y ;
1313+ video_coord_t next_src_y ;
1314+ next_src_y = base_src_y + (wholetiles_src_size_y * (ywholetiles_i + 1 )) / ywholetiles_count;
1315+ LOCAL_stretch (out_x , out_y, dst_x, 0 , dst_size_x , dst->vx_hdr .vxh_cysiz ,
1316+ src_x , src_y, src_size_x, next_src_y - src_y);
1317+ out_y += (next_src_y - src_y);
1318+ src_y = next_src_y ;
13191319 }
13201320 dst_size_y %= dst->vx_hdr .vxh_cysiz ;
13211321 src_size_y = lasttile_src_size_y;
0 commit comments