Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

5
LINES

< > BotCompany Repo | #1023956 // resizeImageOnServer_jpeg [creates new JPEG on server, returns URL]

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (5089L/35K).

sS resizeImageOnServer_jpeg(S imageID, int newW) {
  BufferedImage img = resizeImage(loadImage2(imageID), newW);
  S title = getSnippetTitle(imageID) + " [" + img.getWidth() + "*" + img.getHeight() + "]";
  ret uploadJPEGToImageServer(title, img);
}

Author comment

Began life as a copy of #1004226

download  show line numbers  debug dex  old transpilations   

Travelled to 8 computer(s): bhatertpkbcr, mowyntqkapby, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv

No comments. add comment

Snippet ID: #1023956
Snippet name: resizeImageOnServer_jpeg [creates new JPEG on server, returns URL]
Eternal ID of this version: #1023956/4
Text MD5: 9c00270a6182e78c07b0d92bd27d7dd4
Transpilation MD5: 9a91cfe14c4c19d927fbbe51bb4f0a38
Author: stefan
Category: javax / imaging
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2019-07-14 11:27:09
Source code size: 253 bytes / 5 lines
Pitched / IR pitched: No / No
Views / Downloads: 228 / 326
Version history: 3 change(s)
Referenced in: #1006654 - Standard functions list 2 (LIVE, continuation of #761)
#1024313 - resizeImageOnServer_percent_jpeg [creates new JPEG on server, returns URL]
#1027540 - resizeImageOnServer_png [creates new PNG on server, preserves transparency, returns URL]