Refactor FrameBuffer blit/flip source.

Pass a surface to the blit/flip functions, instead of a raw pointer.
This puts the FrameBuffer in control of locking and unlocking.

Change-Id: I55335b3beef8d7083aae7687bd25392964261bde
Reviewed-on: https://swiftshader-review.googlesource.com/4482
Reviewed-by: Nicolas Capens <nicolascapens@google.com>
Tested-by: Nicolas Capens <nicolascapens@google.com>
diff --git a/src/Main/FrameBufferAndroid.hpp b/src/Main/FrameBufferAndroid.hpp
index 4400188..b71c32b 100644
--- a/src/Main/FrameBufferAndroid.hpp
+++ b/src/Main/FrameBufferAndroid.hpp
@@ -26,12 +26,12 @@
 	class FrameBufferAndroid : public FrameBuffer
 	{
 	public:
-		FrameBufferAndroid(ANativeWindow* window, int width, int height);
+		FrameBufferAndroid(ANativeWindow *window, int width, int height);
 
 		~FrameBufferAndroid() override;
 
-		void flip(void *source, Format sourceFormat, size_t sourceStride) override {blit(source, 0, 0, sourceFormat, sourceStride);};
-		void blit(void *source, const Rect *sourceRect, const Rect *destRect, Format sourceFormat, size_t sourceStride) override;
+		void flip(sw::Surface *source) override {blit(source, nullptr, nullptr);};
+		void blit(sw::Surface *source, const Rect *sourceRect, const Rect *destRect) override;
 
 		void *lock() override;
 		void unlock() override;
@@ -39,8 +39,8 @@
 		bool setSwapRectangle(int l, int t, int w, int h);
 
 	private:
-		ANativeWindow* nativeWindow;
-		ANativeWindowBuffer* buffer;
+		ANativeWindow *nativeWindow;
+		ANativeWindowBuffer *buffer;
 	};
 }