X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=pages%2Fblog-0020.html-inc;h=ab2aa111a72fbea192ce8bcf232e511d6569aa57;hb=c8ad4fe9f211e727310a1ce6d23ffb1d7822d71f;hp=f5d4032823b6c03d8dddcead7217e725791e5374;hpb=c59d9ab1a32a69fcdb54ab78e21e31ee26d88e7a;p=sdlgit%2FSDL-Site.git diff --git a/pages/blog-0020.html-inc b/pages/blog-0020.html-inc index f5d4032..ab2aa11 100644 --- a/pages/blog-0020.html-inc +++ b/pages/blog-0020.html-inc @@ -1,26 +1,17 @@

-The beginnings of modular design for SDL Perl +SDL Perl Documentation: Reviewers need

-
“Do or do not... there is no try.”
-
--yoda
-
-

The design before


-The bindings before were all in one huge XS file. This was then exported into the SDL module. This means that the XS file has to handle with macros if any component (e.x SDL_Mixer) is not compiled. Moreover having ever binding in one XS file prevents use to treat C structs as object with only one point of free and malloc. This would be BEGIN and DESTROY in Perl. Also the monolithic design introduces a lot of bugs because we have to use free and malloc all over the place. Lastly SDL monolithic design has the constructor for all structs in both Perl and in XS.
-
-

The design we are aiming for

Simple one XS per Module. This would also simplify the Build code.
-
-

First Step


-We have began with SDL Rect. It is in github master branch now. We are in the progress of making it back compatible. Originally SDL::Rect took named variables as parameters for new(). Now since the constructor is in XS we have only unnamed parameters.
-
-
-

Before


-SDL::Rect->new( -x => 0, -y => 0, -width => 0, -height => 0);
-
-

After


-SDL::Rect->new(0, 0, 0, 0);
-
-Ideally we would like both ways of constructing Rect. -


-

\ No newline at end of file +

+The written word,
+survives;
+the tests of Time,
+the fires of Hades,
+and wrath of Pluto.
+

+

+

Documentation

In an effort to learn from past versions of SDL Perl and improve. We have been writing lots of documentation for our users. Of course since this is the first time we have been providing documentation we need your help. Please review our docs, at sdl.perl.org and give us some feed back. Send us the feeback at sdl-devel@mail.org or join us at #sdl irc.perl.org


+--yapgh
+


+

\ No newline at end of file