[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] gsoc: pygamedraw - status update



Lorenz Quack wrote:
Hey,

I have to agree with the other comments. it's really looking good so far!

Thanks.


On 06/17/2010 06:05 PM, jug wrote:
Hello,

I'd like to give you a short status report of the pygamedraw gsoc project.
I've implemented the main class structure and basic drawing methods, so
its already usable:

[...]
If you have any ideas for further Pen classes please tell me.
[...]
> Regards,
> Julian
>

I just thought that it *might* be useful to have an attribute "style" or something like that which can be set to "SOLID", "DOTTED" or "DASHED" in analogy to the css attribute border-style [1].
I don't think this is a top priority item but might be nice to have.

keep up the good work

//Lorenz

[1] http://www.tizag.com/cssT/border.php


Yes, I also had this idea of line styles or some kind of orientation that could be passed to the drawing algorithm but this is not that easy due to the generic implementation via masks. However its on my "ideas that would be cool to have and may be implemented later
if I have some time left"-list :)

Luke Paireepinart wrote:
Hey, I'm in need of some fast drawing functions that can correctly
paint brush strokes... eg. if I draw a series of points 1px apart,with
alpha, is it going to look like a bunch of overlapping circles, or is
it going to look like a thick line of the correct alpha value?

By default it will look like a bunch of overlapping circles as this is the
normally expected behavior. However you could prevent this by activating
multi-part drawing. This means, that the (mask of the) last drawn shape is
removed from the (mask of the) next shape.
(note that this is not completely implemented yet.)

Also, these are implemented in pure Python?  How fast are they?  do
they do a lot of work in Python or is most of it done in existing SDL
code or something?

Currently its all done in pure Python. Since this is a rewrite of the
current modules that are only wrappers around the SDL functions
I do not use any SDL drawing routines.  This is why it is not fast
at all now, but its just a prototyping and we plan to port the critical
parts to C at the end.

And how can I test this out?  Do I just install Pygame Reloaded and
then add this to my project folder and import it?

Yes. You need pygame2 installed and the "lib" folder in the pygamedraw
project dir on your python part. Then you can do
"from lib.solidpen import SolidPen" and so on. Have a look at the example
at ./examples/allinone.py.

Regards,
Julian