Re: [pygame] BUG: sprite refresh when using source_rect

2019-03-11 Thread Radomir Dopieralski
e left to the right side. The GetReady > sprite is not repainted right. > > [image: image.png] > > I attach the code to see the issue. > > > Best regards > > -- Radomir Dopieralski -- Radomir Dopieralski

Re: [pygame] How to do some action while a joystick is in motion?

2018-09-18 Thread Radomir Dopieralski
t; Or maybe there's a code sample that illustrates the best practice of > reading joystick states? > > Thanks for any help! -- Radomir Dopieralski -- Radomir Dopieralski

Re: [pygame] Cheap COW clones for surfaces

2018-06-18 Thread Radomir Dopieralski
2018 at 12:17, Daniel Pope wrote: > > > Pygame Zero programmers are not necessarily responsible or adults. > > Overall that idea would break several of our documented principles: > > > > http://pygame-zero.readthedocs.io/en/stable/principles.html > > > > > > O

Re: [pygame] Cheap COW clones for surfaces

2018-06-18 Thread Radomir Dopieralski
ing thread should handle all blits to the screen as well as > flip. But in a framework we cannot prevent users creating surfaces > and mutating them in the logic thread. > > On Mon, 18 Jun 2018, 09:55 Radomir Dopieralski, > wrote: > > > Them again, if you assume that the

Re: [pygame] Cheap COW clones for surfaces

2018-06-18 Thread Radomir Dopieralski
by the drawing thread in the same order in which they were scheduled — including the blits that modify your temporary surface with the digits. As long as all the modifications happen either on one side or the other, we are good. On Mon, 18 Jun 2018 01:09:16 +0200 Radomir Dopieralski wrote: > Oh, I thin

Re: [pygame] Cheap COW clones for surfaces

2018-06-17 Thread Radomir Dopieralski
xample, each font would be represented by a game object > that had a positional element, and you could add them to the map > asynchronous of the draws since the render thread would display them > on the next iteration of the render loop where they existed. > > > On Sun, Jun 17

Re: [pygame] Cheap COW clones for surfaces

2018-06-17 Thread Radomir Dopieralski
buffer copy actually happens at this line, if it is hit: > > surf_a.blit(surf_b, ...) > > Which means that there's 1 copy if cond is True and 0 if cond is > False. > > On Sun, 17 Jun 2018, 20:59 Radomir Dopieralski, > wrote: > > > On Sun, 17 Jun 2018 17:48:26 +0200 &g

Re: [pygame] Cheap COW clones for surfaces

2018-06-17 Thread Radomir Dopieralski
s the drawing thread is more than one frame behind (which really shouldn't happen), you don't care about the data changing. -- Radomir Dopieralski

Re: [pygame] Re: How much blit costs?

2017-06-15 Thread Radomir Dopieralski
em, and not blit them. -- Radomir Dopieralski -- Radomir Dopieralski

Re: blits proposal, was Re: [pygame] Dirty rect overlapping optimizations

2017-03-29 Thread Radomir Dopieralski
t;>> don't seem much value in watering it down or splitting it into > >>> multiple functions for beginners. No need to overthink and > >>> complicate it. Cython may help sprite rendering in Groups, but > >>> it would have to be implemented and tested. > &

Re: [pygame] Dirty rect overlapping optimizations

2017-03-27 Thread Radomir Dopieralski
rectangles even if they don't actually overlap, but simply touch. This would improve this use case (and a common use case of a tiled map) greatly. -- Radomir Dopieralski

Re: [pygame] teaching resources

2017-03-18 Thread Radomir Dopieralski
ive them? Or is that the place to send them? > (I'm not sure they'd be interested in Japanese/German/etc resources) > > > > > best, -- Radomir Dopieralski -- Radomir Dopieralski

Re: [pygame] New pygame.org website

2016-12-23 Thread Radomir Dopieralski
site themselves -- you have to use the tools that the project choose to contribute to that project, and in a pinch you can always send your patches by e-mail. But forcing all members of the PyGame community to become Github's customers somehow feels different. -- Radomir Dopieralski

Re: [pygame] New pygame.org website

2016-12-23 Thread Radomir Dopieralski
the simplest possible thing, and we can refine it and add bling if we have spare resources for that. As a side note, what are we going to do with the existing game list? Are we going to import/migrate it to the new website? -- Radomir Dopieralski

Re: [pygame] New pygame.org website

2016-12-18 Thread Radomir Dopieralski
Doc. Jinja templates are used for page > >>>> generation. > >>>> > >>>> On 16-12-17 02:26 PM, Thomas Kluyver wrote: > >>>> > >>>>> > >>>>> > >>>>> So far, I think the proposals for the static information part > >>>>> of the site are Nikola (a static site generator oriented around > >>>>> blogs) and Sphinx (oriented around docs). Both are written in > >>>>> Python. Does anyone want to make the case for any other system? > >>>>> > >>>>> > >>>> > > > > > > -- > > > > Linkedin <https://www.linkedin.com/in/charles-cosse> | E-Learning > > <http://www.asymptopia.org> > > > > > > -- Radomir Dopieralski -- Radomir Dopieralski

Re: [pygame] New pygame.org website

2016-12-17 Thread Radomir Dopieralski
;http://itch.io>, > > gamejolt) > > - [My thoughts: the general sources don't seem a great fit; > > it's rare to upload screenshots to these, and even if developers > > did, we would have to scrape them from free text. Pulling from game > > stores would mean games have to clear a much higher bar of > > quality and polish than many of the current entries on the feed. > > That is up for discussion, but I like the current amateur-friendly > > feel of the feed. If you just want polished games to play, it > > wouldn't matter that they're in Python] -- Radomir Dopieralski

Re: [pygame] New pygame.org website

2016-12-16 Thread Radomir Dopieralski
openhub.net now), which has some nice user interface and stats. I'm sure there are much more such services. On Fri, 16 Dec 2016 17:59:02 + Thomas Kluyver <tak...@gmail.com> wrote: > On 16 December 2016 at 10:12, Radomir Dopieralski > <pyg...@sheep.art.pl> wrote: > > >

Re: [pygame] New pygame.org website

2016-12-16 Thread Radomir Dopieralski
gs) >- > >We need to keep spam minimal, without making too much work for > either developers submitting their games, or the site maintainers. > E.g. we might use CAPTCHAs and nofollow links. >- > >If the game feed breaks, the information site should still be > available. - > >One obvious way to do this is with a small web app and a database > to hold the content. That’s possible, but it would need hosting and >maintenance. Are there other ways? What external services could we > use? Get creative! -- Radomir Dopieralski

Re: [pygame] pygame Event

2016-03-03 Thread Radomir Dopieralski
Thanks in advance for any help. > > http://pastebin.com/qfKg2bAe http://pastebin.com/KQN8Fpc8 No, that is not a bug. The Events don't have a __dict__ attribute. The attributes that events have are described in the documentation: http://pygame.org/docs/ref/event.html -- Radomir Dopieralski

Re: [pygame] image conversion in memory

2014-08-13 Thread Radomir Dopieralski
On 08/13/2014 04:35 PM, diliup gabadamudalige wrote: This is the complete and correct code. Can anyone say what;s wrong? Thanks in advance. import pygame import StringIO putimage = pygame.image.load(88keykbd.png) buff = StringIO.StringIO() buff.name http://buff.name = '88keykbd.png'

Re: [pygame] image conversion in memory

2014-08-11 Thread Radomir Dopieralski
On 08/11/2014 11:40 AM, diliup gabadamudalige wrote: get_screen = SCREEN.subsurface(0, 0, SCREENW, SCREENH) # grab the screen how can you concert get_screen to a jpeg or a png WITHOUT saving to disk? In Pygame.. I just told you. Use the example I gave you, it works. -- The Sheep

Re: [pygame] image conversion in memory

2014-08-11 Thread Radomir Dopieralski
On 08/11/2014 09:34 PM, diliup gabadamudalige wrote: Dear Radomir, s = pygame.image.load(88keykbd.png) f = StringIO.StringIO() f.name http://f.name = '88keykbd.jpg' pygame.image.save(s, f) pygame.image.load(88keykbd.jpg) yourimage = f.getvalue() why does the line

Re: [pygame] image conversion in memory

2014-08-11 Thread Radomir Dopieralski
On 08/11/2014 09:53 PM, diliup gabadamudalige wrote: type(f) gives type 'instance' yourimage = f.getvalue() with open('myscrambledimage.dat', 'w') as f: f.write(yourimage) so i coukld write this file to disk now how can i convert this back to an image? Thanks in advance What are you

Fwd: Re: [pygame] image conversion in memory

2014-08-10 Thread Radomir Dopieralski
of a file. import pygame import StringIO s = pygame.image.load(yourimage.png) f = StringIO.StringIO() f.name = 'yourimage.jpg' pygame.image.save(s, f) yourimage = f.getvalue() -- Radomir Dopieralski

Re: [pygame] Complicated Blitting Order Issue

2013-06-16 Thread Radomir Dopieralski
, it attempts to remove it. The remaning head problem can be seen clearly from just running this for a few seconds. Any code change advice is hugely welcomed here! On 16 June 2013 12:30, Radomir Dopieralski pyg...@sheep.art.pl wrote: The trick is no not redraw the neighboring tiles in whole, but just

Re: [pygame] Using bitbucket to host latest Pygame docs in the repository

2013-05-29 Thread Radomir Dopieralski
It looks like a handy place to have the latest document builds when the Spectacularly Adequate Automated Pygame Build Page is up and running again. I would like to give it a try. Lenard Lindstrom -- Radomir Dopieralski, http://sheep.art.pl

Re: [pygame] BUG: reproducible hard hang (i.e. SIGKILL only) in pygame!

2013-04-06 Thread Radomir Dopieralski
to send the same bug report to the smpeg people. :-) Steven Boswell -- Radomir Dopieralski, http://sheep.art.pl

Re: [pygame] hello and looking to help out

2013-03-28 Thread Radomir Dopieralski
. -- Radomir Dopieralski, http://sheep.art.pl

Re: [pygame] Loading files from .tar

2013-02-24 Thread Radomir Dopieralski
this before? Yes, although it's much easier using a zip file. I described my method at http://sheep.art.pl/Your%20Python%20Application%20as%20a%20Single%20File -- Radomir Dopieralski, http://sheep.art.pl

Re: [pygame] PYGAME EXE runtime or segmentation error

2013-02-07 Thread Radomir Dopieralski
You can try to strategically place a couple of print statements to see where exactly it is crashing. My bet is the font loading code, as I had problems with that on Windows before, but it's hard to say anything before you actually have a minimal working example. -- Radomir Dopieralski, http

Re: [pygame] PYGAME EXE runtime or segmentation error

2013-02-07 Thread Radomir Dopieralski
On Thu, Feb 7, 2013 at 3:49 PM, Radomir Dopieralski pyg...@sheep.art.pl wrote: You can try to strategically place a couple of print statements to see where exactly it is crashing. My bet is the font loading code, as I had problems with that on Windows before, but it's hard to say anything

Re: [pygame] PyGame website

2012-12-28 Thread Radomir Dopieralski
the relevant code and configuration in the publicly available repositories whenever possible is one thing that would help, for example. -- Radomir Dopieralski, http://sheep.art.pl

Re: [pygame] PyGame website

2012-12-01 Thread Radomir Dopieralski
improvement. If anybody has any better information or ideas, I'd love to hear them. Sorry if this all sounds negative, I'm sure this situation didn't arise because of malice or bad will. But it still hurts to see people wanting to help and being unable to do it. -- Radomir Dopieralski, http

Re: [pygame] PyGame website

2012-11-29 Thread Radomir Dopieralski
. The changes here are quite minimal - I've left the main layout and the colour scheme the same, but tried to make it a bit less crowded. I didn't think it should look too serious. All excellent ideas and I support you in whole. What now? -- Radomir Dopieralski, http://sheep.art.pl

Re: [pygame] PyGame website

2012-11-29 Thread Radomir Dopieralski
you have any plans of how to get access to the website? -- Radomir Dopieralski, http://sheep.art.pl

Re: [pygame] [Pygame] Smooth Animation

2012-11-22 Thread Radomir Dopieralski
feet are sliding on the ground... -- Radomir Dopieralski, http://sheep.art.pl

Re: [pygame] Converting my game into deb package

2012-11-18 Thread Radomir Dopieralski
but unable to find out a good help. Please help me. I really want to do it. You may find this page helpful: https://wiki.ubuntu.com/PackagingGuide/Python -- Radomir Dopieralski, http://sheep.art.pl

Re: [pygame] [Pygame] Tileset Animation

2012-11-14 Thread Radomir Dopieralski
. https://ep2012.europython.eu/conference/talks/hands-on-with-pygame (I will be running an improved version of that tutorial in March on PyCon.US, *if* they accept it) -- Radomir Dopieralski, http://sheep.art.pl

Re: [pygame] PIP

2012-10-22 Thread Radomir Dopieralski
On Mon, Oct 22, 2012 at 11:43 AM, Michiel Overtoom mot...@xs4all.nl wrote: On Oct 22, 2012, at 01:44, Richard Jones wrote: [snip] There was a bug in pip that has been fixed some time ago. Get a new version of pip and try again. -- Radomir Dopieralski, http://sheep.art.pl

Re: [pygame] Redesigning the pygame.org website

2012-09-18 Thread Radomir Dopieralski
. There is no wiki? -- Radomir Dopieralski

Re: [pygame] Redesigning the pygame.org website

2012-09-18 Thread Radomir Dopieralski
. I can help with that too, you know, I made Hatta Wiki, which is a wiki based on Mercurial, so I have some experience with that. -- Radomir Dopieralski, http://sheep.art.pl

Re: [pygame] Redesigning the pygame.org website

2012-09-18 Thread Radomir Dopieralski
. How do I find the 'homebrew' project? The google search on the pygame.org website doesn't find anything relevant. -- Radomir Dopieralski, http://sheep.art.pl

Re: [pygame] Redesigning the pygame.org website

2012-09-17 Thread Radomir Dopieralski
. Personally, I'm a great fan of gradual improvements and small changes -- starting with fixing what is broken -- instead of a huge redesign. Even if it never gets finished, there are immediate benefits. -- Radomir Dopieralski

Re: [pygame] Redesigning the pygame.org website

2012-09-17 Thread Radomir Dopieralski
it is not a small task. -- Radomir Dopieralski

Re: [pygame] Easy networking module - feedback needed

2012-06-21 Thread Radomir Dopieralski
it for several connections. What do you think? -- Radomir Dopieralski

Re: [pygame] Resetting display

2012-05-08 Thread Radomir Dopieralski
On Tue, May 8, 2012 at 11:12 AM, Bartosz Debski bart...@debski.co.uk wrote: toggle_fullscreen will work only under X11. I didn't know you could run pygame outside of X11. [...] -- Radomir Dopieralski

Re: [pygame] Best practices for creating multiple resolution 2D pixel-art games?

2012-04-05 Thread Radomir Dopieralski
(like the icons on the map). You will usually want to mix and match these in your actual games. -- Radomir Dopieralski

Re: [pygame] Resetting display

2012-04-04 Thread Radomir Dopieralski
that? Is that possible? Yes. http://www.pygame.org/docs/ref/display.html#pygame.display.toggle_fullscreen -- Radomir Dopieralski

Re: [pygame] HELP PLEASE: sprite collision - object not iterable error

2012-02-21 Thread Radomir Dopieralski
On Tue, Feb 21, 2012 at 02:47, sc...@scottolling.com sc...@scottolling.com wrote: We're having a problem with the code below, which is returning this error: player = Player('Player.png', [10,10], [50, 50]) monster = Monster('Monster.png', [7,5], [7,5]) MGroup = pygame.sprite.Group(monster)

Re: [pygame] Capturing Multiple Keyboard Inputs

2012-01-16 Thread Radomir Dopieralski
On Mon, Jan 16, 2012 at 20:22, Silver rockac...@gmail.com wrote: On 1/15/2012 8:16 PM, Ian Mallett wrote: On Sun, Jan 15, 2012 at 7:46 PM, Ryan Strunk ryan.str...@gmail.com wrote: Hello everyone, I am testing my understanding of the pygame.key module by creating a program that pans the

Re: [pygame] Segfault on loading font from StringIO

2012-01-07 Thread Radomir Dopieralski
On Wed, Jan 4, 2012 at 05:56, Lenard Lindstrom le...@telus.net wrote: Hi, On 02/01/12 05:45 AM, Radomir Dopieralski wrote: I think that this comment is related to this problem: http://archives.seul.org/pygame/users/Jan-2004/msg00035.html No, this is a different problem. pygame.font.Font

Re: [pygame] Segfault on loading font from StringIO

2012-01-02 Thread Radomir Dopieralski
could be altered to accept a file object. The SDL API spec for FromFile relies on a filename, however, and FromFile does the opening of the file itself using that. Russell On 1 January 2012 10:50, Radomir Dopieralski pyg...@sheep.art.pl wrote: Hello everyone, I'm having a problem loading

[pygame] Segfault on loading font from StringIO

2012-01-01 Thread Radomir Dopieralski
, -- Radomir Dopieralski