0xdeadbeef Wrote: 
> Seems to work:
> http://lemmini.de/test.jpg
> 
> I tried also some scaling on my own:
> 
> use strict;
> use GD;
> 
> my $image = GD::Image->new(100, 100,1);
> $image->filledRectangle(0,0,100,100,0xff0000);
> $image->filledRectangle(30,30,70,70,0x0000ff);
> 
> my $image2 = GD::Image->new(200, 200,1);
> $image2->copyResized( $image, 0,0,0,0, 200, 200, 100, 100);
> 
> open (MYOUTFILE, ">test.jpg");
> binmode MYOUTFILE;
> print MYOUTFILE $image->jpeg();
> close MYOUTFILE;
> 
> open (MYOUTFILE, ">test2.jpg");
> binmode MYOUTFILE;
> print MYOUTFILE $image2->jpeg();
> close MYOUTFILE;
> 
> 
> This works as well:
> http://lemmini.de/test2.jpg
> 
> So why doesn't it work in Slimserver???

Under Win32, and I would assume on other platforms, SlimServer provides
a lot of its own versions of the CPAN modules, and binaries, and I
suspect that those aren't working for some reason.

Could you try the following, editting @INC to point to the appropriate
paths in your system and post the results.

Chris


use strict;
use Data::Dumper;

print Dumper([EMAIL PROTECTED]);

unshift @INC, 'C:\Documents and Settings\Chris\My
Documents\slim\trunk\server\CPAN\arch\5.8\MSWin32-x86-multi-thread';
unshift @INC, 'C:\Documents and Settings\Chris\My
Documents\slim\trunk\server\CPAN\arch\5.8\MSWin32-x86-multi-thread\auto';
unshift @INC, 'C:\Documents and Settings\Chris\My
Documents\slim\trunk\server\CPAN';

print Dumper([EMAIL PROTECTED]);

require GD;

print Dumper(\%INC);

my $image = GD::Image->new(100, 100,1);
$image->filledRectangle(0,0,100,100,0xff0000);
$image->filledRectangle(30,30,70,70,0x0000ff);

print "can jpeg\n" if GD::Image->can('jpeg');
print "can png\n" if GD::Image->can('png');

open (MYOUTFILE, ">test.jpg");
binmode MYOUTFILE;
print MYOUTFILE $image->jpeg();
close MYOUTFILE;


-- 
cjk32
------------------------------------------------------------------------
cjk32's Profile: http://forums.slimdevices.com/member.php?userid=5151
View this thread: http://forums.slimdevices.com/showthread.php?t=23206

_______________________________________________
beta mailing list
beta@lists.slimdevices.com
http://lists.slimdevices.com/lists/listinfo/beta

Reply via email to