Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much

Re^2: Images from - Android

by clanrbr (Novice)
on Dec 18, 2012 at 12:46 UTC ( #1009357=note: print w/replies, xml ) Need Help??

in reply to Re: Images from - Android
in thread Images from - Android

This app is posting the image to perl script.
my $req = new CGI; $contentpic=$req->param("pic") if ($req->param("pic") ); if ( open ( PICTF,">somepath/image.jpeg" ) ) { binmode PICTF; print PICTF $contentpic; close (PICTF); my ($x, $y, $info) = imgsize("somepath/image.jpeg"); $info=lc($info); $info=~s/jpg/jpeg/; if ( $info eq "jpeg" ) { my $logo=Imager->new(); $logo->read(file =>"somepath/mylogo.png", type => 'png'); my $imgorg=Imager->new(); $imgorg->read(file => "somepath/image.jpeg", type => $info); my $img=$imgorg->scale(xpixels=>280); my ($tx,$ty)=((280-$logosize[0]-$logooffs),(int(280*$y/$x)-$log +osize[1]-$logooffs)); $img->rubthrough( src=>$logo, tx=>$tx,ty=>$ty ); $img->write(file => "somepath/image.jpeg", type => $info); $result=1; }

Replies are listed 'Best First'.
Re^3: Images from - Android
by BrowserUk (Pope) on Dec 18, 2012 at 13:20 UTC
    This app is posting the image to perl script.

    You're missing the point. Where and how do you obtain the data held in $contentpic?

    With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.

    RIP Neil Armstrong

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1009357]
[LanX]: well try to find my profile xD
[marto]: derp
[marto]: I've never had an account, and wouldn't visit the site
LanX having only a fake profile is hard if a flirt asks to befriend you
[erix]: "surveillance companies" have been rebranded as "social media"
[LanX]: I'm using whatapp though :-/
[LanX]: Snowden remins me of Evan Spiegel (... start of a new conspiracy theory)
[LanX]: yes! The same person!
[Eily]: LanX can't be, they're both on the picture at the same time. Duh

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (10)
As of 2018-03-19 15:30 GMT
Find Nodes?
    Voting Booth?
    When I think of a mole I think of:

    Results (240 votes). Check out past polls.