Author: Lars Wassermann <[email protected]>
Branch:
Changeset: r469:d5040bb62aaf
Date: 2013-06-20 13:04 +0200
http://bitbucket.org/pypy/lang-smalltalk/changeset/d5040bb62aaf/
Log: added convert_to_c_layout to W_DisplayBitmap removing the
(now wrongful) caching is still pending
diff --git a/spyvm/interpreter_proxy.py b/spyvm/interpreter_proxy.py
--- a/spyvm/interpreter_proxy.py
+++ b/spyvm/interpreter_proxy.py
@@ -247,6 +247,8 @@
return w_object.convert_to_c_layout()
elif isinstance(w_object, model.W_BytesObject):
return rffi.cast(sqIntArrayPtr, w_object.convert_to_c_layout())
+ elif isinstance(w_object, model.W_DisplayBitmap):
+ return rffi.cast(sqIntArrayPtr, w_object.convert_to_c_layout())
else:
raise ProxyFunctionFailed
diff --git a/spyvm/model.py b/spyvm/model.py
--- a/spyvm/model.py
+++ b/spyvm/model.py
@@ -998,6 +998,9 @@
def is_array_object(self):
return True
+ def convert_to_c_layout(self):
+ return self.pixelbuffer
+
class W_DisplayBitmap1Bit(W_DisplayBitmap):
def getword(self, n):
return self._real_depth_buffer[n]
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit