X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=pages%2FSDL-GFX-Primitives.html-inc;h=bee6fd4355ff0ffe67457c55b4104da2f59dc4ad;hb=c8ad4fe9f211e727310a1ce6d23ffb1d7822d71f;hp=8a79d22b541c158677edc147308e74cbeb301bfa;hpb=c256636b7bb9431b6605429e3f793859c6983842;p=sdlgit%2FSDL-Site.git diff --git a/pages/SDL-GFX-Primitives.html-inc b/pages/SDL-GFX-Primitives.html-inc index 8a79d22..bee6fd4 100644 --- a/pages/SDL-GFX-Primitives.html-inc +++ b/pages/SDL-GFX-Primitives.html-inc @@ -49,12 +49,14 @@

CATEGORY

Top

-

GFX, Primitives

+

GFX

DESCRIPTION

Top

-

All color values for the _color functions are 0xRRGGBBAA (32bit), even if the surface uses e. g. 8bit colors.

+

All functions take an SDL::Surface object as first parameter. This can be a new surface that will be blittet afterwads, can be an surface +obtained by SDL::Video::set_video_mode or can be an SDLx::App.

+

The color values for the _color functions are 0xRRGGBBAA (32bit), even if the surface uses e. g. 8bit colors.

METHODS

Top

@@ -73,10 +75,10 @@ use SDL::Surface; use SDL::GFX::Primitives; - my $display = SDL::Video::set_video_mode(640, 480, 32, SDL_SWSURFACE); + my $surface = SDL::Video::set_video_mode(640, 480, 32, SDL_SWSURFACE); - SDL::GFX::Primitives::pixel_color($display, 2, 2, 0xFF0000FF); # red pixcel - SDL::GFX::Primitives::pixel_RGBA( $display, 4, 4, 0x00, 0xFF, 0x00, 0xFF); # green pixel + SDL::GFX::Primitives::pixel_color($surface, 2, 2, 0xFF0000FF); # red pixcel + SDL::GFX::Primitives::pixel_RGBA( $surface, 4, 4, 0x00, 0xFF, 0x00, 0xFF); # green pixel