Fri Feb 18 15:48:52 2011: Request 65881 was acted upon.
Transaction: Correspondence added by [email protected]
Queue: Wx
Subject: Re: [rt.cpan.org #65881] Export wxMemory{In,Out}putStream
Broken in: 0.98
Severity: Wishlist
Owner: Nobody
Requestors: [email protected]
Status: new
Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=65881 >
Hi,
Untested, but you may like to give the following a try
my $jpegdata = <rawjepgdata>
open my $file, '<', \$jpegdata;
my $handler = Wx::JPEGHandler->new();
my $image = Wx::Image->new();
$handler->LoadFile( $image, $file );
Mark
On 18/02/2011 19:36, Olivier 'dolmen' Mengué via RT wrote:
> Fri Feb 18 14:36:15 2011: Request 65881 was acted upon.
> Transaction: Ticket created by DOLMEN
> Queue: Wx
> Subject: Export wxMemory{In,Out}putStream
> Broken in: 0.98
> Severity: Wishlist
> Owner: Nobody
> Requestors: [email protected]
> Status: new
> Ticket<URL: https://rt.cpan.org/Ticket/Display.html?id=65881>
>
>
> wxMemoryInputStream seems to be the missing piece to be able to build a
> Wx::Image from JPEG data contained in a memory buffer.
>
>
> Use case:
> I need this to build an photo managing application. I'm extracting the
> thumbnail data from the JPEG files using Image::ExifTool. The thumbnail
> data itself is encoded as a JPEG.
> This could also be used to display images loaded from file using other
> Perl libraries instead of the wxWidgets libraries.
>
> --
> Olivier Mengué - http://search.cpan.org/~dolmen/ http://github.com/dolmen/