[Perl-win32-gui-cvscommit] Win32-GUI-DIBitmap/extlib - New directory
Update of /cvsroot/perl-win32-gui/Win32-GUI-DIBitmap/extlib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31922/extlib Log Message: Directory /cvsroot/perl-win32-gui/Win32-GUI-DIBitmap/extlib added to the repository
[Perl-win32-gui-cvscommit] Win32-GUI-DIBitmap/samples - New directory
Update of /cvsroot/perl-win32-gui/Win32-GUI-DIBitmap/samples In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31922/samples Log Message: Directory /cvsroot/perl-win32-gui/Win32-GUI-DIBitmap/samples added to the repository
[Perl-win32-gui-cvscommit] Win32-GUI-DIBitmap/samples/bmp - New directory
Update of /cvsroot/perl-win32-gui/Win32-GUI-DIBitmap/samples/bmp In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32021/bmp Log Message: Directory /cvsroot/perl-win32-gui/Win32-GUI-DIBitmap/samples/bmp added to the repository
[Perl-win32-gui-cvscommit] Win32-GUI-DIBitmap/samples/bmp 1.bmp,NONE,1.1 1.png,NONE,1.1 1.tga,NONE,1.1 2.bmp,NONE,1.1 2.png,NONE,1.1 2.tga,NONE,1.1 3.bmp,NONE,1.1 3.png,NONE,1.1 3.tga,NONE,1.1 4.bmp,N
Update of /cvsroot/perl-win32-gui/Win32-GUI-DIBitmap/samples/bmp In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32157/samples/bmp Added Files: 1.bmp 1.png 1.tga 2.bmp 2.png 2.tga 3.bmp 3.png 3.tga 4.bmp 4.png 4.tga 5.bmp 5.png 5.tga Zapotec.JPG Zapotec.bmp small.tga Log Message: Added to repository --- NEW FILE: 1.bmp --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 4.bmp --- (This appears to be a binary file; contents omitted.) --- NEW FILE: small.tga --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 4.tga --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 2.bmp --- (This appears to be a binary file; contents omitted.) --- NEW FILE: Zapotec.JPG --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 1.tga --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 5.bmp --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 2.png --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 3.png --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 5.tga --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 2.tga --- (This appears to be a binary file; contents omitted.) --- NEW FILE: Zapotec.bmp --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 4.png --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 5.png --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 3.tga --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 1.png --- (This appears to be a binary file; contents omitted.) --- NEW FILE: 3.bmp --- (This appears to be a binary file; contents omitted.)
[Perl-win32-gui-cvscommit] Win32-GUI-DIBitmap/extlib FreeImage.h,NONE,1.1 FreeImage.lib,NONE,1.1 Readme.txt,NONE,1.1
Update of /cvsroot/perl-win32-gui/Win32-GUI-DIBitmap/extlib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32157/extlib Added Files: FreeImage.h FreeImage.lib Readme.txt Log Message: Added to repository --- NEW FILE: FreeImage.h --- // == // FreeImage 3 // // Design and implementation by // - Floris van den Berg ([EMAIL PROTECTED]) // - Hervé Drolon ([EMAIL PROTECTED]) // // Contributors: // - Adam Gates ([EMAIL PROTECTED]) // - Alex Kwak // - Alexander Dymerets ([EMAIL PROTECTED]) // - Detlev Vendt ([EMAIL PROTECTED]) // - Jan L. Nauta ([EMAIL PROTECTED]) // - Jani Kajala ([EMAIL PROTECTED]) // - Juergen Riecker ([EMAIL PROTECTED]) // - Karl-Heinz Bussian ([EMAIL PROTECTED]) // - Laurent Rocher ([EMAIL PROTECTED]) // - Luca Piergentili ([EMAIL PROTECTED]) // - Machiel ten Brinke ([EMAIL PROTECTED]) // - Markus Loibl ([EMAIL PROTECTED]) // - Martin Weber ([EMAIL PROTECTED]) // - Matthias Wandel ([EMAIL PROTECTED]) // - Michal Novotny ([EMAIL PROTECTED]) // - Petr Pytelka ([EMAIL PROTECTED]) // - Riley McNiff ([EMAIL PROTECTED]) // - Ryan Rubley ([EMAIL PROTECTED]) // - Volker Gärtner ([EMAIL PROTECTED]) // // This file is part of FreeImage 3 // // COVERED CODE IS PROVIDED UNDER THIS LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTY // OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, WITHOUT LIMITATION, WARRANTIES // THAT THE COVERED CODE IS FREE OF DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE // OR NON-INFRINGING. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE COVERED // CODE IS WITH YOU. SHOULD ANY COVERED CODE PROVE DEFECTIVE IN ANY RESPECT, YOU (NOT // THE INITIAL DEVELOPER OR ANY OTHER CONTRIBUTOR) ASSUME THE COST OF ANY NECESSARY // SERVICING, REPAIR OR CORRECTION. THIS DISCLAIMER OF WARRANTY CONSTITUTES AN ESSENTIAL // PART OF THIS LICENSE. NO USE OF ANY COVERED CODE IS AUTHORIZED HEREUNDER EXCEPT UNDER // THIS DISCLAIMER. // // Use at your own risk! // == #ifndef FREEIMAGE_H #define FREEIMAGE_H // Version information -- #define FREEIMAGE_MAJOR_VERSION 3 #define FREEIMAGE_MINOR_VERSION 5 #define FREEIMAGE_RELEASE_SERIAL 1 // Compiler options - #if defined(FREEIMAGE_LIB) || !(defined(WIN32) || defined(__WIN32__)) #define DLL_API #define DLL_CALLCONV #else #ifdef __MINGW32__ // prevents a bug in mingw32 #include #endif // __MINGW32__ #define DLL_CALLCONV __stdcall // The following ifdef block is the standard way of creating macros which make exporting // from a DLL simpler. All files within this DLL are compiled with the FREEIMAGE_EXPORTS // symbol defined on the command line. this symbol should not be defined on any project // that uses this DLL. This way any other project whose source files include this file see // DLL_API functions as being imported from a DLL, wheras this DLL sees symbols // defined with this macro as being exported. #ifdef FREEIMAGE_EXPORTS #define DLL_API __declspec(dllexport) #else #define DLL_API __declspec(dllimport) #endif // FREEIMAGE_EXPORTS #endif // FREEIMAGE_LIB || !WIN32 // Some versions of gcc may have BYTE_ORDER or __BYTE_ORDER defined // If your big endian system isn't being detected, add an OS specific check #if (defined(BYTE_ORDER) && BYTE_ORDER==BIG_ENDIAN) || \ (defined(__BYTE_ORDER) && __BYTE_ORDER==__BIG_ENDIAN) || \ defined(__APPLE__) #define FREEIMAGE_BIGENDIAN #endif // BYTE_ORDER // Ensure 4-byte enums if we're using Borland C++ compilers #if defined(__BORLANDC__) #pragma option push -b #endif // For C compatility #ifdef __cplusplus #define FI_DEFAULT(x) = x #define FI_ENUM(x) enum x #define FI_STRUCT(x)struct x #else #define FI_DEFAULT(x) #define FI_ENUM(x) typedef int x; enum x #define FI_STRUCT(x)typedef struct x x; struct x #endif // Bitmap types - FI_STRUCT (FIBITMAP) { void *data; }; FI_STRUCT (FIMULTIBITMAP) { void *data; }; // Types used in the library (directly copied from Windows) - #ifndef _WINDOWS_ #define _WINDOWS_ #ifndef FALSE #define FALSE 0 #endif #ifndef TRUE #define TRUE 1 #endif #ifndef NULL #define NULL 0 #endif #ifndef SEEK_SET #define SEEK_SET 0 #define SEEK_CUR 1 #define SEEK_END 2 #endif #ifndef __MINGW32__ // prevents a bug in mingw32 typedef long BOOL; typedef unsigned char BYTE; typedef unsigned short WORD; typedef unsigned long DWORD; typedef long LONG; #if (defined(WIN32) || defined(__WIN32__)) #pragma pack(push, 1) #else #pragma pack(1) #endif // WIN32 typedef struct tagRGBQUAD { #ifdef FREEIMAGE_BIGENDIAN BYTE rgbRed; BYTE rgbGreen; BYTE rgbBlue; #else BYTE rgbBlue; BYTE rgbGreen; BYTE rgbRed; #endif // FREEIMAGE_BIGENDIAN BYTE
[Perl-win32-gui-cvscommit] Win32-GUI-DIBitmap Changes,NONE,1.1 DIBitmap.html,NONE,1.1 DIBitmap.pm,NONE,1.1 DIBitmap.xs,NONE,1.1 MANIFEST,NONE,1.1 Makefile.PL,NONE,1.1 Readme,NONE,1.1 TYPEMAP,NONE,1.1
Update of /cvsroot/perl-win32-gui/Win32-GUI-DIBitmap In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32157 Added Files: Changes DIBitmap.html DIBitmap.pm DIBitmap.xs MANIFEST Makefile.PL Readme TYPEMAP Log Message: Added to repository --- NEW FILE: Makefile.PL --- use ExtUtils::MakeMaker; # See lib/ExtUtils/MakeMaker.pm for details of how to influence # the contents of the Makefile that is written. WriteMakefile( 'NAME' => 'Win32::GUI::DIBitmap', 'VERSION_FROM' => 'DIBitmap.pm', 'XS' => { 'DIBitmap.xs' => 'DIBitmap.cpp' }, 'LIBS' => ['Msvcprt.lib'], # e.g., '-lm' 'DEFINE'=> '', # e.g., '-DHAVE_SOMETHING' 'INC' => '', # e.g., '-I/usr/include/other' 'MYEXTLIB' => 'extlib/FreeImage.lib', ($] ge '5.005') ? ( 'AUTHOR' => 'ROCHER Laurent ([EMAIL PROTECTED])', 'ABSTRACT' => 'Add new load/save image format and some image manipulation', ) : (), ); sub MY::xs_c { ' .xs.c: $(PERL) -I$(PERL_ARCHLIB) -I$(PERL_LIB) $(XSUBPP) $(XSPROTOARG) $(XSUBPPARGS) $*.xs > $*.c .xs.cpp: $(PERL) -I$(PERL_ARCHLIB) -I$(PERL_LIB) $(XSUBPP) $(XSPROTOARG) $(XSUBPPARGS) $*.xs > $*.cpp '; } --- NEW FILE: DIBitmap.html --- DIBitmap.pm mailto:";> NAME SYNOPSIS DESCRIPTION PACKAGE FUNCTIONS FreeImage Library Info functions FIF functions FIF info functions Colors functions DIBITMAP OBJECT DIBitmap New methods DIBitmap Save methods DIBitmap information methods DIBitmap and GD DIBitmap Pixels and Background methods DIBitmap Convertion methods DIBitmap Rotating and flipping DIBitmap UpSampling / DownSampling DIBitmap Color manipulation DIBitmap Channel methods DIBitmap Copy/Paste methods DIBitmap Devise Context methods MDIBITMAP OBJECT MDIBitmap New methods MDIBitmap Get methods MDIBitmap Lock methods MDIBitmap Edit methods AUTHOR SEE ALSO NAME Win32::GUI::DIBitmap add new reading/writing bitmap formats to Win32::GUI and some image manipulation. SYNOPSIS use Win32::GUI; use Win32::GUI::DIBitmap; $W = new Win32::GUI::Window ( -title=> "Win32::GUI::DIBitmap test", -pos => [100, 100], -size => [400, 400], -name => "Window", ); $dib = newFromFile Win32::GUI::DIBitmap ('image.jpg'); $hbitmap = $dib->ConvertToBitmap(); undef $dib; $W->AddButton ( -pos => [100, 100], -size=> [200, 200], -bitmap => $hbitmap, -name=> "Button", -visible => 1, ); $W->Show(); Win32::GUI::Dialog(); sub Window_Terminate { -1 } DESCRIPTION Win32::GUI::DIBitmap add new reading/writing bitmap formats to Win32::GUI and some image manipulation. This package use FreeImage 3.5.1, an open source image library supporting all common bitmap formats (visit : http://freeimage.sourceforge.net/";>http://freeimage.sourceforge.net/ ). Supports many formats, such as: Format Reading Writing Description BMP Y Y Windows or OS/2 Bitmap [Export = 1 4 8 16 24 32] ICO Y Y Windows Icon [Export = 1 4 8 16 24 32] JPEGY Y JPEG - JFIF Compliant [Export = 8 24] JNG Y N JPEG Network Graphics KOALA Y N C64 Koala Graphics IFF Y N IFF Interleaved Bitmap MNG Y N Multiple Network Graphics PBM Y Y Portable Bitmap (ASCII) [Export = 1 8 24] PBMRAW Y Y Portable Bitmap (RAW) [Export = 1 8 24] PCD Y N Kodak PhotoCD PCX Y N Zsoft Paintbrush PGM Y Y Portable Greymap (ASCII) [Export = 1 8 24] PGMRAW Y Y Portable Greymap (RAW) [Export = 1 8 24] PNG Y Y Portable Network Graphics [Export = 1 4 8 24 32] PPM Y Y Portable Pixelmap (ASCII) [Export = 1 8 24] PPMRAW Y Y Portable Pixelmap (RAW) [Export = 1 8 24] RAS Y N Sun Raster Image TARGA Y Y Truevision Targa [Export = 8 16 24 32] TIFFY Y Tagged Image File Format [Export = 1 4 8 24 32] WBMPY Y Wireless Bitmap [Export = 1] PSD Y N Adobe Photoshop CUT Y N Dr. Halo XBM Y N X11 Bitmap Format XPM Y Y X11 Pixmap Format [Export = 8 24] DDS Y N DirectX Surface GIF Y Y Graphics Interchange Format [Export = 8] FreeImage can handle multi-page file
[Perl-win32-gui-cvscommit] Win32-GUI-DIBitmap/samples INFO2.PL,NONE,1.1 Zapotec.zip,NONE,1.1 demo.pl,NONE,1.1 demo2.pl,NONE,1.1 info.pl,NONE,1.1 piv.pl,NONE,1.1 test1.pl,NONE,1.1 test10.pl,NONE,1.1 te
Update of /cvsroot/perl-win32-gui/Win32-GUI-DIBitmap/samples In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32157/samples Added Files: INFO2.PL Zapotec.zip demo.pl demo2.pl info.pl piv.pl test1.pl test10.pl test11.pl test12.pl test13.pl test14.pl test15.pl test2.pl test3.pl test4.pl test5.pl test6.pl test7.pl test8.pl test9.pl zipimage.PL Log Message: Added to repository --- NEW FILE: test11.pl --- #perl -w # # Test with Win32::GUI # # Functions Test : #- newFromBitmap #- CopyToDC #- AlphaCopyToDC #- AlphaStretchToDC use Win32::GUI; use Win32::GUI::DIBitmap; $W = new Win32::GUI::Window ( -title=> "Win32::GUI::DIBitmap test", -left => 100, -top => 100, -width=> 400, -height => 400, -name => "Window", ) or die "new Window"; $dib = newFromFile Win32::GUI::DIBitmap ('bmp/zapotec.bmp') or die "newFromFile"; $dibalpha = newFromFile Win32::GUI::DIBitmap ('bmp/small.tga') or die "newFromFile"; print "transparent : ", $dibalpha->IsTransaparent(), "\n"; print "BPP : ", $dibalpha->GetBPP(), "\n"; $W->Show(); Win32::GUI::Dialog(); sub Window_Resize { Paint(); } sub Window_Activate { Paint(); } sub Window_Terminate { $W->PostQuitMessage(0); } sub Paint { ($width, $height) = ($W->GetClientRect)[2..3]; $dc = new Win32::GUI::DC ($W); $dib->StretchToDC($dc, 10, 10, $width - 20, $height - 20); $dibalpha->CopyToDC($dc); $dibalpha->AlphaCopyToDC($dc, 200); $dibalpha->AlphaStretchToDC($dc, 0, 200, 260, 200 ); } --- NEW FILE: info.pl --- #perl -w use Win32::GUI::DIBitmap; print Win32::GUI::DIBitmap::GetVersion(), "\n"; print Win32::GUI::DIBitmap::GetCopyright(), "\n"; $count = Win32::GUI::DIBitmap::GetFIFCount(); print "Format\tReading\tWriting\tDescription\n"; for ($fif = 0; $fif < $count; $fif++) { $format = Win32::GUI::DIBitmap::GetFormatFromFIF($fif); $desc = Win32::GUI::DIBitmap::FIFDescription($fif); $read = "N"; $read = "Y" if (Win32::GUI::DIBitmap::FIFSupportsReading($fif)); $write = "N"; $write = "Y" if (Win32::GUI::DIBitmap::FIFSupportsWriting($fif)); $export = ""; $export .= " 1" if (Win32::GUI::DIBitmap::FIFSupportsExportBPP($fif, 1)); $export .= " 4" if (Win32::GUI::DIBitmap::FIFSupportsExportBPP($fif, 4)); $export .= " 8" if (Win32::GUI::DIBitmap::FIFSupportsExportBPP($fif, 8)); $export .= " 16" if (Win32::GUI::DIBitmap::FIFSupportsExportBPP($fif, 16)); $export .= " 24" if (Win32::GUI::DIBitmap::FIFSupportsExportBPP($fif, 24)); $export .= " 32" if (Win32::GUI::DIBitmap::FIFSupportsExportBPP($fif, 32)); $export = " [Export =$export]" unless ($export eq ""); print "$format\t$read\t$write\t$desc$export\n"; } --- NEW FILE: test4.pl --- #perl -w # # Test with Win32::GUI # # Functions Test : #- newFromFile #- ConvertToBitmap use Win32::GUI; use Win32::GUI::DIBitmap; $W = new Win32::GUI::Window ( -title=> "Win32::GUI::DIBitmap test", -left => 100, -top => 100, -width=> 400, -height => 400, -name => "Window", ) or die "new Window"; ($width, $height) = ($W->GetClientRect)[2..3]; $dib = newFromFile Win32::GUI::DIBitmap ("bmp/zapotec.jpg") or die "Load zapotec.jpg"; $hbitmap = $dib->ConvertToBitmap(); undef $dib; # $hbitmap = new Win32::GUI::Bitmap('bmp/zapotec.bmp') or die ("new Bitmap"); $BITMAP = $W->AddLabel ( -pos => [0 , 0], -size=> [$width, $height], -bitmap => $hbitmap, -name=> "Bitmap", -visible => 1, ); $BITMAP->SetImage ($hbitmap); $W->Show(); Win32::GUI::Dialog(); sub Window_Resize { $W->Bitmap->Resize($W->ScaleWidth, $W->ScaleHeight); } sub Window_Terminate { $W->PostQuitMessage(0); } --- NEW FILE: test1.pl --- #perl -w # # Test standalone : # # Functions Test : #- GetVersion #- GetCopyright #- GetFIFCount #- GetFormatFromFIF #- GetFIFFromFormat #- FIFExtensionList #- FIFDescription #- FIFRegExpr #- FIFSupportsWriting #- FIFSupportsReading #- new #- SaveToFile use Win32::GUI::DIBitmap; print Win32::GUI::DIBitmap::GetVersion(), "\n"; print Win32::GUI::DIBitmap::GetCopyright(), "\n"; $count = Win32::GUI::DIBitmap::GetFIFCount(); print "count = $count\n"; for ($i = 0; $i < $count; $i++) { $format = Win32::GUI::DIBitmap::GetFormatFromFIF($i); $fif = Win32::GUI::DIBitmap::GetFIFFromFormat($format); $ext = Win32::GUI::DIBitmap::FIFExtensionList($fif); $desc = Win32::GUI::DIBitmap::FIFDescription($fif); $reg = Win32::GUI::DIBitmap::FIFRegExpr($fif); $read = Win32::GUI::DIBitmap::FIFSupportsReading($fif); $write = Win32::GUI::DIBitmap::FIFSupportsWriting($fif); print "$i : Format = $format FIF = $fif Extention = $ext Description = $desc RegExp = $reg Reading = $read Writing = $write\n"; } $dib = new Win32::GUI::DIBitmap (100,100,24,255,255,255); for ($i = 0; $i < $count; $i++) { ($ext, $misc) = split /,/