diff options
Diffstat (limited to 'graphics/surface.cpp')
| -rw-r--r-- | graphics/surface.cpp | 5 | 
1 files changed, 5 insertions, 0 deletions
diff --git a/graphics/surface.cpp b/graphics/surface.cpp index a9f3e75886..263a4fd23b 100644 --- a/graphics/surface.cpp +++ b/graphics/surface.cpp @@ -66,6 +66,11 @@ void Surface::free() {  	bytesPerPixel = 0;  } +void Surface::copyFrom(const Surface &surf) { +	create(surf.w, surf.h, surf.bytesPerPixel); +	memcpy(pixels, surf.pixels, h * pitch); +} +  void Surface::hLine(int x, int y, int x2, uint32 color) {  	// Clipping  	if (y < 0 || y >= h)  | 
