[Scummvm-git-logs] scummvm master -> 6609c70fc0adf5fabbc220c257ef75ea9b25c736
mduggan
mgithub at guarana.org
Sun Apr 5 05:17:48 UTC 2020
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
6609c70fc0 ULTIMA8: Remove some unused code in SoftRenderSurface
Commit: 6609c70fc0adf5fabbc220c257ef75ea9b25c736
https://github.com/scummvm/scummvm/commit/6609c70fc0adf5fabbc220c257ef75ea9b25c736
Author: Matthew Duggan (mgithub at guarana.org)
Date: 2020-04-05T14:17:13+09:00
Commit Message:
ULTIMA8: Remove some unused code in SoftRenderSurface
Changed paths:
engines/ultima/ultima8/graphics/soft_render_surface.cpp
diff --git a/engines/ultima/ultima8/graphics/soft_render_surface.cpp b/engines/ultima/ultima8/graphics/soft_render_surface.cpp
index 1498ebc8f8..5b477c3b74 100644
--- a/engines/ultima/ultima8/graphics/soft_render_surface.cpp
+++ b/engines/ultima/ultima8/graphics/soft_render_surface.cpp
@@ -409,76 +409,6 @@ template<class uintX> void SoftRenderSurface<uintX>::Blit(Texture *_tex, int32 s
}
}
- /* Old complete code
- // Clamp or wrap or return?
- #ifndef BLIT_WRAP
- if (w > static_cast<int32>(_tex->w))
- #ifndef BLIT_CLIP
- return;
- #else
- w = _tex->w;
- #endif
-
- // Clamp or wrap or return?
- if (h > static_cast<int32>(_tex->_height))
- #ifndef BLIT_CLIP
- return;
- #else
- h = _tex->_height;
- #endif
- #endif
-
- // Clip to window
- int px = dx, py = dy;
- _clipWindow.IntersectOther(dx,dy,w,h);
- if (!w || !h) return;
-
- // Adjust source x and y
- if (px != dx) sx += dx - px;
- if (py != dy) sy += dy - py;
-
- uint8 *pixel = _pixels + dy * _pitch + dx * sizeof(uintX);
- uint8 *line_end = pixel + w*sizeof(uintX);
- uint8 *end = pixel + h * _pitch;
- int diff = _pitch - w*sizeof(uintX);
-
- uint32 *texel = _tex->_buffer + (sy * _tex->w + sx);
- #ifdef BLIT_WRAP
- uint32 *texel_line_start = _tex->_buffer + sy * _tex->w;
- uint32 *texel_line_end = _tex->_buffer + (sy+1) * _tex->w;
- uint32 *texel_col_start = _tex->_buffer + sx;
- uint32 *texel_col_end = _tex->_buffer + (_tex->_height * _tex->w + sx);
- #endif
- int tex_diff = _tex->w - w;
-
- //b = PACK_RGB8( (rgb>>16)&0xFF , (rgb>>8)&0xFF , rgb&0xFF );
-
- while (pixel != end)
- {
- while (pixel != line_end)
- {
- if (*texel & TEX32_A_MASK)
- {
- *(reinterpret_cast<uintX*>(pixel)) = static_cast<uintX>(PACK_RGB8( TEX32_R(*texel), TEX32_G(*texel), TEX32_B(*texel) ));
- }
- pixel+=sizeof(uintX);
- texel++;
- #ifdef BLIT_WRAP
- if (texel == texel_line_end) texel = texel_line_start;
- #endif
- }
-
- line_end += _pitch;
- pixel += diff;
- texel+= tex_diff;
- #ifdef BLIT_WRAP
- if (texel == texel_col_end) texel = texel_col_start;
- #endif
- }
-
- */
-
-
}
More information about the Scummvm-git-logs
mailing list