Hi, Running Strawberry Perl on Win 7 x64 I have installed SDL and Alien::SDL from CPAN (selecting option 1) and I'm writing a twin stick shooter game for fun. I have three questions:
1) When rotating sprites using the ->rotation() method the sprites often get a line of "artifact noise" along one of the sides, usually the right and/or bottom edge of the original sprite. The effect is not constant and the original sprites are all 100% transparent at the edges so I believe the artifacts are introduced by the rotation algorithm. Or is it? 2) After experimenting with different sprite sizes, it seems that there's a limit somewhere. When attempting to load a sprite that's too large, I get a seemingly valid sprite object that just doesn't seem to render anything. Is there a known size limit to sprites or could this be a driver issue? Or am I overlooking something? 3) How exactly does the 'alpha_key' property work? I tried setting it to the ubiquitous bright purple (FF00FF) but this just caused half my sprites to become completely invisible. When using PNG files with an alpha channel, using a key color seems pointless to me, which makes the POD example code somewhat confusing: # spawning can include almost all of the above: my $sprite = SDLx::Sprite->new( image => 'hero.png', # or surface => SDL::Surface rect => SDL::Rect, # or x => $x, y => $y clip => SDL::Rect, alpha_key => SDL::Color, # or [$r, $g, $b] alpha => 1, rotation => 45, # degrees ); If anyone is interested in a sneak peek, here's the code: http://floyd.atc.no/Programming/Perl/IfItMoves/2012-04-23.zip Suggestions are welcome :-) -- Andreas Lund (fl...@atc.no) Tel: +47 90077162 #include <disclaimer.h> "Look at you hacker, panting and sweating as you run through my corridors. How can you challenge a perfect immortal machine?" -- SHODAN, System Shock