If you wanted, you could make things fall back to a python-based RGBA_PREMULT conversion if the required function doesn't exist. We had such a function before, which I removed. Using it causes a significantly slower load time vs. using pygame's new 1.8.x feature.<br>
<br><br><div class="gmail_quote">On Tue, Oct 28, 2008 at 8:25 AM, James Paige <span dir="ltr"><<a href="mailto:Bob@hamsterrepublic.com" target="_blank">Bob@hamsterrepublic.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">It has 1.7.1release. Do we require 1.8.x now?<br>
<br>
---<br>
<font color="#888888">James<br>
</font><div><div></div><div><br>
On Mon, Oct 27, 2008 at 10:18:58PM -0700, Brian Fisher wrote:<br>
> That is a pygame version thing - what version of pygame is that box<br>
> running?<br>
><br>
> On Mon, Oct 27, 2008 at 10:04 AM, James Paige <<a href="mailto:Bob@hamsterrepublic.com" target="_blank">Bob@hamsterrepublic.com</a>><br>
> wrote:<br>
><br>
> When I try to run using revision 229, I get a crash in<br>
> GetLightOpacityStringForSurface where it says<br>
><br>
> return pygame.image.tostring(surface, "RGBA_PREMULT", True)<br>
> ValueError: Unrecognized type of format<br>
><br>
> Here is the full traceback<br>
><br>
> ---<br>
> James<br>
><br>
> james@doomtrain:~/src/mhgames/sidescroller$ python sidescroller.py<br>
> Failed to find asset camera of type <class 'movement.SpeedStyle'><br>
> Traceback (most recent call last):<br>
> File "sidescroller.py", line 105, in <module><br>
> game.run_game()<br>
> File "/usr/lib/python2.5/site-packages/motherhamster/hamsterwheel.py",<br>
> line 295, in run_game<br>
> self._draw()<br>
> File "/usr/lib/python2.5/site-packages/motherhamster/hamsterwheel.py",<br>
> line 336, in _draw<br>
> self.draw()<br>
> File "sidescroller.py", line 85, in draw<br>
> self.player.draw()<br>
> File "/home/james/src/mhgames/sidescroller/player.py", line 104, in<br>
> draw<br>
> self.display.render(body, pos, scale=scale)<br>
> File "/usr/lib/python2.5/site-packages/motherhamster/displayGL.py",<br>
> line 409, in render<br>
> self.pack_image(image)<br>
> File "/usr/lib/python2.5/site-packages/motherhamster/displayGL.py",<br>
> line 229, in pack_image<br>
> if pack.pack_image(image):<br>
> File "/usr/lib/python2.5/site-packages/motherhamster/displayGL.py",<br>
> line 127, in pack_image<br>
> pixels = GetLightOpacityStringForSurface(image.surface)<br>
> File "/usr/lib/python2.5/site-packages/motherhamster/displayGL.py",<br>
> line 33, in GetLightOpacityStringForSurface<br>
> return pygame.image.tostring(surface, "RGBA_PREMULT", True)<br>
> ValueError: Unrecognized type of format<br>
> _______________________________________________<br>
> Dev mailing list<br>
> <a href="mailto:Dev@lists.motherhamster.org" target="_blank">Dev@lists.motherhamster.org</a><br>
> <a href="http://lists.motherhamster.org/listinfo.cgi/dev-motherhamster.org" target="_blank">http://lists.motherhamster.org/listinfo.cgi/dev-motherhamster.org</a><br>
<br>
> _______________________________________________<br>
> Dev mailing list<br>
> <a href="mailto:Dev@lists.motherhamster.org" target="_blank">Dev@lists.motherhamster.org</a><br>
> <a href="http://lists.motherhamster.org/listinfo.cgi/dev-motherhamster.org" target="_blank">http://lists.motherhamster.org/listinfo.cgi/dev-motherhamster.org</a><br>
<br>
_______________________________________________<br>
Dev mailing list<br>
<a href="mailto:Dev@lists.motherhamster.org" target="_blank">Dev@lists.motherhamster.org</a><br>
<a href="http://lists.motherhamster.org/listinfo.cgi/dev-motherhamster.org" target="_blank">http://lists.motherhamster.org/listinfo.cgi/dev-motherhamster.org</a><br>
</div></div></blockquote></div><br>