Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery

Re: TK Photo Cam - Memory Leak

by Anonymous Monk
on Jul 15, 2002 at 22:26 UTC ( #181949=note: print w/ replies, xml ) Need Help??

in reply to TK Photo Cam - Memory Leak

Owell, I found the answer to my question. I guess I should'nt have rushed to post the question. To anyone else interested the following fixes the problem. Im still looking for an answer (or some hints) on the second part of my initial question.

sub update_image { my $data = encode_base64( get($CAM_URL) ); $buttonImage->configure(-data => $data, -format => 'jpeg'); $TT->configure(-image => $buttonImage); $mw->after( $UPDATE_INTERVAL,[\&update_image]); };

Comment on Re: TK Photo Cam - Memory Leak
Download Code
Re: Re: TK Photo Cam - Memory Leak
by ichimunki (Priest) on Jul 16, 2002 at 18:23 UTC
    You might try the Tk::Photo attribute '-subsample', to get the image to reduce by literally removing every x pixel from the image. You might also use ImageMagick (which has perl modules available and works on both Windows and Linux/Unix) to resize the image (I'm not sure if there is a way to use ImageMagick on data in memory, I've only ever used it on files).

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://181949]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (9)
As of 2015-07-07 02:31 GMT
Find Nodes?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...

    Results (86 votes), past polls