Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number

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]); };

Replies are listed 'Best First'.
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 all is quiet...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (5)
As of 2018-06-21 11:27 GMT
Find Nodes?
    Voting Booth?
    Should cpanminus be part of the standard Perl release?

    Results (118 votes). Check out past polls.